Package com.yahoo.config.codegen
Class LeafCNode
java.lang.Object
com.yahoo.config.codegen.CNode
com.yahoo.config.codegen.LeafCNode
- Direct Known Subclasses:
LeafCNode.EnumLeaf,LeafCNode.NoClassLeafCNode,LeafCNode.NoClassNoDefaultLeafCNode
- Author:
- gjoranv
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classstatic classstatic classstatic classstatic classstatic classstatic classSuperclass for leaf nodes that should not generate class.static classSuperclass for no-class leaf nodes that cannot have a default.static classstatic classstatic classstatic class -
Field Summary
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedLeafCNode(InnerCNode parent, String name) Constructor for the leaf nodes -
Method Summary
Modifier and TypeMethodDescriptionvoidcheckDefaultValue(DefaultValue defaultValue) CNode[]abstract StringgetType()booleanstatic LeafCNodenewInstance(DefLine.Type type, InnerCNode parent, String name) static LeafCNodenewInstance(DefLine.Type type, InnerCNode parent, String name, String defVal) setDefaultValue(DefaultValue defaultValue) protected voidfinal voidsetValue(DefaultValue defaultValue) Methods inherited from class com.yahoo.config.codegen.CNode
checkMyName, getComment, getCommentBlock, getFullName, getMd5, getName, getNamespace, getPackage, getParent, getVersion, toString
-
Constructor Details
-
LeafCNode
Constructor for the leaf nodes
-
-
Method Details
-
newInstance
-
newInstance
public static LeafCNode newInstance(DefLine.Type type, InnerCNode parent, String name, String defVal) -
getType
-
getChildren
- Specified by:
getChildrenin classCNode
-
getChild
-
getDefaultValue
-
setDefaultValue
-
checkDefaultValue
- Parameters:
defaultValue- the value to check.- Throws:
IllegalArgumentException- if the value is illegal according to the node type.
-
setLeaf
protected void setLeaf(String name, DefLine defLine, String comment) throws IllegalArgumentException - Specified by:
setLeafin classCNode- Throws:
IllegalArgumentException
-
needRestart
public boolean needRestart()- Specified by:
needRestartin classCNode
-
setValue
- Throws:
IllegalArgumentException
-