Class AbstractGssParser
java.lang.Object
com.google.common.css.compiler.ast.AbstractGssParser
- Direct Known Subclasses:
GssParser
Base parser implementation that delegates management of the underlying
JavaCC parser to the subclass. This class does not expose any public
methods; subclasses should expose an appropriate interface.
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract GssParserCCImplementations must return an emptyGssParserCCobject.protected final AbstractGssParser.ParseResultparseInternal(List<SourceCode> sources, boolean errorHandling) Parses a list of GSS sources.
-
Field Details
-
EMPTY_CHAR_STREAM
-
-
Constructor Details
-
AbstractGssParser
public AbstractGssParser()
-
-
Method Details
-
parseInternal
protected final AbstractGssParser.ParseResult parseInternal(List<SourceCode> sources, boolean errorHandling) throws GssParserException Parses a list of GSS sources. Subclasses should use this method to do the actual parsing ofSourceCodeobjects. It will in turn call the subclass's implementation ofgetParser()as necessary.- Parameters:
sources- a list of GSSSourceCodeobjects to parseerrorHandling- if error handling should be enabled. If this isfalse, noGssParserExceptions will be returned in the result.- Returns:
- ParseResult the result containing the
CssTreeand parsing errors - Throws:
GssParserException
-
getParser
Implementations must return an emptyGssParserCCobject. Whether this object is actually new or not isn't important which allows pooling.
-