Package com.microstrategy.web.beans
Interface PromptsBean
- 
- All Superinterfaces:
 EnumWebPersistableState,Persistable,RequestPersistable,Transformable,WebBean,WebComponent
public interface PromptsBean extends WebBean
This interface acts as a controller to orchestrate the collection and assembly of prompt questions. There are two different modes of operation:- Traditional Report-centric Mode: An application selects a report to execute. If it contains prompts that need to be answered, the Prompts Bean is responsible for managing those questions.
 - Prompts-centric Mode: An application creates a Prompts Bean object and supplies some number of prompt sources.
 
ReportBean,DocumentBean,RWBean,SubscriptionBean,ScheduleBean- Since:
 - MicroStrategy Web 7.3.1 or earlier
 
 
- 
- 
Field Summary
- 
Fields inherited from interface com.microstrategy.utils.serialization.EnumWebPersistableState
BARE_MINIMAL_STATE_INFO, MAXIMAL_STATE_INFO, MINIMAL_STATE_INFO, TYPICAL_STATE_INFO 
 - 
 
- 
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description PromptsSourceaddPromptsSource(int promptSourceType)Creates and adds a newPromptsSourceobject to this bean.intgetCount(int typeOfPrompt)Returns the count of prompts of a specific type from all the sources.intgetCurrentPromptPosition()Returns the position of the current prompt object the caller is working on.intgetNextPromptPosition()Returns the position of the next prompt object of the same type as the current prompt, starting search from the current prompt.intgetNextPromptPosition(int type)Returns the position of the prompt object of the specified type, next to the current prompt.intgetNextPromptPosition(int type, int startPos)Returns the position of the prompt object of the specified type, next to the startPos.intgetPreviousPromptPosition()Returns the position of the previous prompt object of the same type as the current prompt, starting search from the current prompt.intgetPreviousPromptPosition(int type)Returns the position of the prompt object of the specified type, previous to the current prompt.intgetPreviousPromptPosition(int type, int startPos)Returns the position of the prompt object of the specified type, previous to the startPos.PromptBeangetPromptBean()Returns thePromptBeanat the current position.PromptBeangetPromptBean(int position)Returns thePromptBeanat the specific position.java.util.Iterator<PromptBean>getPromptBeans(int typeOfPrompt)Returns a read-onlyjava.util.Iteratorover all the containedPromptBean, each of which has the specified type.PromptObjectgetPromptObject()Returns thePromptObjectat the current position.PromptObjectgetPromptObject(int position)Returns thePromptObjectat a specific position.java.util.IteratorgetPromptObjects(int typeOfPrompt)Returns a read-onlyjava.util.Iteratorover all the containedPromptObject, each of which has the specified type.WebPromptsgetPrompts()Returns promptsjava.util.IteratorgetPromptsSources()Returns anjava.util.Iteratorover all thePromptsSourcecontained within this bean.voidsetCurrentPromptPosition(int position)Sets the prompt object at a new position as the current working prompt object.- 
Methods inherited from interface com.microstrategy.utils.serialization.Persistable
restoreState, restoreState, saveState, saveState, saveState, saveState 
- 
Methods inherited from interface com.microstrategy.web.beans.RequestPersistable
restoreStateFromRequest, restoreStateFromRequest 
- 
Methods inherited from interface com.microstrategy.web.beans.Transformable
addTransform, addTransformByClass, addTransformByStyle, addTransformByStyle, clearTransforms, getBeanContext, getMessageString, getMyTransformInstances, getTransformInstance, getTransformInstance, getTransformInstances, getType, hasTransform, hasTransform, invalidateTransformCache, setBeanContext, transform, transform 
- 
Methods inherited from interface com.microstrategy.web.beans.WebBean
getDocument, getErrorInfo, getSessionInfo, isStale, setSessionInfo, setStale 
- 
Methods inherited from interface com.microstrategy.web.beans.WebComponent
addChild, addChildStateInfo, addChildStateInfo, collectData, collectMinimalData, generateOutput, getBeanContext, getChild, getChild, getChildByClass, getChildByType, getChildCount, getChildrenByClass, getDefaultStateLevel, getFeaturesManager, getMaximumStateLevel, getName, getOutputFormat, getParent, getPath, getPersistMode, getRenderingFilter, getRoot, getTargetBean, getTargetBeanPath, getWebEvent, getWebEvent, getWebEventHandler, getXMLStatus, handleRequest, hasChanged, hasJustOpened, initBean, invalidateChildrenState, isBeanContextEmpty, isFeatureAvailable, prepareForReuse, removeChild, removeChild, searchChild, setBeanContext, setBeanContext, setChanged, setChanged, setDefaultStateLevel, setFeaturesManager, setName, setOutputFormat, setParent, setPersistMode, setRenderingFilter, setTargetBean, setTargetBeanPath, setWebEventHandler 
 - 
 
 - 
 
- 
- 
Method Detail
- 
getCount
int getCount(int typeOfPrompt) throws WebBeanExceptionReturns the count of prompts of a specific type from all the sources. The type could be a combination of two or more types.- Parameters:
 typeOfPrompt- a bitwise flag fromEnumPromptsBeanTypes.- Returns:
 - the total count of prompts of the specified type from this PromptsBean.
 - Throws:
 WebBeanException- thrown if the count is unable to obtain.
 
- 
getCurrentPromptPosition
int getCurrentPromptPosition()
Returns the position of the current prompt object the caller is working on.- Returns:
 - The position of the current prompt.
 
 
