com.sas.actionprovider.support
Class HttpNavigationBarSupport

com.sas.actionprovider.support.HttpNavigationBarSupport
All Implemented Interfaces:
NavigationBarAreaInterface

public class HttpNavigationBarSupport

In the context of the ActionProvider framework, this Support class assists in the registering and retrieval of actions for the NavigationBar.


Field Summary
static java.lang.String FIRST_COLUMN_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the first column when editing is enabled.
static java.lang.String FIRST_ROW_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the first row when editing is enabled.
static java.lang.String GOTO_COLUMN_EDIT_ENABLED_ACTION
          The actionType key used to define the goto column action when editing is enabled.
static java.lang.String GOTO_ROW_EDIT_ENABLED_ACTION
          The actionType key used to define the goto row action when editing is enabled.
static java.lang.String LAST_COLUMN_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the last column when editing is enabled.
static java.lang.String LAST_ROW_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the last row when editing is enabled.
static java.lang.String NEXT_COLUMN_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the next column when editing is enabled.
static java.lang.String NEXT_ROW_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the next row when editing is enabled.
static java.lang.String PAGE_BACKWARD_COLUMNS_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the previous column page when editing is enabled.
static java.lang.String PAGE_BACKWARD_ROWS_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the previous row page when editing is enabled.
static java.lang.String PAGE_FORWARD_COLUMNS_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the next column page when editing is enabled.
static java.lang.String PAGE_FORWARD_ROWS_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the next row page when editing is enabled.
static java.lang.String PREVIOUS_COLUMN_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the previous column when editing is enabled.
static java.lang.String PREVIOUS_ROW_EDIT_ENABLED_ACTION
          The actionType key used to define the action to scroll to the previous row when editing is enabled.
 
Fields inherited from class com.sas.actionprovider.support.BaseNavigationBarSupport
CANCEL_ACTION, cancelAction, COMMIT_ACTION, commitAction, DELETE_ACTION, deleteAction, FIRST_COLUMN_ACTION, FIRST_ROW_ACTION, firstColumnAction, firstRowAction, GOTO_COLUMN_ACTION, GOTO_ROW_ACTION, gotoColumnAction, gotoRowAction, INSERT_ACTION, insertAction, LAST_COLUMN_ACTION, LAST_ROW_ACTION, lastColumnAction, lastRowAction, NEXT_COLUMN_ACTION, NEXT_ROW_ACTION, nextColumnAction, nextRowAction, PAGE_BACKWARD_COLUMNS_ACTION, PAGE_BACKWARD_ROWS_ACTION, PAGE_FORWARD_COLUMNS_ACTION, PAGE_FORWARD_ROWS_ACTION, pageBackwardColumnsAction, pageBackwardRowsAction, pageForwardColumnsAction, pageForwardRowsAction, PREVIOUS_COLUMN_ACTION, PREVIOUS_ROW_ACTION, previousColumnAction, previousRowAction, UPDATE_ACTION, updateAction
 
Fields inherited from class com.sas.actionprovider.support.BaseActionProviderSupport
AREA_DISABLED, AREA_VALUE_ATTRKEY, DISABLED, ENABLED, IS_CURRENT_STATE_DISABLED, MODEL_MEMBER_DISABLED, MODEL_STATE_DISABLED, MODEL_TYPE_DISABLED, NON_SPECIFIC_AREA, UNSUPPORTED, VIEWER_DISABLED
 
Fields inherited from interface com.sas.actionprovider.support.NavigationBarAreaInterface
COLUMN_GOTO_AREA, COLUMN_SCROLL_BACKWARD_AREA, COLUMN_SCROLL_FORWARD_AREA, EDIT_AREA, ROW_GOTO_AREA, ROW_SCROLL_BACKWARD_AREA, ROW_SCROLL_FORWARD_AREA
 
Constructor Summary
HttpNavigationBarSupport(java.lang.Class actionClass)
          Constructor
 
