Atomic zero width assertion

xiaoxiao2021-03-06  20

The metadature described in the table below does not cause the engine to advance or use characters in a string. They only make the match success or fail based on the current position in the string. For example, ^ specifies the current position at the beginning of the row or string. Therefore, the regular expression ^ ftp will only return the match item of the string "FTP" that appears at the beginning of the row.

As a result, the specified match must appear on the beginning or row of the string. For more information, see the Multiline option in the regular expression option. $ Specify match must appear in the following location: The string ends, the end of the string / N before the end of the end. For more information, see the Multiline option in the regular expression option. / A Specifies that the match must appear on the beginning of the string (ignore the multiline option). / Z Specifies that the match must appear before / n at the end of the string or the end of the string (Ignore the Multiline option). / z Specifies that the match must appear on the end of the string (ignore the multiline option). / G Specify the match must appear on the previous match. This assertion ensures that all matches are continuous when used with match.nextmatch (). / b Specify match must appear on the boundary between / w (alphanumeric) and / w (non-alphanumeric) characters. The match must appear on the word boundary, that is, the first or last character in the word separated by any non-alphanumeric character. / B Specify matching must not appear on the / B boundary.

See

Regular Expression Language Element | Regular Expression Options

转载请注明原文地址:https://www.9cbs.com/read-42768.html

New Post(0)