Package fmpp.models

Class JSONBooleanNode

java.lang.Object
fmpp.models.JSONNode
fmpp.models.JSONBooleanNode
All Implemented Interfaces:
freemarker.template.AdapterTemplateModel, freemarker.template.TemplateBooleanModel, freemarker.template.TemplateModel, freemarker.template.TemplateNodeModel, Serializable

public class JSONBooleanNode extends JSONNode implements freemarker.template.TemplateBooleanModel
JSON "true" and "false" value; see http://www.json.org/.
See Also:
  • Field Details

  • Constructor Details

    • JSONBooleanNode

      public JSONBooleanNode(JSONNode parentNode, String nodeName, boolean value)
  • Method Details

    • getChildNodes

      public freemarker.template.TemplateSequenceModel getChildNodes() throws freemarker.template.TemplateModelException
      Always returns null.
      Specified by:
      getChildNodes in interface freemarker.template.TemplateNodeModel
      Throws:
      freemarker.template.TemplateModelException
    • getNodeType

      public String getNodeType() throws freemarker.template.TemplateModelException
      Returns NODE_TYPE.
      Specified by:
      getNodeType in interface freemarker.template.TemplateNodeModel
      Throws:
      freemarker.template.TemplateModelException
    • getAsBoolean

      public boolean getAsBoolean() throws freemarker.template.TemplateModelException
      Specified by:
      getAsBoolean in interface freemarker.template.TemplateBooleanModel
      Throws:
      freemarker.template.TemplateModelException
    • getDefaultNodeName

      protected String getDefaultNodeName()
      Description copied from class: JSONNode
      Returns the name of the node if it has no explicit name. This is normally called by the JSONNode(JSONNode, String) constructor if its second argument is null.
      Specified by:
      getDefaultNodeName in class JSONNode
      See Also:
    • getAdaptedObject

      public Boolean getAdaptedObject(Class<?> hint)
      Returns the plain Java object wrapped into this node.
      Specified by:
      getAdaptedObject in interface freemarker.template.AdapterTemplateModel
      Since:
      0.9.16