Method Summary
protected  void createDefaultActions()
          Initializes the actionClass property and creates the default actions that this class supports.
protected  BaseAction defineActionProperties(BaseAction action, java.lang.String actionType)
          Returns an action whose default dynamic attributes have been defined according to their actionType.
protected  java.util.Map getActionScopeAttributeMap(java.lang.String actionType, ActionSupportFilter filter)
          Returns mappings for a pre-defined set of Action Attribues keys to their corresponding dynamic values for a specific area and a specific actionType.
protected  int getActionStatus(BaseAction action, ActionSupportFilter filter)
          Returns an int value indicating whether the Action is enabled for a specific area as suggested by filter attributes.
protected  java.util.Map getAreaScopeAttributeMap(ActionSupportFilter filter)
          Returns mappings for a pre-defined set of Action Attribute keys to their corresponding dynamic values for a specific area.
protected  java.util.Map initializeShortActionTypeMap()
          This method is called by the constructor and used to initiallize the actionTypeToShortActionTypeMap map.
 BaseAction newActionInstance(java.lang.String areaType, java.lang.String actionType)
          Return a newly instantiated default Action based on the specified actionType or return null if actionType not recognized.
 
Methods inherited from class com.sas.actionprovider.support.BaseNavigationBarSupport
initialize, validArea
 
Methods inherited from class com.sas.actionprovider.support.BaseActionProviderSupport
addDefaultAction, getAction, getActionId, getActionOrderList, getActionProvider, getActions, getActionScopeAttribute, getDefaultAction, getLocale, listActionTypes, listAreaTypes, listDefaultActions, reset, setAction, setActionOrderList, setActionProvider, setLocale
 

Field Detail

FIRST_ROW_EDIT_ENABLED_ACTION

public static final java.lang.String FIRST_ROW_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the first row when editing is enabled.

See Also:
Constant Field Values

PAGE_BACKWARD_ROWS_EDIT_ENABLED_ACTION

public static final java.lang.String PAGE_BACKWARD_ROWS_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the previous row page when editing is enabled.

See Also:
Constant Field Values

PREVIOUS_ROW_EDIT_ENABLED_ACTION

public static final java.lang.String PREVIOUS_ROW_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the previous row when editing is enabled.

See Also:
Constant Field Values

NEXT_ROW_EDIT_ENABLED_ACTION

public static final java.lang.String NEXT_ROW_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the next row when editing is enabled.

See Also:
Constant Field Values

PAGE_FORWARD_ROWS_EDIT_ENABLED_ACTION

public static final java.lang.String PAGE_FORWARD_ROWS_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the next row page when editing is enabled.

See Also:
Constant Field Values

LAST_ROW_EDIT_ENABLED_ACTION

public static final java.lang.String LAST_ROW_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the last row when editing is enabled.

See Also:
Constant Field Values

GOTO_ROW_EDIT_ENABLED_ACTION

public static final java.lang.String GOTO_ROW_EDIT_ENABLED_ACTION
The actionType key used to define the goto row action when editing is enabled.

See Also:
Constant Field Values

FIRST_COLUMN_EDIT_ENABLED_ACTION

public static final java.lang.String FIRST_COLUMN_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the first column when editing is enabled.

See Also:
Constant Field Values

PAGE_BACKWARD_COLUMNS_EDIT_ENABLED_ACTION

public static final java.lang.String PAGE_BACKWARD_COLUMNS_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the previous column page when editing is enabled.

See Also:
Constant Field Values

PREVIOUS_COLUMN_EDIT_ENABLED_ACTION

public static final java.lang.String PREVIOUS_COLUMN_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the previous column when editing is enabled.

See Also:
Constant Field Values

NEXT_COLUMN_EDIT_ENABLED_ACTION

public static final java.lang.String NEXT_COLUMN_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the next column when editing is enabled.

See Also:
Constant Field Values

PAGE_FORWARD_COLUMNS_EDIT_ENABLED_ACTION

