Class GridEditProxy

All Implemented Interfaces:
HasHandlers

public class GridEditProxy extends LayoutEditProxy
EditProxy that handles ListGrid and TreeGrid components when editMode is enabled.
See Also:
  • Constructor Details

    • GridEditProxy

      public GridEditProxy()
    • GridEditProxy

      public GridEditProxy(JavaScriptObject jsObj)
  • Method Details

    • getOrCreateRef

      public static GridEditProxy getOrCreateRef(JavaScriptObject jsObj)
    • create

      public JavaScriptObject create()
      Overrides:
      create in class LayoutEditProxy
    • setCanAddFormulaFields

      public GridEditProxy setCanAddFormulaFields(Boolean canAddFormulaFields) throws IllegalStateException
      Can new formula fields be created from header context menu? Overrides ListGrid.canAddFormulaFields when in edit mode.
      Parameters:
      canAddFormulaFields - New canAddFormulaFields value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getCanAddFormulaFields

      public Boolean getCanAddFormulaFields()
      Can new formula fields be created from header context menu? Overrides ListGrid.canAddFormulaFields when in edit mode.
      Returns:
      Current canAddFormulaFields value. Default value is true
    • setCanAddSummaryFields

      public GridEditProxy setCanAddSummaryFields(Boolean canAddSummaryFields) throws IllegalStateException
      Can new summary fields be created from header context menu? Overrides ListGrid.canAddSummaryFields when in edit mode.
      Parameters:
      canAddSummaryFields - New canAddSummaryFields value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getCanAddSummaryFields

      public Boolean getCanAddSummaryFields()
      Can new summary fields be created from header context menu? Overrides ListGrid.canAddSummaryFields when in edit mode.
      Returns:
      Current canAddSummaryFields value. Default value is true
    • setCanEditHilites

      public GridEditProxy setCanEditHilites(Boolean canEditHilites) throws IllegalStateException
      Can highlights be edited from header context menu? Overrides ListGrid.canEditHilites when in edit mode.
      Parameters:
      canEditHilites - New canEditHilites value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getCanEditHilites

      public Boolean getCanEditHilites()
      Can highlights be edited from header context menu? Overrides ListGrid.canEditHilites when in edit mode.
      Returns:
      Current canEditHilites value. Default value is true
    • setCanGroupBy

      public GridEditProxy setCanGroupBy(Boolean canGroupBy) throws IllegalStateException
      Can records be grouped from header context menu? Overrides ListGrid.canGroupBy when in edit mode.
      Parameters:
      canGroupBy - New canGroupBy value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getCanGroupBy

      public Boolean getCanGroupBy()
      Can records be grouped from header context menu? Overrides ListGrid.canGroupBy when in edit mode.
      Returns:
      Current canGroupBy value. Default value is true
    • setCanReorderFields

      public GridEditProxy setCanReorderFields(Boolean canReorderFields) throws IllegalStateException
      Indicates whether fields in this listGrid can be reordered by dragging and dropping header fields. Overrides ListGrid.canReorderFields when in edit mode.
      Parameters:
      canReorderFields - New canReorderFields value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getCanReorderFields

      public Boolean getCanReorderFields()
      Indicates whether fields in this listGrid can be reordered by dragging and dropping header fields. Overrides ListGrid.canReorderFields when in edit mode.
      Returns:
      Current canReorderFields value. Default value is true
    • setCanResizeFields

      public GridEditProxy setCanResizeFields(Boolean canResizeFields) throws IllegalStateException
      Indicates whether fields in this listGrid can be resized by dragging header fields. Overrides ListGrid.canResizeFields when in edit mode.
      Parameters:
      canResizeFields - New canResizeFields value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getCanResizeFields

      public Boolean getCanResizeFields()
      Indicates whether fields in this listGrid can be resized by dragging header fields. Overrides ListGrid.canResizeFields when in edit mode.
      Returns:
      Current canResizeFields value. Default value is true
    • setGenerateEditableFormulas

      public GridEditProxy setGenerateEditableFormulas(Boolean generateEditableFormulas) throws IllegalStateException
      Controls whether formula fields created while in edit mode are editable by end users at runtime (when the grid is no longer in edit mode). See ListGridField.canEditFormula.
      Parameters:
      generateEditableFormulas - New generateEditableFormulas value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getGenerateEditableFormulas

      public Boolean getGenerateEditableFormulas()
      Controls whether formula fields created while in edit mode are editable by end users at runtime (when the grid is no longer in edit mode). See ListGridField.canEditFormula.
      Returns:
      Current generateEditableFormulas value. Default value is true
    • setGenerateEditableHilites

      public GridEditProxy setGenerateEditableHilites(Boolean generateEditableHilites) throws IllegalStateException
      Controls whether highlights created while in edit mode are editable by end users at runtime (when the grid is no longer in edit mode). See Hilite.canEdit.
      Parameters:
      generateEditableHilites - New generateEditableHilites value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getGenerateEditableHilites

      public Boolean getGenerateEditableHilites()
      Controls whether highlights created while in edit mode are editable by end users at runtime (when the grid is no longer in edit mode). See Hilite.canEdit.
      Returns:
      Current generateEditableHilites value. Default value is true
    • setGenerateEditableSummaries

      public GridEditProxy setGenerateEditableSummaries(Boolean generateEditableSummaries) throws IllegalStateException
      Controls whether summary fields created while in edit mode are editable by end users at runtime (when the grid is no longer in edit mode). See ListGridField.canEditSummary.
      Parameters:
      generateEditableSummaries - New generateEditableSummaries value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getGenerateEditableSummaries

      public Boolean getGenerateEditableSummaries()
      Controls whether summary fields created while in edit mode are editable by end users at runtime (when the grid is no longer in edit mode). See ListGridField.canEditSummary.
      Returns:
      Current generateEditableSummaries value. Default value is true
    • setSaveFieldFrozenState

      public GridEditProxy setSaveFieldFrozenState(Boolean saveFieldFrozenState) throws IllegalStateException
      Should changes to which fields are frozen be persisted?

      Note that changes are saved directly into the ListGridFields not via fieldState or viewState settings. EditNodes will also be introduced for fields as needed if they do not already exist.

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Parameters:
      saveFieldFrozenState - New saveFieldFrozenState value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getSaveFieldFrozenState

      public Boolean getSaveFieldFrozenState()
      Should changes to which fields are frozen be persisted?

      Note that changes are saved directly into the ListGridFields not via fieldState or viewState settings. EditNodes will also be introduced for fields as needed if they do not already exist.

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Returns:
      Current saveFieldFrozenState value. Default value is true
    • setSaveFieldOrder

      public GridEditProxy setSaveFieldOrder(Boolean saveFieldOrder) throws IllegalStateException
      Should changes to grid field order be persisted?

      Note that changes are saved directly into the ListGridFields not via fieldState or viewState settings. EditNodes will also be introduced for fields as needed if they do not already exist.

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Parameters:
      saveFieldOrder - New saveFieldOrder value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getSaveFieldOrder

      public Boolean getSaveFieldOrder()
      Should changes to grid field order be persisted?

      Note that changes are saved directly into the ListGridFields not via fieldState or viewState settings. EditNodes will also be introduced for fields as needed if they do not already exist.

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Returns:
      Current saveFieldOrder value. Default value is true
    • setSaveFieldVisibility

      public GridEditProxy setSaveFieldVisibility(Boolean saveFieldVisibility) throws IllegalStateException
      Should changes to grid field visibility be persisted?

      Note that changes are saved directly into the ListGridFields not via fieldState or viewState settings. EditNodes will also be introduced for fields as needed if they do not already exist.

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Parameters:
      saveFieldVisibility - New saveFieldVisibility value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getSaveFieldVisibility

      public Boolean getSaveFieldVisibility()
      Should changes to grid field visibility be persisted?

      Note that changes are saved directly into the ListGridFields not via fieldState or viewState settings. EditNodes will also be introduced for fields as needed if they do not already exist.

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Returns:
      Current saveFieldVisibility value. Default value is true
    • setSaveFilterCriteria

      public GridEditProxy setSaveFilterCriteria(Boolean saveFilterCriteria) throws IllegalStateException
      Should changes to filter criteria by end user editing of criteria in the filter editor by persisted?

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Parameters:
      saveFilterCriteria - New saveFilterCriteria value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getSaveFilterCriteria

      public Boolean getSaveFilterCriteria()
      Should changes to filter criteria by end user editing of criteria in the filter editor by persisted?

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Returns:
      Current saveFilterCriteria value. Default value is true
    • setSaveGroupBy

      public GridEditProxy setSaveGroupBy(Boolean saveGroupBy) throws IllegalStateException
      Should changes to grid grouping (including both grouping and ungrouping the grid) be persisted?

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Parameters:
      saveGroupBy - New saveGroupBy value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getSaveGroupBy

      public Boolean getSaveGroupBy()
      Should changes to grid grouping (including both grouping and ungrouping the grid) be persisted?

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Returns:
      Current saveGroupBy value. Default value is true
    • setSaveSort

      public GridEditProxy setSaveSort(Boolean saveSort) throws IllegalStateException
      Should changes to which fields are sorted be persisted?

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Parameters:
      saveSort - New saveSort value. Default value is true
      Returns:
      GridEditProxy instance, for chaining setter calls
      Throws:
      IllegalStateException - this property cannot be changed after the underlying component has been created
    • getSaveSort

      public Boolean getSaveSort()
      Should changes to which fields are sorted be persisted?

      Only valid with SelectedAppearance settings that allow direct interactivity (such as "outlineEdges").

      Returns:
      Current saveSort value. Default value is true
    • getInlineEditText

      public void getInlineEditText()
      Returns the text based on the current component state to be edited inline. Called by the EditProxy.inlineEditForm to obtain the starting edit value.

      Returns the grid's wiki-style data - see MockDataSource.mockData for a description of this format.

      Overrides:
      getInlineEditText in class EditProxy
    • setInlineEditText

      public void setInlineEditText(String newValue)
      Save the new value into the component's state. Called by the EditProxy.inlineEditForm to commit the change.

      Updates the grid's data and field configuration.

      Overrides:
      setInlineEditText in class EditProxy
      Parameters:
      newValue - the new grid configuration