com.sas.servlet.tbeans.dataselectors.html
Class ActionProviderMenuBar

com.sas.servlet.tbeans.dataselectors.html.ActionProviderMenuBar
All Implemented Interfaces:
ActionProviderViewInterface, HttpActionProviderInterface, HttpActionProviderViewInterface, com.sas.actionprovider.refresh.PartialRefreshActionsInterface, URLTemplateViewInterface, com.sas.beans.PropertyChangeSource, com.sas.lang.ObjectDataInterface, com.sas.servlet.tbeans.AJAXControllerURLInterface, RenderableInterface, TransformationInterface, com.sas.servlet.tbeans.TransformationInterface2, com.sas.util.WriteToPrintWriterInterface, java.io.Serializable
Direct Known Subclasses:
OLAPMenuBar, RelationalMenuBar

public abstract class ActionProviderMenuBar

The ActionProviderMenuBar is an abstract TransformationBean™ that provides a menubar representation of the actions defined for an area of a viewer. Menus can be appended to the end via the add method. The default behavior for a menubar selector can be overridden by retrieving the instance of the selector from the appropriate default action and making changes to that instance. Custom selectors can also be set by passing in a custom selector instance on a setAction call to the ActionProvider.

For More Information:

Note: A snapshot of the AppDev Studio Developers Site is installed on your local Web server when you install AppDev Studio. To access the site from webAF, select Help -> Developer Site .

Since:
3.1
See Also:
Serialized Form

Constructor Summary
ActionProviderMenuBar()
          Default Constructor
 
Method Summary
 SelectorMenuBar buildMenuBar()
          Build a menubar from the actions defined for the area on the menubar default filter and set initial properties on the menubar.
 int getBorderWidth()
          Gets the width of the outer border around the Table.
 int getCellPadding()
          Gets the number of pixels between the border of a cell and the cell's contents.
 int getCellSpacing()
          Gets the number of pixels between the border of each cell.
 SelectorMenuBar getDefaultSelectorMenubar()
          Returns a default SelectorMenuBar
 int getFirstTabIndex()
          Returns the first tab index set on the first menu
 int getHeight()
          Gets the height of the MenuBar/Table in pixels.
 int getHeightPercentage()
          Gets the height of the Table/MenuBar as a percentage
 boolean getHorizontalOrientation()
          Returns the orientation of the menu bar
 int getLastTabIndex()
          Returns the last tab index used on this MenuBar
 java.lang.String getLeftImage()
          Returns the image displayed on the left side of the button
 int getMenuCount()
          Returns the number of menus that havve been added to this menubar
 java.util.ArrayList getMenus()
           
 java.lang.String getRightImage()
          Returns the image displayed on the right side of the button
 ActionList getSelectorActions(ActionSupportFilter menuBarFilter)
          Return the list of actions that represent the valid selectors to be placed on the menubar.
 SelectorMenuBar getSelectorMenubar()
          Gets the selectorMenubar value
 java.lang.String getSeparator()
          Returns the separator of the menu
 java.lang.String getSeparatorImage()
          Returns the separator image of the menu
 java.lang.String getStyleClassPrefix()
          Returns the styleClassPrefix of the menu bar
 java.lang.String getTarget()
          getTarget returns the value of the TARGET= argument used on the anchor tags generated.
 java.lang.String getTemplate()
          Returns the menubar template
 BaseActionTransformation getViewer()
          Get the viewer that contains the menubar
 int getWidth()
          Gets the width of the MenuBar/Table in pixels.
 int getWidthPercentage()
          Gets the width of the Table/MenuBar as a percentage
 void setBorderWidth(int border)
          Sets the width of the outer border around the Table in pixels.
 void setCellPadding(int padding)
          Sets the number of pixels between the border of a cell and the cell's contents.
 void setCellSpacing(int spacing)
          Sets the number of pixels between the border of each cell.
 void setFirstTabIndex(int tabindex)
          Sets the first tab index to be set on the first menu.
 void setHeight(int value)
          Sets the height of the Table/MenuBar in pixels.
 void setHeightPercentage(int value)
          Sets the height of the Table/MenuBar as a percentage
 void setHorizontalOrientation(boolean orientation)
          Sets the orientation of the menu bar
 void setLeftImage(java.lang.String image)
          Sets the image displayed on the left side of the button
 void setRightImage(java.lang.String image)
          Sets the image displayed on the right side of the button
 void setSelectorMenubar(SelectorMenuBar selectorMenubar)
          Set the selectorMenubar
 void setSeparator(java.lang.String value)
          Sets the separator of the menu
 void setSeparatorImage(java.lang.String value)
          Sets the separator image of the menu
 void setStyleClassPrefix(java.lang.String styleClassPrefix)
          Sets the styleClassPrefix of the menu bar
 void setTarget(java.lang.String value)
          Sets the value of the TARGET= argument used on the anchor tags generated.
 void setTemplate(java.io.File f)
          Sets the menubar template as a file
 void setTemplate(java.io.InputStreamReader isr)
          Sets the menubar template as an InputStreamReader
 void setTemplate(java.lang.String template)
          Sets the menubar template as a string
 void setViewer(BaseActionTransformation viewer)
          Set the viewer that the menu bar is attached to
 void setWidth(int value)
          Sets the width of the Table/MenuBar in pixels.
 void setWidthPercentage(int value)
          Sets the width of the Table/MenuBar as a percentage
 
