Package org.htmlunit.cssparser.parser
Interface LexicalUnit
- All Known Implementing Classes:
LexicalUnitImpl
public interface LexicalUnit
Lexical unit of css values.
- Author:
- Ronald Brill
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic enum
Enum for the various unit types. -
Method Summary
Modifier and TypeMethodDescriptiongetDimensionUnitText.double
getDoubleValue.getFunctionName.int
getIntegerValue.getLexicalUnitType.getLocator.getNextLexicalUnit.getParameters.getPreviousLexicalUnit.getStringValue.getSubValues.void
setLocator
(Locator locator) setLocator.
-
Method Details
-
getLexicalUnitType
LexicalUnit.LexicalUnitType getLexicalUnitType()getLexicalUnitType.
- Returns:
- an integer indicating the type of
LexicalUnit
.
-
getNextLexicalUnit
LexicalUnit getNextLexicalUnit()getNextLexicalUnit.
- Returns:
- the next value or
null
if any.
-
getPreviousLexicalUnit
LexicalUnit getPreviousLexicalUnit()getPreviousLexicalUnit.
- Returns:
- the previous value or
null
if any.
-
getIntegerValue
int getIntegerValue()getIntegerValue.
- Returns:
- the integer value.
-
getDoubleValue
double getDoubleValue()getDoubleValue.
- Returns:
- the double value.
-
getDimensionUnitText
String getDimensionUnitText()getDimensionUnitText.
- Returns:
- the string representation of the unit.
-
getFunctionName
String getFunctionName()getFunctionName.
- Returns:
- the name of the function.
-
getParameters
LexicalUnit getParameters()getParameters.
- Returns:
- the function parameters including operators (like the comma).
-
getStringValue
String getStringValue()getStringValue.
- Returns:
- the string value.
-
getSubValues
LexicalUnit getSubValues()getSubValues.
- Returns:
- a list of values inside the sub expression.
-
getLocator
Locator getLocator()getLocator.
- Returns:
- the locator
-
setLocator
setLocator.
- Parameters:
locator
- the new locator
-