freemarker.template

Interface TemplateBooleanModel

All Superinterfaces:
TemplateModel
Known Implementing Classes:
BooleanModel, JythonHashModel, JythonModel, JythonNumberModel, JythonSequenceModel

public interface TemplateBooleanModel
extends TemplateModel

Objects that will be interpreted as true/false in the appropriate context must implement this interface.
Version:
$Id: TemplateBooleanModel.java,v 1.8 2003/01/12 23:40:21 revusky Exp $

Field Summary

static TemplateBooleanModel
FALSE
A singleton object to represent boolean false
static TemplateBooleanModel
TRUE
A singleton object to represent boolean true

Fields inherited from interface freemarker.template.TemplateModel

NOTHING

Method Summary

boolean
getAsBoolean()

Field Details

FALSE

public static final TemplateBooleanModel FALSE
A singleton object to represent boolean false

TRUE

public static final TemplateBooleanModel TRUE
A singleton object to represent boolean true

Method Details

getAsBoolean

public boolean getAsBoolean()
            throws TemplateModelException
Returns:
whether to interpret this object as true or false in a boolean context