|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectfreemarker.ext.beans2.BeanWrapper<T>
freemarker.ext.beans2.EnumerationWrapper<T>
public class EnumerationWrapper<T extends java.util.Enumeration>
Wraps an Enumeration object as an Iterator model. Also provides support for any additional methods provided by the enumeration.
| Field Summary |
|---|
| Fields inherited from class freemarker.ext.beans2.BeanWrapper |
|---|
emptyParams, object |
| Constructor Summary | |
|---|---|
EnumerationWrapper()
Default constructor where an object is not provided initially. |
|
EnumerationWrapper(T enumeration)
Constructor that takes an Enumeration object to be wrapped. |
|
| Method Summary | |
|---|---|
boolean |
hasNext()
Do we have another item in the list? |
boolean |
isEmpty()
Is the object empty? |
TemplateModel |
next()
Retrieve the next item in the list. |
| Methods inherited from class freemarker.ext.beans2.BeanWrapper |
|---|
clone, get, getAsObject, getAsString, put, setObject |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EnumerationWrapper()
public EnumerationWrapper(T enumeration)
enumeration - the enumeration object to be wrapped| Method Detail |
|---|
public boolean isEmpty()
throws TemplateModelException
isEmpty in interface TemplateModelisEmpty in class BeanWrapper<T extends java.util.Enumeration>true if this object is empty, otherwise false
TemplateModelException
public boolean hasNext()
throws TemplateModelException
hasNext in interface TemplateIteratorModeltrue if there are more items to be iterated over,
otherwise false
TemplateModelException - there was a problem determining the
next item in the list
public TemplateModel next()
throws TemplateModelException
TemplateModel
containing the underlying value.
next in interface TemplateIteratorModelTemplateModelException - the next item couldn't be retrieved,
or we're at the end of the list
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||