Class: Scrubyt::CompoundExampleLookup
- Inherits:
-
Object
- Object
- Scrubyt::CompoundExampleLookup
- Defined in:
- lib/scrubyt/utils/compound_example_lookup.rb
Overview
Lookup of compund examples
There are two types of string examples in scRUBYt! right now: the simple example and the compound example.
This class is responsible for finding elements matched by compound examples. In the futre probably more sophisticated matching algorithms will be added (e.g. match the n-th which matches the text, or element that matches the text but also contains a specific attribute etc.)
Class Method Summary collapse
Class Method Details
.find_node_from_compund_example(doc, compound_example, next_link = false, index = 0) ⇒ Object
11 12 13 14 |
# File 'lib/scrubyt/utils/compound_example_lookup.rb', line 11 def self.find_node_from_compund_example(doc, compound_example, next_link=false, index = 0) @partial_results = [] self.lookup_compound_example(doc, compound_example, index) end |