url(at:effectiveRange:)
Returns a URL, either from a link attribute or from text at the specified location that appears to be a URL string, for use in automatic link detection.
Declaration
func url(at location: Int, effectiveRange: NSRangePointer) -> URL?Parameters
- location:
The character index in the string at which the method checks for a link.
- effectiveRange:
The actual range covered by the link attribute or URL string, or of non-URL text if no apparent URL is found.
Return Value
The URL found at location.