Efficient regular expression pattern ?
- From: "Steve B." <steve_beauge@xxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 14 Jun 2006 14:24:55 +0200
Hi,
I'm building an application that analyse a flow of url in order to detect
some pages.
I've a very huge list of regular expressions (up to several thousands) that
I have to check on all urls.
Each regular expression will be evaluated agains all urls.
How can I write the code in order to be the most efficient ?
My fisrt idea is to create a List<Regex> that I populate once, and each time
an url is incoming, I do a foreach(Regex r in Regexs).
But I'm afraid this process is quite slow since urls can input up to
10/seconds.
I'd apreciate any comments or suggestions.
Thanks,
Steve
.
- Follow-Ups:
- Re: Efficient regular expression pattern ?
- From: Nick Malik [Microsoft]
- Re: Efficient regular expression pattern ?
- From: Barry Kelly
- Re: Efficient regular expression pattern ?
- Prev by Date: Noobie Error?
- Next by Date: Re: Efficient regular expression pattern ?
- Previous by thread: Noobie Error?
- Next by thread: Re: Efficient regular expression pattern ?
- Index(es):
Relevant Pages
|