public abstract class AbstractListModelConverter<C extends Component> extends java.lang.Object implements Converter<java.lang.Object,java.lang.Object,C>, java.io.Serializable
Converter
implementation for converting collection to ListModel and vice versa.IGNORED_VALUE
Constructor and Description |
---|
AbstractListModelConverter() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
coerceToBean(java.lang.Object val,
C comp,
BindContext ctx)
Convert a
ListModel to Set, Map, List, or ListModel (itself). |
java.lang.Object |
coerceToUi(java.lang.Object val,
C comp,
BindContext ctx)
Convert a Set, Map, List, Object[], Enum, or other kind of ListModel to associated
ListModel . |
protected abstract ListModel<?> |
getComponentModel(C comp) |
protected ListModel<?> |
handleWrappedModel(BindContext ctx,
C comp,
ListModel<?> model)
post processing the wrapped model. default return original one
|
protected abstract ListModel<?> getComponentModel(C comp)
comp
- the component that has listmodelprotected ListModel<?> handleWrappedModel(BindContext ctx, C comp, ListModel<?> model)
ctx
- the contextcomp
- the component of the convertermodel
- the wrapped modelpublic java.lang.Object coerceToUi(java.lang.Object val, C comp, BindContext ctx)
ListModel
.coerceToUi
in interface Converter<java.lang.Object,java.lang.Object,C extends Component>
val
- must be instanceof Set, Map, List, Object[], Enum Class, or other kind of ListModel implementation.comp
- associated componentctx
- bind contextpublic java.lang.Object coerceToBean(java.lang.Object val, C comp, BindContext ctx)
ListModel
to Set, Map, List, or ListModel (itself).coerceToBean
in interface Converter<java.lang.Object,java.lang.Object,C extends Component>
val
- must be ListModelSet, ListModelList, ListModelMap, or other kind of ListModelcomp
- associated componentctx
- bind contextCopyright © 2005-2011 Potix Corporation. All Rights Reserved.