Class AbstractPromptExpressionTransform
- java.lang.Object
-
- com.microstrategy.web.transform.AbstractTransform
-
- com.microstrategy.web.transform.AbstractLayoutTransform
-
- com.microstrategy.web.app.transforms.AbstractPromptObjectTransform
-
- com.microstrategy.web.app.transforms.AbstractPromptExpressionTransform
-
- All Implemented Interfaces:
EnumPromptsBeanEvents
,Transform
- Direct Known Subclasses:
PromptCartTransform
,PromptCartXHTMLTransform
,PromptExpressionNonCartTransform
public abstract class AbstractPromptExpressionTransform extends AbstractPromptObjectTransform
Title: PromptExpressionBaseTransform.
Description: This is an intermediate class between the AbstractPromptObjectTransform and all other expression
transforms. This transform contains expression prompts specific methods. This transforms makes use ofTag
instances to render HTML output. See reference toTagsFactory
.Copyright: Copyright (c) 2002
Company: Microstrategy, Inc.
- Since:
- MicroStrategy Web 8.0.0
-
-
Field Summary
Fields Modifier and Type Field Description FormalParameter
attrFormTypeInAvailableList
Specifies what attribute forms are to be displayed.FormalParameter
defaultOperatorId
Specifies operator Id to be used as default in expression.FormalParameter
editMetricQualificationOutputLevel
Specifies whether or not the output level of a metric qualification is editable.FormalParameter
inputFromTextFile
Specifies whether or not to display section for uploading prompt answers in text file.-
Fields inherited from class com.microstrategy.web.app.transforms.AbstractPromptObjectTransform
_blockCount, _calendar, _cssPrefix, _dataTypeForCalendar, _globalCss, _imagesFolder, cssPrefix, imgBackToTop, imgCalendar, imgError, isDhtmlMode, levelFlag, showRequired
-
Fields inherited from interface com.microstrategy.web.beans.EnumPromptsBeanEvents
ANSWER_SEPARATOR, EXPRESSION_SEPARATOR, ITEM_SEPARATOR, ITEM_SPECIAL_SEPARATOR, PROMPTS_EVENT_ADD_UNITS, PROMPTS_EVENT_ANSWER_ALL_PROMPTS, PROMPTS_EVENT_ANSWER_ANY_PROMPTS, PROMPTS_EVENT_ANSWER_CONSTANT_PROMPT, PROMPTS_EVENT_ANSWER_DIMTY_PROMPT, PROMPTS_EVENT_ANSWER_ELEMENTS_PROMPT, PROMPTS_EVENT_ANSWER_EXPRESSION_PROMPT, PROMPTS_EVENT_ANSWER_OBJECTS_PROMPT, PROMPTS_EVENT_ANSWER_PROMPTS_IN_ADVANCE, PROMPTS_EVENT_ARGUMENT_ACTION_ADD_UNITS, PROMPTS_EVENT_ARGUMENT_ACTION_ANSWER_PROMPT, PROMPTS_EVENT_ARGUMENT_ACTION_BROWSE_CHILD_FOLDER, PROMPTS_EVENT_ARGUMENT_ACTION_BROWSE_ELEMENT, PROMPTS_EVENT_ARGUMENT_ACTION_BROWSE_PARENT_FOLDER, PROMPTS_EVENT_ARGUMENT_ACTION_CANCEL_PROMPT, PROMPTS_EVENT_ARGUMENT_ACTION_CLEAR_EXISTING_AND_ADD_UNITS, PROMPTS_EVENT_ARGUMENT_ACTION_DRILL_WITHIN_HIERARCHY, PROMPTS_EVENT_ARGUMENT_ACTION_HIGHLIGHT_DIMENSION, PROMPTS_EVENT_ARGUMENT_ACTION_HIGHLIGHT_DIMENSION_ATTRIBUTE, PROMPTS_EVENT_ARGUMENT_ACTION_INCREMENTAL_FETCH, PROMPTS_EVENT_ARGUMENT_ACTION_REMOVE_UNITS, PROMPTS_EVENT_ARGUMENT_ACTION_SEARCH_BY_NAME, PROMPTS_EVENT_ARGUMENT_ACTION_SHOW_SUMMARY, PROMPTS_EVENT_ARGUMENT_ANSWER, PROMPTS_EVENT_ARGUMENT_ANSWER_FORMAT, PROMPTS_EVENT_ARGUMENT_ANSWER_MODE_OPTION, PROMPTS_EVENT_ARGUMENT_ANSWER_OPTIONS, PROMPTS_EVENT_ARGUMENT_ATTRIBUTE_ID, PROMPTS_EVENT_ARGUMENT_ATTRIBUTE_ID_AND_FORM_ID, PROMPTS_EVENT_ARGUMENT_BLOCK_BEGIN, PROMPTS_EVENT_ARGUMENT_BLOCK_COUNT, PROMPTS_EVENT_ARGUMENT_BROWSE_PATH, PROMPTS_EVENT_ARGUMENT_CALENDAR_BUTTON, PROMPTS_EVENT_ARGUMENT_CHILD_FOLDER_ID, PROMPTS_EVENT_ARGUMENT_DIMENSION_ID, PROMPTS_EVENT_ARGUMENT_DO_NOT_AUTO_REPROMPT, PROMPTS_EVENT_ARGUMENT_DRILL_TO_ATTRIBUTE_ID, PROMPTS_EVENT_ARGUMENT_EXEC_FLAGS, PROMPTS_EVENT_ARGUMENT_FILTER_STRING, PROMPTS_EVENT_ARGUMENT_FUNCTION, PROMPTS_EVENT_ARGUMENT_HIDDEN_ATTRIBUTE_ID, PROMPTS_EVENT_ARGUMENT_HIDDEN_DIMENSION_ID, PROMPTS_EVENT_ARGUMENT_INCREMENTAL_FETCH_GOTO_PAGE, PROMPTS_EVENT_ARGUMENT_LINK_ANSWERS, PROMPTS_EVENT_ARGUMENT_MATCH_CASE, PROMPTS_EVENT_ARGUMENT_MESSAGE_ALIAS, PROMPTS_EVENT_ARGUMENT_METRIC_ID, PROMPTS_EVENT_ARGUMENT_NAVIGATION, PROMPTS_EVENT_ARGUMENT_OBJECT_TYPE, PROMPTS_EVENT_ARGUMENT_ORIGIN_MESSAGE_ID, PROMPTS_EVENT_ARGUMENT_ORIGIN_SHORT_ANSWER_XML, PROMPTS_EVENT_ARGUMENT_PARENT_FOLDER_ID, PROMPTS_EVENT_ARGUMENT_PLAIN_ELEMENT_PROMPT_ANSWER, PROMPTS_EVENT_ARGUMENT_PLAIN_OBJECT_PROMPT_ANSWER, PROMPTS_EVENT_ARGUMENT_PLAIN_VALUE_PROMPT_ANSWER, PROMPTS_EVENT_ARGUMENT_PROMPT_POSITION, PROMPTS_EVENT_ARGUMENT_REOPEN_PROMPT, PROMPTS_EVENT_ARGUMENT_SAP_VARIABLE_EXCLUDE, PROMPTS_EVENT_ARGUMENT_SEARCH_NAME, PROMPTS_EVENT_ARGUMENT_SEARCH_ROOT, PROMPTS_EVENT_ARGUMENT_SRC_ANSWERS, PROMPTS_EVENT_ARGUMENT_SUB_ROOT_OPERATOR, PROMPTS_EVENT_ARGUMENT_SUBMIT_ANSWER, PROMPTS_EVENT_ARGUMENT_UNITS_TO_ADD, PROMPTS_EVENT_ARGUMENT_UNITS_TO_REMOVE, PROMPTS_EVENT_ARGUMENT_USE_SET_ANSWERS, PROMPTS_EVENT_ARGUMENT_USER_SEPARATOR, PROMPTS_EVENT_BROWSE_DIMENSION_ATTRIBUTE_ELEMENTS, PROMPTS_EVENT_BROWSE_ELEMENTS, PROMPTS_EVENT_BROWSE_HIERARCHICAL_CHILD_FOLDER, PROMPTS_EVENT_BROWSE_HIERARCHICAL_PARENT_FOLDER, PROMPTS_EVENT_CANCEL_ALL_PROMPTS, PROMPTS_EVENT_CANCEL_ANY_PROMPTS, PROMPTS_EVENT_CLEAR_EXISTING_AND_ADD_UNITS, PROMPTS_EVENT_CLEAR_HIERARCHICAL_SEARCH_EXPRESSION, PROMPTS_EVENT_DRILL_WITHIN_HIERARCHY, PROMPTS_EVENT_HIGHLIGHT_DIMENSION, PROMPTS_EVENT_HIGHLIGHT_DIMENSION_ATTRIBUTE, PROMPTS_EVENT_INCREMENTAL_FETCH, PROMPTS_EVENT_NAVIGATE_PROMPTS_BEAN, PROMPTS_EVENT_PROCESS_ALL_PROMPTS, PROMPTS_EVENT_PROCESS_ANY_PROMPTS, PROMPTS_EVENT_REMOVE_UNITS, PROMPTS_EVENT_SEARCH_BY_NAME, PROMPTS_EVENT_SHOW_ALL_PROMPTS_SUMMARY, PROMPTS_EVENT_SHOW_ANY_PROMPTS_SUMMARY, SIMPLE_SEPARATOR_CARET, SIMPLE_SEPARATOR_COMMA, SIMPLE_SEPARATOR_SEMICOLON, UNIT_SEPARATOR
-
-
Constructor Summary
Constructors Constructor Description AbstractPromptExpressionTransform()
Default no-args constructor, initialize all the formal parameters.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.String
getDimtyAsString()
Returns the dimensionality of a metric qualification as a string.protected java.lang.String
getDimtyAttributesAsString()
Returns the dimensionality of a metric qualification as a string.protected int
getOutputLevel()
Returns the output level of the prompt if it is a metric qualification promptprotected boolean
isBrowserIE6()
Utility method that checks if the browser is IE 6.0 version or higher.protected boolean
isCart()
protected boolean
isMQLevelEditingSupported()
Indicates whether or not metric qualification level editing is supported or not.protected boolean
isNodeComplex(WebNode node)
Indicates whether or not given node is considered as complex.protected boolean
isNodeDimtyEmpty(WebNode node)
Indicates whether or not node parameter has dimensionality.void
renderHiddenInputsForMQEditor(MarkupOutput out)
Renders hidden inputs used in the MQLevel Editor.void
renderOutputLevelLabel(MarkupOutput out)
Renders label for output level button.void
renderPromptHiddenInputs(MarkupOutput out)
Renders all hidden inputs of this prompt.protected void
setExtraArguments()
Sets extra arguments and properties for this prompt.protected void
setMetricQualOutputLevelAndDimty()
Determines the output level and dimensionality for current prompt being processed.-
Methods inherited from class com.microstrategy.web.app.transforms.AbstractPromptObjectTransform
addFormalParameter, arePromptsLoadedFirstTime, areThereAvailableSelections, checkLevel, getAnswerEvent, getArgumentName, getAttrElemBlockCount, getAvailableDisplayUnits, getCalendar, getContainerServices, getDescriptor, getDescriptor, getDescriptor, getDimensionAttribute, getDisplayHelper, getErrorMessage, getIntValue, getLocale, getMatchCaseSensitivity, getMultipleEvent, getMultipleEventArgumentString, getObjectsBlockCount, getPrompt, getPromptsAppContext, getPromptsBean, getPromptsList, getRequestKeys, getShowRequired, getStringValue, getSupportedBeanType, getTagsFactory, hasAnswer, initializeCss, initializeImages, initializePromptContent, initializePromptObject, isAnswerComplex, isBackToTopAnchorEnabled, isDhtmlMode, isDimensionalPrompt, isForDefinition, isIFrameRequest, isItemKeptInCartAvailable, isLocked, isLockedForSearch, isPromptObjectInitialized, isPromptRequired, isPromptSummaryEnabled, isTrue, isXDA_CustomSQL_Report, isXDA_MDX_Report, isXDAReport, newHiddenInputBuilder, newNamespaceEncoder, onBeforeApplyDefaultDisplaySettings, processAvailableItems, processIncrementalFetch, renderLayout, renderMinMaxHiddenValues, renderPromptAnswerMeaning, renderPromptBackToTopAnchor, renderPromptContent, renderPromptDefaultAnswer, renderPromptErrorMessage, renderPromptIFrameRequest, renderPromptMeaning, renderPromptNoSelectionsAvailable, renderPromptNotAnswered, renderPromptQuestion, renderPromptRestrictions, renderPromptSummary, renderPromptSummaryAnswer, renderPromptSummaryTitle, renderPromptTitle, setArgumentValue, setAttrElemBlockCount, setEnableBackToTopAnchor, setIsItemKeptInCartAvailable, setLevelFlag, setLocale, setMatchCaseSensitivity, setObjectsBlockCount, setPromptSummary, setShowRequired, transform
-
Methods inherited from class com.microstrategy.web.transform.AbstractLayoutTransform
getLayoutContext, getLayoutDefinition, setLayoutDefinition, transformUsingLayout
-
Methods inherited from class com.microstrategy.web.transform.AbstractTransform
addFormalParam, canTransform, getEvents, getFormalParams, getID, getPreview, isPreviewAvailable, isResolved, removeFormalParam, setAnnotation, setDeprecated, supports, supports
-
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.transform.Transform
getDescription
-
-
-
-
Field Detail
-
editMetricQualificationOutputLevel
public FormalParameter editMetricQualificationOutputLevel
Specifies whether or not the output level of a metric qualification is editable.
If this value is set to true, a button to open and edit the output level is shown.
This flag is used as a boolean value
Default value istrue
.
-
inputFromTextFile
public FormalParameter inputFromTextFile
Specifies whether or not to display section for uploading prompt answers in text file.
Not all prompt types and styles support this functionality, so even if this parameter is true, this section might not be available.
This flag is used as a boolean value.
-
defaultOperatorId
public FormalParameter defaultOperatorId
Specifies operator Id to be used as default in expression.
If this value is set to empty string, then original behavior will be adopted.
Default value is empty string.
Possible values are any constant defined in EnumDSSXMLFunction enumeration which is supported by any style of Expression prompts.
-
attrFormTypeInAvailableList
public FormalParameter attrFormTypeInAvailableList
Specifies what attribute forms are to be displayed.
This formal parameter will only three possible values defined in CartExpression interface:- CartExpression.DISPLAY_ONLY_ATTR_ID_FORMS indicates only display ID forms and ignore other forms when displaying.
- CartExpression.DISPLAY_ATTR_NON_ID_FORMS indicates to ignore ID forms and display all other type of forms.
- CartExpression.DISPLAY_ALL_ATTR_FORMS indicates to display both ID and Non-Id forms (default behavior).
- Since:
- MicroStrategy Web 8.0.1
-
-
Method Detail
-
isBrowserIE6
protected boolean isBrowserIE6()
Utility method that checks if the browser is IE 6.0 version or higher.- Returns:
- boolean true if IE v6.0 or higher.
-
getOutputLevel
protected int getOutputLevel()
Returns the output level of the prompt if it is a metric qualification prompt- Returns:
- Integer representing the output level , from EnumMetricQualOutputLevels
-
getDimtyAsString
protected java.lang.String getDimtyAsString()
Returns the dimensionality of a metric qualification as a string.- Returns:
- String representing the dimensionality of a metric qualification
-
getDimtyAttributesAsString
protected java.lang.String getDimtyAttributesAsString()
Returns the dimensionality of a metric qualification as a string.- Returns:
- String representing the dimensionality of a metric qualification
-
setMetricQualOutputLevelAndDimty
protected void setMetricQualOutputLevelAndDimty()
Determines the output level and dimensionality for current prompt being processed.
It parses WebPrompt instance being transformed and sets transform properties for indicating output level and dimensionality in a formmated text to be used in Metric Level editor. This function is invoked from setExtraArguments() method.
-
isNodeDimtyEmpty
protected boolean isNodeDimtyEmpty(WebNode node)
Indicates whether or not node parameter has dimensionality.
Dimty node is empty if given node has dimensionality and its size is 0. It is required to have MQ level editing supported and permission for editing Metric Qualification Output level.- Parameters:
node
- The node to check.- Returns:
- True if the Node has no dimensionality or if it has but it's empty
-
isMQLevelEditingSupported
protected boolean isMQLevelEditingSupported()
Indicates whether or not metric qualification level editing is supported or not.
This returns TRUE if the user preference is set to DHTML and the browser is IE6 or higher version and the report is not a XDA/MDX report.- Returns:
- true if MQ level editing is enabled or supported.
-
isNodeComplex
protected boolean isNodeComplex(WebNode node)
Indicates whether or not given node is considered as complex.
An expression is complex if it cannot be created using the Web interface. This is used by ExpressionPrompts transforms to determine if the Answer is Complex.- Overrides:
isNodeComplex
in classAbstractPromptObjectTransform
- Parameters:
node
- the root node of the subexpression to check- Returns:
- True if the Node is complex, that is, it cannot be created using Web.
-
renderPromptHiddenInputs
public void renderPromptHiddenInputs(MarkupOutput out)
Renders all hidden inputs of this prompt.
The inputs are retrieved from the answer event. It invokes overriten method and if user has permissions for editing MQ level, then it invokes renderHiddenInputsForMQEditor() method.- Overrides:
renderPromptHiddenInputs
in classAbstractPromptObjectTransform
- Parameters:
out
- the transform output
-
renderHiddenInputsForMQEditor
public void renderHiddenInputsForMQEditor(MarkupOutput out)
Renders hidden inputs used in the MQLevel Editor.
It gets invoked from renderPromptHiddenInputs() if MQ Level editing is supported.- Parameters:
out
- where to write the output of the method.
-
setExtraArguments
protected void setExtraArguments()
Sets extra arguments and properties for this prompt.
It invokes method setMetricQualOutputLevelAndDimty() which sets properties related to MQ level editing. It invokes its parent method as well.
These arguments will be render later as hidden inputs.- Overrides:
setExtraArguments
in classAbstractPromptObjectTransform
-
renderOutputLevelLabel
public void renderOutputLevelLabel(MarkupOutput out)
Renders label for output level button.- Parameters:
out
- where to write the output of the method.
-
isCart
protected boolean isCart()
- Since:
- MicroStrategy Web 8.0.2
-
-