Package org.adempiere.webui.component
Class SimpleListModel
- java.lang.Object
-
- org.zkoss.zul.AbstractListModel<Object>
-
- org.adempiere.webui.component.SimpleListModel
-
- All Implemented Interfaces:
Serializable
,org.zkoss.zul.ext.Pageable
,org.zkoss.zul.ext.Selectable<Object>
,org.zkoss.zul.ext.Sortable<Object>
,org.zkoss.zul.ListitemRenderer<Object>
,org.zkoss.zul.ListitemRendererExt
,org.zkoss.zul.ListModel<Object>
,org.zkoss.zul.PageableModel
public class SimpleListModel extends org.zkoss.zul.AbstractListModel<Object> implements org.zkoss.zul.ListitemRenderer<Object>, org.zkoss.zul.ListitemRendererExt, org.zkoss.zul.ext.Sortable<Object>
- Author:
- Low Heng Sin
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.zkoss.zul.AbstractListModel
org.zkoss.zul.AbstractListModel.DefaultSelectionControl<E extends Object>
-
-
Constructor Summary
Constructors Constructor Description SimpleListModel()
SimpleListModel(List<?> list)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(int index, Object obj)
void
addElement(Object obj)
int
getControls()
Object
getElementAt(int index)
int
getSize()
String
getSortDirection(Comparator<Object> cmpr)
int
indexOf(Object value)
org.zkoss.zul.Listcell
newListcell(org.zkoss.zul.Listitem item)
org.zkoss.zul.Listitem
newListitem(org.zkoss.zul.Listbox listbox)
void
removeAllElements()
void
removeElement(Object element)
void
render(org.zkoss.zul.Listitem item, Object data, int index)
protected void
renderCell(int col, org.zkoss.zul.Listitem item, String value)
void
setElementAt(Object element, int index)
void
setMaxLength(int[] maxLength)
void
sort(Comparator<Object> cmpr, boolean ascending)
protected StringBuffer
truncate(String src, int maxLength)
-
Methods inherited from class org.zkoss.zul.AbstractListModel
addListDataListener, addPagingEventListener, addToSelection, clearSelection, clone, fireEvent, fireSelectionEvent, getActivePage, getPageCount, getPageSize, getSelection, getSelectionControl, isMultiple, isSelected, isSelectionEmpty, newEmptySelection, readSelection, removeAllSelection, removeFromSelection, removeListDataListener, removePagingEventListener, retainAllSelection, setActivePage, setMultiple, setPageSize, setSelection, setSelectionControl, writeSelection
-
-
-
-
Constructor Detail
-
SimpleListModel
public SimpleListModel()
-
SimpleListModel
public SimpleListModel(List<?> list)
-
-
Method Detail
-
getElementAt
public Object getElementAt(int index)
- Specified by:
getElementAt
in interfaceorg.zkoss.zul.ListModel<Object>
-
getSize
public int getSize()
- Specified by:
getSize
in interfaceorg.zkoss.zul.ListModel<Object>
-
truncate
protected StringBuffer truncate(String src, int maxLength)
-
renderCell
protected void renderCell(int col, org.zkoss.zul.Listitem item, String value)
-
getControls
public int getControls()
- Specified by:
getControls
in interfaceorg.zkoss.zul.ListitemRendererExt
-
newListcell
public org.zkoss.zul.Listcell newListcell(org.zkoss.zul.Listitem item)
- Specified by:
newListcell
in interfaceorg.zkoss.zul.ListitemRendererExt
-
newListitem
public org.zkoss.zul.Listitem newListitem(org.zkoss.zul.Listbox listbox)
- Specified by:
newListitem
in interfaceorg.zkoss.zul.ListitemRendererExt
-
setMaxLength
public void setMaxLength(int[] maxLength)
-
addElement
public void addElement(Object obj)
-
add
public void add(int index, Object obj)
-
removeAllElements
public void removeAllElements()
-
removeElement
public void removeElement(Object element)
-
setElementAt
public void setElementAt(Object element, int index)
-
indexOf
public int indexOf(Object value)
-
sort
public void sort(Comparator<Object> cmpr, boolean ascending)
- Specified by:
sort
in interfaceorg.zkoss.zul.ext.Sortable<Object>
-
getSortDirection
public String getSortDirection(Comparator<Object> cmpr)
- Specified by:
getSortDirection
in interfaceorg.zkoss.zul.ext.Sortable<Object>
-
-