Package com.microstrategy.web.objects
Class WebDeliveryThresholdsMetricImpl
- java.lang.Object
-
- com.microstrategy.utils.serialization.AbstractPersistable
-
- com.microstrategy.web.objects.WebDeliveryThresholdsMetricImpl
-
- All Implemented Interfaces:
EnumWebPersistableState,Persistable,WebThresholds
public class WebDeliveryThresholdsMetricImpl extends AbstractPersistable
-
-
Field Summary
-
Fields inherited from class com.microstrategy.utils.serialization.AbstractPersistable
scriptEndTagEncoder
-
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 Concrete Methods Modifier and Type Method Description WebThresholdadd(java.lang.String tmpId)Adds a new threshold object with the given temporary identifier.WebThresholdadd(java.lang.String tmpId, WebThreshold template)voidclear()Removes all threshold instances.WebThresholdscreateCopy()Returns aWebThresholdscollection that is a copy of the current object.java.util.Enumerationelements()WebThresholdget(int index)WebThresholdget(java.lang.String id)protected AbstractHandlergetStateHandler()booleanisModified()Returns whether theWebThresholdsobject is modified or not.voidpopulate(WebThresholds thresholds)The populate method will populate the current collection with the contents of the given one.WebThresholdremove(java.lang.String id)Removes a threshold.voidreorder(java.lang.String[] ids)The array of identifiers define the new relative ordering of thresholds.protected voidsaveXMLState(java.lang.StringBuffer buf, int howMuchState)intsize()-
Methods inherited from class com.microstrategy.utils.serialization.AbstractPersistable
doFlatState, doFlatState, isXMLStateZipped, restoreState, restoreState, restoreXMLState, saveState, saveState, saveState, saveState, saveXMLState
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.microstrategy.utils.serialization.Persistable
restoreState, restoreState, saveState, saveState, saveState, saveState
-
-
-
-
Method Detail
-
size
public int size()
- Specified by:
sizein interfaceWebThresholds- Returns:
- the number of threshold instances.
-
add
public WebThreshold add(java.lang.String tmpId)
Description copied from interface:WebThresholdsAdds a new threshold object with the given temporary identifier. The identifier is no longer valid once the manipulation is submitted.- Specified by:
addin interfaceWebThresholds- Parameters:
tmpId- a temporary id used to refer to the new threshold- Returns:
- a new threshold instance
-
add
public WebThreshold add(java.lang.String tmpId, WebThreshold template)
- Specified by:
addin interfaceWebThresholds
-
reorder
public void reorder(java.lang.String[] ids)
Description copied from interface:WebThresholdsThe array of identifiers define the new relative ordering of thresholds. Each identifier pair is subject toKeyedList.moveByKey(Object, Object). For example, if thresholds "a, b, c, d, e" were reordered with the parameter array "b, e", we would have "a, c, d, b, e".- Specified by:
reorderin interfaceWebThresholds- Parameters:
ids- array of threshold identifiers in relative order
-
remove
public WebThreshold remove(java.lang.String id)
Description copied from interface:WebThresholdsRemoves a threshold.- Specified by:
removein interfaceWebThresholds- Parameters:
id- identifier of threshold to remove.- Returns:
- the threshold instance removed.
-
clear
public void clear()
Description copied from interface:WebThresholdsRemoves all threshold instances. This is equivalent to invokingWebThresholds.remove(String)for all threshold identifiers.- Specified by:
clearin interfaceWebThresholds
-
get
public WebThreshold get(java.lang.String id)
- Specified by:
getin interfaceWebThresholds- Parameters:
id- identifier of the threshold instance- Returns:
- the threshold instance matching the given identifier.
-
get
public WebThreshold get(int index)
- Specified by:
getin interfaceWebThresholds- Parameters:
index- the index (starting from 0) of the threshold instance in the list- Returns:
- the threshold instance at the index
-
elements
public java.util.Enumeration elements()
- Specified by:
elementsin interfaceWebThresholds- Returns:
Enumerationof threshold instances.
-
populate
public void populate(WebThresholds thresholds)
Description copied from interface:WebThresholdsThe populate method will populate the current collection with the contents of the given one. This is primarily intended to be used to propagate changes made to a copy obtained via the createCopy method back to the original.- Specified by:
populatein interfaceWebThresholds- Parameters:
thresholds- The source object whose definition will be copied into the current object.
-
createCopy
public WebThresholds createCopy()
Description copied from interface:WebThresholdsReturns aWebThresholdscollection that is a copy of the current object. Note that this copy will still be aware of its container, but the container will still be attached to the original WebThresholds object. The primary purpose of this method is to allow the caller to capture the state of the thresholds collection, and then edit the state without affecting the original collection. Typical usage will see this method being used along with the populate method, to move the information back from the copy to the original collection.- Specified by:
createCopyin interfaceWebThresholds- Returns:
- A
WebThresholdscollection that is in exactly the same state as the original.
-
saveXMLState
protected void saveXMLState(java.lang.StringBuffer buf, int howMuchState)- Overrides:
saveXMLStatein classAbstractPersistable
-
isModified
public boolean isModified()
Description copied from interface:WebThresholdsReturns whether theWebThresholdsobject is modified or not.- Specified by:
isModifiedin interfaceWebThresholds- Returns:
- True if the collection is modified, false otherwise.
-
getStateHandler
protected AbstractHandler getStateHandler() throws java.lang.UnsupportedOperationException
- Overrides:
getStateHandlerin classAbstractPersistable- Throws:
java.lang.UnsupportedOperationException
-
-