CFURLCopyNetLocation(_:)
Returns the net location portion of a given URL.
Declaration
func CFURLCopyNetLocation(_ anURL: CFURL!) -> CFString!Parameters
- anURL:
The
CFURLobject to examine.
Return Value
The net location of anURL, or NULL if the URL cannot be decomposed (doesn’t conform to RFC 1808). Ownership follows the create rule. See The Create Rule.
Discussion
The URL net location is the portion of the URL that identifies the network address of the resource. It includes the optional username and password, as well as the target machine’s IP address or host name.
This function leaves any percent escape sequences intact.
See Also
Accessing the Parts of a URL
CFURLCanBeDecomposed(_:)CFURLCopyFileSystemPath(_:_:)CFURLCopyFragment(_:_:)CFURLCopyHostName(_:)CFURLCopyLastPathComponent(_:)CFURLCopyParameterString(_:_:)CFURLCopyPassword(_:)CFURLCopyPath(_:)CFURLCopyPathExtension(_:)CFURLCopyQueryString(_:_:)CFURLCopyResourceSpecifier(_:)CFURLCopyScheme(_:)CFURLCopyStrictPath(_:_:)CFURLCopyUserName(_:)CFURLGetPortNumber(_:)