Class ReportCellDrill
- 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.ReportCellDrill
-
- All Implemented Interfaces:
ContextMenuItemBuilder
- Direct Known Subclasses:
ReportGraphDrill
public class ReportCellDrill extends AbstractReportCellComposedContextMenuItemBuilder
TheReportCellDrill
represents a context menu item builder that will generate a sub-menu structure with a list of the options that a user is enabled to access for navigating different drill paths for the current grid cell selected, specified on the context.- Since:
- MicroStrategy Web 8.0.1
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ReportCellDrill.AbstractDrillContextMenuBuilder
Abstract base implementation of theReportCellDrill.DrillContextMenuBuilder
class.protected static interface
ReportCellDrill.DrillContextMenuBuilder
Helper builder interface that allows generating the different drill path options for the current cell that shall be displayed to the user.static class
ReportCellDrill.HeaderDrillContextMenuBuilder
Relevant to WebHeader (could be MetricHeader, AttributeHeader or DimensionHeaderprotected static class
ReportCellDrill.InvalidDrillContextMenuBuilder
Implementation of theReportCellDrill.DrillContextMenuBuilder
interface for representing a builder instance corresponding to a non-supported context.static class
ReportCellDrill.RowValueDrillContextMenuBuilder
Relavant for metric cell valuesstatic class
ReportCellDrill.TitleDrillContextMenuBuilder
Relevant to WebTitle related to attribute or metric
-
Constructor Summary
Constructors Constructor Description ReportCellDrill(Shortcut definition)
Class constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addExtraSubMenuOptions(ContextMenu cm)
This methods can be used to add extra options to the drill menu option.ContextMenuItem
createItem(TransformContext context)
Creates and populates aContextMenuItem
based on the information in theShortcut
used as its definition, as well as the logic included on this builder instance.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 ofReportCellDrill.DrillContextMenuBuilder
that will help obtaining the different drill options that shall be presented to the user.protected ReportCellDrill.AbstractDrillContextMenuBuilder
getDrillContextMenuBuilder(TransformContext context)
java.lang.String
getItemKey(TransformContext context)
Retrieve the key will be set on the context menu item corresponding to the context input.protected boolean
isActionEnabled(TransformContext context)
Called byAbstractReportCellContextMenuItemBuilder.isItemAvailable(com.microstrategy.web.app.transforms.TransformContext)
, indicates the abstract class if the corresponding action of this item is available.protected boolean
itemHasSubMenus(ContextMenuItem item, TransformContext context)
protected void
setOndemandMenuItemProperties(ContextMenuItem item, TransformContext context)
Sets the properties on "Drill" ContextMenuItems which is essential for populating of ondemand drilling items for grids.protected static void
setOndemandProperties(ContextMenuItem item, ReportCellDrill.AbstractDrillContextMenuBuilder subMenuBuilder)
Sets the properties on "Drill" ContextMenuItem which is essential for populating of ondemand drilling items for grids.protected boolean
shuoldAddExtraSubMenuOptions(TransformContext context)
-
Methods inherited from class com.microstrategy.web.app.transforms.contextmenus.AbstractReportCellComposedContextMenuItemBuilder
getJSCode
-
Methods inherited from class com.microstrategy.web.app.transforms.contextmenus.AbstractReportCellContextMenuItemBuilder
canDefineDerivedElements, getCell, getFormalParameter, getIntValue, getPassThroughMode, getStringValue, getTransform, isFeatureAvailable, isIframeEnabled, isItemAvailable, isRW, isTrue
-
Methods inherited from class com.microstrategy.web.app.gui.ContextMenu.DefaultContextMenuItemBuilder
createItem, getDefinition, getScript
-
-
-
-
Method Detail
-
createItem
public ContextMenuItem createItem(TransformContext context)
Creates and populates aContextMenuItem
based on the information in theShortcut
used as its definition, as well as the logic included on this builder instance.- Specified by:
createItem
in interfaceContextMenuItemBuilder
- Overrides:
createItem
in classAbstractReportCellComposedContextMenuItemBuilder
- Parameters:
context
-TransformContext
initialized instance with the information on where this option will be used- Returns:
- a new instance of a
ContextMenuItem
initialized with the option information to present to the user.
-
itemHasSubMenus
protected boolean itemHasSubMenus(ContextMenuItem item, TransformContext context)
- Overrides:
itemHasSubMenus
in classAbstractReportCellComposedContextMenuItemBuilder
- Since:
- MicroStrategy Web 9.0.0
-
setOndemandMenuItemProperties
protected void setOndemandMenuItemProperties(ContextMenuItem item, TransformContext context)
Sets the properties on "Drill" ContextMenuItems which is essential for populating of ondemand drilling items for grids.- Parameters:
item
- a ContextMenuItemcontext
- a TransformContext- Since:
- MicroStrategy Web 9.0.0
-
setOndemandProperties
protected static void setOndemandProperties(ContextMenuItem item, ReportCellDrill.AbstractDrillContextMenuBuilder subMenuBuilder)
Sets the properties on "Drill" ContextMenuItem which is essential for populating of ondemand drilling items for grids. The properties set are: onDemandJUILModelID, represents the id of the model for ondemand menus onDemandJUILViewID, represents the id of the view for ondemand menus onDemandDynamicMenusKey, represents the key to store the submenu of "Drill" ContextMenuItem and is used byReportCellDrill.AbstractDrillContextMenuBuilder.getSubMenu()
The method is static since it is also used in ReportPageByCellDrill class
- Parameters:
item
- ContextMenuItemsubMenuBuilder
-- Since:
- MicroStrategy Web 9.0.0
-
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.
-
shuoldAddExtraSubMenuOptions
protected boolean shuoldAddExtraSubMenuOptions(TransformContext context)
- Since:
- MicroStrategy Web 9.0.0
-
addExtraSubMenuOptions
public void addExtraSubMenuOptions(ContextMenu cm)
This methods can be used to add extra options to the drill menu option.
By default this method does nothing- Parameters:
cm
- the ContextMenu object- Since:
- MicroStrategy Web 8.1.2
-
getItemKey
public java.lang.String getItemKey(TransformContext context)
Description copied from class:ContextMenu.DefaultContextMenuItemBuilder
Retrieve the key will be set on the context menu item corresponding to the context input. The context menu item generated based on the same context input will have the same key. This method can be called by context menu before callingContextMenu.DefaultContextMenuItemBuilder.createItem(TransformContext)
to check whether the item already exists in the menu to avoid unnecessary creation.- Specified by:
getItemKey
in interfaceContextMenuItemBuilder
- Overrides:
getItemKey
in classContextMenu.DefaultContextMenuItemBuilder
- Parameters:
context
- The context for context menu item creation- Returns:
- The key for the context menu item if created using the context. By default
null
will be return, which means build has no knowledge about the item key. Then context menu item may generate the key by itself. For builder who wants avoid unnecessary item creation should take advantage of this method by overriding with a meaningful implementation. - Since:
- MicroStrategy Web 9.0.0
-
getDrillContextMenuBuilder
protected ReportCellDrill.AbstractDrillContextMenuBuilder getDrillContextMenuBuilder(TransformContext context)
- Since:
- MicroStrategy Web 9.0.0
-
getComposedContextMenuBuilder
protected ComposedContextMenuBuilder getComposedContextMenuBuilder(TransformContext context)
Get an instance ofReportCellDrill.DrillContextMenuBuilder
that will help obtaining the different drill 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:
ReportCellDrill.DrillContextMenuBuilder
initialized instance. Calling itsComposedContextMenuBuilder.generateSubMenu()
method provides theContextMenu
with the different drill paths available. Returns an instance of (ReportCellAttributeForms.InvalidAttributeFormsContextMenuBuilder
if not supported.
-
isActionEnabled
protected boolean isActionEnabled(TransformContext context)
Called byAbstractReportCellContextMenuItemBuilder.isItemAvailable(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.
-
-