Methods inherited from class com.sas.servlet.tbeans.BaseActionTransformation
dispose, getActionProvider, getActionSupportType, getUniqueId, isActionVisible, listActionTypes, listAreaTypes, setActionProvider, setActionSupportType, setActionVisible, setUniqueId
 
Methods inherited from class com.sas.servlet.tbeans.BaseTransformation
addPropertyChangeListener, addPropertyChangeListener, cleanUpResources, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getCustomAttributes, getDescription, getId, getInputTransform, getLocale, getName, getObjectData, getObjectDataProperty, getOutputTransform, getRequest, getResponse, getTagEpilog, getTagProlog, hasListeners, isCleanUpResourcesOn, isVisible, removePropertyChangeListener, removePropertyChangeListener, setCleanUpResourcesOn, setCustomAttributes, setDescription, setId, setInputTransform, setLocale, setLocaleDependentProperties, setName, setObjectData, setObjectDataProperty, setOutputTransform, setRequest, setResponse, setTagEpilog, setTagProlog, setVisible, toString, write, write, write
 
Methods inherited from interface com.sas.servlet.tbeans.TransformationInterface
getCustomAttributes, getDescription, getId, getLocale, getName, getRequest, getResponse, getTagEpilog, getTagProlog, isVisible, setCustomAttributes, setDescription, setId, setLocale, setName, setRequest, setResponse, setTagEpilog, setTagProlog, setVisible, write, write, write
 
Methods inherited from interface com.sas.actionprovider.HttpActionProviderViewInterface
getRequest, setRequest
 

Constructor Detail

ActionProviderMenuBar

public ActionProviderMenuBar()
Default Constructor

Method Detail

setLeftImage

public void setLeftImage(java.lang.String image)
Sets the image displayed on the left side of the button

Parameters:
image - the name of the image

getLeftImage

public java.lang.String getLeftImage()
Returns the image displayed on the left side of the button

Returns:
image

setRightImage

public void setRightImage(java.lang.String image)
Sets the image displayed on the right side of the button

Parameters:
image - the name of the image

getRightImage

public java.lang.String getRightImage()
Returns the image displayed on the right side of the button

Returns:
image

setViewer

public void setViewer(BaseActionTransformation viewer)
Set the viewer that the menu bar is attached to

Parameters:
viewer - The viewer containing the menubar

getViewer

public BaseActionTransformation getViewer()
Get the viewer that contains the menubar

Returns:
viewer The viewer that contains the menubar

getSelectorActions

public ActionList getSelectorActions(ActionSupportFilter menuBarFilter)
Return the list of actions that represent the valid selectors to be placed on the menubar. The order of the actions can be changed by manipulating the ActionList.

Parameters:
menuBarFilter - Determines the type of actions returned from the action provider
See Also:
ActionList

buildMenuBar

public SelectorMenuBar buildMenuBar()
Build a menubar from the actions defined for the area on the menubar default filter and set initial properties on the menubar.

Returns:
a selector menubar

setSelectorMenubar

public void setSelectorMenubar(SelectorMenuBar selectorMenubar)
Set the selectorMenubar

Parameters:
selectorMenubar - The value for selectormenubar

getSelectorMenubar

public SelectorMenuBar getSelectorMenubar()
Gets the selectorMenubar value

Returns:
selectorMenubar The selectorMenubar value

getDefaultSelectorMenubar

public SelectorMenuBar getDefaultSelectorMenubar()
Returns a default SelectorMenuBar

Returns:
selectorMenubar The default SelectorMenuBar

setStyleClassPrefix

public void setStyleClassPrefix(java.lang.String styleClassPrefix)
Sets the styleClassPrefix of the menu bar

Parameters:
styleClassPrefix - The styleClassPrefix to use for the menubar.

getStyleClassPrefix

public java.lang.String getStyleClassPrefix()
Returns the styleClassPrefix of the menu bar

