public abstract class

AbstractPromptExpressionTransform

extends AbstractPromptObjectTransform
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
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

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 of Tag instances to render HTML output. See reference to TagsFactory.

Copyright: Copyright (c) 2002

Company: Microstrategy, Inc.

Summary

[Expand]
Inherited Constants
From interface com.microstrategy.web.beans.EnumPromptsBeanEvents
Fields
public FormalParameter attrFormTypeInAvailableList Specifies what attribute forms are to be displayed.
public FormalParameter defaultOperatorId Specifies operator Id to be used as default in expression.
public FormalParameter editMetricQualificationOutputLevel Specifies whether or not the output level of a metric qualification is editable.
public FormalParameter inputFromTextFile Specifies whether or not to display section for uploading prompt answers in text file.
[Expand]
Inherited Fields
From class com.microstrategy.web.app.transforms.AbstractPromptObjectTransform
Public Constructors
AbstractPromptExpressionTransform()
Default no-args constructor, initialize all the formal parameters.
Public Methods
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 Methods
String getDimtyAsString()
Returns the dimensionality of a metric qualification as a string.
String getDimtyAttributesAsString()
Returns the dimensionality of a metric qualification as a string.
int getOutputLevel()
Returns the output level of the prompt if it is a metric qualification prompt
boolean isBrowserIE6()
Utility method that checks if the browser is IE 6.0 version or higher.
boolean isCart()
boolean isMQLevelEditingSupported()
Indicates whether or not metric qualification level editing is supported or not.
boolean isNodeComplex(WebNode node)
This method is deprecated. This method has been deprecated since this is specific to expression prompts.
Use the method on AbstractPromptExpressionTransform.
boolean isNodeDimtyEmpty(WebNode node)
Indicates whether or not node parameter has dimensionality.
void setExtraArguments()
Sets extra arguments and properties for this prompt.
void setMetricQualOutputLevelAndDimty()
Determines the output level and dimensionality for current prompt being processed.
[Expand]
Inherited Methods
From class com.microstrategy.web.app.transforms.AbstractPromptObjectTransform
From class com.microstrategy.web.transform.AbstractLayoutTransform
From class com.microstrategy.web.transform.AbstractTransform
From class java.lang.Object
From interface com.microstrategy.web.transform.Transform

Fields

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).

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.

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 is true.

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.

Public Constructors

public AbstractPromptExpressionTransform ()

Default no-args constructor, initialize all the formal parameters.

Public Methods

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.

public void renderOutputLevelLabel (MarkupOutput out)

Renders label for output level button.

Parameters
out where to write the output of the method.

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.

Parameters
out the transform output

Protected Methods

protected String getDimtyAsString ()

Returns the dimensionality of a metric qualification as a string.

Returns
  • String representing the dimensionality of a metric qualification

protected String getDimtyAttributesAsString ()

Returns the dimensionality of a metric qualification as a string.

Returns
  • String representing the dimensionality of a metric qualification

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

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.

protected boolean isCart ()

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.

protected boolean isNodeComplex (WebNode node)

This method is deprecated.
This method has been deprecated since this is specific to expression prompts.
Use the method on AbstractPromptExpressionTransform.

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.

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.

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

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.

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.