public static final java.lang.String PAGE_FORWARD_COLUMNS_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the next column page when editing is enabled.

See Also:
Constant Field Values

LAST_COLUMN_EDIT_ENABLED_ACTION

public static final java.lang.String LAST_COLUMN_EDIT_ENABLED_ACTION
The actionType key used to define the action to scroll to the last column when editing is enabled.

See Also:
Constant Field Values

GOTO_COLUMN_EDIT_ENABLED_ACTION

public static final java.lang.String GOTO_COLUMN_EDIT_ENABLED_ACTION
The actionType key used to define the goto column action when editing is enabled.

See Also:
Constant Field Values
Constructor Detail

HttpNavigationBarSupport

public HttpNavigationBarSupport(java.lang.Class actionClass)
Constructor

Parameters:
actionClass - The class used to instantiate new actions.
Method Detail

createDefaultActions

protected void createDefaultActions()
Initializes the actionClass property and creates the default actions that this class supports. This method is called by the action provider that instantiates this support class.

Overrides:
createDefaultActions in class BaseNavigationBarSupport

newActionInstance

public BaseAction newActionInstance(java.lang.String areaType,
                                    java.lang.String actionType)
Return a newly instantiated default Action based on the specified actionType or return null if actionType not recognized.

Specified by:
newActionInstance in class BaseActionProviderSupport
Parameters:
areaType - the key associated with a defined area.
actionType - the key associated with a defined action type.
Returns:
a new action of the specified type.

defineActionProperties

protected BaseAction defineActionProperties(BaseAction action,
                                            java.lang.String actionType)
Returns an action whose default dynamic attributes have been defined according to their actionType. The method also sets each attributes meta attributes ( e.g. visible ) accordingly.

Overrides:
defineActionProperties in class BaseNavigationBarSupport
Parameters:
action - The action object whose properties are to be defined.
actionType - the key associated with a defined action type.
Returns:
an action with all of its default attributes defined.

getAreaScopeAttributeMap

protected java.util.Map getAreaScopeAttributeMap(ActionSupportFilter filter)
Description copied from class: BaseNavigationBarSupport
Returns mappings for a pre-defined set of Action Attribute keys to their corresponding dynamic values for a specific area.

Overrides:
getAreaScopeAttributeMap in class BaseNavigationBarSupport
Parameters:
filter - Defines the specific area
Returns:
mappings for a pre-defined set of Action Attribues keys

getActionScopeAttributeMap

protected java.util.Map getActionScopeAttributeMap(java.lang.String actionType,
                                                   ActionSupportFilter filter)
Returns mappings for a pre-defined set of Action Attribues keys to their corresponding dynamic values for a specific area and a specific actionType.

Overrides:
getActionScopeAttributeMap in class BaseActionProviderSupport
Parameters:
actionType - the key associated with a defined action type
filter - Defines the specific area
Returns:
mappings for a pre-defined set of Action Attribues keys

getActionStatus

protected int getActionStatus(BaseAction action,
                              ActionSupportFilter filter)
Returns an int value indicating whether the Action is enabled for a specific area as suggested by filter attributes.
If enabled, the value is:
ENABLED

If disabled, the value may be one of the following values which indicate why the Action is disabled.

See the documentation of these keys on this class for more information on the meaning of each key.

Overrides:
getActionStatus in class BaseActionProviderSupport
Parameters:
action - The Action to check the status of
filter - Defines the specific area
Returns:
the boolean indicating whether the Action is enabled
See Also:
CommandSupportedInterface, CommandStatusInterface

initializeShortActionTypeMap

protected java.util.Map initializeShortActionTypeMap()
This method is called by the constructor and used to initiallize the actionTypeToShortActionTypeMap map. This map should contain the ActionType as the key and the new short name as the value. The short names are used to generate ids for HttpActions.

Overrides:
initializeShortActionTypeMap in class BaseActionProviderSupport



Copyright © 2009 SAS Institute Inc. All Rights Reserved.