Class AbstractShortcutList
- java.lang.Object
-
- com.microstrategy.web.app.gui.AbstractGuiElement
-
- com.microstrategy.web.app.gui.shortcuts.AbstractShortcutList
-
- All Implemented Interfaces:
GuiElement,ShortcutListElement
- Direct Known Subclasses:
ShortcutListPicker,ShortcutListStyles
public abstract class AbstractShortcutList extends AbstractGuiElement implements ShortcutListElement
This abstractGuiElementimplementation serves as base for rendering information about the different types ofShortcutListElementa toolbar might use for displaying its different options to the user.- Since:
- MicroStrategy Web 8.0.0
-
-
Field Summary
-
Fields inherited from class com.microstrategy.web.app.gui.AbstractGuiElement
_appContext, _name, _webComponent
-
-
Constructor Summary
Constructors Constructor Description AbstractShortcutList()Class constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddAttributesToTag(Tag tag, WebAttributeList attributes)Convenience method for adding properties to theTaginstance, based on the attribute information sent as parameter.protected WebComponentgetFeaturesRoot()Get theWebComponentinstance that will be used as base for testing features.java.lang.StringgetGroupCss()Get the css class for the main div that contains theShortcutList.java.lang.StringgetId()Get the id for the main div that contains theShortcutList.ShortcutListgetShortcutList()Get theShortcutListinstance to be rendered by this elementprotected booleanisEnabled(ShortcutList list)Utility method that tests if theShortcutListinstance shall be enabled for the user.booleanisIncludeSubItems()This flag indicates whether the HTML should include the subitems content when this element is rendered.booleanisShowPrefixElements()Indicates whether there are children elements maked as "Prefix" that should be included in the output as such.booleanisShowSuffixElements()Indicates whether there are children elements maked as "Suffix" that should be included in the output as such.MarkupOutputrenderElement()Render the instance according to the information provided on its configuration.voidsetGroupCss(java.lang.String css)Set the css class for the main div that contains theShortcutList.voidsetId(java.lang.String id)Set the id for the main div that contains theShortcutList.voidsetIncludeSubItems(boolean value)This flag indicates whether the HTML should include the subitems content when this element is rendered.voidsetShortcutList(ShortcutList _config)Set theShortcutListinstance to be rendered by this elementvoidsetShowPrefixElements(boolean value)Set the boolean flag value that indicates whether there are children elements maked as "Prefix" that should be included in the output as such.voidsetShowSuffixElements(boolean value)Set the boolean flag value that indicates whether there are children elements maked as "Suffix" that should be included in the output as such.-
Methods inherited from class com.microstrategy.web.app.gui.AbstractGuiElement
getAppContext, getDescriptor, getDescriptor, getDescriptor, getEventManager, getExtraInput, getExtraUrl, getFeatures, getMessages, getName, getTagsFactory, getUseIFrame, getWebComponent, isDhtml, isIFrameEnabled, newHiddenInputBuilder, newNamespaceEncoder, newURIBuilder, renderElement, setAppContext, setExtraInput, setExtraUrl, setName, setUseIFrame, setWebComponent
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.microstrategy.web.app.gui.GuiElement
getAppContext, getDescriptor, getDescriptor, getEventManager, getExtraInput, getExtraUrl, getFeatures, getMessages, getName, getUseIFrame, getWebComponent, renderElement, setAppContext, setExtraInput, setExtraUrl, setName, setUseIFrame, setWebComponent
-
-
-
-
Method Detail
-
renderElement
public MarkupOutput renderElement()
Render the instance according to the information provided on its configuration.- Specified by:
renderElementin interfaceGuiElement- Specified by:
renderElementin classAbstractGuiElement- Returns:
MarkupOutputinstance initialized with the HTML information to display to the user.
-
getFeaturesRoot
protected WebComponent getFeaturesRoot()
Get theWebComponentinstance that will be used as base for testing features.- Returns:
- the
WebComponentto use as the root to check features (i.e. check-feature, active-feature, etc.)
-
addAttributesToTag
protected void addAttributesToTag(Tag tag, WebAttributeList attributes)
Convenience method for adding properties to theTaginstance, based on the attribute information sent as parameter.- Parameters:
tag-Taginstance where the attribute information shall be addedattributes-WebAttributeListinstance with the attribute information to add to theTag, as name and value pairs.
-
setShortcutList
public void setShortcutList(ShortcutList _config)
Set theShortcutListinstance to be rendered by this element- Specified by:
setShortcutListin interfaceShortcutListElement- Parameters:
_config-ShortcutListinstance to be rendered by this GUI element.
-
getShortcutList
public ShortcutList getShortcutList()
Get theShortcutListinstance to be rendered by this element- Specified by:
getShortcutListin interfaceShortcutListElement- Returns:
- the current
ShortcutListinstance associated with this element
-
setIncludeSubItems
public void setIncludeSubItems(boolean value)
This flag indicates whether the HTML should include the subitems content when this element is rendered.- Specified by:
setIncludeSubItemsin interfaceShortcutListElement- Parameters:
value- boolean value of true if shortcut should include it automatically.
-
isIncludeSubItems
public boolean isIncludeSubItems()
This flag indicates whether the HTML should include the subitems content when this element is rendered.- Specified by:
isIncludeSubItemsin interfaceShortcutListElement- Returns:
- boolean true if subitems content will be included when the element is rendered.
-
setShowPrefixElements
public void setShowPrefixElements(boolean value)
Set the boolean flag value that indicates whether there are children elements maked as "Prefix" that should be included in the output as such.- Specified by:
setShowPrefixElementsin interfaceShortcutListElement- Parameters:
value- boolean true if these children should be rendered.
-
isShowPrefixElements
public boolean isShowPrefixElements()
Indicates whether there are children elements maked as "Prefix" that should be included in the output as such.- Specified by:
isShowPrefixElementsin interfaceShortcutListElement- Returns:
- boolean true if children marked as "Prefix" are included when the element is rendered.
-
setShowSuffixElements
public void setShowSuffixElements(boolean value)
Set the boolean flag value that indicates whether there are children elements maked as "Suffix" that should be included in the output as such.- Specified by:
setShowSuffixElementsin interfaceShortcutListElement- Parameters:
value-booleanvalue indicating if these children should be rendered.
-
isShowSuffixElements
public boolean isShowSuffixElements()
Indicates whether there are children elements maked as "Suffix" that should be included in the output as such.- Specified by:
isShowSuffixElementsin interfaceShortcutListElement- Returns:
- boolean true if children marked as "Suffix" are included when the element is rendered.
-
setGroupCss
public void setGroupCss(java.lang.String css)
Set the css class for the main div that contains theShortcutList.- Specified by:
setGroupCssin interfaceShortcutListElement- Parameters:
css- the new css class to use. By default the value is "group:
-
setId
public void setId(java.lang.String id)
Set the id for the main div that contains theShortcutList.- Specified by:
setIdin interfaceShortcutListElement- Parameters:
id-Stringvalue with the identifier for the instance.
-
getId
public java.lang.String getId()
Get the id for the main div that contains theShortcutList.- Specified by:
getIdin interfaceShortcutListElement- Returns:
- the current id for the main div that contains the ShortcutList. If an id has not been set it uses the name of the associated ShortcutList If no ShortcutList is associated, it then returns null.
-
getGroupCss
public java.lang.String getGroupCss()
Get the css class for the main div that contains theShortcutList.- Specified by:
getGroupCssin interfaceShortcutListElement- Returns:
- the current css class for the main div that contains the ShortcutList.
-
isEnabled
protected boolean isEnabled(ShortcutList list)
Utility method that tests if theShortcutListinstance shall be enabled for the user.- Parameters:
list-ShortcutListinstance to test- Returns:
booleanvalue indicating if the instance tested is enabled or not.
-
-