java.lang.Object | |
↳ | com.microstrategy.web.app.beans.GraphFormatHelper |
This class provides a series of methods that aid on the manipulation of graph formatting properties.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | LocalShowGraphAttributeID | Enum for undefined graph property | |||||||||
int | SHOW_MAXIMUM_INDEX | Index value pointing to the place where it indicates if the maximum property should be shown or not. | |||||||||
int | SHOW_MINIMUM_INDEX | Index value pointing to the place where it indicates if the minimum property should be shown or not. | |||||||||
int | VALUE_MAXIMUM_INDEX | Index value pointing to the place where the maximum value is located. | |||||||||
int | VALUE_MINIMUM_INDEX | Index value pointing to the place where the minimum value is located. |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
GraphFormatHelper() |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
static ImageTag |
generateMacroInformationTag(WebComponent wc)
Generates an information image tag with tooltip details about how macros can be used
on text fields for content properties on a graph.
| ||||||||||
static Tag[] |
generateMajorGraphTypesImages(WebComponent bean, AppContext appContext, ShortcutList majorTypePicker, String paramNamePrefix, String currentValue, String selectedCss)
Generate a series of
Tag objects corresponding to images
for the graph major type picker requested. | ||||||||||
static Tag |
generateMinorGraphTypesCombo(WebComponent bean, AppContext appContext, ShortcutList minorTypePicker, String paramName, String currentValue)
Generate a
Tag instance with all the information required for displaying
the user the different options for graph minor type. | ||||||||||
static GraphTitleInformation[] |
getApplicableAxisTitles(int majorType, int minorType)
This method is deprecated.
please use
getGraphAxisTargets() and
getGraphTitleTargets() instead | ||||||||||
static GraphTitleInformation[] |
getApplicableAxisTitles()
This method is deprecated.
please use
getGraphAxisTargets() and
getGraphTitleTargets() instead
| ||||||||||
static GraphTitleInformation[] |
getApplicableAxisTitles(int majorType)
This method is deprecated.
Please use the interface that receives both major and minor types as arguments. The logic for validating
which axis are applicable depend on these two properties.
| ||||||||||
static GraphAxisInformation[] |
getApplicableAxisValues(int majorType)
Given the graph major type, it gets the list of axis that should be enabled to be modified and
included as arguments for the formatting event to handle axis values.
| ||||||||||
static int |
getGraphAttributeID(int objectID)
Utility method taht based on the objectID sent as parameter, get the corresponding attribute ID for its show flag
| ||||||||||
static int |
getGraphAttributeID(int objectID, int seriesID)
Utility method that based on the objectID sent as parameter, get the corresponding attribute ID for its show flag
| ||||||||||
static GraphTitleInformation[] | getGraphAxisTargets() | ||||||||||
static GraphTitleInformation[] | getGraphFormatTargets() | ||||||||||
static GraphTitleInformation[] | getGraphLabelTargets() | ||||||||||
static int |
getGraphNumFormatAttributeID(int objectID)
Utility method that based on the objectID sent as parameter, get the corresponding attribute ID used for Graph number format attribute
| ||||||||||
static int |
getGraphNumFormatObjectID(int objectID)
Utility method that adjust the objectID for Graph number format attribute
| ||||||||||
static String |
getGraphProperty(WebGraphProperties graphProperties, int objectID, int attributeID, int seriesID)
Retrieves the requested property from the graph
| ||||||||||
static String |
getGraphProperty(WebGraphProperties graphProperties, int objectID, int attributeID)
Retrieves the requested property from the graph
| ||||||||||
static ArrayList |
getGraphSeries(int maxSeries, WebGraphProperties graphProperties)
Based on the graph properties provided, returns an ArrayList instance with
WebGraphProperty elements of all the series available. | ||||||||||
static ArrayList |
getGraphSeriesColorTargets(AppContext appContext, WebGraphProperties graphProperties)
Get the information about the applicable series color targets, depending on the
major and minor types currently associated with the graph
| ||||||||||
static GraphSeriesInformation[] | getGraphSeriesColorTargets(int major, int minor) | ||||||||||
static ArrayList |
getGraphSeriesColorTargets(AppContext appContext, WebGraphProperties graphProperties, GraphSeriesTargetInfo gstInfo)
Get the information about the applicable series label targets, depending on the
major and minor types currently associated with the graph
| ||||||||||
static GraphSeriesInformation[] |
getGraphSeriesLabelTargets(int major, int minor)
Get the information about the applicable series label targets, depending on the
major and minor types currently associated with the graph
| ||||||||||
static ArrayList | getGraphSeriesLabelTargets(AppContext appContext, WebGraphProperties graphProperties, GraphSeriesTargetInfo gstInfo) | ||||||||||
static GraphSeriesTargetInfo | getGraphSeriesTargetInfo(WebGraph graphObj, boolean isRWBean) | ||||||||||
static GraphTitleInformation[] | getGraphTitleTargets() | ||||||||||
static int | getMaxGraphSeries(WebGraph graphObj) | ||||||||||
static String | getPropertyValue(WebGraphProperties graphProperties, int objectId, int attributeId) | ||||||||||
static String | getPropertyValue(WebGraphProperties graphProperties, int objectId, int attributeId, int seriesId) | ||||||||||
static int |
getRiserObjectID(int orgRiserID)
This method is to transform some special riser id to the common riser id
If the original id is not a valid riser object id, just maintain it
| ||||||||||
static int |
getSupportPropertyId(int attributeID)
Returns the grouping category id for an attribute id
| ||||||||||
static String |
getValueForAllSeriesLabelTarget(WebGraphProperties graphProperties, ArrayList graphSeries, int orgAttributeId, WebComponent bean)
This method is designed to compute the related property value for "All Data Label" target.
| ||||||||||
static String |
getValueForAllTitleTarget(WebGraphProperties graphProperties, GraphTitleInformation[] availableTitles, int objectId, int attributeId, WebComponent bean)
This method is designed to compute the related property value for those "all" target, such as: All Text, All Titles, All Axes
We check values of sub targets for each "all" target.
| ||||||||||
static boolean |
hasPrivilegesForTitle(WebComponent bean, int objectId)
This method can check if user has format privilege on giving title item.
| ||||||||||
static boolean |
isCombinableAttr(int attributeId)
For some attribute, we can't directly get property value for "All" target.
| ||||||||||
static boolean |
isGraph3D(int majorType)
This method determines if the graph major type sent as parameter corresponds to a 3D graph type
| ||||||||||
static boolean |
isLegendSupported(int majorType)
Determines given the major graph type if Legends are supported or not
| ||||||||||
static boolean |
isTargetForAll(int graphTargetID)
This method determines whether the graph target is a place holder for All items (e.g.
| ||||||||||
static String |
obtainMajorTypesFilter(Hashtable exceptValues)
Utility method to generate a filter that will be used for determining which objects will be shown or not to the
user, based on the graph major type currently selected.
| ||||||||||
static String |
obtainMajorTypesFilter(int[] includeValues)
Utility method to generate a filter that will be used for determining which objects will be shown or not to the
user, based on the graph major type currently selected.
| ||||||||||
static void |
renderMajorGraphTypes(MarkupOutput out, int availableGraphTypes, int currentGraphType, String imgSourcePath, String majorTypeParam, AppContext appContext)
This method is deprecated.
No replacement.
| ||||||||||
static void |
renderMinorGraphTypes(MarkupOutput out, int currentGraphType, int currentMinorType, String minorTypeParam, AppContext appContext, String extraParameters)
This method is deprecated.
No replacement.
| ||||||||||
static String |
retrieveIntervalValues(String interval)
Processes the interval property value obtained from the metadata
| ||||||||||
static String[] |
retrieveMinMaxFromScale(String scale)
Based on the Scale string, retrieve the values of the properties to use
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Enum for undefined graph property
Index value pointing to the place where it indicates if the maximum property should be shown or not.
Index value pointing to the place where it indicates if the minimum property should be shown or not.
Index value pointing to the place where the maximum value is located.
Index value pointing to the place where the minimum value is located.
Generates an information image tag with tooltip details about how macros can be used on text fields for content properties on a graph.
wc | WebComponent initialized instance |
---|
ImageTag
instance initialized as an image with the macro information
to display to the user as its tooltip.Generate a series of Tag
objects corresponding to images
for the graph major type picker requested.
bean | WebComponent base bean from where Messages and features
can be asked |
---|---|
appContext | AppContext instance from where Messages can
be retrieved |
majorTypePicker | ShortcutList instance with the information of the
major types to render |
paramNamePrefix | String value with the prefix name for the resulting image tags. |
currentValue | String value with the current major type selected |
selectedCss | String value with the css class to assign to the currently selected graph major type image. |
Tag
instances including each one
of the images of the major types to render to the userGenerate a Tag
instance with all the information required for displaying
the user the different options for graph minor type.
bean | WebComponent base bean from where Messages and features
can be asked |
---|---|
appContext | AppContext instance from where Messages can
be retrieved |
minorTypePicker | ShortcutList instance with the information of the
minor types to render |
paramName | String value with the name the resulting select box tag will have |
currentValue | String value with the current minor type selected |
Tag
instance initialized with all the information and
options to present to the user as graph minor types available.
This method is deprecated.
please use getGraphAxisTargets()
and
getGraphTitleTargets()
instead
Given the graph major and minor type, it gets the list of titles that should be enabled to be modified and included as arguments for the formatting event to handle axis titles.
majorType | an element of the EnumDSSXMLMajorGraphTypes enumeration |
---|---|
minorType | the minor type selected |
GraphTitleInformation
instances that contain the information of the axis titles
applicable given the graph major and minor type.
This method is deprecated.
please use getGraphAxisTargets()
and
getGraphTitleTargets()
instead
GraphTitleInformation
instances that contain the information of the axis titles
that can be shown to the user.
This method is deprecated.
Please use the interface that receives both major and minor types as arguments. The logic for validating
which axis are applicable depend on these two properties.
Given the graph major type, it gets the list of axis that should be enabled to be modified and included as arguments for the formatting event to handle axis titles.
majorType | an element of the EnumDSSXMLMajorGraphTypes enumeration |
---|
GraphTitleInformation
instances that contain the information of the axis titles
applicable given the graph major type.Given the graph major type, it gets the list of axis that should be enabled to be modified and included as arguments for the formatting event to handle axis values.
majorType | an element of the EnumDSSXMLMajorGraphTypes enumeration |
---|
GraphAxisInformation
instances containing the information of the axis titles
applicable given the graph major type.
For the ObjectID related with this axis, for these properties EnumDSSXMLGraphObjectID.DssXmlObjectIDNull
should be used, that's why this method doesn't include this value.
Utility method taht based on the objectID sent as parameter, get the corresponding attribute ID for its show flag
objectID | the object being analyzed |
---|
EnumDSSXMLGraphAttributeID
enumeration corresponding to the show flag
for the object requestedUtility method that based on the objectID sent as parameter, get the corresponding attribute ID for its show flag
objectID | the object being analyzed |
---|---|
seriesID | the series being analyzed |
EnumDSSXMLGraphAttributeID
enumeration corresponding to the show flag
for the object requestedUtility method that based on the objectID sent as parameter, get the corresponding attribute ID used for Graph number format attribute
objectID | the object being analyzed |
---|
EnumDSSXMLGraphAttributeID
enumeration corresponding to Graph number format attributeUtility method that adjust the objectID for Graph number format attribute
objectID | the object being analyzed |
---|
EnumDSSXMLGraphObjectID
enumeration used in Graph number formatRetrieves the requested property from the graph
graphProperties | a WebGraphProperties initialized instance |
---|---|
objectID | a valid objectID for the property |
attributeID | a valid attributeID for the property |
seriesID | a valid seriesID for the property |
Retrieves the requested property from the graph
graphProperties | a WebGraphProperties initialized instance |
---|---|
objectID | a valid objectID for the property |
attributeID | a valid attributeID for the property |
Based on the graph properties provided, returns an ArrayList instance with
WebGraphProperty
elements of all the series available.
graphProperties | WebGraphProperties initialized instance |
---|
WebGraphProperty
elements
corresponding to each one of the visible series available on the graph.Get the information about the applicable series color targets, depending on the major and minor types currently associated with the graph
appContext | AppContext instance |
---|---|
graphProperties | WebGraphProperties instance related to the graph to analyze |
GraphSeriesInformation
instances with the
applicable series color targetsGet the information about the applicable series label targets, depending on the major and minor types currently associated with the graph
appContext | AppContext instance |
---|---|
graphProperties | WebGraphProperties instance related to the graph to analyze |
GraphSeriesInformation
instances with the
applicable series label targetsGet the information about the applicable series label targets, depending on the major and minor types currently associated with the graph
major | int value with the graph major type |
---|---|
minor | int value with the graph minor type |
This method is to transform some special riser id to the common riser id If the original id is not a valid riser object id, just maintain it
Returns the grouping category id for an attribute id
This method is designed to compute the related property value for "All Data Label" target. We check values of sub targets for each series label. If values are same, set it to "all" target; If not, set empty to "all" target
This method is designed to compute the related property value for those "all" target, such as: All Text, All Titles, All Axes We check values of sub targets for each "all" target. If value are same, set it to "all" target; If not, set empty to "all" target
This method can check if user has format privilege on giving title item.
For some attribute, we can't directly get property value for "All" target. This method can help to check out these attributes
This method determines if the graph major type sent as parameter corresponds to a 3D graph type
majorType | an element of the EnumDSSXMLMajorGraphTypes enumeration |
---|
True
if the graph representation is 3D. Otherwise returns False
.
Determines given the major graph type if Legends are supported or not
majorType | an element of the EnumDSSXMLMajorGraphTypes enumeration |
---|
True
if this graph type supports Legends. Otherwise, returns
False
This method determines whether the graph target is a place holder for All items (e.g. All Texts, All Titles) For those place holders, their fontStyle values should be depending on the contained individual items instead of the values from their own
graphTargetID | an element of the EnumDSSXMLGraphObjectID enumeration |
---|
True
if the graph target is a place holder indicating a All "X" item. Otherwise returns False
.Utility method to generate a filter that will be used for determining which objects will be shown or not to the user, based on the graph major type currently selected.
exceptValues | hash table with the values not to include on the resulting filter |
---|
String
value with the different major type values separated by commas.
Those values included on the exceptValues
parameter will not be included on the resulting filter string.Utility method to generate a filter that will be used for determining which objects will be shown or not to the user, based on the graph major type currently selected.
includeValues | array of integer values to be included on the string |
---|
String
value with the different major type values separated by commas.
Those values included on the includeValues
parameter will be added to the resulting filter string.
This method is deprecated.
No replacement.
Displays the images that correspond to the graph types available given the flag of available graph types
out | instance of MarkupOutput that will hold the HTML output of this method |
---|---|
availableGraphTypes | flag from the Report Data that indicates which major graph types are available to a given report. |
currentGraphType | major type used currently for a given report. |
imgSourcePath | source path where images to be displayed are located. |
majorTypeParam | prefix name to use for the controls to be displayed. |
appContext | a AppContext instance. |
This method is deprecated.
No replacement.
Displays the combo box that corresponds to the minor graph types available given the current graph major types
out | instance of MarkupOutput that will hold the HTML output of this method |
---|---|
currentGraphType | major type used currently for a given graph. |
currentMinorType | minor type used currently for a given graph. |
minorTypeParam | name to use for the control to be displayed. |
appContext | a AppContext instance. |
extraParameters | any other attributes that should be added to the Select control to be rendered. |
Processes the interval property value obtained from the metadata
interval | String value of the graph property |
---|
null
if the interval option was not selected. Otherwise, returns the value saved in the
metadata (meaning the option is checked)Based on the Scale string, retrieve the values of the properties to use
scale | a String with the information of the graph's scale property saved on the metadata |
---|