public class JSONNumberNode extends JSONNode implements TemplateNumberModel
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_NODE_NAME |
static String |
NODE_TYPE |
NOTHING
Constructor and Description |
---|
JSONNumberNode(JSONNode parentNode,
String nodeName,
Number value) |
Modifier and Type | Method and Description |
---|---|
Number |
getAsNumber() |
TemplateSequenceModel |
getChildNodes()
Always returns
null . |
protected String |
getDefaultNodeName()
Returns the name of the node if it has no explicit name.
|
String |
getNodeType()
Returns
NODE_TYPE . |
getNodeName, getNodeNamespace, getParentNode, nodeTypeToDefaultNodeName, wrap, wrap
public static final String NODE_TYPE
public static final String DEFAULT_NODE_NAME
public TemplateSequenceModel getChildNodes() throws TemplateModelException
null
.getChildNodes
in interface TemplateNodeModel
TemplateModelException
public String getNodeType() throws TemplateModelException
NODE_TYPE
.getNodeType
in interface TemplateNodeModel
TemplateModelException
public Number getAsNumber() throws TemplateModelException
getAsNumber
in interface TemplateNumberModel
TemplateModelException
protected String getDefaultNodeName()
JSONNode
JSONNode.JSONNode(JSONNode, String)
constructor if its second argument is null
.getDefaultNodeName
in class JSONNode
JSONNode.nodeTypeToDefaultNodeName(String)