com.sas.visuals
Interface SelectionGroupInterface

All Superinterfaces:
java.lang.Cloneable, com.sas.collection.CollectionInterface, com.sas.collection.ContentsChangedSource, com.sas.util.Countable, com.sas.util.Enumerable, IndexedGetInterface, IndexedSetInterface, java.awt.ItemSelectable, com.sas.collection.OrderedCollectionInterface, com.sas.beans.PropertyChangeSource, com.sas.PublicClonable, com.sas.collection.Sortable, com.sas.collection.StaticCollectionInterface, com.sas.collection.StaticOrderedCollectionInterface, com.sas.beans.VetoableChangeSource
All Known Implementing Classes:
SelectionGroup

public interface SelectionGroupInterface
extends java.awt.ItemSelectable, com.sas.collection.OrderedCollectionInterface, com.sas.beans.VetoableChangeSource

SelectionGroupInterface is an interface used to group and manipulate SelectableInterface objects. SelectableInterface objects have a buttonModel that holds the selected state for that SelectableInterface object. The SelectionGroup handles setting the state of the buttonModel when the SelectableInterface object is selected or deselected.

See Also:
SelectionGroup

Method Summary
 boolean containsItem(java.lang.Object item)
          Test for the presence of an object set as the item property on one of the SelectableInterface objects in the collection.
 com.sas.util.transforms.TransformInterface getDisplayTransform()
          Get the transform used to change the item property for display on the SelectableInterface.
 int getIndex(SelectableInterface selectableObject)
          Get the index of the specified SelectableInterface object.
 com.sas.util.transforms.TransformInterface getInputTransform()
          Get the transform used to change the item property for input to the SelectionGroupInterface.
 java.lang.Object getItem(int index)
          Get the Item object of the SelectableInterface object at the specified index.
 int getItemIndex(java.lang.Object item)
          Get the index of the SelectableInterface object with the specified item property.
 java.util.Enumeration getItemsData()
          Get an enumeration of the objects used as item properties on the SelectableInterface objects.
 com.sas.util.transforms.TransformInterface getOutputTransform()
          Get the transform used to change the item property for output on the SelectableInterface.
 int getSelectedIndex()
          Get the index of the selected SelectableInterface.
 java.lang.Object getSelectedItem()
          Get the item property of the selected SelectableInterface.
 boolean isDeselectable()
          Get if the SelectionGroup can have no SelectableInterface objects selected.
 void select(SelectableInterface selectableObject)
          Select the specified SelectableInterface object.
 void setDeselectable(boolean state)
          Set the SelectionGroup to deselectable, so all of the SelectableInterface objects can be deselected at the same time.
 void setDisplayTransform(com.sas.util.transforms.TransformInterface displayTransform)
          Set the transform used to change the item property for display on the SelectableInterface.
 void setInputTransform(com.sas.util.transforms.TransformInterface inputTransform)
          Set the transform used to change the item property for input to the SelectionGroup.
 void setOutputTransform(com.sas.util.transforms.TransformInterface outputTransform)
          Set the transform used to change the item property for output from the SelectionGroup.
 void setSelectedIndex(int index)
          Set the selected SelectableInterface based on the specified index.
 void setSelectedItem(java.lang.Object selectedItem)
          Set the selected SelectableInterface object based on its item.
 
Methods inherited from interface com.sas.util.Enumerable
getItems
 
Methods inherited from interface com.sas.util.IndexedGetInterface
get
 
Methods inherited from interface com.sas.util.Countable
count
 

Method Detail

containsItem

boolean containsItem(java.lang.Object item)
Test for the presence of an object set as the item property on one of the SelectableInterface objects in the collection. The item is transformed using the inputTransform before the search.

Parameters:
item - the item to search for
Returns:
true if item is found, false otherwise.
See Also:
StaticCollectionInterface.contains(java.lang.Object)

getDisplayTransform

com.sas.util.transforms.TransformInterface getDisplayTransform()
Get the transform used to change the item property for display on the SelectableInterface.

Returns:
the transform used on the item property of the SelectableInterface.
See Also:
setDisplayTransform(com.sas.util.transforms.TransformInterface)

getInputTransform

com.sas.util.transforms.TransformInterface getInputTransform()
Get the transform used to change the item property for input to the SelectionGroupInterface.

