Module com.sun.xml.bind
Class Lister.CollectionLister<BeanT,T extends Collection>
- java.lang.Object
-
- org.glassfish.jaxb.runtime.v2.runtime.reflect.Lister<BeanT,T,Object,T>
-
- org.glassfish.jaxb.runtime.v2.runtime.reflect.Lister.CollectionLister<BeanT,T>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.glassfish.jaxb.runtime.v2.runtime.reflect.Lister
Lister.CollectionLister<BeanT,T extends Collection>, Lister.IDREFSIterator, Lister.Pack<ItemT>
-
-
Constructor Summary
Constructors Constructor Description CollectionLister(Class<? extends T> implClass)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddToPack(T collection, Object o)Once theLister.startPacking(BeanT, org.glassfish.jaxb.runtime.v2.runtime.reflect.Accessor<BeanT, PropT>)is called, you can add values to the pack by using this method.voidendPacking(T collection, BeanT bean, Accessor<BeanT,T> acc)Finally, call this method to wraps up thepack.ListIteratoriterator(T collection, XMLSerializer context)Iterates values of a multi-value property.voidreset(BeanT bean, Accessor<BeanT,T> acc)Clears the values of the property.TstartPacking(BeanT bean, Accessor<BeanT,T> acc)Setting values to a multi-value property starts by creating a transient object called "pack" from the current field.-
Methods inherited from class org.glassfish.jaxb.runtime.v2.runtime.reflect.Lister
create, getErrorInstance
-
-
-
-
Method Detail
-
iterator
public ListIterator iterator(T collection, XMLSerializer context)
Description copied from class:ListerIterates values of a multi-value property.- Specified by:
iteratorin classLister<BeanT,T extends Collection,Object,T extends Collection>context- This parameter is used to support ID/IDREF handling.
-
startPacking
public T startPacking(BeanT bean, Accessor<BeanT,T> acc) throws AccessorException
Description copied from class:ListerSetting values to a multi-value property starts by creating a transient object called "pack" from the current field.- Specified by:
startPackingin classLister<BeanT,T extends Collection,Object,T extends Collection>- Throws:
AccessorException
-
addToPack
public void addToPack(T collection, Object o)
Description copied from class:ListerOnce theLister.startPacking(BeanT, org.glassfish.jaxb.runtime.v2.runtime.reflect.Accessor<BeanT, PropT>)is called, you can add values to the pack by using this method.- Specified by:
addToPackin classLister<BeanT,T extends Collection,Object,T extends Collection>
-
endPacking
public void endPacking(T collection, BeanT bean, Accessor<BeanT,T> acc) throws AccessorException
Description copied from class:ListerFinally, call this method to wraps up thepack. This method may update the field of the given bean.- Specified by:
endPackingin classLister<BeanT,T extends Collection,Object,T extends Collection>- Throws:
AccessorException
-
reset
public void reset(BeanT bean, Accessor<BeanT,T> acc) throws AccessorException
Description copied from class:ListerClears the values of the property.- Specified by:
resetin classLister<BeanT,T extends Collection,Object,T extends Collection>- Throws:
AccessorException
-
-