阅读背景:

为什么C#编译正则表达式比等效的字符串方法更快?

来源:互联网 

Every time I have to do simple containment or replacement operations on strings, where the term that I'm searching for is a fixed value, I find that if I take my sample input and do some profiling on it, using a compiled regular expression is nearly* always faster than using the equivalent method from the String class. Every time I have to do simple containment or r




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: