public interface

PromptObject

implements WebBean
com.microstrategy.web.beans.PromptObject
Known Indirect Subclasses

Class Overview

This interface represents information about a single prompt. It manages its position property and a WebPrompt object.

Summary

[Expand]
Inherited Constants
From interface com.microstrategy.utils.serialization.EnumWebPersistableState
Public Methods
abstract WebDisplayHelper getDisplayHelper()
Returns the cached WebDisplayHelper object from the current PromptObject.
abstract HighlightedObjects getHighlightedObjects()
Returns a collection of highlighted objects.
abstract String getOriginalSearchRoot()
Returns original search root or empty string.
abstract int getPromptPosition()
Returns the position of this PromptObject in the collection of prompt objects in a PromptsBean.
abstract PromptsBean getPromptsBean()
Returns the PromptsBean which contains this prompt object.
abstract PromptsSource getPromptsSource()
Returns the PromptsSource object from which this prompt object is originated.
abstract String getUserSearchPattern()
Returns the user search pattern on a PromptObject.
abstract WebBeanError getValidationInfo()
Returns the prompt answer validation error information for this particular prompt only.
abstract WebPrompt getWebPrompt()
Returns the embedded WebPrompt object.
abstract boolean hasAnswerChanged()
Returns true if the prompt answer has been changed since it is loaded from the Intelligence Server.
abstract void setAnswerChanged(boolean changed)
Sets a boolean value indicating that the prompt answer has been changed for the underlying prompt.
abstract void setUserSearchPattern(String pattern)
Sets the user search pattern on a PromptObject.
abstract void setValidationInfo(WebBeanError wbe)
Sets a prompt answer validation error on this prompt object.
[Expand]
Inherited Methods
From interface com.microstrategy.utils.serialization.Persistable
From interface com.microstrategy.web.beans.RequestPersistable
From interface com.microstrategy.web.beans.Transformable
From interface com.microstrategy.web.beans.WebBean
From interface com.microstrategy.web.beans.WebComponent

Public Methods

public abstract WebDisplayHelper getDisplayHelper ()

Returns the cached WebDisplayHelper object from the current PromptObject. If the cached one is null, then return a new one from the underlying WebPrompt.

The cached WebDisplayHelper is typically set by the prompt event handler.

Returns
  • the WebDisplayHelper object
Throws
WebObjectsException thrown if the WebDisplayHelper is unable to retrieved.

public abstract HighlightedObjects getHighlightedObjects ()

Returns a collection of highlighted objects. PromptsBean queries this collection and then tries to highlight each element in the collection in its collectData method.

Returns

public abstract String getOriginalSearchRoot ()

Returns original search root or empty string.

Returns
  • original search root or empty string.

public abstract int getPromptPosition ()

Returns the position of this PromptObject in the collection of prompt objects in a PromptsBean.

Returns
  • the position of this object in a PromptsBean.

public abstract PromptsBean getPromptsBean ()

Returns the PromptsBean which contains this prompt object.

Returns
  • the PromptsBean.

public abstract PromptsSource getPromptsSource ()

Returns the PromptsSource object from which this prompt object is originated.

Returns
  • a PromptsSource object.

public abstract String getUserSearchPattern ()

Returns the user search pattern on a PromptObject. A search pattern is what a user types in a search box on a Web browser to perform a search. Except WebConstantPrompt, other types of WebPrompt all provide the search ability to search for a WebObjectInfo or WebElement.

Returns
  • the most recent user search pattern

public abstract WebBeanError getValidationInfo ()

Returns the prompt answer validation error information for this particular prompt only.

Returns
  • the prompt answer validation error. null if there is no error.

public abstract WebPrompt getWebPrompt ()

Returns the embedded WebPrompt object.

Returns
  • the WebPrompt object associated with this object.

public abstract boolean hasAnswerChanged ()

Returns true if the prompt answer has been changed since it is loaded from the Intelligence Server. Answering a prompt should reset this flag to false.

PromptsEventHandler uses this method to decide whether to open a closed prompt.

Returns
  • true if the prompt answer has been changed since it is loaded from the Intelligence Server.

public abstract void setAnswerChanged (boolean changed)

Sets a boolean value indicating that the prompt answer has been changed for the underlying prompt. After answering a prompt, users should reset this flag to false.

PromptsEventHandler uses this method to decide whether to open a closed prompt.

Parameters
changed true if the prompt answer has been changed for the underlying prompt.

public abstract void setUserSearchPattern (String pattern)

Sets the user search pattern on a PromptObject. A search pattern is what a user types in a search box on a Web browser to perform a search. Except WebConstantPrompt, other types of WebPrompt all provide the search ability to search for a WebObjectInfo or WebElement.

Parameters
pattern the new user search pattern a user types in

public abstract void setValidationInfo (WebBeanError wbe)

Sets a prompt answer validation error on this prompt object. Prompt event handler calls this method to pass validation error info to th caller.

Parameters
wbe the prompt answer validation error.