美文网首页
Sublime-Text3 Find正则表达式

Sublime-Text3 Find正则表达式

作者: lucientlau | 来源:发表于2017-10-12 21:23 被阅读0次

Lookbehind

Match-Find

(?<=abc)d

匹配 abcd中的d,但是不会匹配cebd中的d

(?<=abc) 匹配abc后面的位置即上述例子中abcd中c和d之间的位置。
.(?<=abc)匹配abc中的c

Not Match-Find

(?<!abc)d

不匹配 abcd中的d,但是匹配cebd中的d。

Lookahead

Match-Find

a(?=bcd) 

匹配 abcd中的a,但是不匹配aebd中的a。

(?=bcd) 匹配bcd前面的位置即上述例子中abcd中a和b之间的位置。
(?=abc). 匹配abc中的a

Not Match-Find

a(?!bcd)

不匹配 abcd中的a,但是匹配aebd中的a。

相关文章

网友评论

      本文标题:Sublime-Text3 Find正则表达式

      本文链接:https://www.haomeiwen.com/subject/tkaoyxtx.html