Package com.itextpdf.tool.xml.css.parser
Class CssStateController
- java.lang.Object
-
- com.itextpdf.tool.xml.css.parser.CssStateController
-
public class CssStateController extends java.lang.ObjectState controller for CSS Processing
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.StringBuilderbufferprivate StatecommentEndprivate StatecommentInsideprivate StatecommentStartprivate CssFilecssprivate Statecurrentprivate java.lang.StringcurrentSelectorprivate Statepreviousprivate Statepropertiesprivate Stateruleprivate Stateunknownprivate CssUtilsutils
-
Constructor Summary
Constructors Constructor Description CssStateController(CssFile file)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidappend(char c)Appends a character to the buffer.voidprevious()Sets the state to the previous statevoidprocess(char c)Processes the character, delegates to states.private voidprocessProps(java.lang.String props)private voidsetPrevious()private voidsetState(State state)voidstateCommentEnd()voidstateCommentInside()voidstateCommentStart()voidstateProperties()voidstateRule()voidstateUnknown()voidstoreProperties()voidstoreSelector()
-
-
-
Field Detail
-
current
private State current
-
previous
private State previous
-
commentEnd
private final State commentEnd
-
commentStart
private final State commentStart
-
commentInside
private final State commentInside
-
buffer
private final java.lang.StringBuilder buffer
-
properties
private final State properties
-
unknown
private final State unknown
-
currentSelector
private java.lang.String currentSelector
-
rule
private final State rule
-
utils
private final CssUtils utils
-
css
private final CssFile css
-
-
Constructor Detail
-
CssStateController
public CssStateController(CssFile file)
- Parameters:
file- the CssFile
-
-
Method Detail
-
append
public void append(char c)
Appends a character to the buffer.- Parameters:
c- the char to append to the buffer.
-
previous
public void previous()
Sets the state to the previous state
-
process
public void process(char c)
Processes the character, delegates to states.- Parameters:
c- a character that needs to be processed
-
processProps
private void processProps(java.lang.String props)
-
setState
private void setState(State state)
-
setPrevious
private void setPrevious()
-
stateCommentEnd
public void stateCommentEnd()
-
stateCommentInside
public void stateCommentInside()
-
stateCommentStart
public void stateCommentStart()
-
stateProperties
public void stateProperties()
-
stateUnknown
public void stateUnknown()
-
stateRule
public void stateRule()
-
storeSelector
public void storeSelector()
-
storeProperties
public void storeProperties()
-
-