public class ExtendedParserWrapper extends Object implements ExtendedParser
ExtendedParser
interface by wrapping a standard Parser.| Modifier and Type | Field and Description |
|---|---|
org.w3c.css.sac.Parser |
parser |
| Constructor and Description |
|---|
ExtendedParserWrapper(org.w3c.css.sac.Parser parser) |
| Modifier and Type | Method and Description |
|---|---|
String |
getParserVersion()
SAC: Implements
Parser.getParserVersion(). |
org.w3c.css.sac.SACMediaList |
parseMedia(String mediaText)
Implements
ExtendedParser.parseMedia(String). |
boolean |
parsePriority(org.w3c.css.sac.InputSource source)
SAC: Implements
Parser.parsePriority(InputSource). |
boolean |
parsePriority(String source)
Parse a CSS priority value (e.g. "!important").
|
org.w3c.css.sac.LexicalUnit |
parsePropertyValue(org.w3c.css.sac.InputSource source)
SAC: Implements
Parser.parsePropertyValue(InputSource). |
org.w3c.css.sac.LexicalUnit |
parsePropertyValue(String source)
Parse a CSS property value.
|
void |
parseRule(org.w3c.css.sac.InputSource source)
SAC: Implements
Parser.parseRule(InputSource). |
void |
parseRule(String source)
Parse a CSS rule.
|
org.w3c.css.sac.SelectorList |
parseSelectors(org.w3c.css.sac.InputSource source)
SAC: Implements
Parser.parseSelectors(InputSource). |
org.w3c.css.sac.SelectorList |
parseSelectors(String source)
Parse a comma separated list of selectors.
|
void |
parseStyleDeclaration(org.w3c.css.sac.InputSource source)
SAC: Implements
Parser.parseStyleDeclaration(InputSource). |
void |
parseStyleDeclaration(String source)
Parse a CSS style declaration (without '{' and '}').
|
void |
parseStyleSheet(org.w3c.css.sac.InputSource source)
SAC: Implements
Parser.parseStyleSheet(InputSource). |
void |
parseStyleSheet(String uri)
Parse a CSS document from a URI.
|
void |
setConditionFactory(org.w3c.css.sac.ConditionFactory conditionFactory)
SAC: Implements
Parser.setConditionFactory(ConditionFactory). |
void |
setDocumentHandler(org.w3c.css.sac.DocumentHandler handler)
SAC: Implements
Parser.setDocumentHandler(DocumentHandler). |
void |
setErrorHandler(org.w3c.css.sac.ErrorHandler handler)
SAC: Implements
Parser.setErrorHandler(ErrorHandler). |
void |
setLocale(Locale locale)
SAC: Implements
Parser.setLocale(Locale). |
void |
setSelectorFactory(org.w3c.css.sac.SelectorFactory selectorFactory)
SAC: Implements
Parser.setSelectorFactory(SelectorFactory). |
static ExtendedParser |
wrap(org.w3c.css.sac.Parser p)
This converts a standard @link org.w3c.css.sac.Parser into
an Extended Parser.
|
public ExtendedParserWrapper(org.w3c.css.sac.Parser parser)
public static ExtendedParser wrap(org.w3c.css.sac.Parser p)
p - Parser to wrap.public String getParserVersion()
Parser.getParserVersion().getParserVersion in interface org.w3c.css.sac.Parserpublic void setLocale(Locale locale) throws org.w3c.css.sac.CSSException
Parser.setLocale(Locale).setLocale in interface org.w3c.css.sac.Parserorg.w3c.css.sac.CSSExceptionpublic void setDocumentHandler(org.w3c.css.sac.DocumentHandler handler)
Parser.setDocumentHandler(DocumentHandler).setDocumentHandler in interface org.w3c.css.sac.Parserpublic void setSelectorFactory(org.w3c.css.sac.SelectorFactory selectorFactory)
Parser.setSelectorFactory(SelectorFactory).setSelectorFactory in interface org.w3c.css.sac.Parserpublic void setConditionFactory(org.w3c.css.sac.ConditionFactory conditionFactory)
Parser.setConditionFactory(ConditionFactory).setConditionFactory in interface org.w3c.css.sac.Parserpublic void setErrorHandler(org.w3c.css.sac.ErrorHandler handler)
Parser.setErrorHandler(ErrorHandler).setErrorHandler in interface org.w3c.css.sac.Parserpublic void parseStyleSheet(org.w3c.css.sac.InputSource source)
throws org.w3c.css.sac.CSSException,
IOException
Parser.parseStyleSheet(InputSource).parseStyleSheet in interface org.w3c.css.sac.Parserorg.w3c.css.sac.CSSExceptionIOExceptionpublic void parseStyleSheet(String uri) throws org.w3c.css.sac.CSSException, IOException
This method is a shortcut for the common case of reading a document from a URI. It is the exact equivalent of the following:
parse(new InputSource(uri));
The URI must be fully resolved by the application before it is passed to the parser.
parseStyleSheet in interface org.w3c.css.sac.Parseruri - The URI.org.w3c.css.sac.CSSException - Any CSS exception, possibly
wrapping another exception.IOException - An IO exception from the parser,
possibly from a byte stream or character stream
supplied by the application.parseStyleSheet(InputSource)public void parseStyleDeclaration(org.w3c.css.sac.InputSource source)
throws org.w3c.css.sac.CSSException,
IOException
Parser.parseStyleDeclaration(InputSource).parseStyleDeclaration in interface org.w3c.css.sac.Parserorg.w3c.css.sac.CSSExceptionIOExceptionpublic void parseStyleDeclaration(String source) throws org.w3c.css.sac.CSSException, IOException
parseStyleDeclaration in interface ExtendedParsersource - The declaration.org.w3c.css.sac.CSSException - Any CSS exception, possibly
wrapping another exception.IOException - An IO exception from the parser,
possibly from a byte stream or character stream
supplied by the application.public void parseRule(org.w3c.css.sac.InputSource source)
throws org.w3c.css.sac.CSSException,
IOException
Parser.parseRule(InputSource).parseRule in interface org.w3c.css.sac.Parserorg.w3c.css.sac.CSSExceptionIOExceptionpublic void parseRule(String source) throws org.w3c.css.sac.CSSException, IOException
parseRule in interface ExtendedParserorg.w3c.css.sac.CSSException - Any CSS exception, possibly
wrapping another exception.IOException - An IO exception from the parser,
possibly from a byte stream or character stream
supplied by the application.public org.w3c.css.sac.SelectorList parseSelectors(org.w3c.css.sac.InputSource source)
throws org.w3c.css.sac.CSSException,
IOException
Parser.parseSelectors(InputSource).parseSelectors in interface org.w3c.css.sac.Parserorg.w3c.css.sac.CSSExceptionIOExceptionpublic org.w3c.css.sac.SelectorList parseSelectors(String source) throws org.w3c.css.sac.CSSException, IOException
parseSelectors in interface ExtendedParserorg.w3c.css.sac.CSSException - Any CSS exception, possibly
wrapping another exception.IOException - An IO exception from the parser,
possibly from a byte stream or character stream
supplied by the application.public org.w3c.css.sac.LexicalUnit parsePropertyValue(org.w3c.css.sac.InputSource source)
throws org.w3c.css.sac.CSSException,
IOException
Parser.parsePropertyValue(InputSource).parsePropertyValue in interface org.w3c.css.sac.Parserorg.w3c.css.sac.CSSExceptionIOExceptionpublic org.w3c.css.sac.LexicalUnit parsePropertyValue(String source) throws org.w3c.css.sac.CSSException, IOException
parsePropertyValue in interface ExtendedParserorg.w3c.css.sac.CSSException - Any CSS exception, possibly
wrapping another exception.IOException - An IO exception from the parser,
possibly from a byte stream or character stream
supplied by the application.public boolean parsePriority(org.w3c.css.sac.InputSource source)
throws org.w3c.css.sac.CSSException,
IOException
Parser.parsePriority(InputSource).parsePriority in interface org.w3c.css.sac.Parserorg.w3c.css.sac.CSSExceptionIOExceptionpublic org.w3c.css.sac.SACMediaList parseMedia(String mediaText) throws org.w3c.css.sac.CSSException, IOException
ExtendedParser.parseMedia(String).parseMedia in interface ExtendedParserorg.w3c.css.sac.CSSException - Any CSS exception, possibly
wrapping another exception.IOException - An IO exception from the parser,
possibly from a byte stream or character stream
supplied by the application.public boolean parsePriority(String source) throws org.w3c.css.sac.CSSException, IOException
parsePriority in interface ExtendedParserorg.w3c.css.sac.CSSException - Any CSS exception, possibly
wrapping another exception.IOException - An IO exception from the parser,
possibly from a byte stream or character stream
supplied by the application.Copyright © 2000–2024 Apache Software Foundation. All rights reserved.