C# Regex class with Timeout

Selesai Dipasang Sep 28, 2006 Dibayar saat pengiriman
Selesai Dibayar saat pengiriman

Hi we have an application that lets people provide a regular expression via an textbox and then processes some text using the C# regex class. The problem we have right now is that sometimes users can put in regex that take a long time and the app just hanges. We would as a result like to have a way to let a C# regex timeout.

The deliverable for the project is a class called RegexWT. This class should have the same methods as Regex (and even possibly inherhit from Regex) save for that the worker methods like Match and Replace provide an addition long parameter called "timeout" which allows you to specify a timeout in milliseconds.

In the event that the regex processing goes over the timeout, the call should return.

The usage should be just like Regex:

string regexstr = "[\\s*Mybadregex*;][1]";

RegexWT regexwt = new RegexWT(s, [url removed, login to view] | [url removed, login to view] | [url removed, login to view]);

string temp = "Here is a string to parse";

temp = [url removed, login to view](temp, "", 30000); //times out after 30 seconds

It would seem after some research that the way to accomplish this is to have something wrap regex and run asynch and then if the operation does not complete kill the thread.

This technique is discussed here:

<[url removed, login to view]>

## Deliverables

1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.

2) Deliverables must be in ready-to-run condition, as follows (depending on the nature of the deliverables):

a) For web sites or other server-side deliverables intended to only ever exist in one place in the Buyer's environment--Deliverables must be installed by the Seller in ready-to-run condition in the Buyer's environment.

b) For all others including desktop software or software the buyer intends to distribute: A software installation package that will install the software in ready-to-run condition on the platform(s) specified in this bid request.

3) All deliverables will be considered "work made for hire" under U.S. Copyright law. Buyer will receive exclusive and complete copyrights to all work purchased. (No GPL, GNU, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site per the coder's Seller Legal Agreement).

## Platform

.net 2.0 (vs2005)

windows xp or better

Pemrograman C# Teknik MySQL PHP Perancangan Perangkat Lunak Pengujian Perangkat Lunak

ID Proyek: #3826093

Tentang proyek

6 proposal Proyek online Aktif Sep 28, 2006

Diberikan kepada:

wavemaker

See private message.

$55.25 USD dalam 14 hari
(7 Ulasan)
3.4

6 freelancer rata-rata menawar $61 untuk pekerjaan ini

muskad202

See private message.

$25.5 USD dalam 14 hari
(123 Ulasan)
5.7
tungstensol

See private message.

$58.65 USD dalam 14 hari
(1 Ulasan)
0.8
nikusoftinc

See private message.

$68 USD dalam 14 hari
(0 Ulasan)
0.0
pgcodingvw

See private message.

$85 USD dalam 14 hari
(0 Ulasan)
0.0
vrbitmen

See private message.

$76.5 USD dalam 14 hari
(0 Ulasan)
0.0