Class AbstractPromptEditorTransform
- java.lang.Object
-
- com.microstrategy.web.transform.AbstractTransform
-
- com.microstrategy.web.transform.AbstractLayoutTransform
-
- com.microstrategy.web.app.transforms.AbstractAppTransform
-
- com.microstrategy.web.app.transforms.AbstractPromptEditorTransform
-
- All Implemented Interfaces:
AppTransform
,LayoutTransform
,Transform
- Direct Known Subclasses:
ConstantPromptEditorTransform
,ElementsPromptEditorTransform
,ExpressionPromptEditorTransform
,ObjectsPromptEditorTransform
public abstract class AbstractPromptEditorTransform extends AbstractAppTransform implements LayoutTransform
- Since:
- MicroStrategy Web 9.0.0
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AbstractPromptEditorTransform.ListItem
-
Nested classes/interfaces inherited from class com.microstrategy.web.app.transforms.AbstractAppTransform
AbstractAppTransform.Context
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
_imagesFolder
Indicates images folder path.FormalParameter
imgCalendar
Specifies image to use when Calendar object is enabled and visible.protected WebPrompt
prompt
protected PromptDefinitionAppBean
promptEditor
-
Fields inherited from class com.microstrategy.web.app.transforms.AbstractAppTransform
_bean, _componentBlock, _cssPrefix, _imgBlank, _imgWait, _selfOutput, _subOutput, appliesTo, CLASS_INPUT, CLASS_MESSAGE, contextMenus, cssFile, cssPrefix, debugErrorFlags, debugFlags, dragMode, extraInput, extraUrl, FP_APPLIES_TO, FP_CONTEXT_MENUS, FP_CSS_ERROR_MESSAGE, FP_CSS_ERROR_TITLE, FP_CSS_FILE, FP_CSS_PREFIX, FP_DEBUG_ERROR_FLAGS, FP_DEBUG_FLAGS, FP_DRAG_MODE, FP_EXTRA_INPUT, FP_EXTRA_URL, FP_HEIGHT, FP_IFRAME_ENABLED, FP_IMG_WAIT, FP_INITIAL_INDENT, FP_ORIENTATION, FP_ORIENTATIONS_ALLOWED, FP_PARTIAL_IFRAME_UPDATE, FP_PROCESSING_BUTTONS_FLAGS, FP_PROCESSING_INFO_FLAGS, FP_RESIZE_LEVEL, FP_SCRIPT_CLASS, FP_TYPE, FP_USE_DHTML, FP_WIDTH, globalCssErrorMessage, globalCssErrorTitle, height, iframeEnabled, imgWait, indent, initialIndent, isDHTML, orientation, orientationsAllowed, partialIframeUpdate, PROCESSING_BUTTONS_ALL, PROCESSING_BUTTONS_CANCEL, PROCESSING_BUTTONS_HISTORY_LIST, PROCESSING_BUTTONS_REFRESH, PROCESSING_BUTTONS_VIEW_DETAILS, PROCESSING_INFO_ALL, PROCESSING_INFO_DESCRIPTION, PROCESSING_INFO_LAST_UPDATE, PROCESSING_INFO_NAME, PROCESSING_INFO_NONE, PROCESSING_INFO_STATUS, processingButtonsFlags, processingInfoFlags, RESIZE_ALL, RESIZE_HORIZONTAL, RESIZE_NONE, RESIZE_VERTICAL, resizeLevel, scriptClass, scriptEndTagEncoder, type, useDHTML, width
-
-
Constructor Summary
Constructors Constructor Description AbstractPromptEditorTransform()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description java.util.Map
addArrangeSizeAsValue()
java.util.Map
addAttr(java.lang.String attName, java.lang.String attValue)
Adds an attribute, whose attribute name is attName and whose value is attValue.java.util.Map
addBackwardDisplay()
java.util.Map
addCheckedAttr()
Add checked attribute into the attribute map.java.util.Map
addDisableObjs(java.lang.String objs)
Returns the attribute map for default value attribute.java.util.Map
addHeightAsValue(java.lang.String max)
java.util.Map
addMaxElemPerSubAsValue()
java.util.Map
addMaxValueAttr()
Add maximum value as a value attribute.java.util.Map
addMinValueAttr()
Add minimum value as a value attribute.java.util.Map
addNameAsValue()
java.util.Map
addOptionAttr(AbstractPromptEditorTransform.ListItem value)
Generate attributes for an option node, based on the input ListItem.java.util.Map
addPre90StyleAsValue()
java.util.Map
addTitleAsValue()
Add the title of the prompt as a value attribute into the attribute map.java.util.Map
addWidthAsValue(java.lang.String max)
protected java.lang.String
buildObjOptionValue(WebObjectInfo obj)
java.util.List
getArrangementList()
protected GGCalendar
getCalendar()
Returns a localized instance of Calendar component.java.util.List
getColFillOrderList()
java.lang.String
getDescription()
Returns a textual description of the transform.protected abstract java.util.List
getDisplayStyleList(java.util.ArrayList list, java.lang.String currentStyle)
java.util.List
getDisplayStyles()
java.util.List
getPersonalAnswersAllowedList()
Return a list of allowed personal answers.protected WebProperty
getProperty(java.lang.String psName, java.lang.String pName)
protected java.lang.String
getPropertyValue(java.lang.String psName, java.lang.String pName)
java.util.List
getShowSearchBoxPropValues()
java.lang.Class
getSupportedBeanType()
Returns the supported bean type.boolean
hasMax()
Returns whether the prompt has a maximum value.boolean
hasMin()
Returns whether the prompt has a minimum value.void
initializeImages()
Initializes the images to be used by this transform.void
initializeTransform(Transformable data)
This method initialize the private and protected fields of the transform, such as width and height.boolean
isAllowElementBrowse()
boolean
isAllowElementImport()
boolean
isAllowFullExpChange()
boolean
isAllowInterOpChange()
boolean
isAllowNavigateAbove()
boolean
isAllowOpChange()
boolean
isAllowRootOpChange()
boolean
isArrangementSizeNonDefault()
boolean
isAttributeQualificationPrompt()
boolean
isDateRangeAvailable()
boolean
isDispOuputLevelSelector()
boolean
isDonotShowEmptyFolders()
boolean
isElementPrompt()
boolean
isExpressionPrompt()
boolean
isFixedHeight()
boolean
isFixedWidth()
boolean
isHierarchyPrompt()
boolean
isMaxElemPerSubNonDefault()
boolean
isMetricQualificationPrompt()
boolean
isOnlyAllowRootOpChange()
boolean
isPre90CustomStyle()
boolean
isProjectLevelUserAnswerAllowed()
boolean
isRequired()
Returns whether the prompt require an answer.boolean
isSearchRequired()
boolean
isSearchRequiredAvailable()
boolean
isUseFolderStructure()
boolean
isUseWebBlocks()
void
renderCalendar(MarkupOutput out, java.lang.String textBoxName, java.lang.String calendarArg, java.lang.String maxRestrictionName, java.lang.String minRestrictionName)
Renders calendar HTML code.void
renderDescription(MarkupOutput out)
Render the description into the output stream.void
renderOptionText(MarkupOutput out, AbstractPromptEditorTransform.ListItem list)
Render the text for an option node based on the input ListItemvoid
renderText(MarkupOutput out, java.lang.String text)
Render a text into output stream.void
renderTimePicker(MarkupOutput out, java.lang.String pickerFieldsName, java.lang.String onChangeEvent, java.lang.String hourPickerName, java.lang.String minPickerName, java.lang.String secPickerName, java.lang.String dependField)
void
renderUnitsLabel(MarkupOutput mo)
boolean
showBackwardCompatibility()
boolean
showUserAnswerRestriction()
void
transformForRequestSuccessful(MarkupOutput out)
Generates the output when the bean's status isEnumRequestStatus.WebBeanRequestSuccessful
.-
Methods inherited from class com.microstrategy.web.app.transforms.AbstractAppTransform
addContactInfo, addDynamicScriptClass, addDynamicScriptFile, addFormalParameter, checkLevel, checkProcessingButtonsFlag, checkProcessingInfoFlag, checkStatus, displayError, displayError, displayError, emptyCell, excludeStaticTags, generateAnchor, generateAnchorForExport, generateHiddenInputsForEvent, generateIFrameTag, getAppContext, getArgumentName, getAttributesShellDiv, getBeanPath, getBoneId, getCancelEvent, getClientSideHelper, getContainerServices, getContext, getContextMenu, getContextMenuManager, getContextMenuManagerName, getContextMenusDefinition, getCssPrefix, getDateFormat, getDebugOut, getDescriptor, getDescriptor, getDescriptor, getDescriptor, getDisplayMode, getDisplayName, getErrorMessage, getErrorMessage, getErrorTitle, getErrorTitle, getEventManager, getFirstDayOfWeek, getFloatValue, getHelpPath, getID, getIntValue, getJSNameSpace, getLayoutContext, getLocale, getLocale, getPreferenceValue, getProjectID, getRefreshEvent, getRequestKeys, getResourcesFolder, getScriptClass, getStringValue, getStyleRequestContext, getStyleShellDiv, getTagsFactory, getTimeFormat, getUnitsLabel, getWebBeanErrorInfo, hasSubBlock, initHeightAndWidthFromPreferences, initializeCss, initializeWebComponent, is508, isBlockMode, isContextMenusEnabled, isDhtml, isDialog, isDormant, isFeatureAvailable, isIFrameDisplayMode, isIFrameEnabled, isIFrameRequest, isJobExpired, isModal, isOpen, isPortlet, isTrue, localIsIFrameDisplayMode, newContext, newHiddenInputBuilder, newNamespaceEncoder, newURIBuilder, redirectToDisplayError, renderBean, renderBean, renderBean, renderBean, renderCancelButton, renderContextMenus, renderCssLink, renderDescriptor, renderDescriptor, renderErrorButton, renderHiddenInputFromRequest, renderImage, renderLayout, renderProcessingButton, renderProcessingButton, renderProcessingButton, renderProcessingButtonForGet, renderProcessingButtonForGet, renderProcessingButtons, renderProcessingInfo, renderProcessingInfoData, renderProcessingInfoImage, renderProcessingInfoSubtitle, renderProcessingInfoTitle, renderProcessingObjectName, renderRefreshButton, renderRegisterBone, renderSelf, renderShell, renderSubBlock, renderUserHelpAnchor, setBoneProperties, setDisplayMode, setHasSubBlock, setHeight, setIFrameDisplayMode, setIsDormant, setRenderSubBlock, setShellAttributeOnClosedComponent, setWidth, shouldDisplay, transform, transformForRequestCanceled, transformForRequestInError, transformForRequestNotInited, transformForRequestProcessing, transformForRequestWaitingForUserInput
-
Methods inherited from class com.microstrategy.web.transform.AbstractLayoutTransform
getLayoutDefinition, setLayoutDefinition, transformUsingLayout
-
Methods inherited from class com.microstrategy.web.transform.AbstractTransform
addFormalParam, canTransform, getEvents, getFormalParams, 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.LayoutTransform
getLayoutDefinition, setLayoutDefinition
-
Methods inherited from interface com.microstrategy.web.transform.Transform
canTransform, getFormalParams, getID, getPreview, isPreviewAvailable, isResolved, supports, supports, transform
-
-
-
-
Field Detail
-
promptEditor
protected PromptDefinitionAppBean promptEditor
-
prompt
protected WebPrompt prompt
-
imgCalendar
public FormalParameter imgCalendar
Specifies image to use when Calendar object is enabled and visible.
The value to indicate should be a valid image file name, with any necessary path information not included already on theresourcesFolderImage
application configuration parameter.
-
_imagesFolder
protected java.lang.String _imagesFolder
Indicates images folder path.
-
-
Method Detail
-
initializeTransform
public void initializeTransform(Transformable data)
Description copied from class:AbstractAppTransform
This method initialize the private and protected fields of the transform, such as width and height. It also invokes the
This method is automatically called from theinitializeWebComponent
,initializeImages
andinitializeCss
methods.transform
method. Transforms which would like to invoke other methods in this instance directly (for example, to invoke some render methods), need first to call this method to guarantee that the Transform is ready to generate output.- Specified by:
initializeTransform
in interfaceAppTransform
- Overrides:
initializeTransform
in classAbstractAppTransform
- Parameters:
data
- the bean to transform.
-
getSupportedBeanType
public java.lang.Class getSupportedBeanType()
Description copied from class:AbstractAppTransform
Returns the supported bean type. This abstract Transform supports allWebComponents
so every sub-class should override this method to return the class of theBean
the Transform is expecting, for example:public class CustomReportClass extends AbstractAppTransform { public Class getSupportedBeanType() { //This Transform is expected to work only with a ReportBean, //therefore this method needs to return this class: return ReportBean.class; } }
- Specified by:
getSupportedBeanType
in interfaceTransform
- Overrides:
getSupportedBeanType
in classAbstractAppTransform
- Returns:
- a root class/interface supported by this transform.
-
initializeImages
public void initializeImages()
Initializes the images to be used by this transform.- Overrides:
initializeImages
in classAbstractAppTransform
-
transformForRequestSuccessful
public void transformForRequestSuccessful(MarkupOutput out)
Description copied from class:AbstractAppTransform
Generates the output when the bean's status isEnumRequestStatus.WebBeanRequestSuccessful
. This is the main entry point to generate the output for those Transforms that just want to render the "regular" bean case.
This is an abstract method. All classes need to implement it.- Specified by:
transformForRequestSuccessful
in classAbstractAppTransform
- Parameters:
out
- output by this transform- See Also:
AbstractAppTransform.checkStatus(com.microstrategy.web.beans.MarkupOutput)
-
getDescription
public java.lang.String getDescription()
Description copied from interface:Transform
Returns a textual description of the transform.- Specified by:
getDescription
in interfaceTransform
- Returns:
- The textual description of the transform.
-
addCheckedAttr
public java.util.Map addCheckedAttr()
Add checked attribute into the attribute map.
-
addTitleAsValue
public java.util.Map addTitleAsValue()
Add the title of the prompt as a value attribute into the attribute map.
-
addNameAsValue
public java.util.Map addNameAsValue()
-
addWidthAsValue
public java.util.Map addWidthAsValue(java.lang.String max)
-
addHeightAsValue
public java.util.Map addHeightAsValue(java.lang.String max)
-
addArrangeSizeAsValue
public java.util.Map addArrangeSizeAsValue()
-
isArrangementSizeNonDefault
public boolean isArrangementSizeNonDefault()
-
addMaxElemPerSubAsValue
public java.util.Map addMaxElemPerSubAsValue()
-
isMaxElemPerSubNonDefault
public boolean isMaxElemPerSubNonDefault()
-
renderDescription
public void renderDescription(MarkupOutput out)
Render the description into the output stream.- Parameters:
out
-
-
getPersonalAnswersAllowedList
public java.util.List getPersonalAnswersAllowedList()
Return a list of allowed personal answers.
-
getDisplayStyles
public java.util.List getDisplayStyles()
-
getDisplayStyleList
protected abstract java.util.List getDisplayStyleList(java.util.ArrayList list, java.lang.String currentStyle)
-
getArrangementList
public java.util.List getArrangementList()
-
getColFillOrderList
public java.util.List getColFillOrderList()
-
addOptionAttr
public java.util.Map addOptionAttr(AbstractPromptEditorTransform.ListItem value)
Generate attributes for an option node, based on the input ListItem.
-
renderOptionText
public void renderOptionText(MarkupOutput out, AbstractPromptEditorTransform.ListItem list)
Render the text for an option node based on the input ListItem- Parameters:
out
-list
-
-
addMinValueAttr
public java.util.Map addMinValueAttr()
Add minimum value as a value attribute.
-
addMaxValueAttr
public java.util.Map addMaxValueAttr()
Add maximum value as a value attribute.
-
hasMin
public boolean hasMin()
Returns whether the prompt has a minimum value.
-
hasMax
public boolean hasMax()
Returns whether the prompt has a maximum value.
-
isRequired
public boolean isRequired()
Returns whether the prompt require an answer.
-
addAttr
public java.util.Map addAttr(java.lang.String attName, java.lang.String attValue)
Adds an attribute, whose attribute name is attName and whose value is attValue.- Parameters:
attName
-attValue
-
-
renderText
public void renderText(MarkupOutput out, java.lang.String text)
Render a text into output stream.- Parameters:
out
-text
-
-
isFixedWidth
public boolean isFixedWidth()
-
isFixedHeight
public boolean isFixedHeight()
-
getShowSearchBoxPropValues
public java.util.List getShowSearchBoxPropValues()
-
isUseFolderStructure
public boolean isUseFolderStructure()
-
isDonotShowEmptyFolders
public boolean isDonotShowEmptyFolders()
-
isUseWebBlocks
public boolean isUseWebBlocks()
-
isSearchRequired
public boolean isSearchRequired()
-
isAllowNavigateAbove
public boolean isAllowNavigateAbove()
-
isAllowOpChange
public boolean isAllowOpChange()
-
isAllowFullExpChange
public boolean isAllowFullExpChange()
-
isOnlyAllowRootOpChange
public boolean isOnlyAllowRootOpChange()
-
isAllowRootOpChange
public boolean isAllowRootOpChange()
-
isAllowInterOpChange
public boolean isAllowInterOpChange()
-
isAllowElementImport
public boolean isAllowElementImport()
-
isAllowElementBrowse
public boolean isAllowElementBrowse()
-
isDispOuputLevelSelector
public boolean isDispOuputLevelSelector()
-
getPropertyValue
protected java.lang.String getPropertyValue(java.lang.String psName, java.lang.String pName) throws WebObjectsException
- Throws:
WebObjectsException
-
getProperty
protected WebProperty getProperty(java.lang.String psName, java.lang.String pName) throws java.lang.IllegalArgumentException, WebObjectsException
- Throws:
java.lang.IllegalArgumentException
WebObjectsException
-
addDisableObjs
public java.util.Map addDisableObjs(java.lang.String objs)
Returns the attribute map for default value attribute. If the input data type is the same as the current defined prompt and it has a default value, then this method will return the default value in attribute map. For other cases, except date data type, no attribute will be added. When the input data type is date, and the current prompt is not a date prompt, then the current date will be added as the default value attribute. This means GUI will show current date as default for default value for date type, when the current prompt data type is not Date. This will let calendar picker correctly show the date.- Parameters:
objs
-
-
getCalendar
protected GGCalendar getCalendar()
Returns a localized instance of Calendar component.
This object is used for creating an calendar HTML object used for entering date values.- Returns:
- calendar as a GGCalendar instance.
-
isExpressionPrompt
public boolean isExpressionPrompt()
-
isHierarchyPrompt
public boolean isHierarchyPrompt()
-
isElementPrompt
public boolean isElementPrompt()
-
isSearchRequiredAvailable
public boolean isSearchRequiredAvailable()
-
isDateRangeAvailable
public boolean isDateRangeAvailable()
-
isAttributeQualificationPrompt
public boolean isAttributeQualificationPrompt()
-
isMetricQualificationPrompt
public boolean isMetricQualificationPrompt()
-
buildObjOptionValue
protected java.lang.String buildObjOptionValue(WebObjectInfo obj)
-
showUserAnswerRestriction
public boolean showUserAnswerRestriction()
-
isProjectLevelUserAnswerAllowed
public boolean isProjectLevelUserAnswerAllowed()
-
showBackwardCompatibility
public boolean showBackwardCompatibility()
-
addBackwardDisplay
public java.util.Map addBackwardDisplay()
-
renderUnitsLabel
public void renderUnitsLabel(MarkupOutput mo)
-
isPre90CustomStyle
public boolean isPre90CustomStyle()
-
addPre90StyleAsValue
public java.util.Map addPre90StyleAsValue()
-
renderCalendar
public void renderCalendar(MarkupOutput out, java.lang.String textBoxName, java.lang.String calendarArg, java.lang.String maxRestrictionName, java.lang.String minRestrictionName)
Renders calendar HTML code.
It takes as parameters argument indicating which Textbox to write Dates and unique Id for Calendar denoted by calendarArg.- Parameters:
out
- MarkupOutput where to writhe Calendar HTML code.textBoxName
- String Id denoting textboxcalendarArg
- String Unique Id for Calendar object.
-
renderTimePicker
public void renderTimePicker(MarkupOutput out, java.lang.String pickerFieldsName, java.lang.String onChangeEvent, java.lang.String hourPickerName, java.lang.String minPickerName, java.lang.String secPickerName, java.lang.String dependField)
-
-