- 
setCurrentPromptPosition
void setCurrentPromptPosition(int position) throws WebBeanException, java.lang.IndexOutOfBoundsExceptionSets the prompt object at a new position as the current working prompt object.- Parameters:
 position- a new position in this PromptsBean.- Throws:
 java.lang.IndexOutOfBoundsException- thrown if the position is out of range.WebBeanException- thrown if error occurs when loading prompts
 
- 
getNextPromptPosition
int getNextPromptPosition(int type, int startPos) throws WebBeanExceptionReturns the position of the prompt object of the specified type, next to the startPos. Returns -1 if it is not found.- Parameters:
 type- a flag fromEnumPromptsBeanTypes.startPos- the starting position to search.- Returns:
 - the position of the next prompt object of the specified type.
 - Throws:
 java.lang.IndexOutOfBoundsException- thrown if startPos is out of range.WebBeanException- thrown if error occurs when loading prompts
 
- 
getNextPromptPosition
int getNextPromptPosition(int type) throws WebBeanExceptionReturns the position of the prompt object of the specified type, next to the current prompt. Returns -1 if it is not found.- Parameters:
 type- a flag fromEnumPromptsBeanTypes.- Returns:
 - the position of the next prompt object of the specified type.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts
 
- 
getNextPromptPosition
int getNextPromptPosition() throws WebBeanExceptionReturns the position of the next prompt object of the same type as the current prompt, starting search from the current prompt. Returns -1 if it is not found.- Returns:
 - the position of the next prompt object of the specified type.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts
 
- 
getPromptObject
PromptObject getPromptObject(int position) throws WebBeanException
Returns thePromptObjectat a specific position.- Parameters:
 position- the position of aPromptObject.- Returns:
 - the PromptObject at the specified position.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts
 
- 
getPromptObject
PromptObject getPromptObject() throws WebBeanException
Returns thePromptObjectat the current position.- Returns:
 - the current PromptObject.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts
 
- 
getPromptObjects
java.util.Iterator getPromptObjects(int typeOfPrompt) throws WebBeanExceptionReturns a read-onlyjava.util.Iteratorover all the containedPromptObject, each of which has the specified type.- Parameters:
 typeOfPrompt- a flag fromEnumPromptsBeanTypes.- Returns:
 - an 
java.util.Iteratorover all thePromptObjectwith the specified type. - Throws:
 WebBeanException- thrown if error occurs when loading prompts
 
- 
addPromptsSource
PromptsSource addPromptsSource(int promptSourceType) throws java.lang.UnsupportedOperationException
Creates and adds a newPromptsSourceobject to this bean.- Parameters:
 promptSourceType- a flag fromEnumPromptsSourceTypesindicating the source type.- Returns:
 - an instantiated 
PromptsSource. - Throws:
 java.lang.UnsupportedOperationException- thrown if the prompts source collection is read-only.
 
- 
getPromptsSources
java.util.Iterator getPromptsSources()
Returns anjava.util.Iteratorover all thePromptsSourcecontained within this bean.- Returns:
 - an iterator over all the 
PromptsSource. 
 
- 
getPreviousPromptPosition
int getPreviousPromptPosition(int type, int startPos) throws WebBeanExceptionReturns the position of the prompt object of the specified type, previous to the startPos. Returns -1 if it is not found.- Parameters:
 type- a flag fromEnumPromptsBeanTypes.startPos- the starting position to search.- Returns:
 - the position of the previous prompt object of the specified type.
 - Throws:
 java.lang.IndexOutOfBoundsException- thrown if startPos is out of range.WebBeanException- thrown if error occurs when loading prompts
 
- 
getPreviousPromptPosition
int getPreviousPromptPosition(int type) throws WebBeanExceptionReturns the position of the prompt object of the specified type, previous to the current prompt. Returns -1 if it is not found.- Parameters:
 type- a flag fromEnumPromptsBeanTypes.- Returns:
 - the position of the previous prompt object of the specified type.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts
 
- 
getPreviousPromptPosition
int getPreviousPromptPosition() throws WebBeanExceptionReturns the position of the previous prompt object of the same type as the current prompt, starting search from the current prompt. Returns -1 if it is not found.- Returns:
 - the position of the previous prompt object of the specified type.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts
 
- 
getPrompts
WebPrompts getPrompts()
Returns prompts- Since:
 - MicroStrategy Web 8.1.2
 
 
- 
getPromptBean
PromptBean getPromptBean() throws WebBeanException
Returns thePromptBeanat the current position.- Returns:
 - the current PromptBean.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts- Since:
 - MicroStrategy Web 9.0.0
 
 
- 
getPromptBean
PromptBean getPromptBean(int position) throws WebBeanException
Returns thePromptBeanat the specific position.- Parameters:
 position- the position of aPromptObject.- Returns:
 - the PromptBean at the specified position.
 - Throws:
 WebBeanException- thrown if error occurs when loading prompts- Since:
 - MicroStrategy Web 9.0.0
 
 
- 
getPromptBeans
java.util.Iterator<PromptBean> getPromptBeans(int typeOfPrompt) throws WebBeanException
Returns a read-onlyjava.util.Iteratorover all the containedPromptBean, each of which has the specified type.- Parameters:
 typeOfPrompt- a flag fromEnumPromptsBeanTypes.- Returns:
 - an 
java.util.Iteratorover all thePromptBeanwith the specified type. - Throws:
 WebBeanException- thrown if error occurs when loading prompts- Since:
 - MicroStrategy Web 9.0.0
 
 
 - 
 
 -