|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object freemarker.ext.beans2.BeanWrapper<T> freemarker.ext.beans2.EnumWrapper<T>
public class EnumWrapper<T extends java.lang.Enum>
Wraps an Enum object. Subclasses BeanWrapper to provide an Iterator model for all values of the enum.
Field Summary |
---|
Fields inherited from class freemarker.ext.beans2.BeanWrapper |
---|
emptyParams, object |
Constructor Summary | |
---|---|
EnumWrapper()
Default constructor where an object is not provided initially. |
|
EnumWrapper(T t)
Constructor that takes an enum object to be wrapped. |
Method Summary | |
---|---|
void |
releaseIterator(TemplateIteratorModel iterator)
Returns the used iterator to the list model. |
TemplateIteratorModel |
templateIterator()
Retrieves an iterator to iterate over the elements of the enum. |
Methods inherited from class freemarker.ext.beans2.BeanWrapper |
---|
clone, get, getAsObject, getAsString, isEmpty, put, setObject |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface freemarker.template.TemplateModel |
---|
isEmpty |
Constructor Detail |
---|
public EnumWrapper()
public EnumWrapper(T t)
t
- the enum object to be wrappedMethod Detail |
---|
public TemplateIteratorModel templateIterator() throws TemplateModelException
templateIterator
in interface TemplateListModel2
TemplateModelException
- the next item in the list can't be
retrieved, or no next item exists.public void releaseIterator(TemplateIteratorModel iterator)
Returns the used iterator to the list model.
releaseIterator
in interface TemplateListModel2
iterator
- the iterator to be returned
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |