Package com.inet.lib.less
Class Expression
- java.lang.Object
-
- com.inet.lib.less.Expression
-
- Direct Known Subclasses:
JavaScriptExpression
public abstract class Expression extends java.lang.ObjectBase expression with value formating.
-
-
Field Summary
Fields Modifier and Type Field Description static intCOMMENTstatic intCSS_AT_RULEstatic intEXPRESSIONstatic intEXTENDSstatic intMIXINstatic intPROPERTYstatic intREFERENCE_INFOstatic intRULE
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidappendTo(CssFormatter formatter)abstract booleanbooleanValue(CssFormatter formatter)Get the boolean valueabstract doubledoubleValue(CssFormatter formatter)Get the numeric value.abstract intgetDataType(CssFormatter formatter)The data type of the expressionintgetType()com.inet.lib.less.OperationlistValue(CssFormatter formatter)Get the value as a listvoidprepare(CssFormatter formatter)java.lang.StringstringValue(CssFormatter formatter)Get the string valuejava.lang.StringtoString()abstract java.lang.Stringunit(CssFormatter formatter)Get the unit of a NUMBER value.
-
-
-
Field Detail
-
PROPERTY
public static final int PROPERTY
- See Also:
- Constant Field Values
-
RULE
public static final int RULE
- See Also:
- Constant Field Values
-
MIXIN
public static final int MIXIN
- See Also:
- Constant Field Values
-
EXPRESSION
public static final int EXPRESSION
- See Also:
- Constant Field Values
-
COMMENT
public static final int COMMENT
- See Also:
- Constant Field Values
-
CSS_AT_RULE
public static final int CSS_AT_RULE
- See Also:
- Constant Field Values
-
EXTENDS
public static final int EXTENDS
- See Also:
- Constant Field Values
-
REFERENCE_INFO
public static final int REFERENCE_INFO
- See Also:
- Constant Field Values
-
-
Method Detail
-
getType
public final int getType()
-
prepare
public void prepare(CssFormatter formatter)
-
appendTo
public void appendTo(CssFormatter formatter)
-
getDataType
public abstract int getDataType(CssFormatter formatter)
The data type of the expression- Parameters:
formatter- the CCS target- Returns:
- one of the constant
-
doubleValue
public abstract double doubleValue(CssFormatter formatter)
Get the numeric value.- Parameters:
formatter- the CCS target- Returns:
- the value
-
booleanValue
public abstract boolean booleanValue(CssFormatter formatter)
Get the boolean value- Parameters:
formatter- the CCS target- Returns:
- the value
-
stringValue
public java.lang.String stringValue(CssFormatter formatter)
Get the string value- Parameters:
formatter- the CCS target- Returns:
- the value
-
listValue
public com.inet.lib.less.Operation listValue(CssFormatter formatter)
Get the value as a list- Parameters:
formatter- the CCS target- Returns:
- the value
-
unit
public abstract java.lang.String unit(CssFormatter formatter)
Get the unit of a NUMBER value.- Parameters:
formatter- the CCS target- Returns:
- the unit or empty string if nothing
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-