com.sas.dataselectors.sort
Class BaseSortSelectorAdapter

com.sas.dataselectors.sort.BaseSortSelectorAdapter
All Implemented Interfaces:
SortSelectorInterface, com.sas.util.SortDirectionInterface

public class BaseSortSelectorAdapter
implements SortSelectorInterface

The SortSelectorInterface defines the basic methods required for the model of a RelationalSortSelector.


Field Summary
 
Fields inherited from interface com.sas.util.SortDirectionInterface
ASCENDING, DESCENDING, NOT_SORTED
 
Constructor Summary
BaseSortSelectorAdapter()
           
 
Method Summary
 java.lang.Object[] getAllItems()
          Returns all items in the model which sorting is allowed.
 java.lang.Object[] getAvailableItems()
          Returns the items in which sorting is allowed.
 java.lang.Object[] getHiddenAvailableItems()
          Returns the hidden available items in which sorting is allowed.
 java.lang.Object getPropertiesBean()
          Returns the properties for the SortSelector that will be on the Request.
 int[] getSortedDirections()
          Returns an array of ints that indicate which direction each item in the sortItems array is to be sorted.
 java.lang.Object[] getSortedItems()
          Returns the items that the table is to sort.
 void setAllItems(java.lang.Object[] items)
          Sets the items in which sorting is allowed.
 void setAvailableItems(java.lang.Object[] items)
          Sets the items in which sorting is allowed.
 void setHiddenAvailableItems(java.lang.Object[] items)
          Sets the hidden available items in which sorting is allowed.
 void setSortedDirections(int[] directions)
          Sets an array of ints that indicate which direction each item in the sortItems array is to be sorted.
 void setSortedItems(java.lang.Object[] items)
          Sets the items that the table is to sort.
 

Constructor Detail

BaseSortSelectorAdapter

public BaseSortSelectorAdapter()
Method Detail

getAvailableItems

public java.lang.Object[] getAvailableItems()
Returns the items in which sorting is allowed. The availableItems contains all the items in which sorting is allowed on the model, all other items are to be non-sortable.

Specified by:
getAvailableItems in interface SortSelectorInterface
Returns:
An array of items in which sorting is allowed.

setAvailableItems

public void setAvailableItems(java.lang.Object[] items)
Sets the items in which sorting is allowed. The availableItems contains all the items in which sorting is allowed on the model, all other items are to be non-sortable.

Parameters:
items - an array of items in which sorting is allowed

getHiddenAvailableItems

public java.lang.Object[] getHiddenAvailableItems()
Returns the hidden available items in which sorting is allowed. The hiddenAvailableItems contains all the hidden available items in which sorting is allowed on the model, all other items are to be non-sortable.

Specified by:
getHiddenAvailableItems in interface SortSelectorInterface
Returns:
An array of hidden available items in which sorting is allowed.

setHiddenAvailableItems

public void setHiddenAvailableItems(java.lang.Object[] items)
Sets the hidden available items in which sorting is allowed. The hiddenAvailableItems contains all the hidden available items in which sorting is allowed on the model, all other items are to be non-sortable.

Parameters:
items - an array of hidden available items in which sorting is allowed

getAllItems

public java.lang.Object[] getAllItems()
Returns all items in the model which sorting is allowed. The allItems contains all the items in which sorting is allowed on the model, all other items are to be non-sortable.

Specified by:
getAllItems in interface SortSelectorInterface
Returns:
An array of items in which sorting is allowed.

setAllItems

public void setAllItems(java.lang.Object[] items)
Sets the items in which sorting is allowed. The allItems contains all the items in which sorting is allowed on the model, all other items are to be non-sortable.

Parameters:
items - an array of items in which sorting is allowed

getSortedItems

public java.lang.Object[] getSortedItems()
Returns the items that the table is to sort. The length of the array can be from 0 to maxSortableItems.

Specified by:
getSortedItems in interface SortSelectorInterface
Returns:
An array of objects that are the items on which the data is sorted.

setSortedItems

public void setSortedItems(java.lang.Object[] items)
Sets the items that the table is to sort. The length of the array will be from 0 to maxSortableItems.

Specified by:
setSortedItems in interface SortSelectorInterface
Parameters:
items - an array of objects that are the items on which the data is sorted

getSortedDirections

public int[] getSortedDirections()
Returns an array of ints that indicate which direction each item in the sortItems array is to be sorted. The array will be the same size of the sortItems. Valid values are ASCENDING or DESCENDING.

Specified by:
getSortedDirections in interface SortSelectorInterface
Returns:
An array of ints that indicate which direction the sort items are to be sorted. Valid values are ASCENDING or DESCENDING.

setSortedDirections

public void setSortedDirections(int[] directions)
Sets an array of ints that indicate which direction each item in the sortItems array is to be sorted. The array will be the same size of the sortItems. Valid values are ASCENDING or DESCENDING.

Specified by:
setSortedDirections in interface SortSelectorInterface
Parameters:
directions - an array of ints that indicate which direction the sort items are to be sorted

getPropertiesBean

public java.lang.Object getPropertiesBean()
Returns the properties for the SortSelector that will be on the Request.

Returns:
SortRequestProperties the SortSelector properties on the request.



Copyright © 2009 SAS Institute Inc. All Rights Reserved.