com.ezware.oxbow.swingbits.list
Class ActionCheckListModel<T>

java.lang.Object
  extended by com.ezware.oxbow.swingbits.list.ActionCheckListModel<T>
All Implemented Interfaces:
ICheckListModel<T>, ListModel

public class ActionCheckListModel<T>
extends Object
implements ICheckListModel<T>


Constructor Summary
ActionCheckListModel(ICheckListModel<T> originalModel)
           
 
Method Summary
 void addListDataListener(ListDataListener l)
           
 void filter(String filter, IObjectToStringTranslator translator, CheckListFilterType filterType)
          Allows filtered view.
 Collection<T> getCheckedItems()
          Returns a collections of checked items
 Object getElementAt(int index)
           
 int getSize()
           
 boolean isCheckedIndex(int index)
          Returns the check state of the element at specified position
 void removeListDataListener(ListDataListener l)
           
 void setCheckedIndex(int index, boolean value)
          Sets the check state of the element at specified position
 void setCheckedItems(Collection<T> items)
          Sets checked items
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActionCheckListModel

public ActionCheckListModel(ICheckListModel<T> originalModel)
Method Detail

getSize

public int getSize()
Specified by:
getSize in interface ListModel

getElementAt

public Object getElementAt(int index)
Specified by:
getElementAt in interface ListModel

addListDataListener

public void addListDataListener(ListDataListener l)
Specified by:
addListDataListener in interface ListModel

removeListDataListener

public void removeListDataListener(ListDataListener l)
Specified by:
removeListDataListener in interface ListModel

isCheckedIndex

public boolean isCheckedIndex(int index)
Description copied from interface: ICheckListModel
Returns the check state of the element at specified position

Specified by:
isCheckedIndex in interface ICheckListModel<T>
Parameters:
index - element index
Returns:
true if element at specified position is checked

setCheckedIndex

public void setCheckedIndex(int index,
                            boolean value)
Description copied from interface: ICheckListModel
Sets the check state of the element at specified position

Specified by:
setCheckedIndex in interface ICheckListModel<T>
Parameters:
index - element index

getCheckedItems

public Collection<T> getCheckedItems()
Description copied from interface: ICheckListModel
Returns a collections of checked items

Specified by:
getCheckedItems in interface ICheckListModel<T>
Returns:

setCheckedItems

public void setCheckedItems(Collection<T> items)
Description copied from interface: ICheckListModel
Sets checked items

Specified by:
setCheckedItems in interface ICheckListModel<T>

filter

public void filter(String filter,
                   IObjectToStringTranslator translator,
                   CheckListFilterType filterType)
Description copied from interface: ICheckListModel
Allows filtered view. Setting empty or null filter will clear filter and show all items

Specified by:
filter in interface ICheckListModel<T>
Parameters:
filter - filter string
translator - object to string translator to aid the search


Copyright © 2011. All Rights Reserved.