Match

public class Match

Represents the matches.

  • The string.

    Declaration

    Swift

    public private(set) var string: String { get }
  • The NSTextCheckingResult object.

    Declaration

    Swift

    public private(set) var checkResult: NSTextCheckingResult { get }
  • The position of the matching range.

    Declaration

    Swift

    public var position: Int { get }
  • The end position of the matching range,

    Declaration

    Swift

    public var endPosition: Int { get }
  • The match groups.

    Declaration

    Swift

    public func groups() -> [String]

    Return Value

    An array of string.

  • Returns the string at the given index.

    Declaration

    Swift

    public func group(at index: Int) -> String?

    Parameters

    index

    The index.

    Return Value

    The string.