Interface RWManipulation


  • public interface RWManipulation
    The manipulation object contains manipulation methods that require immediate call to backend. Whenever any of methods on this object called all accumulated deltas (included deltas generated by this call are send to backend.
    Since:
    MicroStrategy Web 8.0.0
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void addAttributeForm​(java.lang.String keyContext, java.lang.String attributeID, java.lang.String formID, int index)
      Add an attribute form to a gridgraph in an RW
      RWInstance addControlSort​(java.lang.String keyContext, int sortType, boolean isAscending, int subTotalsPosition, java.lang.String unitID, int unitType, java.lang.String formID, boolean applyChanges)
      Adds a sort to the specified control
      RWInstance addDataSet​(java.lang.String[] _id, int _type, boolean _setDefault)
      Adds data set
      RWInstance addDataSet​(java.lang.String[] _id, int _type, boolean _setDefault, boolean applyNow)
      Adds data set
      RWInstance addDataSet​(java.lang.String _id, int _type)
      Adds data set
      RWInstance addDataSet​(java.lang.String _id, int _type, boolean _setDefault)
      Adds data set
      RWInstance addDataSetAndTemplate​(java.lang.String _dsId, int _dsType, java.lang.String _templateKey, int populateOption)
      Adds specified data set to document and copies it's template to specified document template
      void addDeltaXML​(java.lang.String deltaXml)
      Append the DeltaXML to the current manipulator Delta
      RWInstance addDerivedAttributeToDataSet​(java.lang.String dataSetId, java.lang.String name, java.lang.String formula, java.lang.Integer bft, java.lang.Boolean isTokenStream)
      add derived attribute to dataset only with id form, you can add other forms by
      RWInstance addDerivedAttributeToTemplate​(java.lang.String key, java.lang.String name, int axisName, int position, java.lang.String formula, java.lang.Integer bft, java.lang.Boolean isTokenStream)
      Adds derived attribute to a template inside document
      RWInstance addDerivedMetricToDataSet​(java.lang.String id, java.lang.String formula, java.lang.String name, boolean aggFromBase)
      Adds derived mettic to document data set
      RWInstance addDerivedMetricToDataSet​(java.lang.String id, java.lang.String formula, java.lang.String name, boolean aggFromBase, boolean isTokenStream)
      Adds derived metric to document data set
      RWInstance addDerivedMetricToTemplate​(java.lang.String key, java.lang.String formula, int position, java.lang.String name)
      Adds derived mettic to a template inside document
      RWInstance addDerivedMetricToTemplate​(java.lang.String key, java.lang.String formula, int position, java.lang.String name, java.lang.Boolean aggFromBase)
      Adds derived mettic to a template inside document
      RWInstance addDerivedMetricToTemplate​(java.lang.String key, java.lang.String formula, int position, java.lang.String name, java.lang.Boolean aggFromBase, java.lang.Boolean isTokenStream)
      Adds derived metric to a template inside document
      RWInstance addDocumentView​(java.lang.String name, int resolutionX, int resolutionY, int density, int orientation, int index, boolean applyChanges)
      Add a new document by duplicating an existing document.
      RWInstance addFormToDerivedAttribute​(java.lang.String attributeId, java.lang.String dataSetId, java.lang.String formId, java.lang.String name, java.lang.Integer index, java.lang.String formula, java.lang.Integer bft, boolean applyChanges)
      add one attribute form to derived attribute
      RWInstance addLayout​(java.lang.String key, java.lang.String beforeKey, java.lang.String name)  
      void addMetric​(java.lang.String keyContext, java.lang.String unitDisplayName, java.lang.String unitID, int unitType, int unitPosition)
      Add a metric to a gridgraph in an RW
      RWInstance addPercentToTotalMetric​(java.lang.String key, WebPercentToTotalMetric metric)
      Adds percent-to-total metric to specified grid
      RWInstance addQuickCalculationGroup​(java.lang.String key, java.lang.String deName, java.lang.String attId, int depth, int[] ordinals, int function, java.lang.String sliceId)  
      RWInstance addQuickListGroup​(java.lang.String key, java.lang.String deName, java.lang.String attId, int depth, int[] ordinals, java.lang.String sliceId)  
      RWInstance addRankMetric​(java.lang.String key, WebRankMetric metric)
      Adds new rank metric to specified grid
      RWInstance addShortcutMetric​(java.lang.String datasetID, java.lang.String datasetType, java.lang.String nodeKey, java.lang.String treeType, int functionType, int functionType2, java.util.List<WebObjectInfo> unitsInfo)
      Add shortcut metric to a given dataset and optionally a given template
      RWInstance addTemplateFromDataSet​(java.lang.String dataSetId, java.lang.String key, java.lang.String parentKey, java.lang.String name, java.lang.String left, java.lang.String top, java.lang.String width, java.lang.String height, java.lang.String zIndex, int displayMode)
      Adds a template unit containing a copy of the data set's template
      RWInstance addTemplateFromDataSet​(java.lang.String dataSetId, java.lang.String key, java.lang.String parentKey, java.lang.String name, java.lang.String left, java.lang.String top, java.lang.String width, java.lang.String height, java.lang.String zIndex, int displayMode, boolean linked, java.lang.String styleId)
      Adds a template unit containing a copy of the data set's template
      RWInstance addTemplateFromDataSet​(java.lang.String dataSetId, java.lang.String key, java.lang.String parentKey, java.lang.String name, java.lang.String left, java.lang.String top, java.lang.String width, java.lang.String height, java.lang.String zIndex, int displayMode, boolean linked, java.lang.String styleId, boolean applyToAllViews)
      Adds a template unit containing a copy of the data set's template
      RWInstance addTransactionReport​(java.lang.String keyContext, java.lang.String transactionElementID, int transactionElementType, boolean applyChanges)
      Associate a transaction report with a rwGridGraph unit or rwFieldGroupUnit
      RWInstance advSort​(java.lang.String nodeKey, int treeType, boolean clearSorts, WebSortConfig config, boolean applyNow, boolean isAdvSort)
      Apply multiple sort rules to the grid
      RWInstance applyAttributeLinking​(boolean unlink, java.lang.String srcAttrID, java.lang.String srcFormIDs, java.lang.String tgtAttrIDs, java.lang.String tgtFormsIDs)
      Apply linking or unlinking attributes
      RWInstance applyAttributeRemapping​(java.lang.String datasetID, int datasetType, java.lang.String tarDatasetID, int tarDatasetType, java.lang.String srcID, java.lang.String tarID)
      Apply or cancel attribute re-mapping
      RWInstance applyChanges()
      Applys all accumulated changes
      RWInstance applyGraphControlAction​(java.lang.String nodeKey, int sliceID, int x, int y)
      Sects control selection based on graph area
      RWInstance applySegment​(java.lang.String segmentID, java.lang.String keyContext, boolean applyChanges)
      Apply a Segment to the RWInstance
      RWInstance applyStyleByID​(java.lang.String key, java.lang.String id)
      Apply a style by style DSSID.
      RWInstance applyTheme​(java.lang.String themeID, boolean applyChanges)
      Apply theme to this RWInstance
      RWInstance applyThemeOnNode​(java.lang.String themeID, RWUnitDef unit, boolean isLink, boolean applyChanges)
      Apply theme on specified node
      RWInstance cancel​(int stateID)
      Cancels current updates and resets object to specified state
      RWInstance changeDerivedAttributeName​(java.lang.String attributeId, java.lang.String dataSetId, java.lang.String name)
      change derived attribute name
      RWInstance changeDerivedMetric​(java.lang.String metricId, java.lang.String dataSetId, java.lang.String formula, java.lang.String alias)
      Changes derived metric
      RWInstance changeDerivedMetric​(java.lang.String metricId, java.lang.String dataSetId, java.lang.String formula, java.lang.String alias, java.lang.Boolean isTokenStream, java.lang.Boolean aggregateFromBase)
      Changes derived metric
      RWInstance changeTemplateLinkToDataSet​(java.lang.String key, java.lang.String dataSetID, boolean linked)
      Changes the property of the template from being linked to unlinked or vise-versa
      void changeUnitName​(java.lang.String keyContext, java.lang.String unitID, int unitType, java.lang.String unitName)  
      RWInstance clearAllSorts​(java.lang.String nodeKey, int treeType)  
      RWInstance clearControlSorts​(java.lang.String keyContext, boolean applyChanges)
      Clears all sorts for a givent control
      void copyToClipboard​(java.lang.String[] keys)
      Copies units to clipboard
      RWUnitDef copyUnit​(java.lang.String fieldKey, java.lang.String newKey, java.lang.String newParentKey, java.lang.String beforeKey)
      Copyes specified unit to specified section
      void cutToClipboard​(java.lang.String[] keys)
      Cuts units to clipboard
      RWInstance drill​(java.lang.String drillKey, java.lang.String[] drillElements, java.util.Map drillProperties)
      Drills on the current RW instance using the drill path key and settings passed as arguments.
      RWInstance duplicatePanel​(RWUnitDef panel, java.lang.String name)  
      RWInstance duplicatePanelStacks​(java.lang.String[] keys, java.lang.String[] names, float offset)  
      RWInstance editDocumentView​(java.lang.String name, int resolutionX, int resolutionY, int density, int orientation, int index, boolean applyChanges)
      Edit a document view
      RWInstance filterOnSelections​(java.lang.String[] drillElements, java.util.Map drillProperties, java.lang.String nodeKey)  
      RWInstance forceApplyChanges()
      If we have delta on the manipulator, we must force to apply changes
      WebPercentToTotalMetric getNewPercentToTotalMetric​(java.lang.String key, WebMetric metric)
      Returns a new instance of the WebPercentToTotalMetric object.
      WebRankMetric getNewRankMetric​(java.lang.String key, WebMetric metric)
      Returns a new instance of the WebRankMetric object.
      WebSortConfig getNewSortConfig​(int sortType)  
      RWInstance importDocument​(java.lang.String id, java.lang.String beforeKey, boolean isTemplate)  
      RWInstance importDocument​(java.lang.String id, java.lang.String beforeKey, int importDocumentOption)  
      RWInstance makeTabular()
      Makes all grids within this document tabular.
      RWInstance moveLayout​(java.lang.String key, java.lang.String beforeKey)  
      RWUnitDef moveUnit​(java.lang.String key, java.lang.String newParentKey, java.lang.String beforeKey)
      Moves a unit to a new owner
      RWUnitDef[] pasteFromClipboard​(java.lang.String newParentKey, java.lang.String[] newKeys)
      Pastes units from clipboard to a subsection
      RWInstance performActionOnActionSelector​(java.lang.String keyContext, int action, boolean applyChanges)
      Perform and action on an ActionSelector.
      void pivotTemplateUnit​(java.lang.String keyContext, java.lang.String unitID, int unitType, int dAxis, int dPos)
      Pivot the template unit specified to a new axis and position
      RWInstance populateTemplateFromDataSet​(java.lang.String _dsId, int _dsType, java.lang.String _templateKey, int _populateOption)
      Populates document template unit with data set template
      RWInstance redo​(int stateID)  
      RWInstance refresh()
      Convenience method.
      RWInstance refresh​(boolean reprompt)
      Refreshes the current state of the instance.
      RWInstance refresh​(boolean reprompt, boolean rerun)
      Refreshes the instance.
      RWInstance refresh​(boolean reprompt, boolean rerun, boolean regenerate)  
      RWInstance refresh​(boolean reprompt, boolean rerun, boolean regenerate, int stateID)  
      RWInstance refresh​(java.lang.String promptAnswerXML)
      Uses the prompt answer to refresh the report.
      RWInstance removeDocumentView​(int index, boolean applyChanges)
      Remove a document view at specified index
      RWInstance removeFormFromDerivedAttribute​(java.lang.String attributeId, java.lang.String dataSetId, java.lang.String formId)
      remove attribute form from derived attribute
      RWInstance removeLayout​(java.lang.String key)  
      RWInstance removeLayout​(java.lang.String key, boolean isCurrent)  
      RWInstance removeThemeOnNode​(RWUnitDef unit, boolean applyChanges)
      remove theme on specified node
      RWInstance removeTransactionInfoOnField​(java.lang.String keyContext, java.lang.String fieldKey, boolean applyChanges)
      Clear the transaction information for text fields
      RWInstance removeTransactionInfoOnGridObject​(java.lang.String keyContext, java.lang.String objectID, int objectType, java.lang.String attributeFormID, boolean applyChanges)
      Clear the transaction information for attribute form/metric on a grid
      RWInstance removeTransactionReport​(java.lang.String keyContext, boolean applyChanges)  
      RWUnitDef removeUnit​(java.lang.String key)
      Removes a unit with specified key
      RWInstance replaceDataSet​(java.lang.String oldDataSetID, java.lang.String newDataSetID, int oldDSType, int newDSType)
      replace the old dataset with the new one
      RWInstance replaceDataSet​(java.lang.String oldDataSetID, java.lang.String newDataSetID, int oldDSType, int newDSType, boolean applyChanges)
      replace the old dataset with the new one
      RWInstance replaceDataSetKeepDerivedObjects​(java.lang.String oldDataSetID, java.lang.String newDataSetID, boolean clearAliasAndFormatting, boolean applyChanges)
      Function providing the ability to replace a dataset while retaining all of the derived metrics and their definitions
      RWInstance replaceDataSetReplaceMap​(java.lang.String oldDataSetID, java.lang.String newDataSetID, boolean clearAliasAndFormatting, java.util.HashMap<java.lang.String,​java.lang.String> resolutionMap, boolean applyChanges)
      Function providing the ability to replace a dataset, replacing or removing objects on the document based on the HashMap.
      RWInstance resetSelections​(java.lang.String keyContext)
      Reset document selections
      RWInstance setAutomaticTransactionRecordNumber​(java.lang.String keyContext, int recordNumber, boolean applyChanges)
      Set the number of rows that will be automatically transacted
      RWInstance setAvailableActionTypesForControl​(java.lang.String keyContext, int actionType, boolean applyChanges)
      Set the available control types in a control
      RWInstance setControlAttributeForms​(java.lang.String keyContext, java.util.List<java.lang.String> formIDs, boolean applyChanges)
      Set forms for custom control forms
      RWInstance setControlAttributeFormsDelimeter​(java.lang.String keyContext, java.lang.String delimiter, boolean applyChanges)
      Set delimiter for custom control forms
      RWInstance setControlAttributeFormsDisplayType​(java.lang.String keyContext, int displayType, boolean applyChanges)
      Set display type for control forms
      RWInstance setControlCurrentElementStatusToUnset​(java.lang.String keyContext, boolean applyChanges)
      Sets the control status to unset
      RWInstance setControlDisplayText​(java.lang.String keyContext, java.lang.String displayText, boolean applyChanges)
      Set the display text for the action selector
      RWInstance setControlExpression​(java.lang.String keyContext, int controlType, WebExpression expression, boolean applyChanges)
      Set the expression for a conditional selector
      RWInstance setControlSubsquentAction​(java.lang.String keyContext, int action, boolean applyChanges)
      Set the subsequent action in the action control after submit.
      RWInstance setControlSubsquentActionObject​(java.lang.String keyContext, int controlType, java.lang.String objectID, int objectType, java.lang.String objectName, boolean applyChanges)
      Set the subsequent action in the action control after submit.
      RWInstance setControlSubsquentDisplayMessage​(java.lang.String keyContext, java.lang.String displayMessage, boolean applyChanges)
      Set message to display after perform the action using action selector.
      RWInstance setControlTexts​(java.lang.String keyContext, java.util.List<java.lang.String> texts, boolean applyChanges)
      Sets current control's text selections
      RWInstance setControlUnsetStatus​(java.lang.String keyContext, int unsetStatus, int unsetCount, boolean applyChanges)
      Set the unset status of the control specified by keyContext
      RWInstance setCurrentControlElements​(java.lang.String key, java.util.List elementIds, boolean applyChanges)
      Sets current control selection
      RWInstance setCurrentControlElements​(java.lang.String key, java.util.List elementIds, boolean isInList, boolean applyChanges)
      Sets current control selection.
      RWInstance setCurrentDocumentView​(int index, boolean applyChanges)
      set the current document view with the specified index
      RWInstance setCurrentGroupByElement​(java.lang.String groupKey, java.lang.String elementId)
      Sets current group by element
      RWInstance setCurrentGroupByElement​(java.lang.String groupKey, java.lang.String elementId, boolean applyChanges)
      Sets current group by element.
      RWInstance setCurrentGroupByElement​(java.lang.String groupKey, java.lang.String elementId, int flags, boolean applyChanges)
      Sets current group by element.
      RWInstance setCurrentGroupByElementByUnitID​(java.lang.String unitID, int unitType, java.lang.String elementId, boolean applyChanges)
      Set the current group-by using unitID
      RWInstance setCurrentLayout​(int index, boolean applyChanges)
      Set the current layout by 0-based index
      RWInstance setCurrentLayout​(java.lang.String key)  
      void setCurrentPanel​(java.lang.String keyContext, java.lang.String panelKey)
      Sets panel stack current panel
      void setDisplayMode​(java.lang.String keyContext, int viewMode)
      Sets document template unit display mode
      RWInstance setGridViewFilter​(java.lang.String unitKey, java.lang.String filterXML)  
      RWInstance setNextCurrentGroupByElement​(int elementAction)
      Movets to another group by element
      RWInstance setTemplateUnitProperties​(java.lang.String nodeKey, int treeType, java.lang.String unitID, int unitType, boolean applyNow)
      Apply the changed properties of a template unit
      RWInstance setTransactionChangeType​(java.lang.String keyContext, int changeType, boolean applyChanges)
      Set the transaction change type in the filed group node or gridGraph node.
      RWInstance setTransactionInfoOnField​(java.lang.String keyContext, java.lang.String fieldKey, int mappedColumnIndex, int transactionFlags, java.lang.String inputControlKey, java.lang.String inputControlProperties, boolean applyChanges)
      Set transaction information for text fields
      RWInstance setTransactionInfoOnGridObject​(java.lang.String keyContext, java.lang.String objectID, int objectType, java.lang.String attributeFormID, int mappedColumnIndex, int transactionFlags, java.lang.String inputControlKey, java.lang.String inputControlProperties, boolean applyChanges)
      Set transaction information for attribute form/metric on a grid
      RWInstance showAllThresholds​(java.lang.String nodeKey, boolean enable)
      Enables/disables report thresholds
      void showSubtotals​(java.lang.String keyContext, java.lang.String unitID, int unitType, java.lang.String subtotalType, boolean isAdd)  
      RWInstance sortGrid​(java.lang.String nodeKey, int treeType, boolean clearSorts, WebSortConfig config, boolean applyNow)  
      RWInstance toggleDataServeMode​(java.lang.String dsid, int type, int mode)  
      RWInstance undo​(int stateID)  
      RWInstance updateDerivedAttributeForm​(java.lang.String attributeId, java.lang.String dataSetId, java.lang.String formId, java.lang.String name, java.lang.String formula, java.lang.Integer bft, java.lang.Boolean isTokenStream, java.lang.Boolean isDisplayForm)
      update form of derived attribute
      void updateTemplateUnits​(java.lang.String keyContext, java.lang.String unitID, int unitType, int dAxis, int dPos, int actions)  
      RWInstance updateTransactionData​(java.lang.String changes, boolean applyChanges)
      Modify transaction data in the RWInstance
      java.lang.String validateExpression​(java.lang.String tokenStreamXML, boolean isForMetric, int outFlags, int baseFormType)
      Check whether the token stream is valid
      java.lang.String validateLocalTransactionExpression​(WebTokenStream tokenStream, java.lang.String ctlKey, java.lang.String nodeKey)
      Check whether the token steam is valid
    • Method Detail

      • addDerivedMetricToTemplate

        RWInstance addDerivedMetricToTemplate​(java.lang.String key,
                                              java.lang.String formula,
                                              int position,
                                              java.lang.String name)
                                       throws WebObjectsException
        Adds derived mettic to a template inside document
        Parameters:
        key - Grid/graph unit key
        formula - derived metric formula
        position - metric position in the collection
        name - visible metric name
        Returns:
        a RW instance representing document after changes
        Throws:
        WebObjectsException
      • addDerivedMetricToTemplate

        RWInstance addDerivedMetricToTemplate​(java.lang.String key,
                                              java.lang.String formula,
                                              int position,
                                              java.lang.String name,
                                              java.lang.Boolean aggFromBase)
                                       throws WebObjectsException
        Adds derived mettic to a template inside document
        Parameters:
        key - Grid/graph unit key
        formula - derived metric formula
        position - metric position in the collection
        name - visible metric name
        aggFromBase - flag to indicate whether the metric should aggregate from base.
        Returns:
        a RW instance representing document after changes
        Throws:
        WebObjectsException
      • addDerivedMetricToDataSet

        RWInstance addDerivedMetricToDataSet​(java.lang.String id,
                                             java.lang.String formula,
                                             java.lang.String name,
                                             boolean aggFromBase)
                                      throws WebObjectsException
        Adds derived mettic to document data set
        Parameters:
        id - data set ID
        formula - derived metric formula
        name - visible metric name
        aggFromBase - flag to indicate whether the metric should aggregate from base.
        Returns:
        a RW instance representing document after changes
        Throws:
        WebObjectsException
      • addDataSet

        RWInstance addDataSet​(java.lang.String _id,
                              int _type)
                       throws WebObjectsException
        Adds data set
        Parameters:
        _id - data set ID
        _type - data set type
        Returns:
        a RW instance representing document after changes
        Throws:
        WebObjectsException
      • addDataSet

        RWInstance addDataSet​(java.lang.String _id,
                              int _type,
                              boolean _setDefault)
                       throws WebObjectsException
        Adds data set
        Parameters:
        _id - data set ID.
        _type - data set type from EnumDSSXMLObjectTypes.
        _setDefault - if this parameter is true a new data set will be set as default.
        Returns:
        a RW instance representing document after changes.
        Throws:
        WebObjectsException
      • addDataSet

        RWInstance addDataSet​(java.lang.String[] _id,
                              int _type,
                              boolean _setDefault)
                       throws WebObjectsException
        Adds data set
        Parameters:
        _id - Array of data set IDs.
        _type - data set type from EnumDSSXMLObjectTypes.
        _setDefault - if this parameter is true a new data set will be set as default.
        Returns:
        a RW instance representing document after changes.
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 9.0.0
      • addDataSet

        RWInstance addDataSet​(java.lang.String[] _id,
                              int _type,
                              boolean _setDefault,
                              boolean applyNow)
                       throws WebObjectsException
        Adds data set
        Parameters:
        _id - Array of data set IDs.
        _type - data set type from EnumDSSXMLObjectTypes.
        _setDefault - if this parameter is true a new data set will be set as default.
        Returns:
        a RW instance representing document after changes if applyNow is true.
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 9.0.0
      • applyStyleByID

        RWInstance applyStyleByID​(java.lang.String key,
                                  java.lang.String id)
                           throws WebObjectsException,
                                  WebReportValidationException
        Apply a style by style DSSID.
        Parameters:
        key - the GridGraph object key
        id - the DSSID of the style object to be applied.
        Returns:
        A WebReportInstance object with the applied style.
        Throws:
        java.lang.IllegalArgumentException - Thrown when id is null or empty string.
        WebObjectsException - Singals an error when sending the changes to the Intelligence Server.
        WebReportValidationException - Signals a report validation error from the Intelligence Server.
      • moveUnit

        RWUnitDef moveUnit​(java.lang.String key,
                           java.lang.String newParentKey,
                           java.lang.String beforeKey)
                    throws WebObjectsException
        Moves a unit to a new owner
        Parameters:
        key - unit key
        newParentKey - new parent key
        beforeKey - before key
        Returns:
        the moved unit
        Throws:
        WebObjectsException
      • copyUnit

        RWUnitDef copyUnit​(java.lang.String fieldKey,
                           java.lang.String newKey,
                           java.lang.String newParentKey,
                           java.lang.String beforeKey)
                    throws WebObjectsException
        Copyes specified unit to specified section
        Parameters:
        fieldKey - unit key
        newKey - a key to be assigned to a new unit
        newParentKey - key of the section where a copy shall be created
        beforeKey - if not null represents a key of the new parent section child before which a new unit shall be added
        Returns:
        new (copyed) unit
        Throws:
        WebObjectsException
      • pasteFromClipboard

        RWUnitDef[] pasteFromClipboard​(java.lang.String newParentKey,
                                       java.lang.String[] newKeys)
                                throws WebObjectsException
        Pastes units from clipboard to a subsection
        Parameters:
        newParentKey - subsection key
        newKeys - keys to be assigned to newly created units
        Returns:
        an array of newly created units, that are copies of units on clipboard.
        Throws:
        WebObjectsException
      • addTemplateFromDataSet

        RWInstance addTemplateFromDataSet​(java.lang.String dataSetId,
                                          java.lang.String key,
                                          java.lang.String parentKey,
                                          java.lang.String name,
                                          java.lang.String left,
                                          java.lang.String top,
                                          java.lang.String width,
                                          java.lang.String height,
                                          java.lang.String zIndex,
                                          int displayMode)
                                   throws WebObjectsException
        Adds a template unit containing a copy of the data set's template
        Parameters:
        dataSetId - data set ID
        key - new node's key
        parentKey - a key of the section where a new unit will be created
        left - left position of the new unit. If this parameter is empty corresponding default vaue is used.
        top - top position of the new unit. If this parameter is empty corresponding default vaue is used.
        width - width of the new unit. If this parameter is empty corresponding default vaue is used.
        height - height of the new unit. If this parameter is empty corresponding default vaue is used.
        displayMode - displayMode of the new unit. Should be a value from the enumeration EnumDSSXMLDisplayMode. If this parameter is -1, then the value is ignored
        Returns:
        RWInstance new instance
        Throws:
        WebObjectsException
      • addTemplateFromDataSet

        RWInstance addTemplateFromDataSet​(java.lang.String dataSetId,
                                          java.lang.String key,
                                          java.lang.String parentKey,
                                          java.lang.String name,
                                          java.lang.String left,
                                          java.lang.String top,
                                          java.lang.String width,
                                          java.lang.String height,
                                          java.lang.String zIndex,
                                          int displayMode,
                                          boolean linked,
                                          java.lang.String styleId)
                                   throws WebObjectsException
        Adds a template unit containing a copy of the data set's template
        Parameters:
        dataSetId - data set ID
        key - new node's key
        parentKey - a key of the section where a new unit will be created
        left - left position of the new unit. If this parameter is empty corresponding default vaue is used.
        top - top position of the new unit. If this parameter is empty corresponding default vaue is used.
        width - width of the new unit. If this parameter is empty corresponding default vaue is used.
        height - height of the new unit. If this parameter is empty corresponding default vaue is used.
        displayMode - displayMode of the new unit. Should be a value from the enumeration EnumDSSXMLDisplayMode. If this parameter is -1, then the value is ignored
        linked - indicates whether the template being created should be linked to the dataset. If so, the template cannot be modified from within the rwInstance
        Returns:
        RWInstance new instance
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 9.0.0
      • addTemplateFromDataSet

        RWInstance addTemplateFromDataSet​(java.lang.String dataSetId,
                                          java.lang.String key,
                                          java.lang.String parentKey,
                                          java.lang.String name,
                                          java.lang.String left,
                                          java.lang.String top,
                                          java.lang.String width,
                                          java.lang.String height,
                                          java.lang.String zIndex,
                                          int displayMode,
                                          boolean linked,
                                          java.lang.String styleId,
                                          boolean applyToAllViews)
                                   throws WebObjectsException
        Adds a template unit containing a copy of the data set's template
        Parameters:
        dataSetId - data set ID
        key - new node's key
        parentKey - a key of the section where a new unit will be created
        left - left position of the new unit. If this parameter is empty corresponding default vaue is used.
        top - top position of the new unit. If this parameter is empty corresponding default vaue is used.
        width - width of the new unit. If this parameter is empty corresponding default vaue is used.
        height - height of the new unit. If this parameter is empty corresponding default vaue is used.
        displayMode - displayMode of the new unit. Should be a value from the enumeration EnumDSSXMLDisplayMode. If this parameter is -1, then the value is ignored
        linked - indicates whether the template being created should be linked to the dataset. If so, the template cannot be modified from within the rwInstance
        applyToAllViews - apply format to all views
        Returns:
        RWInstance new instance
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 9.2.1m
      • changeTemplateLinkToDataSet

        RWInstance changeTemplateLinkToDataSet​(java.lang.String key,
                                               java.lang.String dataSetID,
                                               boolean linked)
                                        throws WebObjectsException
        Changes the property of the template from being linked to unlinked or vise-versa
        Parameters:
        key - the key of the template node
        dataSetID - the id of the dataset to which it should be linked or from which it should be unlinked
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 9.0.0
      • setCurrentGroupByElement

        RWInstance setCurrentGroupByElement​(java.lang.String groupKey,
                                            java.lang.String elementId)
                                     throws WebObjectsException
        Sets current group by element
        Parameters:
        groupKey - group by key
        elementId - element ID
        Returns:
        an instance containing new group by page
        Throws:
        WebObjectsException
      • setCurrentGroupByElement

        RWInstance setCurrentGroupByElement​(java.lang.String groupKey,
                                            java.lang.String elementId,
                                            boolean applyChanges)
                                     throws WebObjectsException
        Sets current group by element. If the applyChanges parameters is true, applyChanges() is executed and a new RWInstance containing the selected group-by is returned, otherwise the manipulations is only stored in deltas and the same RWInstance is returned.
        Parameters:
        groupKey - group by key
        elementId - element ID
        applyChanges - whether to call applyChanges
        Returns:
        an instance containing new group by page
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 8.0.2
      • setCurrentGroupByElement

        RWInstance setCurrentGroupByElement​(java.lang.String groupKey,
                                            java.lang.String elementId,
                                            int flags,
                                            boolean applyChanges)
                                     throws WebObjectsException
        Sets current group by element. If the applyChanges parameters is true, applyChanges() is executed and a new RWInstance containing the selected group-by is returned, otherwise the manipulations is only stored in deltas and the same RWInstance is returned.
        Parameters:
        groupKey - group by key
        elementId - element ID
        flags - flags controlling group by behavior:
        0
        - apply group by changes only to the current layout;
        1
        - apply group by changes to all layouts with matching group by paths;
        2
        - apply group by changes to all layouts containing changed group by units;
        applyChanges - whether to call applyChanges
        Returns:
        an instance containing new group by page
        Throws:
        WebObjectsException
      • setCurrentGroupByElementByUnitID

        RWInstance setCurrentGroupByElementByUnitID​(java.lang.String unitID,
                                                    int unitType,
                                                    java.lang.String elementId,
                                                    boolean applyChanges)
                                             throws WebObjectsException
        Set the current group-by using unitID
        Parameters:
        unitID - String GUID of unit
        unitType - int from EnumDSSXMLObjectTypes
        elementID - String containing the element ID
        applyChanges - boolean specifying whether the changes should be applied after the manipulation
        Returns:
        RWInstance containing changes if applyChanges is true. Without changes if applyChanges is false
        Throws:
        WebObjectsException
      • showAllThresholds

        RWInstance showAllThresholds​(java.lang.String nodeKey,
                                     boolean enable)
                              throws WebObjectsException
        Enables/disables report thresholds
        Parameters:
        nodeKey - Grid/graph node key
        enable - if true thresholds are enabled, othrerwise they are disabled
        Returns:
        a instance with new data
        Throws:
        WebObjectsException
      • getNewPercentToTotalMetric

        WebPercentToTotalMetric getNewPercentToTotalMetric​(java.lang.String key,
                                                           WebMetric metric)
                                                    throws java.lang.IllegalArgumentException,
                                                           WebObjectsException
        Returns a new instance of the WebPercentToTotalMetric object. This derived metric is based on the specified metric on the template or working set.
        Parameters:
        metric - The WebMetric object used to create the derived metric.
        Returns:
        the WebPercentToTotalMetric object created.
        Throws:
        java.lang.IllegalArgumentException - thrown if the metric is null or does not exist in the template or in the working set.
        WebObjectsException - Signals an error when sending the changes to the Intelligence Server.
      • getNewRankMetric

        WebRankMetric getNewRankMetric​(java.lang.String key,
                                       WebMetric metric)
                                throws java.lang.IllegalArgumentException,
                                       WebObjectsException
        Returns a new instance of the WebRankMetric object. This derived metric is based on the specified metric on the template or working set.
        Parameters:
        metric - The WebMetric object used to create the derived metric.
        Returns:
        The WebRankMetric object created.
        Throws:
        java.lang.IllegalArgumentException - thrown if the metric is null or does not exist in the template or in the working set.
        WebObjectsException - Signals an error when sending the changes to the Intelligence Server.
      • addPercentToTotalMetric

        RWInstance addPercentToTotalMetric​(java.lang.String key,
                                           WebPercentToTotalMetric metric)
                                    throws java.lang.IllegalArgumentException,
                                           WebObjectsException
        Adds percent-to-total metric to specified grid
        Parameters:
        key - Grid/graph node key
        metric - metric
        Returns:
        RWInstance new instance containing added metric
        Throws:
        java.lang.IllegalArgumentException
        WebObjectsException
      • addRankMetric

        RWInstance addRankMetric​(java.lang.String key,
                                 WebRankMetric metric)
                          throws java.lang.IllegalArgumentException,
                                 WebObjectsException
        Adds new rank metric to specified grid
        Parameters:
        key - Grid/graph node key
        metric - metric
        Returns:
        RWInstance new instance containing added metric
        Throws:
        java.lang.IllegalArgumentException
        WebObjectsException
      • refresh

        RWInstance refresh​(boolean reprompt,
                           boolean rerun)
                    throws WebObjectsException
        Refreshes the instance.
        Parameters:
        reprompt - whether the prompts will be reopened
        rerun - whether to re-execute the instance
        Returns:
        the new instance
        Throws:
        WebObjectsException - if a problem occurs when attempting to rerun
        Since:
        MicroStrategy Web 8.0.1
      • refresh

        RWInstance refresh​(boolean reprompt)
                    throws WebObjectsException
        Refreshes the current state of the instance. All the changes that have been accumulated thus far are going to be applied
        Parameters:
        reprompt -
        Returns:
        new instance
        Throws:
        WebObjectsException
      • drill

        RWInstance drill​(java.lang.String drillKey,
                         java.lang.String[] drillElements,
                         java.util.Map drillProperties)
                  throws WebObjectsException
        Drills on the current RW instance using the drill path key and settings passed as arguments.
        Parameters:
        drillKey - This is the key to the drill path to be used for drilling. The drill key can be obtained from WebDrillPath#getKey()
        drillElements - This is a string array of the drill elements representing the user filter. Each drill element is represented by an identifier (String) that can be obtained from WebHeader#getDrillElement()
        drillProperties - This should be a map of drill settings that the user wants to override while drilling. The keys in the map should be from EnumWebDrillProperties. Based on the type of drill property (int/boolean), following are the object types that can be passed as values in the Map :
        [1] For a drill property that can have integer values, an Integer or String object, wrapping the (integer) value, should be set.
        [2] For a drill property that can have only boolean values, a Boolean or String object representing the (boolean) value should be set. The String object should have values {"true", "false", "1", "0"} only.
        Returns:
        the new instance upon drilling.
        Throws:
        WebObjectsException - signal error encountered by IServer while executing the drill.
        Since:
        MicroStrategy Web 9.0.0
      • changeDerivedMetric

        RWInstance changeDerivedMetric​(java.lang.String metricId,
                                       java.lang.String dataSetId,
                                       java.lang.String formula,
                                       java.lang.String alias)
                                throws WebObjectsException
        Changes derived metric
        Parameters:
        metricId - metric ID
        dataSetId - data set ID
        formula - new metric formula
        alias - new metric alias
        Returns:
        document instance
        Throws:
        WebObjectsException
      • setCurrentControlElements

        RWInstance setCurrentControlElements​(java.lang.String key,
                                             java.util.List elementIds,
                                             boolean applyChanges)
                                      throws WebObjectsException
        Sets current control selection
        Parameters:
        key - control key
        elementIds - list of selected elements
        applyChanges - if true the changes will be applied immediately
        Returns:
        document instance
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 8.1.0
      • setCurrentControlElements

        RWInstance setCurrentControlElements​(java.lang.String key,
                                             java.util.List elementIds,
                                             boolean isInList,
                                             boolean applyChanges)
                                      throws WebObjectsException
        Sets current control selection. Does not change the inList state of selector
        Parameters:
        key - control key
        elementIds - list of selected elements
        isInList - the current isInList state of the control
        applyChanges - if true the changes will be applied immediately
        Returns:
        document instance
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 8.1.0
      • applyGraphControlAction

        RWInstance applyGraphControlAction​(java.lang.String nodeKey,
                                           int sliceID,
                                           int x,
                                           int y)
                                    throws WebObjectsException
        Sects control selection based on graph area
        Parameters:
        nodeKey - graph key
        sliceID - slice ID
        x - x cursor position
        y - y cursor position
        Returns:
        documrnt instance
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 8.1.0
      • addDataSetAndTemplate

        RWInstance addDataSetAndTemplate​(java.lang.String _dsId,
                                         int _dsType,
                                         java.lang.String _templateKey,
                                         int populateOption)
                                  throws WebObjectsException
        Adds specified data set to document and copies it's template to specified document template
        Parameters:
        _dsId - data set ID
        _dsType - data set type
        _templateKey - document template unit key
        populateOption - populate option
        Returns:
        RWInstance document instance
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 8.1.0
      • populateTemplateFromDataSet

        RWInstance populateTemplateFromDataSet​(java.lang.String _dsId,
                                               int _dsType,
                                               java.lang.String _templateKey,
                                               int _populateOption)
                                        throws WebObjectsException
        Populates document template unit with data set template
        Parameters:
        _dsId - data set ID
        _dsType - data set type
        _templateKey - document template unit key
        _populateOption - populate option
        Returns:
        RWInstance document instance
        Throws:
        WebObjectsException
        Since:
        MicroStrategy Web 8.1.0
      • setCurrentPanel

        void setCurrentPanel​(java.lang.String keyContext,
                             java.lang.String panelKey)
        Sets panel stack current panel
        Parameters:
        keyContext - panel stak key in server-specific format
        panelKey - panel key
        Since:
        MicroStrategy Web 8.1.0
      • setDisplayMode

        void setDisplayMode​(java.lang.String keyContext,
                            int viewMode)
        Sets document template unit display mode
        Parameters:
        keyContext - template unit key in server-specific format
        viewMode - view mode (see EnumWebReportViewMode)
        Since:
        MicroStrategy Web 8.1.0
      • pivotTemplateUnit

        void pivotTemplateUnit​(java.lang.String keyContext,
                               java.lang.String unitID,
                               int unitType,
                               int dAxis,
                               int dPos)
        Pivot the template unit specified to a new axis and position
        Parameters:
        keyContext - String containing the tree id and grid/graph's RW key
        unitID - String containing the template unit's id. Null for metrics
        unitType - int specifying the template unit's type (from EnumDSSXMLObjectTypes)
        dAxis - int specifying the new axis name from EnumDSSXMLAxisName
        dPos - int specifying the new axis position
      • updateTemplateUnits

        void updateTemplateUnits​(java.lang.String keyContext,
                                 java.lang.String unitID,
                                 int unitType,
                                 int dAxis,
                                 int dPos,
                                 int actions)
      • changeUnitName

        void changeUnitName​(java.lang.String keyContext,
                            java.lang.String unitID,
                            int unitType,
                            java.lang.String unitName)
      • showSubtotals

        void showSubtotals​(java.lang.String keyContext,
                           java.lang.String unitID,
                           int unitType,
                           java.lang.String subtotalType,
                           boolean isAdd)
      • addAttributeForm

        void addAttributeForm​(java.lang.String keyContext,
                              java.lang.String attributeID,
                              java.lang.String formID,
                              int index)
        Add an attribute form to a gridgraph in an RW
        Parameters:
        keyContext - String containing the tree id and grid/graph's RW key
        attributeID - String containing the attribute id for which the form will be added
        formID - String containing the attribute's form ID
        index - int specifying the new position of the form relative to the attributes template unit's position (1-starting)
      • addMetric

        void addMetric​(java.lang.String keyContext,
                       java.lang.String unitDisplayName,
                       java.lang.String unitID,
                       int unitType,
                       int unitPosition)
        Add a metric to a gridgraph in an RW
        Parameters:
        keyContext - String containing the tree id and grid/graph's RW key
        unitDisplayName -
        unitID - String containing the metric's id
        unitType - int specifying the metric's type (from EnumDSSXMLObjectTypes)
        unitPosition - int specifying the new position within the metrics collection
      • setCurrentLayout

        RWInstance setCurrentLayout​(int index,
                                    boolean applyChanges)
                             throws WebObjectsException
        Set the current layout by 0-based index
        Parameters:
        index - int 0-based index of new layout
        Returns:
        RWInstance containing changes
        Throws:
        WebObjectsException
      • getNewSortConfig

        WebSortConfig getNewSortConfig​(int sortType)
      • addDeltaXML

        void addDeltaXML​(java.lang.String deltaXml)
                  throws WebObjectsException
        Append the DeltaXML to the current manipulator Delta
        Parameters:
        deltaXml - : manipulator deltaxml
        Throws:
        WebObjectsException
      • setControlCurrentElementStatusToUnset

        RWInstance setControlCurrentElementStatusToUnset​(java.lang.String keyContext,
                                                         boolean applyChanges)
                                                  throws WebObjectsException
        Sets the control status to unset
        Parameters:
        keyContext - String containing treeType, nodeKey, and controlKey
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setControlUnsetStatus

        RWInstance setControlUnsetStatus​(java.lang.String keyContext,
                                         int unsetStatus,
                                         int unsetCount,
                                         boolean applyChanges)
                                  throws WebObjectsException
        Set the unset status of the control specified by keyContext
        Parameters:
        keyContext - String containing treeType, nodeKey, and controlKey
        unsetStatus - int from EnumDSSXMLRWSelectorUnsetStatus
        unsetCount - int number of elements to be retrieved on Default Selection
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • replaceDataSet

        RWInstance replaceDataSet​(java.lang.String oldDataSetID,
                                  java.lang.String newDataSetID,
                                  int oldDSType,
                                  int newDSType,
                                  boolean applyChanges)
                           throws WebObjectsException
        replace the old dataset with the new one
        Parameters:
        oldDataSetID - String
        newDataSetID - String
        oldDSType - int old data set type from EnumDSSXMLObjectTypes
        newDSType - int new data set type from EnumDSSXMLObjectTypes
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • replaceDataSetKeepDerivedObjects

        RWInstance replaceDataSetKeepDerivedObjects​(java.lang.String oldDataSetID,
                                                    java.lang.String newDataSetID,
                                                    boolean clearAliasAndFormatting,
                                                    boolean applyChanges)
                                             throws WebObjectsException
        Function providing the ability to replace a dataset while retaining all of the derived metrics and their definitions
        Parameters:
        oldDataSetID - String
        newDataSetID - String
        clearAliasAndFormatting - Whether to clear the alias and number formatting, false = Don't Clear, true = Clear
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • replaceDataSetReplaceMap

        RWInstance replaceDataSetReplaceMap​(java.lang.String oldDataSetID,
                                            java.lang.String newDataSetID,
                                            boolean clearAliasAndFormatting,
                                            java.util.HashMap<java.lang.String,​java.lang.String> resolutionMap,
                                            boolean applyChanges)
                                     throws WebObjectsException
        Function providing the ability to replace a dataset, replacing or removing objects on the document based on the HashMap. Any Derived object not explicitly removed will be placed on the newDataSet
        Parameters:
        oldDataSetID - String
        newDataSetID - String
        clearAliasAndFormatting - Whether to clear the alias and number formatting, false = Don't Clear, true = Clear
        applyChanges - boolean specifying whether to apply the changes now
        resolutionMap - a HashMap which will provide a mapping for reconciliation, . If a targetGUID is null we can assume we are removing the object from the dataset.
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setControlExpression

        RWInstance setControlExpression​(java.lang.String keyContext,
                                        int controlType,
                                        WebExpression expression,
                                        boolean applyChanges)
                                 throws WebObjectsException
        Set the expression for a conditional selector
        Parameters:
        keyContext - String containing either control key or treeType|nodeKey|controlKey
        controlType - int from EnumDSSXMLRWControlType
        expression - WebExpression object containing expression information
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • addTransactionReport

        RWInstance addTransactionReport​(java.lang.String keyContext,
                                        java.lang.String transactionElementID,
                                        int transactionElementType,
                                        boolean applyChanges)
                                 throws WebObjectsException
        Associate a transaction report with a rwGridGraph unit or rwFieldGroupUnit
        Parameters:
        nodeKey - String the key of the rwGridGraph unit/RWfieldGroupUnit
        transactionElementID - String transaction element ID
        transactionElementType - int transaction element Type
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • removeTransactionReport

        RWInstance removeTransactionReport​(java.lang.String keyContext,
                                           boolean applyChanges)
                                    throws WebObjectsException
        Parameters:
        keyContext - String
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setTransactionInfoOnGridObject

        RWInstance setTransactionInfoOnGridObject​(java.lang.String keyContext,
                                                  java.lang.String objectID,
                                                  int objectType,
                                                  java.lang.String attributeFormID,
                                                  int mappedColumnIndex,
                                                  int transactionFlags,
                                                  java.lang.String inputControlKey,
                                                  java.lang.String inputControlProperties,
                                                  boolean applyChanges)
                                           throws WebObjectsException
        Set transaction information for attribute form/metric on a grid
        Parameters:
        keyContext - String
        objectID - String attributeID/metricID
        objectType - int the dssType of this unit
        attributeFormID - String the attribute formID if it is for attributeForm
        mappedColumnIndex - int the columnIndex in the transactionReport this object mapped to
        transactionFlags - int the new transaction flags refer to EnumDSSXMLUnitTransactionFlags
        inputControlKey - String the controlKey for the inputControl
        inputControlProperties - String the control format properties for the inputControl
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • removeTransactionInfoOnGridObject

        RWInstance removeTransactionInfoOnGridObject​(java.lang.String keyContext,
                                                     java.lang.String objectID,
                                                     int objectType,
                                                     java.lang.String attributeFormID,
                                                     boolean applyChanges)
                                              throws WebObjectsException
        Clear the transaction information for attribute form/metric on a grid
        Parameters:
        keyContext - String
        objectID - String attributeID/metricID
        objectType - int the dssType of this unit
        attributeFormID - String the attribute formID if it is for attributeForm
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setTransactionInfoOnField

        RWInstance setTransactionInfoOnField​(java.lang.String keyContext,
                                             java.lang.String fieldKey,
                                             int mappedColumnIndex,
                                             int transactionFlags,
                                             java.lang.String inputControlKey,
                                             java.lang.String inputControlProperties,
                                             boolean applyChanges)
                                      throws WebObjectsException
        Set transaction information for text fields
        Parameters:
        keyContext - String
        fieldKey - String nodeKey of the textField
        mappedColumnIndex - int the columnIndex in the transactionReport this object mapped to
        transactionFlags - int the new transaction flags refer to EnumDSSXMLUnitTransactionFlags
        inputControlKey - String the controlKey for the inputControl
        inputControlProperties - String the control format properties for the inputControl
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • removeTransactionInfoOnField

        RWInstance removeTransactionInfoOnField​(java.lang.String keyContext,
                                                java.lang.String fieldKey,
                                                boolean applyChanges)
                                         throws WebObjectsException
        Clear the transaction information for text fields
        Parameters:
        keyContext - String
        fieldKey - String nodeKey of the textField
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setAvailableActionTypesForControl

        RWInstance setAvailableActionTypesForControl​(java.lang.String keyContext,
                                                     int actionType,
                                                     boolean applyChanges)
                                              throws WebObjectsException
        Set the available control types in a control
        Parameters:
        keyContext - String
        actionType - int refer to EnumDSSXMLRWControlActionType
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setControlSubsquentAction

        RWInstance setControlSubsquentAction​(java.lang.String keyContext,
                                             int action,
                                             boolean applyChanges)
                                      throws WebObjectsException
        Set the subsequent action in the action control after submit.
        Parameters:
        keyContext - String
        action - int EnumDSSXMLRWControlSubsequentAction
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setControlSubsquentActionObject

        RWInstance setControlSubsquentActionObject​(java.lang.String keyContext,
                                                   int controlType,
                                                   java.lang.String objectID,
                                                   int objectType,
                                                   java.lang.String objectName,
                                                   boolean applyChanges)
                                            throws WebObjectsException
        Set the subsequent action in the action control after submit.
        Parameters:
        keyContext - String
        controlType - int EnumDSSXMLRWControlType
        objectID - String the dssID of the object to be executed after submit
        objectType - int the dssType of the object to be executed after submit
        objectName - String the name of the object to be executed after submit
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setControlSubsquentDisplayMessage

        RWInstance setControlSubsquentDisplayMessage​(java.lang.String keyContext,
                                                     java.lang.String displayMessage,
                                                     boolean applyChanges)
                                              throws WebObjectsException
        Set message to display after perform the action using action selector.
        Parameters:
        keyContext - String
        displayMessage - String the message to display after perform the action using action selector
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setControlDisplayText

        RWInstance setControlDisplayText​(java.lang.String keyContext,
                                         java.lang.String displayText,
                                         boolean applyChanges)
                                  throws WebObjectsException
        Set the display text for the action selector
        Parameters:
        keyContext - String
        displayText - String the text to display for the action selector
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setTransactionChangeType

        RWInstance setTransactionChangeType​(java.lang.String keyContext,
                                            int changeType,
                                            boolean applyChanges)
                                     throws WebObjectsException
        Set the transaction change type in the filed group node or gridGraph node.
        Parameters:
        keyContext - String
        changeType - int EnumDSSXMLRWNodeTransactionChangeType
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • setAutomaticTransactionRecordNumber

        RWInstance setAutomaticTransactionRecordNumber​(java.lang.String keyContext,
                                                       int recordNumber,
                                                       boolean applyChanges)
                                                throws WebObjectsException
        Set the number of rows that will be automatically transacted
        Parameters:
        keyContext - String
        recordNumber - int -1 for all rows, 0 for none, and some value > 0 for a specific number of rows
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • updateTransactionData

        RWInstance updateTransactionData​(java.lang.String changes,
                                         boolean applyChanges)
                                  throws WebObjectsException
        Modify transaction data in the RWInstance
        Parameters:
        changes - String
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • performActionOnActionSelector

        RWInstance performActionOnActionSelector​(java.lang.String keyContext,
                                                 int action,
                                                 boolean applyChanges)
                                          throws WebObjectsException
        Perform and action on an ActionSelector.
        Parameters:
        keyContext - String
        action - int EnumDSSXMLRWControlSubsequentAction
        applyChanges - boolean specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
      • applySegment

        RWInstance applySegment​(java.lang.String segmentID,
                                java.lang.String keyContext,
                                boolean applyChanges)
                         throws WebObjectsException,
                                WebException
        Apply a Segment to the RWInstance
        Parameters:
        segmentID - the ID of the segment to be applied
        keyContext - String
        applyChanges - specifying whether to apply the changes now
        Returns:
        either current RWInstance or the one generated after the applied changes
        Throws:
        WebObjectsException
        WebException
      • setControlTexts

        RWInstance setControlTexts​(java.lang.String keyContext,
                                   java.util.List<java.lang.String> texts,
                                   boolean applyChanges)
                            throws WebObjectsException
        Sets current control's text selections
        Parameters:
        keyContext - String containing either control key or treeType|nodeKey|controlKey
        texts - list of texts
        applyChanges - if true the changes will be applied immediately
        Returns:
        document instance
        Throws:
        WebObjectsException
      • addDocumentView

        RWInstance addDocumentView​(java.lang.String name,
                                   int resolutionX,
                                   int resolutionY,
                                   int density,
                                   int orientation,
                                   int index,
                                   boolean applyChanges)
                            throws WebObjectsException
        Add a new document by duplicating an existing document. Specifying the document view's properties and the source view's index.
        Parameters:
        name - View name
        resolutionX - X resolution
        resolutionY - Y resolution
        density - density
        orientation - orientation (values in 0, 1, 2)
        index - Source document view's index
        applyChanges - apply Changes
        Returns:
        Throws:
        WebObjectsException
      • editDocumentView

        RWInstance editDocumentView​(java.lang.String name,
                                    int resolutionX,
                                    int resolutionY,
                                    int density,
                                    int orientation,
                                    int index,
                                    boolean applyChanges)
                             throws WebObjectsException
        Edit a document view
        Parameters:
        name - View name
        resolutionX - X resolution
        resolutionY - Y resolution
        density - density
        orientation - Orientation (values in 0, 1, 2)
        index - Index of the view to be edited
        applyChanges - apply Changes
        Returns:
        Throws:
        WebObjectsException
      • removeDocumentView

        RWInstance removeDocumentView​(int index,
                                      boolean applyChanges)
                               throws WebObjectsException
        Remove a document view at specified index
        Parameters:
        index - The index of the document view to be removed
        applyChanges - apply Changes
        Returns:
        Throws:
        WebObjectsException
      • setCurrentDocumentView

        RWInstance setCurrentDocumentView​(int index,
                                          boolean applyChanges)
                                   throws WebObjectsException
        set the current document view with the specified index
        Parameters:
        index - The index of the view to be set as the current document view
        applyChanges -
        Returns:
        Throws:
        WebObjectsException
      • setControlAttributeFormsDelimeter

        RWInstance setControlAttributeFormsDelimeter​(java.lang.String keyContext,
                                                     java.lang.String delimiter,
                                                     boolean applyChanges)
                                              throws WebObjectsException
        Set delimiter for custom control forms
        Parameters:
        keyContext - String containing tree type, node key, control key
        delimiter - String containing delimiter
        applyChanges - boolean specifying whether changes should be applied immediately
        Returns:
        either current RWInstance or one generated after applied changes
        Throws:
        WebObjectsException
      • setControlAttributeFormsDisplayType

        RWInstance setControlAttributeFormsDisplayType​(java.lang.String keyContext,
                                                       int displayType,
                                                       boolean applyChanges)
                                                throws WebObjectsException
        Set display type for control forms
        Parameters:
        keyContext - String containing tree type, node key, control key
        displayType - int from EnumDSSXMLControlAttributeFormDisplayOption
        applyChanges - boolean specifying whether changes should be applied immediately
        Returns:
        either current RWInstance or one generated after applied changes
        Throws:
        WebObjectsException
      • setControlAttributeForms

        RWInstance setControlAttributeForms​(java.lang.String keyContext,
                                            java.util.List<java.lang.String> formIDs,
                                            boolean applyChanges)
                                     throws WebObjectsException
        Set forms for custom control forms
        Parameters:
        keyContext - String containing tree type, node key, control key
        formIDs - List containing String of form IDs
        applyChanges - boolean specifying whether changes should be applied immediately
        Returns:
        either current RWInstance or one generated after applied changes
        Throws:
        WebObjectsException
      • addControlSort

        RWInstance addControlSort​(java.lang.String keyContext,
                                  int sortType,
                                  boolean isAscending,
                                  int subTotalsPosition,
                                  java.lang.String unitID,
                                  int unitType,
                                  java.lang.String formID,
                                  boolean applyChanges)
                           throws WebObjectsException
        Adds a sort to the specified control
        Parameters:
        keyContext - String containing tree type, node key, control key
        sortType - int from EnumDSSXMLSortType
        isAscending - boolean specifying whether sort is ascending
        subTotalsPosition - int from EnumDSSXMLSubtotalsPosition
        unitID - String containing ID of target of sort
        unitType - int from EnumDSSXMLObjectTypes
        formID - String containing ID of form to sort on if form is sorted on (null o/w).
        applyChanges - boolean specifying whether changes should be applied immediately
        Returns:
        either current RWInstance or one generated after applied changes
        Throws:
        WebObjectsException
      • clearControlSorts

        RWInstance clearControlSorts​(java.lang.String keyContext,
                                     boolean applyChanges)
                              throws WebObjectsException
        Clears all sorts for a givent control
        Parameters:
        keyContext - String containing tree type, node key, control key
        applyChanges - boolean specifying whether changes should be applied immediately
        Returns:
        either current RWInstance or one generated after applied changes
        Throws:
        WebObjectsException
      • addShortcutMetric

        RWInstance addShortcutMetric​(java.lang.String datasetID,
                                     java.lang.String datasetType,
                                     java.lang.String nodeKey,
                                     java.lang.String treeType,
                                     int functionType,
                                     int functionType2,
                                     java.util.List<WebObjectInfo> unitsInfo)
                              throws WebObjectsException
        Add shortcut metric to a given dataset and optionally a given template
        Parameters:
        datasetID -
        datasetType -
        nodeKey -
        treeType -
        functionType - the main function type for the manipulation
        functionType2 - the optional second function type for the manipulation
        unitsInfo - the WebObjectInfo collection of the units for the manipulation
        Returns:
        current RWInstance
        Throws:
        WebObjectsException
      • applyAttributeRemapping

        RWInstance applyAttributeRemapping​(java.lang.String datasetID,
                                           int datasetType,
                                           java.lang.String tarDatasetID,
                                           int tarDatasetType,
                                           java.lang.String srcID,
                                           java.lang.String tarID)
                                    throws WebObjectsException
        Apply or cancel attribute re-mapping
        Parameters:
        datasetID - id of the source dataset
        datasetType - type of the source dataset
        tarDatasetID - id of the target dataset
        tarDatasetType - type of the target dataset
        srcID - source attribute id
        tarID - target attribute id, if empty, this is cancel link manipulation; else, apply link
        Throws:
        WebObjectsException
      • applyAttributeLinking

        RWInstance applyAttributeLinking​(boolean unlink,
                                         java.lang.String srcAttrID,
                                         java.lang.String srcFormIDs,
                                         java.lang.String tgtAttrIDs,
                                         java.lang.String tgtFormsIDs)
                                  throws WebObjectsException
        Apply linking or unlinking attributes
        Parameters:
        unlink - indicates unlinking attributes
        srcAttrID - id of the source attribute
        srcFormIDs - id of the source attribute's forms, separated by ""
        tgtAttrIDs - id of the target attributes to be linked or unlinked, separated by ""
        tgtFormsIDs - id of the target attributes's corresponding form, separated by ""
        Throws:
        WebObjectsException
      • advSort

        RWInstance advSort​(java.lang.String nodeKey,
                           int treeType,
                           boolean clearSorts,
                           WebSortConfig config,
                           boolean applyNow,
                           boolean isAdvSort)
                    throws WebObjectsException
        Apply multiple sort rules to the grid
        Parameters:
        nodeKey - The nodeKey for the current grid
        treeType - The tree type
        clearSorts - Do we need to clear the current sort definitions that are already applied to the grid
        config - WebSortConfig
        applyNow - Do we need to apply the changes now
        isAdvSort - Is this request come from advanced sort editor, if yes, clear both rows and column definitions
        Returns:
        The RWInstance
        Throws:
        WebObjectsException
      • resetSelections

        RWInstance resetSelections​(java.lang.String keyContext)
                            throws WebObjectsException
        Reset document selections
        Parameters:
        keyContext - String if keyContext is null, we'll reset the whole document
        Throws:
        WebObjectsException
      • validateLocalTransactionExpression

        java.lang.String validateLocalTransactionExpression​(WebTokenStream tokenStream,
                                                            java.lang.String ctlKey,
                                                            java.lang.String nodeKey)
                                                     throws WebObjectsException
        Check whether the token steam is valid
        Parameters:
        tokenStreamXML - the token stream to be validated
        nodeKey - Grid/graph node key
        Returns:
        parsed token stream xml
        Throws:
        WebObjectsException
      • addDerivedMetricToTemplate

        RWInstance addDerivedMetricToTemplate​(java.lang.String key,
                                              java.lang.String formula,
                                              int position,
                                              java.lang.String name,
                                              java.lang.Boolean aggFromBase,
                                              java.lang.Boolean isTokenStream)
                                       throws WebObjectsException
        Adds derived metric to a template inside document
        Parameters:
        key - Grid/graph unit key
        formula - derived metric formula
        position - metric position in the collection
        name - visible metric name
        aggFromBase - flag to indicate whether the metric should aggregate from base.
        isTokenStream - flag to indicate whether the formula is a token stream
        Returns:
        a RW instance representing document after changes
        Throws:
        WebObjectsException
      • addDerivedMetricToDataSet

        RWInstance addDerivedMetricToDataSet​(java.lang.String id,
                                             java.lang.String formula,
                                             java.lang.String name,
                                             boolean aggFromBase,
                                             boolean isTokenStream)
                                      throws WebObjectsException
        Adds derived metric to document data set
        Parameters:
        id - data set ID
        formula - derived metric formula
        name - visible metric name
        aggFromBase - flag to indicate whether the metric should aggregate from base.
        isTokenStream - flag to indicate whether the formula is a token stream.
        Returns:
        a RW instance representing document after changes
        Throws:
        WebObjectsException
      • changeDerivedMetric

        RWInstance changeDerivedMetric​(java.lang.String metricId,
                                       java.lang.String dataSetId,
                                       java.lang.String formula,
                                       java.lang.String alias,
                                       java.lang.Boolean isTokenStream,
                                       java.lang.Boolean aggregateFromBase)
                                throws WebObjectsException
        Changes derived metric
        Parameters:
        metricId - metric ID
        dataSetId - data set ID
        formula - new metric formula
        alias - new metric alias
        isTokenStream - flag to indicate whether the formula is a token stream.
        aggregateFromBase - new metric aggregateFromBase
        Returns:
        document instance
        Throws:
        WebObjectsException
      • validateExpression

        java.lang.String validateExpression​(java.lang.String tokenStreamXML,
                                            boolean isForMetric,
                                            int outFlags,
                                            int baseFormType)
                                     throws WebObjectsException
        Check whether the token stream is valid
        Parameters:
        tokenStreamXML - the token stream to be validated
        isForMetric - flag to indicate whether the token stream is for metric
        outFlags - flags from EnumDSSXMLParserOutFlags indicating which part should be returned.
        baseFormType - if it's greater than 0, iserver needs to check whether the base form type is compatible with the expression.
        Returns:
        parsed token stream xml
        Throws:
        WebObjectsException
      • addDerivedAttributeToDataSet

        RWInstance addDerivedAttributeToDataSet​(java.lang.String dataSetId,
                                                java.lang.String name,
                                                java.lang.String formula,
                                                java.lang.Integer bft,
                                                java.lang.Boolean isTokenStream)
                                         throws WebObjectsException
        add derived attribute to dataset only with id form, you can add other forms by
        Parameters:
        dataSetId - dataset id
        name - new attribute name
        formula - formula of form to add, not null
        bft - base form type of form to add, null or 0 means to be determined by AE
        isTokenStream - flag to indicate whether the formula is a token stream, false or null means not a token stream
        Returns:
        document instance
        Throws:
        WebObjectsException
      • addDerivedAttributeToTemplate

        RWInstance addDerivedAttributeToTemplate​(java.lang.String key,
                                                 java.lang.String name,
                                                 int axisName,
                                                 int position,
                                                 java.lang.String formula,
                                                 java.lang.Integer bft,
                                                 java.lang.Boolean isTokenStream)
                                          throws WebObjectsException
        Adds derived attribute to a template inside document
        Parameters:
        key - Grid/graph unit key
        name - visible attribute name
        axisName - the name of axis the derived attribute added to
        position - attribute position in the collection
        formula - formula of form to add, not null
        bft - base form type of form to add, null or 0 means to be determined by AE
        isTokenStream - flag to indicate whether the formula is a token stream, false or null means not a token stream
        Returns:
        document instance
        Throws:
        WebObjectsException
      • changeDerivedAttributeName

        RWInstance changeDerivedAttributeName​(java.lang.String attributeId,
                                              java.lang.String dataSetId,
                                              java.lang.String name)
                                       throws WebObjectsException
        change derived attribute name
        Parameters:
        attributeId - derived attribute id
        dataSetId - dataset id
        name - new attribute name
        Returns:
        document instance after change
        Throws:
        WebObjectsException
      • addFormToDerivedAttribute

        RWInstance addFormToDerivedAttribute​(java.lang.String attributeId,
                                             java.lang.String dataSetId,
                                             java.lang.String formId,
                                             java.lang.String name,
                                             java.lang.Integer index,
                                             java.lang.String formula,
                                             java.lang.Integer bft,
                                             boolean applyChanges)
                                      throws WebObjectsException
        add one attribute form to derived attribute
        Parameters:
        attributeId - derived attribute id
        dataSetId - data set id
        formId - id of the system form to add, if null, a new managed form to add
        name - the new managed form name if formId is null
        index - the position of this added form, 0 or null means added to the back
        formula - base form formula, not null
        bft - base form type, 0 or null means to be determined by AE
        applyChanges - true to apply changes after this manipulation
        Returns:
        document instance after change
        Throws:
        WebObjectsException
      • updateDerivedAttributeForm

        RWInstance updateDerivedAttributeForm​(java.lang.String attributeId,
                                              java.lang.String dataSetId,
                                              java.lang.String formId,
                                              java.lang.String name,
                                              java.lang.String formula,
                                              java.lang.Integer bft,
                                              java.lang.Boolean isTokenStream,
                                              java.lang.Boolean isDisplayForm)
                                       throws WebObjectsException
        update form of derived attribute
        Parameters:
        attributeId - derived attribute id
        dataSetId - data set id
        formId - id of the form to update
        name - new name
        formula - new base form formula
        bft - new base form type
        isTokenStream - true to update the formula with token stream
        isDisplayForm - true to add the form to display forms collection, false to remove the form from display forms collection, null to do nothing
        Returns:
        document instance after change
        Throws:
        WebObjectsException
      • removeFormFromDerivedAttribute

        RWInstance removeFormFromDerivedAttribute​(java.lang.String attributeId,
                                                  java.lang.String dataSetId,
                                                  java.lang.String formId)
                                           throws WebObjectsException
        remove attribute form from derived attribute
        Parameters:
        attributeId - derived attribute id
        dataSetId - data set id
        formId - id of the form to remove
        Returns:
        document instance after change
        Throws:
        WebObjectsException
      • setTemplateUnitProperties

        RWInstance setTemplateUnitProperties​(java.lang.String nodeKey,
                                             int treeType,
                                             java.lang.String unitID,
                                             int unitType,
                                             boolean applyNow)
                                      throws WebObjectsException
        Apply the changed properties of a template unit
        Parameters:
        nodeKey -
        treeType -
        unitID -
        unitType -
        applyNow -
        Returns:
        Throws:
        WebObjectsException
      • applyTheme

        RWInstance applyTheme​(java.lang.String themeID,
                              boolean applyChanges)
                       throws WebObjectsException
        Apply theme to this RWInstance
        Parameters:
        themeID - the ID of the theme to apply
        applyChanges - whether to call applyChanges
        Returns:
        document instance after changes
        Throws:
        WebObjectsException
      • applyThemeOnNode

        RWInstance applyThemeOnNode​(java.lang.String themeID,
                                    RWUnitDef unit,
                                    boolean isLink,
                                    boolean applyChanges)
                             throws WebObjectsException
        Apply theme on specified node
        Parameters:
        themeID - the ID of the theme to apply
        unit - the definition of the node
        isLink - whether to apply a linked theme, false to apply a copied theme
        applyChanges - whether to call applyChanges
        Returns:
        document instance after changes
        Throws:
        WebObjectsException
      • removeThemeOnNode

        RWInstance removeThemeOnNode​(RWUnitDef unit,
                                     boolean applyChanges)
                              throws WebObjectsException
        remove theme on specified node
        Parameters:
        unit - the definition of the node
        applyChanges - whether to call applyChanges
        Returns:
        document instance after changes
        Throws:
        WebObjectsException
      • forceApplyChanges

        RWInstance forceApplyChanges()
        If we have delta on the manipulator, we must force to apply changes
        Returns:
        document instance