dom.pattern.Sequence Extends goog.dom.pattern.AbstractPattern
Pattern object that matches a sequence of other patterns.

Inheritance

Constructor

goog.dom.pattern.Sequence(patternsopt_ignoreWhitespace)

Parameters

patterns : Array.<goog.dom.pattern.AbstractPattern>
Ordered array of patterns to match.
opt_ignoreWhitespace : boolean=
Optional flag to ignore text nodes consisting entirely of whitespace. The default is to not ignore them.

Instance Methods

Public Protected Private
matchToken(tokentype) goog.dom.pattern.MatchType
Test whether the given token starts, continues, or finishes the sequence of patterns given in the constructor.
Arguments:
token : Node
Token to match against.
type : goog.dom.TagWalkType
The type of token.
Returns: goog.dom.pattern.MatchType  MATCH if the pattern matches, MATCHING if the pattern starts a match, and NO_MATCH if the pattern does not match.
code »
reset()
Reset any internal state this pattern keeps.
code »
matchToken(tokentype) goog.dom.pattern.MatchType
Test whether this pattern matches the given token.
Arguments:
token : Node
Token to match against.
type : goog.dom.TagWalkType
The type of token.
Returns: goog.dom.pattern.MatchType  MATCH if the pattern matches.
code »
reset()
Reset any internal state this pattern keeps.
code »

Instance Properties

constructor :
No description.
Code »
currentPosition_ :
Position in the patterns array we have reached by successful matches.
Code »
ignoreWhitespace_ :
Whether or not to ignore whitespace only Text nodes.
Code »
patterns :
Ordered array of patterns to match.
Code »
matchedNode :
The first node matched by this pattern.
Code »

Static Properties

goog.dom.pattern.Sequence.superClass_ :
No description.
Code »

Package dom.pattern

Package Reference