Package com.microstrategy.web.beans
Interface AnnotationBean
-
- All Superinterfaces:
EnumWebPersistableState
,Persistable
,RequestPersistable
,Transformable
,WebBean
,WebComponent
public interface AnnotationBean extends WebBean
The AnnotationBean is used to editing, updating or adding an annotation to a report or document. This feature may also be known as collaboration, or information in the user interface- Since:
- MicroStrategy Web 9.0.0
-
-
Field Summary
Fields Modifier and Type Field Description static int
ANNOTATION_BEAN_MODE_ADD
Mode where the user is adding to existing annotations/information.static int
ANNOTATION_BEAN_MODE_EDIT
Mode where the user is editing existing annotations/information-
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 void
appendAnnotation(java.lang.String annotation)
Adds an annotation to the already existing information of the target object.java.lang.String
getAnnotations()
Returns the annotations of the target object.int
getMode()
Returns the mode of the AnnotationBean.java.lang.String
getPostfix(boolean isAppend)
Retrieves the postfix used when appending or editing annotation.java.lang.String
getPrefix(java.lang.String locale)
Retrieves the prefix used when appending annotation.WebObjectInfo
getTarget()
Gets theWebObjectInfo
of the target object.boolean
hasAnnotations()
Returns wether anotation of the target object exsits or not.void
setMode(int mode)
Sets the mode of the AnnotationBean.void
setTarget(WebObjectInfo target)
Sets the target objectvoid
updateAnnotation(java.lang.String annotation)
Updates the annotations of the target 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
-
-
-
-
Field Detail
-
ANNOTATION_BEAN_MODE_EDIT
static final int ANNOTATION_BEAN_MODE_EDIT
Mode where the user is editing existing annotations/information- See Also:
- Constant Field Values
-
ANNOTATION_BEAN_MODE_ADD
static final int ANNOTATION_BEAN_MODE_ADD
Mode where the user is adding to existing annotations/information. This is the default mode- See Also:
- Constant Field Values
-
-
Method Detail
-
getAnnotations
java.lang.String getAnnotations() throws WebBeanException
Returns the annotations of the target object.- Throws:
WebBeanException
-
hasAnnotations
boolean hasAnnotations() throws WebBeanException
Returns wether anotation of the target object exsits or not.- Throws:
WebBeanException
-
updateAnnotation
void updateAnnotation(java.lang.String annotation) throws WebBeanException
Updates the annotations of the target object. This method will replaced the entire information of the object with the passed in annotation.- Parameters:
annotation
-- Throws:
WebBeanException
-
appendAnnotation
void appendAnnotation(java.lang.String annotation) throws WebBeanException
Adds an annotation to the already existing information of the target object. This method will append the passed in annotation to the end of the existing information of the object along with a carriage return.- Parameters:
annotation
-- Throws:
WebBeanException
-
setTarget
void setTarget(WebObjectInfo target)
Sets the target object- Parameters:
target
-
-
getTarget
WebObjectInfo getTarget() throws WebBeanException
Gets theWebObjectInfo
of the target object.- Throws:
WebBeanException
-
getMode
int getMode()
Returns the mode of the AnnotationBean.- Returns:
ANNOTATION_BEAN_MODE_ADD
orANNOTATION_BEAN_MODE_EDIT
-
setMode
void setMode(int mode)
Sets the mode of the AnnotationBean. Possible values for mode areANNOTATION_BEAN_MODE_ADD
andANNOTATION_BEAN_MODE_EDIT
- Parameters:
mode
-
-
getPrefix
java.lang.String getPrefix(java.lang.String locale)
Retrieves the prefix used when appending annotation. It's a combination of user name followed by time stamp.- Parameters:
locale
- the locale used to display the time stamp.- Returns:
- the prefix string
-
getPostfix
java.lang.String getPostfix(boolean isAppend)
Retrieves the postfix used when appending or editing annotation. It's "\r\n---\r\n" for append and "\r\n" for editing- Parameters:
isAppend
- true if doing append false for editing case- Returns:
- the postfix string
-
-