Class AbstractPromptWidgetTransform
- java.lang.Object
-
- com.microstrategy.web.transform.AbstractTransform
-
- com.microstrategy.web.transform.AbstractLayoutTransform
-
- com.microstrategy.web.app.transforms.AbstractAppTransform
-
- com.microstrategy.web.app.transforms.AbstractAppWidgetTransform
-
- com.microstrategy.web.app.transforms.AbstractPromptWidgetTransform
-
- All Implemented Interfaces:
AppTransform
,LayoutTransform
,Transform
- Direct Known Subclasses:
PromptAnswerTransform
,PromptConstantWidgetTransform
,PromptDimtyWidgetTransform
,PromptElementsWidgetTransform
,PromptExpressionWidgetTransform
,PromptObjectWidgetTransform
public abstract class AbstractPromptWidgetTransform extends AbstractAppWidgetTransform
- Since:
- MicroStrategy Web 9.0.0
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.microstrategy.web.app.transforms.AbstractAppTransform
AbstractAppTransform.Context
-
-
Field Summary
Fields Modifier and Type Field Description protected PromptBean
_prompt
protected PromptAppBean
_promptAppBean
protected int
_promptPosition
FormalParameter
displayModel
-
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 AbstractPromptWidgetTransform()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
allowMultipleUserAnswer()
boolean
allowSingleUserAnswer()
java.lang.String
getAnswerFormat()
java.lang.String
getAnswerOption()
java.lang.String
getAnswerRestriction()
Block
getChildWidget(WebBean bean, java.lang.String styleName)
Block
getChildWidget(WebBean bean, java.lang.String styleName, java.lang.String[] fpNames, java.lang.Object[] fpValues)
Block
getDataFormsWidget(WebAttributeForms forms)
WebPromptAnswer
getDefaultAnswer()
Return the default user answer.boolean
getDefaultSavingAnswer()
When only one answer allowed and there is default answer (both prompt and re-prompt cases), we would like the saving box be checked.WebProperty
getDisplayProperty(java.lang.String pName)
java.lang.String
getDisplayStyleName()
java.util.ArrayList
getElementsAsList(WebElements elems)
java.lang.String
getErrorMessage()
void
getItemWidget(BlockList blockList, WebElement elem, WebAttributeForms forms)
java.lang.String
getNamePrefixForSingleSavedAnswer()
int
getPromptIndex()
java.lang.String
getPromptMeaning()
java.lang.String
getPromptName()
java.lang.String
getPromptTitle()
int
getPropertyDefaultSelection()
java.lang.String
getPropertyHeightValue()
java.lang.String
getPropertyValue(java.lang.String pName)
java.lang.String
getPropertyWidthValue()
java.lang.String
getRestriction()
java.util.List
getSavedAnswers()
WebSearch
getSearchObject()
subclass can override this method to return its search object associated with the avialable part.java.lang.String
getSearchTypes()
boolean
hasError()
boolean
hasSavedAnswers()
void
initializeWebComponent(Transformable data)
Initialize the web component to be used by the transform.boolean
isAutoCloseAnswer(WebPromptAnswer ans)
boolean
isAvailableFolderAvailable()
In "Each on a separate page" mode, we only collected the first page's search result, if there is a search defined.boolean
isCartStyle()
boolean
isCheckboxStyle()
boolean
isDefaultAnswer(WebPromptAnswer ans)
Returns whether the input argument is a default answer.boolean
isDisplayingModel()
protected boolean
isDisplaySearchPropOn()
boolean
isHICart_or_TreeStyle()
boolean
isHICartStyle()
boolean
isListStyle()
boolean
isMultiListStyle()
boolean
isNonCartStyle()
boolean
isOneByOneDisplayMode()
boolean
isPropertyWidthFixed()
boolean
isPulldownStyle()
boolean
isRadioStyle()
boolean
isReprompting()
Returns whether current is in reprompting process.boolean
isSingleListStyle()
boolean
isTextboxStyle()
boolean
isTreeStyle()
boolean
isTrimmedTree()
Doug's spec 1) We will add a new property to object prompts that meet all of the following criteria: a.boolean
isUseFolderStructure()
java.lang.String
showObjectDescription()
The return value will control how the description of individual object should be shown: No, Yes or ToolTip.boolean
showSearchBox()
boolean
showSearchBoxOrTreeStyle()
boolean
usingDefaultAnswer()
Returns whether current answer is using the default answer.-
Methods inherited from class com.microstrategy.web.app.transforms.AbstractAppWidgetTransform
buildFlattenedExpression, getAttForms, getChildWidget, getCssName, getIserverNodeFunction, getObjectInfoCssName, getPreferenceValueReplaceNull, getSelf, includeAncestorInfo, includeFolderInfo, includeOwnerInfo, includeTimeInfo, insertChildren, inTreeStructure, isNull, isShowObjectTags, renderShell, renderTest, transformForRequestSuccessful
-
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, getSupportedBeanType, getTagsFactory, getTimeFormat, getUnitsLabel, getWebBeanErrorInfo, hasSubBlock, initHeightAndWidthFromPreferences, initializeCss, initializeImages, initializeTransform, 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, 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, getDescription, getFormalParams, getID, getPreview, getSupportedBeanType, isPreviewAvailable, isResolved, supports, supports, transform
-
-
-
-
Field Detail
-
_promptAppBean
protected PromptAppBean _promptAppBean
-
_prompt
protected PromptBean _prompt
-
_promptPosition
protected int _promptPosition
-
displayModel
public FormalParameter displayModel
-
-
Method Detail
-
initializeWebComponent
public void initializeWebComponent(Transformable data)
Description copied from class:AbstractAppTransform
Initialize the web component to be used by the transform.- Specified by:
initializeWebComponent
in interfaceAppTransform
- Overrides:
initializeWebComponent
in classAbstractAppTransform
- Parameters:
data
- the bean to transform.
-
getPromptTitle
public java.lang.String getPromptTitle()
-
getPromptMeaning
public java.lang.String getPromptMeaning()
-
getAnswerFormat
public java.lang.String getAnswerFormat()
-
getAnswerOption
public java.lang.String getAnswerOption()
-
hasError
public boolean hasError()
-
getErrorMessage
public java.lang.String getErrorMessage()
-
getRestriction
public java.lang.String getRestriction()
-
isTextboxStyle
public boolean isTextboxStyle()
-
isRadioStyle
public boolean isRadioStyle()
-
isCheckboxStyle
public boolean isCheckboxStyle()
-
isListStyle
public boolean isListStyle()
-
isSingleListStyle
public boolean isSingleListStyle()
-
isMultiListStyle
public boolean isMultiListStyle()
-
isPulldownStyle
public boolean isPulldownStyle()
-
isCartStyle
public boolean isCartStyle()
-
isHICartStyle
public boolean isHICartStyle()
-
isTreeStyle
public boolean isTreeStyle()
-
getDisplayStyleName
public java.lang.String getDisplayStyleName()
-
isPropertyWidthFixed
public boolean isPropertyWidthFixed()
-
isUseFolderStructure
public boolean isUseFolderStructure()
-
getPropertyValue
public java.lang.String getPropertyValue(java.lang.String pName)
-
getDisplayProperty
public WebProperty getDisplayProperty(java.lang.String pName)
-
getPropertyWidthValue
public java.lang.String getPropertyWidthValue()
-
getPropertyDefaultSelection
public int getPropertyDefaultSelection()
-
getPropertyHeightValue
public java.lang.String getPropertyHeightValue()
-
getChildWidget
public Block getChildWidget(WebBean bean, java.lang.String styleName)
- Overrides:
getChildWidget
in classAbstractAppWidgetTransform
-
getChildWidget
public Block getChildWidget(WebBean bean, java.lang.String styleName, java.lang.String[] fpNames, java.lang.Object[] fpValues)
-
showSearchBox
public boolean showSearchBox()
-
isDisplaySearchPropOn
protected boolean isDisplaySearchPropOn()
-
getElementsAsList
public java.util.ArrayList getElementsAsList(WebElements elems)
-
getSearchObject
public WebSearch getSearchObject()
subclass can override this method to return its search object associated with the avialable part.
-
getDataFormsWidget
public Block getDataFormsWidget(WebAttributeForms forms)
-
getItemWidget
public void getItemWidget(BlockList blockList, WebElement elem, WebAttributeForms forms)
-
isAvailableFolderAvailable
public boolean isAvailableFolderAvailable()
In "Each on a separate page" mode, we only collected the first page's search result, if there is a search defined. The suggested answer for other prompts are valid, but we have not collect the search results for other prompts, if there is any. And we do not want to collect those search data, since avoiding them is the purpose of the "Each on a separate page" mode. So, in layout file, we should first check whether available folder is available before rendering it out.
-
showObjectDescription
public java.lang.String showObjectDescription()
The return value will control how the description of individual object should be shown: No, Yes or ToolTip.
-
getSearchTypes
public java.lang.String getSearchTypes()
-
isOneByOneDisplayMode
public boolean isOneByOneDisplayMode()
-
isDisplayingModel
public boolean isDisplayingModel()
-
getPromptIndex
public int getPromptIndex()
-
showSearchBoxOrTreeStyle
public boolean showSearchBoxOrTreeStyle()
-
isHICart_or_TreeStyle
public boolean isHICart_or_TreeStyle()
-
hasSavedAnswers
public boolean hasSavedAnswers()
-
getSavedAnswers
public java.util.List getSavedAnswers()
-
getDefaultAnswer
public WebPromptAnswer getDefaultAnswer()
Return the default user answer.
-
isDefaultAnswer
public boolean isDefaultAnswer(WebPromptAnswer ans)
Returns whether the input argument is a default answer. Answer is a default answer when its reuse property isEnumDSSXMLPromptAnswerReuse.DssXmlPromptAnswerReuseDefault
orEnumDSSXMLPromptAnswerReuse.DssXmlPromptAnswerReuseDefaultAndClose
.- Parameters:
ans
- The answer object to check- Returns:
true
if the input answer object is a default answer, otherwisefalse
.
-
isAutoCloseAnswer
public boolean isAutoCloseAnswer(WebPromptAnswer ans)
-
isReprompting
public boolean isReprompting()
Returns whether current is in reprompting process.
-
usingDefaultAnswer
public boolean usingDefaultAnswer()
Returns whether current answer is using the default answer. When we are not in reprompting and there is default answer existing and project level answer restriction is not NONE, then we are using default answer. When project level answer restriction is set to NONE, Iserver side will disable the user answers feature.
-
allowMultipleUserAnswer
public boolean allowMultipleUserAnswer()
-
getAnswerRestriction
public java.lang.String getAnswerRestriction()
-
allowSingleUserAnswer
public boolean allowSingleUserAnswer()
-
getNamePrefixForSingleSavedAnswer
public java.lang.String getNamePrefixForSingleSavedAnswer()
-
getPromptName
public java.lang.String getPromptName()
-
getDefaultSavingAnswer
public boolean getDefaultSavingAnswer()
When only one answer allowed and there is default answer (both prompt and re-prompt cases), we would like the saving box be checked.
-
isTrimmedTree
public boolean isTrimmedTree()
Doug's spec 1) We will add a new property to object prompts that meet all of the following criteria: a. use a search that is defined to search within subfolders, b. use the Tree style, and c. the Use folder structure property is True (which is must be if Tree style is selected). 2) When this new property is enabled, the Web server code will retrieve from backend all objects that match the search criteria, including their complete paths. 3) Web will send these objects to the client, where they will be presented in a tree. a. The tree will start at the folder specified as the root of the search. b. The tree will be fully populated from the beginning. c. All nodes of the tree except those on a direct path to the folder specified as the root of the search will start out fully collapsed. The folder specified as the root of the search will itself be collapsed. d. Below the folder specified as the root of the search, only folders that contain a matching object somewhere within them will be shown. (In other words, only folders that are on the path of some matching object will be shown in the tree). e. If the prompt is defined to Allow navigation above search root, navigation above/outside the search root folder will behave as it does today (folder contents will be retrieved from the server only on-demand, and folders that might not contain matching objects will be shown anyway.) In other words, this new property and behaviour will only apply to the folder specified as the root of the search and its subfolders.- Returns:
-
isNonCartStyle
public boolean isNonCartStyle()
-
-