Class CssFunctionNode
java.lang.Object
com.google.common.css.compiler.ast.CssNode
com.google.common.css.compiler.ast.CssValueNode
com.google.common.css.compiler.ast.CssFunctionNode
- All Implemented Interfaces:
ChunkAware,Locatable
- Direct Known Subclasses:
CssCustomFunctionNode
A node representing a function.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classContains the list of recognized CSS functions. -
Constructor Summary
ConstructorsModifierConstructorDescriptionCssFunctionNode(CssFunctionNode function) Copy constructor.CssFunctionNode(CssFunctionNode.Function function, SourceCodeLocation sourceCodeLocation) Constructor of the class.protectedCssFunctionNode(SourceCodeLocation sourceCodeLocation, CssFunctionNode.Function function) Constructor used by the proxy mechanism, avoids unnecessary arguments node initialization. -
Method Summary
Modifier and TypeMethodDescriptiondeepCopy()getChunk()Gets the chunk id of the node.getValue()Print the node instead of null when this node is a parameter.voidsetArguments(CssFunctionArgumentsNode arguments) voidSets the chunk id on the node.toString()Use for debugging only.Methods inherited from class com.google.common.css.compiler.ast.CssValueNode
getIsDefault, setIsDefault, setValueMethods inherited from class com.google.common.css.compiler.ast.CssNode
ancestors, appendComment, deepCopyNodes, equals, getComments, getParent, getShouldBeFlipped, getSourceCodeLocation, getVisitController, hasComment, hashCode, inFunArgs, setComments, setShouldBeFlipped, setSourceCodeLocation
-
Constructor Details
-
CssFunctionNode
public CssFunctionNode(@Nullable CssFunctionNode.Function function, @Nullable SourceCodeLocation sourceCodeLocation) Constructor of the class.TODO(oana): Deal with the situation that we have an unrecognized function.
- Parameters:
function- functionsourceCodeLocation- sourceCodeLocation
-
CssFunctionNode
Copy constructor.- Parameters:
function- function
-
CssFunctionNode
protected CssFunctionNode(@Nullable SourceCodeLocation sourceCodeLocation, @Nullable CssFunctionNode.Function function) Constructor used by the proxy mechanism, avoids unnecessary arguments node initialization.NOTE(dgajda): The signature of this constructor only differs in argument order from the main constructor of this class.
- Parameters:
function- implementation of the function which is "called" by this nodesourceCodeLocation- location of this node
-
-
Method Details
-
deepCopy
- Specified by:
deepCopyin classCssValueNode
-
getFunction
-
getFunctionName
-
getArguments
-
setArguments
-
toString
Description copied from class:CssValueNodeUse for debugging only.- Overrides:
toStringin classCssValueNode- See Also:
-
getChunk
Description copied from interface:ChunkAwareGets the chunk id of the node.- Specified by:
getChunkin interfaceChunkAware- Returns:
- the chunk id or
nullif no chunk id was previously set
-
setChunk
Description copied from interface:ChunkAwareSets the chunk id on the node.- Specified by:
setChunkin interfaceChunkAware- Parameters:
chunk- an object identifying a chunk
-
getValue
Print the node instead of null when this node is a parameter.- Overrides:
getValuein classCssValueNode
-