Page 1 of 1

Questions about how evalid interacts with the DOM

PostPosted: Wed Aug 03, 2016 3:07 pm
by MMorton
Afternoon.

Tell me more about he relative performance of regular expressions used for searching the DOM in eValid?

I have some searches that seem to run quite long?

Why is that?

Re: Questions about how evalid interacts with the DOM

PostPosted: Thu Aug 04, 2016 7:32 am
by eValid
MMorton wrote:Afternoon.

Tell me more about he relative performance of regular expressions used for searching the DOM in eValid?

I have some searches that seem to run quite long?

Why is that?


Good question MMorton.

The answer is: it depends.

It depends on the size of the page you're searching (that is, on the number of DOM elements that have to be examined), and on the complexity of the search.

If you are looking for an exact string match on a small page, you almost can't even notice the time it takes to search.

But if you have a large page (i.e. a large number of DOM elements) and you are asking for a search using a regular expression with a lot of *'s in it (wildcard character searches), then you can expect things to take longer.

Here is a page that shows relative times for typical pages:

http://www.e-valid.com/Products/Documen ... mance.html

The time also depends on where the first match is found.

If it is at the top of the page, the search is quick!

But if it is near the bottom of the page, or if there is NO match, then the entire DOM has to be searched and that will take longer.

-- eValid Support