Returns:
the transform used on the item property of the SelectableInterface.
See Also:
setInputTransform(com.sas.util.transforms.TransformInterface)

getOutputTransform

com.sas.util.transforms.TransformInterface getOutputTransform()
Get the transform used to change the item property for output on the SelectableInterface.

Returns:
the transform used on the item property of the SelectableInterface.
See Also:
setOutputTransform(com.sas.util.transforms.TransformInterface)

getItemsData

java.util.Enumeration getItemsData()
Get an enumeration of the objects used as item properties on the SelectableInterface objects. The item objects are transformed first using the outputTransform before being returned.

Returns:
an Enumeration of the item properties on the SelectableInterface objects.

getItem

java.lang.Object getItem(int index)
Get the Item object of the SelectableInterface object at the specified index. The item object is transformed using the outputTransform before being returned.

Parameters:
index - the index of the SelectableInterface object to get.
Returns:
the transformed item of the SelectableInterface object at index.

getIndex

int getIndex(SelectableInterface selectableObject)
Get the index of the specified SelectableInterface object.

Parameters:
selectableObject - the SelectableInterface to get the index of
Returns:
the index of the selectableObject or -1 if not found
See Also:
getItemIndex(java.lang.Object)

getItemIndex

int getItemIndex(java.lang.Object item)
Get the index of the SelectableInterface object with the specified item property. The item is transformed using the inputTransform before the search.

Parameters:
selectableObject - the SelectableInterface item property value to get the index of
Returns:
the index of the SelectableInterface object with the specifed item property or -1 if not found
See Also:
getItem(int)

getSelectedItem

java.lang.Object getSelectedItem()
Get the item property of the selected SelectableInterface. The item is transformed using the outputTransform before being returned.

Returns:
the item property of the selected SelectableInterface object or null if no object is selected.
See Also:
setSelectedItem(java.lang.Object)

getSelectedIndex

int getSelectedIndex()
Get the index of the selected SelectableInterface.

Returns:
the index of the selected SelectableInterface, or -1 if no SelectableInterface is selected.
See Also:
setSelectedIndex(int)

isDeselectable

boolean isDeselectable()
Get if the SelectionGroup can have no SelectableInterface objects selected.

Returns:
true, when all SelectableInterface objects in the group can be deselected at the same time, false when one SelectableInterface object must be selected.
See Also:
setDeselectable(boolean)

setDeselectable

void setDeselectable(boolean state)
Set the SelectionGroup to deselectable, so all of the SelectableInterface objects can be deselected at the same time.

Parameters:
deselect - if true, all SelectableInterface objects can be deselected.
See Also:
isDeselectable()

select

void select(SelectableInterface selectableObject)
Select the specified SelectableInterface object. This fires a vetoableChange event that can stop the selection of the specified object.

Parameters:
selectableObject - the SelectableInterface object to set the selected state to true.

setDisplayTransform

void setDisplayTransform(com.sas.util.transforms.TransformInterface displayTransform)
Set the transform used to change the item property for display on the SelectableInterface.

Parameters:
displayTransform - the new TransformInterface for the displayTransform
See Also:
getDisplayTransform()

setInputTransform

void setInputTransform(com.sas.util.transforms.TransformInterface inputTransform)
Set the transform used to change the item property for input to the SelectionGroup.

Parameters:
inputTransform - the new TransformInterface for the inputTransform
See Also:
getInputTransform()

setOutputTransform

void setOutputTransform(com.sas.util.transforms.TransformInterface outputTransform)
Set the transform used to change the item property for output from the SelectionGroup.

Parameters:
outputTransform - the new TransformInterface for the outputTransform
See Also:
getOutputTransform()

setSelectedIndex

void setSelectedIndex(int index)
Set the selected SelectableInterface based on the specified index.

Parameters:
index - the index of the SelectableInterface item to be selected.
See Also:
getSelectedIndex()

setSelectedItem

void setSelectedItem(java.lang.Object selectedItem)
Set the selected SelectableInterface object based on its item.

Parameters:
selectedItem - the SelectableInterface item to be selected.
See Also:
getSelectedItem()



Copyright © 2009 SAS Institute Inc. All Rights Reserved.