Package freemarker.ext.beans
Class StringModel
java.lang.Object
freemarker.ext.beans.BeanModel
freemarker.ext.beans.StringModel
- All Implemented Interfaces:
- WrapperTemplateModel,- AdapterTemplateModel,- TemplateHashModel,- TemplateHashModelEx,- TemplateModel,- TemplateModelWithAPISupport,- TemplateScalarModel
- Direct Known Subclasses:
- CollectionModel,- GenericObjectModel,- MapModel
Deprecated.
Subclass of 
BeanModel that exposes the return value of the Object.toString() method through the TemplateScalarModel
 interface.- 
Field SummaryFields inherited from interface freemarker.template.TemplateModelNOTHINGFields inherited from interface freemarker.template.TemplateScalarModelEMPTY_STRING
- 
Constructor SummaryConstructorsConstructorDescriptionStringModel(Object object, BeansWrapper wrapper)Deprecated.Creates a new model that wraps the specified object with BeanModel + scalar functionality.
- 
Method SummaryModifier and TypeMethodDescriptionDeprecated.Returns the result of callingObject.toString()on the wrapped object.Methods inherited from class freemarker.ext.beans.BeanModelget, get, getAdaptedObject, getAPI, getBeforeMethodCall, getWrappedObject, hasPlainGetMethod, invokeGenericGet, isEmpty, keys, keySet, size, toString, unwrap, values, wrap
- 
Constructor Details- 
StringModelDeprecated.Creates a new model that wraps the specified object with BeanModel + scalar functionality.- Parameters:
- object- the object to wrap into a model.
- wrapper- the- BeansWrapperassociated with this model. Every model has to have an associated- BeansWrapperinstance. The model gains many attributes from its wrapper, including the caching behavior, method exposure level, method-over-item shadowing policy etc.
 
 
- 
- 
Method Details- 
getAsStringDeprecated.Returns the result of callingObject.toString()on the wrapped object.- Specified by:
- getAsStringin interface- TemplateScalarModel
 
 
- 
GenericObjectModelinstead, which implementsMethodCallAwareTemplateHashModel.