Class ReportCellRankMetric
- java.lang.Object
-
- com.microstrategy.web.app.gui.ContextMenu.DefaultContextMenuItemBuilder
-
- com.microstrategy.web.app.transforms.contextmenus.AbstractReportCellContextMenuItemBuilder
-
- com.microstrategy.web.app.transforms.contextmenus.AbstractReportCellComposedContextMenuItemBuilder
-
- com.microstrategy.web.app.transforms.contextmenus.ReportCellRankMetric
-
- All Implemented Interfaces:
ContextMenuItemBuilder
public class ReportCellRankMetric extends AbstractReportCellComposedContextMenuItemBuilder
TheReportCellRankMetric
represents a context menu item builder that will hold a sub-menu structure with a list of the options that a user is enabled to access for inserting new ranking metrics based on the grid information, available on the context. The different submenu options are generated automatically based on the template structure; if no children options are defined on its submenu (lack of privileges, conditions required not met by the current context, etc) the option will automatically be ignored and the final context menu will not display it.- Since:
- MicroStrategy Web 8.0.1
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
ReportCellRankMetric.AbstractInsertMetricContextMenuBuilder
Abstract base implementation of theReportCellRankMetric.InsertMetricContextMenuBuilder
class.protected static interface
ReportCellRankMetric.InsertMetricContextMenuBuilder
Helper builder interface that allows generating the different insert metric options for the current cell that shall be displayed to the user.protected static class
ReportCellRankMetric.InvalidInsertMetricContextMenuBuilder
Implementation of theReportCellRankMetric.InsertMetricContextMenuBuilder
interface for representing a builder instance corresponding to a non-supported context.
-
Constructor Summary
Constructors Constructor Description ReportCellRankMetric(Shortcut definition)
Class constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ContextMenu
generateSubMenu(TransformContext context)
Get the submenu that will display the different sub-menu options to the user.protected ComposedContextMenuBuilder
getComposedContextMenuBuilder(TransformContext context)
Get an instance ofReportCellRankMetric.InsertMetricContextMenuBuilder
that will help obtaining the different insert metric options that shall be presented to the user.protected boolean
isActionEnabled(TransformContext context)
Called byisItemAvailable(com.microstrategy.web.app.transforms.TransformContext)
, indicates the abstract class if the corresponding action of this item is available.boolean
isItemAvailable(TransformContext context)
Determines if the option shall be available to the user or not.-
Methods inherited from class com.microstrategy.web.app.transforms.contextmenus.AbstractReportCellComposedContextMenuItemBuilder
createItem, getJSCode, itemHasSubMenus
-
Methods inherited from class com.microstrategy.web.app.transforms.contextmenus.AbstractReportCellContextMenuItemBuilder
canDefineDerivedElements, getCell, getFormalParameter, getIntValue, getPassThroughMode, getStringValue, getTransform, isFeatureAvailable, isIframeEnabled, isRW, isTrue
-
Methods inherited from class com.microstrategy.web.app.gui.ContextMenu.DefaultContextMenuItemBuilder
createItem, getDefinition, getItemKey, getScript
-
-
-
-
Method Detail
-
generateSubMenu
public ContextMenu generateSubMenu(TransformContext context)
Description copied from class:AbstractReportCellComposedContextMenuItemBuilder
Get the submenu that will display the different sub-menu options to the user.- Overrides:
generateSubMenu
in classAbstractReportCellComposedContextMenuItemBuilder
- Parameters:
context
-TransformContext
initialized instance with the information on where this option will be used- Returns:
ContextMenu
instance initialized with all the options that can be presented to the user.
-
getComposedContextMenuBuilder
protected ComposedContextMenuBuilder getComposedContextMenuBuilder(TransformContext context)
Get an instance ofReportCellRankMetric.InsertMetricContextMenuBuilder
that will help obtaining the different insert metric options that shall be presented to the user.- Specified by:
getComposedContextMenuBuilder
in classAbstractReportCellComposedContextMenuItemBuilder
- Parameters:
context
-TransformContext
initialized instance with the information on where this option will be used- Returns:
ReportCellRankMetric.InsertMetricContextMenuBuilder
initialized instance. Calling its generateInsertMetricSubMenu method provides theContextMenu
with the different insert metric options available. Returns an instance of (ReportCellRankMetric.InvalidInsertMetricContextMenuBuilder
if not supported.
-
isActionEnabled
protected boolean isActionEnabled(TransformContext context)
Called byisItemAvailable(com.microstrategy.web.app.transforms.TransformContext)
, indicates the abstract class if the corresponding action of this item is available.- Specified by:
isActionEnabled
in classAbstractReportCellContextMenuItemBuilder
- Parameters:
context
-TransformContext
initialized instance with the information on where this option will be used- Returns:
- boolean value indicating if the option should be enabled to the user or not, given the properties available on the context object.
-
isItemAvailable
public boolean isItemAvailable(TransformContext context)
Description copied from class:AbstractReportCellContextMenuItemBuilder
Determines if the option shall be available to the user or not.- Specified by:
isItemAvailable
in interfaceContextMenuItemBuilder
- Overrides:
isItemAvailable
in classAbstractReportCellContextMenuItemBuilder
- Parameters:
context
-TransformContext
initialized instance with the information on where this option will be used- Returns:
- boolean value indicating if the option should be enabled to the user or not, given the properties available on the context object.
-
-