Returns:
The styleClassPrefix

getHorizontalOrientation

public boolean getHorizontalOrientation()
Returns the orientation of the menu bar

Returns:
A returned value of false indicates vertical menu bar orientation.

setHorizontalOrientation

public void setHorizontalOrientation(boolean orientation)
Sets the orientation of the menu bar

Parameters:
orientation - A value of false indicates verical menu bar orientation.

setSeparator

public void setSeparator(java.lang.String value)
Sets the separator of the menu

Parameters:
value - The separator of the menu

getSeparator

public java.lang.String getSeparator()
Returns the separator of the menu

Returns:
The separator

setSeparatorImage

public void setSeparatorImage(java.lang.String value)
Sets the separator image of the menu

Parameters:
value - The separator image of the menu

getSeparatorImage

public java.lang.String getSeparatorImage()
Returns the separator image of the menu

Returns:
The separator image

getMenuCount

public int getMenuCount()
Returns the number of menus that havve been added to this menubar

Returns:
the number of menus, 0 if no menus are added

getTarget

public java.lang.String getTarget()
getTarget returns the value of the TARGET= argument used on the anchor tags generated. This value determines where/how the links associated with the menu/menu items.

Returns:
TARGET= argument of the anchor tags

setTarget

public void setTarget(java.lang.String value)
Sets the value of the TARGET= argument used on the anchor tags generated.

Parameters:
value - The value of the TARGET= argrument on the anchor tag

setBorderWidth

public void setBorderWidth(int border)
Sets the width of the outer border around the Table in pixels.

Parameters:
border - The border width in pixels

getBorderWidth

public int getBorderWidth()
Gets the width of the outer border around the Table.

Returns:
The border width in pixels

setWidth

public void setWidth(int value)
Sets the width of the Table/MenuBar in pixels.

Parameters:
value - The width in pixels

getWidth

public int getWidth()
Gets the width of the MenuBar/Table in pixels.

Returns:
The width in pixels

setWidthPercentage

public void setWidthPercentage(int value)
Sets the width of the Table/MenuBar as a percentage

Parameters:
value - The width as a percentage

getWidthPercentage

public int getWidthPercentage()
Gets the width of the Table/MenuBar as a percentage

Returns:
The width as a percentage

setHeight

public void setHeight(int value)
Sets the height of the Table/MenuBar in pixels.

Parameters:
value - The height in pixels

getHeight

public int getHeight()
Gets the height of the MenuBar/Table in pixels.

Returns:
The height in pixels

setHeightPercentage

public void setHeightPercentage(int value)
Sets the height of the Table/MenuBar as a percentage

Parameters:
value - The height as a percentage

getHeightPercentage

public int getHeightPercentage()
Gets the height of the Table/MenuBar as a percentage

Returns:
The height as a percentage

setCellSpacing

public void setCellSpacing(int spacing)
Sets the number of pixels between the border of each cell.

Parameters:
spacing - The number of pixels between each cell

getCellSpacing

public int getCellSpacing()
Gets the number of pixels between the border of each cell.

Returns:
The number of pixels between each cell.

setCellPadding

public void setCellPadding(int padding)
Sets the number of pixels between the border of a cell and the cell's contents.

Parameters:
padding - The number of pixels between the cell border and the cell content

getCellPadding

public int getCellPadding()
Gets the number of pixels between the border of a cell and the cell's contents.

Returns:
The number of pixels between the cell border and the cell content

getFirstTabIndex

public int getFirstTabIndex()
Returns the first tab index set on the first menu

Returns:
first tab index
See Also:
setFirstTabIndex(int)

setFirstTabIndex

public void setFirstTabIndex(int tabindex)
Sets the first tab index to be set on the first menu. The tabindex for other menus and menu items will be a subsequent of the first tab index.


getLastTabIndex

public int getLastTabIndex()
Returns the last tab index used on this MenuBar

Returns:
The last tab index
See Also:
setFirstTabIndex(int), getFirstTabIndex()

getTemplate

public java.lang.String getTemplate()
Returns the menubar template

Returns:
templatestring The template string

setTemplate

public void setTemplate(java.lang.String template)
Sets the menubar template as a string

Parameters:
templatestring - The template string

setTemplate

public void setTemplate(java.io.File f)
Sets the menubar template as a file

Parameters:
templatefile - The template file

setTemplate

public void setTemplate(java.io.InputStreamReader isr)
Sets the menubar template as an InputStreamReader

Parameters:
inputstream - The template inputstream

getMenus

public java.util.ArrayList getMenus()



Copyright © 2009 SAS Institute Inc. All Rights Reserved.