|
Oracle Fusion Middleware Java API Reference for Oracle ADF Faces 11g Release 2 (11.1.2.0.0) E17488-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
javax.faces.component.UIComponent
org.apache.myfaces.trinidad.component.UIXComponent
org.apache.myfaces.trinidad.component.UIXComponentBase
org.apache.myfaces.trinidad.component.UIXPanel
oracle.adf.view.rich.component.rich.RichMenu
public class RichMenu
A menu is a vertical container for menu items. A menu consists of two main parts - the menu link and the menu container. The menu link is what you click on to open the menu popup. The menu container is the popup that opens when you click on the menu link. The menu container displays the contents of the menu, which are menu items. These items are typically commandMenuItems, goMenuItems, and submenus. Menus are not rendered on printable pages.
<section name="Allowed_Children">
A menu is designed to only hold menus, commandMenuItems, goMenuItems, and groups of these same components. A menuBar can also dynamically add children of these allowed types using a facetRef, iterator, or switcher.
Besides these components, other types of children are not allowed. This is because the menu provides special menu functionality, like in menu type access key behavior and arrow key support that will not function correctly if other components are included in the menu.
</section> <section name="Special_Menu_Functionality">
Menus provide special menu functionality, including menu type access key behavior, and arrow key support.
With menu type access key behavior, once your keyboard focus is in a menu or menuBar, you can simply press the access key without modifiers to move the focus to the menu item in that menu or menubar with that access key.
Arrow keys provide convenient keyboard focus movement between items in a menu and its parent menuBar. While in a menu you can press the up and down arrow keys to cycle through the menu items. If your menu is rooted in a menuBar, then pressing the left or right arrow keys closes the menu and moves the focus to the previous or next menu item on the menBar. The exception to this is pressing the right arrow key while on a submenu item, which will open that submenu instead and place focus on its first item. While inside a detachable submenu, pressing ctrl plus arrow keys will cause the detachable menu to become detached and move in the specified direction.
</section> <section name="Grouping_Items_in_a_Menu">
If you use <af:group>
to group items inside a menu, the menu will include separators around the group. You should also not that the group has an effect on certain items. For example, commandMenuItems with type of radio that are grouped together are automatically considered part of the same radio group.
</section> <section name="Menu_Size_and_Scrolling">
The number of items displayed in a menu is limited in size by the -tr-visible-items property. When there are more items than the display limit, scroll up and scroll down icons are displayedfor the menu, allowing the user to scroll through the menu contents.
</section> <section name="Menu_Types">
There are several different types of menus, determined by the parent component of the menu as well as the menu's attributes.
Menu components that are placed inside a menuBar are called root menus. The menu item links are placed horizontally across the menuBar. When the menu item link is selected, the menu container opens up, displaying the menu contents.
Menu components that are placed inside another menu component are called submenus. The submenu item links are placed vertically inside the parent menu. When the submenu item link is selected, the submenu container opens. There is no enforced maximum depth to the level of submenu nesting, although it is generally considered a good UI practice to limit nested menus to no more than 3 levels deep.
A detachable submenu is a submenu that has its detachable attribute set to true. This submenu has a handle area at the top of the menu that can be used to grab the submenu and drag it to a desireable spot where it will remain open.
A menu component can also be placed directly inside a popup component. This is typically called a menu popup. In the case of a menu popup, the menu component does not provide the menu item link. In otherwords, the text attribute of the menu does not appear anywhere on the page. Instead, you would create another command type component (like a commandLink or commandButton) that would be set to open the menu popup.
A menu popup that is set to open on a right mouse click is typically refered to as a context menu.
</section> <section name="Geometry_Management"> <html:ul> <html:li>There are two distinct parts to a menu. The menu item does not render on its own, must be inside a menu or menuBar. The menu popup (an opened menu) has its own fixed size and is not effected by layout.</html:li> <html:li>The children of a menu are displayed in a popup that has its own fixed size and is not effected by layout.</html:li> </html:ul> </section>
Type | Phases | Description |
---|---|---|
org.apache.myfaces.trinidad.event.AttributeChangeEvent |
Invoke Application Apply Request Values |
Event delivered to describe an attribute change. Attribute change events are not delivered for any programmatic change to a property. They are only delivered when a renderer changes a property without the application's specific request. An example of an attribute change event might include the width of a column that supported client-side resizing. |
Field Summary | |
---|---|
static org.apache.myfaces.trinidad.bean.PropertyKey |
ACCESS_KEY_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
CLIENT_ATTRIBUTES_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
CLIENT_COMPONENT_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
CLIENT_LISTENERS_KEY |
static java.lang.String |
COMPONENT_FAMILY |
static java.lang.String |
COMPONENT_TYPE |
static java.lang.String |
CONTENT_DELIVERY_IMMEDIATE |
static org.apache.myfaces.trinidad.bean.PropertyKey |
CONTENT_DELIVERY_KEY |
static java.lang.String |
CONTENT_DELIVERY_LAZY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
CUSTOMIZATION_ID_KEY Deprecated. |
static org.apache.myfaces.trinidad.bean.PropertyKey |
DETACHABLE_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
DISABLED_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
ICON_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
INLINE_STYLE_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
PARTIAL_TRIGGERS_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
SHORT_DESC_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
STYLE_CLASS_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
TEXT_KEY |
static org.apache.myfaces.trinidad.bean.FacesBean.Type |
TYPE |
static org.apache.myfaces.trinidad.bean.PropertyKey |
UNSECURE_KEY |
static org.apache.myfaces.trinidad.bean.PropertyKey |
VISIBLE_KEY |
Fields inherited from class org.apache.myfaces.trinidad.component.UIXComponentBase |
---|
BINDING_KEY, ID_KEY, RENDERED_KEY, RENDERER_TYPE_KEY, TRANSIENT_KEY |
Fields inherited from class javax.faces.component.UIComponent |
---|
BEANINFO_KEY, bindings, COMPOSITE_COMPONENT_TYPE_KEY, COMPOSITE_FACET_NAME, CURRENT_COMPONENT, CURRENT_COMPOSITE_COMPONENT, FACETS_KEY, VIEW_LOCATION_KEY |
Constructor Summary | |
---|---|
|
RichMenu() Construct an instance of the RichMenu. |
protected |
RichMenu(java.lang.String rendererType) Construct an instance of the RichMenu. |
Method Summary | |
---|---|
void |
addClientBehavior(java.lang.String eventName, javax.faces.component.behavior.ClientBehavior behavior) |
char |
getAccessKey() Gets a character used to gain quick access to this menu. |
protected org.apache.myfaces.trinidad.bean.FacesBean.Type |
getBeanType() |
java.util.Set |
getClientAttributes() Gets a set of client attribute names. |
java.util.Map<java.lang.String,java.util.List<javax.faces.component.behavior.ClientBehavior>> |
getClientBehaviors() |
ClientListenerSet |
getClientListeners() Gets a set of client listeners. |
java.lang.String |
getContentDelivery() Gets whether the menu content is delivered with the initial page. |
java.lang.String |
getCustomizationId() Deprecated. This attribute is deprecated. This attribute will be removed in the next release. Use the 'id' attribute instead. |
java.lang.String |
getDefaultEventName() |
java.util.Collection<java.lang.String> |
getEventNames() |
java.lang.String |
getFamily() |
java.lang.String |
getIcon() Gets the URI of an image to be displayed on the menu item. |
java.lang.String |
getInlineStyle() Gets the CSS styles to use for this component. |
java.lang.String[] |
getPartialTriggers() Gets the IDs of the components that should trigger a partial update. |
java.lang.String |
getShortDesc() Gets the short description of the component. |
java.lang.String |
getStyleClass() Gets a CSS style class to use for this component. |
java.lang.String |
getText() Gets the text of the item |
java.util.Set<java.lang.String> |
getUnsecure() Gets A whitespace separated list of attributes whose values ordinarily can be set only on the server, but need to be settable on the client. |
boolean |
isClientComponent() Gets whether a client-side component will be generated. |
boolean |
isDetachable() Gets whether the menu is detachable. |
boolean |
isDisabled() Gets whether the menu should be disabled. |
boolean |
isVisible() Gets the visibility of the component. |
void |
setAccessKey(char accessKey) Sets a character used to gain quick access to this menu. |
void |
setClientAttributes(java.util.Set clientAttributes) Sets a set of client attribute names. |
void |
setClientComponent(boolean clientComponent) Sets whether a client-side component will be generated. |
void |
setClientListeners(ClientListenerSet clientListeners) Sets a set of client listeners. |
void |
setContentDelivery(java.lang.String contentDelivery) Sets whether the menu content is delivered with the initial page. |
void |
setCustomizationId(java.lang.String customizationId) Deprecated. This attribute is deprecated. This attribute will be removed in the next release. Use the 'id' attribute instead. |
void |
setDetachable(boolean detachable) Sets whether the menu is detachable. |
void |
setDisabled(boolean disabled) Sets whether the menu should be disabled. |
void |
setIcon(java.lang.String icon) Sets the URI of an image to be displayed on the menu item. |
void |
setInlineStyle(java.lang.String inlineStyle) Sets the CSS styles to use for this component. |
void |
setPartialTriggers(java.lang.String[] partialTriggers) Sets the IDs of the components that should trigger a partial update. |
void |
setShortDesc(java.lang.String shortDesc) Sets the short description of the component. |
void |
setStyleClass(java.lang.String styleClass) Sets a CSS style class to use for this component. |
void |
setText(java.lang.String text) Sets the text of the item |
void |
setUnsecure(java.util.Set<java.lang.String> unsecure) Sets A whitespace separated list of attributes whose values ordinarily can be set only on the server, but need to be settable on the client. |
void |
setVisible(boolean visible) Sets the visibility of the component. |
Methods inherited from class org.apache.myfaces.trinidad.component.UIXComponentBase |
---|
adaptMethodBinding, addAttributeChange, addAttributeChangeListener, addFacesListener, broadcast, broadcastToMethodBinding, broadcastToMethodExpression, clearInitialState, createFacesBean, decode, decodeChildren, decodeChildrenImpl, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributeChangeListener, getAttributeChangeListeners, getAttributes, getBooleanProperty, getChildCount, getChildren, getClientId, getContainerClientId, getFacesBean, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacetNames, getFacets, getFacetsAndChildren, getId, getIntProperty, getLifecycleRenderer, getListenersForEventClass, getParent, getProperty, getPropertyKey, getRenderer, getRendererType, getRendersChildren, getValueBinding, getValueExpression, initialStateMarked, invokeOnChildrenComponents, invokeOnComponent, invokeOnNamingContainerComponent, isRendered, isTransient, markInitialState, processDecodes, processRestoreState, processSaveState, processUpdates, processValidators, queueEvent, removeAttributeChangeListener, removeFacesListener, restoreState, satisfiesPartialTrigger, saveState, setAttributeChangeListener, setAttributeChangeListener, setBooleanProperty, setId, setIntProperty, setParent, setProperty, setRendered, setRendererType, setTransient, setValueBinding, setValueExpression, subscribeToEvent, toString, unsubscribeFromEvent, updateChildren, updateChildrenImpl, validateChildren, validateChildrenImpl |
Methods inherited from class org.apache.myfaces.trinidad.component.UIXComponent |
---|
addPartialTarget, clearCachedClientIds, clearCachedClientIds, encodeFlattenedChild, encodeFlattenedChildren, getLogicalParent, getLogicalParent, getStateHelper, getStateHelper, isVisitable, partialEncodeVisit, processFlattenedChildren, processFlattenedChildren, processFlattenedChildren, processFlattenedChildren, setPartialTarget, setupChildrenEncodingContext, setupChildrenVisitingContext, setupEncodingContext, setUpEncodingContext, setupVisitingContext, tearDownChildrenEncodingContext, tearDownChildrenVisitingContext, tearDownEncodingContext, tearDownVisitingContext, visitAllChildren, visitChildren, visitChildren, visitTree, visitTree |
Methods inherited from class javax.faces.component.UIComponent |
---|
encodeAll, getClientId, getCompositeComponentParent, getContainerClientId, getCurrentComponent, getCurrentCompositeComponent, getNamingContainer, getResourceBundleMap, isCompositeComponent, isInView, popComponentFromEL, processEvent, pushComponentToEL, setInView |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String CONTENT_DELIVERY_IMMEDIATE
public static final java.lang.String CONTENT_DELIVERY_LAZY
public static final org.apache.myfaces.trinidad.bean.FacesBean.Type TYPE
public static final org.apache.myfaces.trinidad.bean.PropertyKey INLINE_STYLE_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey STYLE_CLASS_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey SHORT_DESC_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey UNSECURE_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey VISIBLE_KEY
@Deprecated
public static final org.apache.myfaces.trinidad.bean.PropertyKey CUSTOMIZATION_ID_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey CLIENT_COMPONENT_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey CLIENT_ATTRIBUTES_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey PARTIAL_TRIGGERS_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey CLIENT_LISTENERS_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey CONTENT_DELIVERY_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey DISABLED_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey TEXT_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey ACCESS_KEY_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey DETACHABLE_KEY
public static final org.apache.myfaces.trinidad.bean.PropertyKey ICON_KEY
public static final java.lang.String COMPONENT_FAMILY
public static final java.lang.String COMPONENT_TYPE
Constructor Detail |
---|
public RichMenu()
protected RichMenu(java.lang.String rendererType)
Method Detail |
---|
public final java.lang.String getInlineStyle()
public final void setInlineStyle(java.lang.String inlineStyle)
inlineStyle
- the new inlineStyle valuepublic final java.lang.String getStyleClass()
public final void setStyleClass(java.lang.String styleClass)
styleClass
- the new styleClass valuepublic final java.lang.String getShortDesc()
public final void setShortDesc(java.lang.String shortDesc)
shortDesc
- the new shortDesc valuepublic final java.util.Set<java.lang.String> getUnsecure()
public final void setUnsecure(java.util.Set<java.lang.String> unsecure)
unsecure
- the new unsecure valuepublic final boolean isVisible()
public final void setVisible(boolean visible)
visible
- the new visible value
@Deprecated
public final java.lang.String getCustomizationId()
@Deprecated
public final void setCustomizationId(java.lang.String customizationId)
customizationId
- the new customizationId valuepublic final boolean isClientComponent()
public final void setClientComponent(boolean clientComponent)
clientComponent
- the new clientComponent valuepublic final java.util.Set getClientAttributes()
public final void setClientAttributes(java.util.Set clientAttributes)
clientAttributes
- the new clientAttributes valuepublic final java.lang.String[] getPartialTriggers()
public final void setPartialTriggers(java.lang.String[] partialTriggers)
partialTriggers
- the new partialTriggers valuepublic final ClientListenerSet getClientListeners()
public final void setClientListeners(ClientListenerSet clientListeners)
clientListeners
- the new clientListeners valuepublic final java.lang.String getContentDelivery()
Note that for a menu popup (a menu component placed directly inside a popup component) both the menu and the popup have a content delivery setting. In this case the popup's contentDelivery setting has precedence, and the menu's content delivery setting is ignored.
public final void setContentDelivery(java.lang.String contentDelivery)
Note that for a menu popup (a menu component placed directly inside a popup component) both the menu and the popup have a content delivery setting. In this case the popup's contentDelivery setting has precedence, and the menu's content delivery setting is ignored.
contentDelivery
- the new contentDelivery valuepublic final boolean isDisabled()
public final void setDisabled(boolean disabled)
disabled
- the new disabled valuepublic final java.lang.String getText()
public final void setText(java.lang.String text)
text
- the new text valuepublic final char getAccessKey()
If the same access key appears in multiple input fields in the same page of output, the rendering user agent will cycle among the elements accessed by the similar keys. Note that user agents are inconsistent about dealing with two links having same access key, and so the cycling behavior is dependent on what the user agent provides.
This attribute is sometimes referred to as the "mnemonic".
The character specified by this attribute must exist in the Text
attribute of this button instance. If it does not, the user will receive no visual indication of the existence of the accessKey. The easiest, and most convenient way to specify both the text and the mnemonic together is to use textAndAccessKey.
Note that the accessKey is triggered by browser-specific and platform-specific modifier keys. It even has browser-specific meaning. For example, Internet Explorer will set focus when you press Alt+<accessKey>. Firefox sets focus on some operating systems when you press Alt+Shift+<accessKey>. Firefox on other operating systems sets focus when you press Control+<accessKey>. Refer to your browser's documentation for how it treats access keys.
Beyond normal type menu access key behavior, menus and commandMenuItems support menu-type access key behavior when the focus is currently in a menu or menuBar. Menu-type access key behavior allows access to contained menus, submenus, and commandMenuItems without the need for any keyboard modifiers. When the focus is inside a menu or menuBar, you can simply press the accessKey, without modifiers, for a menu or commandMenuItem accessible within the menu or menuBar to immediately move focus to that menu item.
public final void setAccessKey(char accessKey)
If the same access key appears in multiple input fields in the same page of output, the rendering user agent will cycle among the elements accessed by the similar keys. Note that user agents are inconsistent about dealing with two links having same access key, and so the cycling behavior is dependent on what the user agent provides.
This attribute is sometimes referred to as the "mnemonic".
The character specified by this attribute must exist in the Text
attribute of this button instance. If it does not, the user will receive no visual indication of the existence of the accessKey. The easiest, and most convenient way to specify both the text and the mnemonic together is to use textAndAccessKey.
Note that the accessKey is triggered by browser-specific and platform-specific modifier keys. It even has browser-specific meaning. For example, Internet Explorer will set focus when you press Alt+<accessKey>. Firefox sets focus on some operating systems when you press Alt+Shift+<accessKey>. Firefox on other operating systems sets focus when you press Control+<accessKey>. Refer to your browser's documentation for how it treats access keys.
Beyond normal type menu access key behavior, menus and commandMenuItems support menu-type access key behavior when the focus is currently in a menu or menuBar. Menu-type access key behavior allows access to contained menus, submenus, and commandMenuItems without the need for any keyboard modifiers. When the focus is inside a menu or menuBar, you can simply press the accessKey, without modifiers, for a menu or commandMenuItem accessible within the menu or menuBar to immediately move focus to that menu item.
accessKey
- the new accessKey valuepublic final boolean isDetachable()
Detachable is always considered 'false' in screen reader mode and on iOS (Apple mobile devices).
public final void setDetachable(boolean detachable)
Detachable is always considered 'false' in screen reader mode and on iOS (Apple mobile devices).
detachable
- the new detachable valuepublic final java.lang.String getIcon()
public final void setIcon(java.lang.String icon)
icon
- the new icon valuepublic java.lang.String getDefaultEventName()
getDefaultEventName
in interface javax.faces.component.behavior.ClientBehaviorHolder
getDefaultEventName
in class org.apache.myfaces.trinidad.component.UIXComponentBase
public java.util.Collection<java.lang.String> getEventNames()
getEventNames
in interface javax.faces.component.behavior.ClientBehaviorHolder
public java.util.Map<java.lang.String,java.util.List<javax.faces.component.behavior.ClientBehavior>> getClientBehaviors()
getClientBehaviors
in interface javax.faces.component.behavior.ClientBehaviorHolder
getClientBehaviors
in class org.apache.myfaces.trinidad.component.UIXComponentBase
public void addClientBehavior(java.lang.String eventName, javax.faces.component.behavior.ClientBehavior behavior)
addClientBehavior
in interface javax.faces.component.behavior.ClientBehaviorHolder
addClientBehavior
in class org.apache.myfaces.trinidad.component.UIXComponentBase
public java.lang.String getFamily()
getFamily
in class org.apache.myfaces.trinidad.component.UIXPanel
protected org.apache.myfaces.trinidad.bean.FacesBean.Type getBeanType()
getBeanType
in class org.apache.myfaces.trinidad.component.UIXPanel
|
Oracle Fusion Middleware Java API Reference for Oracle ADF Faces 11g Release 2 (11.1.2.0.0) E17488-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |