All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sas.swing.visuals.tableview
Interface HoldInterface

All Known Implementing Classes:
  BaseColumnHeader, ColumnHeader, ColumnHeader, ColumnHeader, ColumnHeader, HoldColumnSupport, HttpHoldColumnSupport, OLAPColumnHeader, OLAPRowHeader, RowHeader, SwingHoldColumnSupport

    public interface HoldInterface

An interface for holding various indices in a view so they are always visible when scrolling. The indices can be held in their default location or an orientation parameter can be used if more then one orientation or location is available.

Method Summary
`abstract java.util.List` | `getHeldIndices()` Returns a list of the indices that are being held.
`abstract java.util.List` | `getHeldIndices(int orientation)` Returns a list of the indices that are being held for the given orientation.
`abstract void` | `hold(int modelIndex)` "Holds" the given index using the default orientation.
`abstract void` | `hold(int modelIndex, int orientation)` "Holds" the given index using the orientation specified.
`abstract boolean` | `isHeld(int modelIndex)` Returns true if the given `modelIndex` is held for any orientation, false otherwise.
`abstract boolean` | `isHeld(int modelIndex, int orientation)` Returns true if the given `modelIndex` is held for the given orientation, false otherwise.
`abstract boolean` | `isHoldingAllowed(int orientation)` Returns true if holding for a given orientation is allowed or false otherwise.
`abstract boolean` | `isHoldingEnabled()` Returns true is holding is enabled, should return false if holding is not allowed.
`abstract void` | `release(int modelIndex)` Releases the given `modelIndex` from being held, so it will return to its original place in the view.
`abstract void` | `releaseAll()` Releases all held indices and returns them to their previous location.
`abstract void` | `setHoldingEnabled(boolean enableHolding)` Sets the state of whether holding of indices is enabled or not.

Method Detail

### hold

    void hold(int modelIndex)

  "Holds" the given index using the default orientation. For example, on a table, the default held column location would be on the left side and for a row would be at the top. A held index is one that has been made non-scrollable and is thus always, space permitting, displayed; i.e. it is never scrolled out of view.

  The order in which the indices are held controls the order in which they are displayed.

  Should do nothing if the index is already held.

  Parameters:
    `modelIndex` - the data model index of the object wishing to be held
  See Also:
    `hold(int, int)`, `release(int)`, `releaseAll()`

### hold

    void hold(int modelIndex,
              int orientation)

  "Holds" the given index using the orientation specified. For example, on a table, a column could be held on the left or right and a row could be held on the top or bottom. A held index is one that has been made non-scrollable and is thus always, space permitting, displayed; i.e. it is never scrolled out of view.

  The order in which the indices are held controls the order in which they are displayed.

  Should do nothing if the index is already held.

  Parameters:
    `modelIndex` - the data model index of the object wishing to be held
    `orientation` - the orientation or location the index is to be held
  See Also:
    `hold(int)`, `release(int)`, `releaseAll()`

### release

    void release(int modelIndex)

  Releases the given `modelIndex` from being held, so it will return to its original place in the view. If the `modelIndex` is not held, nothing is done.

  Parameters:
    `modelIndex` - the index currently held that is wishing to be released
  See Also:
    `hold(int)`, `hold(int, int)`, `releaseAll()`

### releaseAll

    void releaseAll()

  Releases all held indices and returns them to their previous location.

  See Also:
    `hold(int)`, `hold(int, int)`, `release(int)`

### getHeldIndices

    java.util.List getHeldIndices()

  Returns a list of the indices that are being held. This list will include all the indices for all the orientations. Modifications to this list will not be reflected in the held list, this list is a duplicate.

  Returns:
    a list of the held indices
  See Also:
    `getHeldIndices(int)`

### getHeldIndices

    java.util.List getHeldIndices(int orientation)

  Returns a list of the indices that are being held for the given orientation. Modifications to this list will be reflected in the held list as this is the true list.

  Parameters:
    `orientation` - the orientation of the held indices that are being returned
  Returns:
    a list of the held indices
  See Also:
    `getHeldIndices()`

### isHeld

    boolean isHeld(int modelIndex)

  Returns true if the given `modelIndex` is held for any orientation, false otherwise.

  Parameters:
    `modelIndex` - the data model index of the object queried about
  Returns:
    true if the index is held, false otherwise
  See Also:
    `isHeld(int, int)`

### isHeld

    boolean isHeld(int modelIndex,
                   int orientation)

  Returns true if the given `modelIndex` is held for the given orientation, false otherwise.

  Parameters:
    `modelIndex` - the data model index of the object queried about
    `orientation` - the orientation or location that the index is being queried for
  Returns:
    true if the index is held at the given orientation, false otherwise
  See Also:
    `isHeld(int)`

### isHoldingEnabled

    boolean isHoldingEnabled()

  Returns true is holding is enabled, should return false if holding is not allowed.

  Returns:
    true is holding of indices is enabled, false otherwise
  See Also:
    `setHoldingEnabled(boolean)`

### setHoldingEnabled

    void setHoldingEnabled(boolean enableHolding)

  Sets the state of whether holding of indices is enabled or not.

  Parameters:
    `enableHolding` - true to enable holding, false otherwise
  See Also:
    `isHoldingEnabled()`

### isHoldingAllowed

    boolean isHoldingAllowed(int orientation)

  Returns true if holding for a given orientation is allowed or false otherwise. Holding must be enabled for this to return true.

  Parameters:
    `orientation` - the orientation being queried about
  Returns:
    true is holding is enabled an dallowed for a given orientation, false otherwise

All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 SAS Institute Inc. All Rights Reserved.