Package io.sf.carte.doc.style.css.parser
Class SyntaxParser
java.lang.Object
io.sf.carte.doc.style.css.parser.SyntaxParser
Parses a syntax specification according to
CSS Properties
and Values API Level 1 (accepts additional types like
<string>
).-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic CSSValueSyntax
createSimpleSyntax
(String category) Create a single-component syntax without multipliers.parseSyntax
(String def) Parse a syntax definition.
-
Constructor Details
-
SyntaxParser
public SyntaxParser()
-
-
Method Details
-
createSimpleSyntax
Create a single-component syntax without multipliers.- Parameters:
category
- the category name (url
,string
,image
, etc).- Returns:
- the single-component syntax, or
null
if the category name was not recognized.
-
parseSyntax
Parse a syntax definition.- Parameters:
def
- the syntax definition.- Returns:
- the object representing the syntax.
- Throws:
CSSException
- if the definition was not valid.
-