com.smartgwt.client.tools

## Class HiddenPalette

- java.lang.Object
- - com.smartgwt.client.core.BaseClass
  - - com.smartgwt.client.tools.HiddenPalette

- All Implemented Interfaces:
    com.google.gwt.event.shared.HasHandlers, Palette

      public class HiddenPalette
      extends BaseClass
      implements Palette

  A Palette with no visible representation that handles programmatic creation of components.
  See Also:
    `Dashboards & Tools Framework Overview`

- - ### Field Summary

    - ### Fields inherited from class com.smartgwt.client.core.BaseClass

      `config, configOnly, factoryCreated, factoryProperties, id, scClassName`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `HiddenPalette()`
    `HiddenPalette(com.google.gwt.core.client.JavaScriptObject jsObj)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `com.google.gwt.core.client.JavaScriptObject` | `create()`
    `PaletteNode[]` | `getData()` A list of `PaletteNodes` for component creation.
    `EditContext` | `getDefaultEditContext()` Default EditContext that this palette should use.
    `EditPane` | `getDefaultEditContextAsEditPane()` Default EditContext that this palette should use.
    `EditTree` | `getDefaultEditContextAsEditTree()` Default EditContext that this palette should use.
    `boolean` | `getGenerateNames()` Whether created components should have their "ID" or "name" property automatically set to a unique value based on the component's type, eg, "ListGrid0".
    `com.google.gwt.core.client.JavaScriptObject` | `getJsObj()`
    `com.google.gwt.core.client.JavaScriptObject` | `getOrCreateJsObj()`
    `static HiddenPalette` | `getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj)`
    `boolean` | `isCreated()`
    `EditNode` | `makeEditNode(PaletteNode paletteNode)` Given a `PaletteNode`, make an `EditNode` from it by creating a `liveObject` from the `PaletteNode.defaults` and copying presentation properties (eg `title` to the editNode.
    `EditNode` | `makeEditNode(PaletteNode paletteNode, EditContext editContext)` Given a `PaletteNode`, make an `EditNode` from it by creating a `liveObject` from the `PaletteNode.defaults` and copying presentation properties (eg `title` to the editNode.
    `HiddenPalette` | `setData(PaletteNode... data)` A list of `PaletteNodes` for component creation.
    `HiddenPalette` | `setDefaultEditContext(EditContext defaultEditContext)` Default EditContext that this palette should use.
    `HiddenPalette` | `setDefaultEditContext(EditPane defaultEditContext)` Default EditContext that this palette should use.
    `HiddenPalette` | `setDefaultEditContext(EditTree defaultEditContext)` Default EditContext that this palette should use.
    `HiddenPalette` | `setGenerateNames(boolean generateNames)` Whether created components should have their "ID" or "name" property automatically set to a unique value based on the component's type, eg, "ListGrid0".
    `void` | `setJavaScriptObject(com.google.gwt.core.client.JavaScriptObject jsObj)`

    - ### Methods inherited from class com.smartgwt.client.core.BaseClass

      `addDynamicProperty, addDynamicProperty, addDynamicProperty, addDynamicProperty, applyFactoryProperties, asSGWTComponent, clearDynamicProperty, createJsObj, destroy, doAddHandler, doInit, error, error, errorIfNotCreated, fireEvent, getAttribute, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDouble, getAttributeAsElement, getAttributeAsFloat, getAttributeAsInt, getAttributeAsJavaScriptObject, getAttributeAsMap, getAttributeAsString, getAttributeAsStringArray, getClassName, getConfig, getHandlerCount, getID, getRef, getRuleScope, getScClassName, getTestInstance, hasAutoAssignedID, hasDynamicProperty, internalSetID, internalSetID, isConfigOnly, isFactoryCreated, onBind, onInit, registerID, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAutoID, setConfig, setConfigOnly, setFactoryCreated, setID, setProperty, setProperty, setProperty, setProperty, setRuleScope, setScClassName`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### HiddenPalette

          public HiddenPalette()

    - #### HiddenPalette

          public HiddenPalette(com.google.gwt.core.client.JavaScriptObject jsObj)

  - ### Method Detail

    - #### getOrCreateRef

          public static HiddenPalette getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj)

    - #### setJavaScriptObject

          public void setJavaScriptObject(com.google.gwt.core.client.JavaScriptObject jsObj)

      Overrides:
        `setJavaScriptObject` in class `BaseClass`

    - #### create

          public com.google.gwt.core.client.JavaScriptObject create()

      Specified by:
        `create` in class `BaseClass`

    - #### isCreated

          public boolean isCreated()

      Overrides:
        `isCreated` in class `BaseClass`

    - #### getJsObj

          public com.google.gwt.core.client.JavaScriptObject getJsObj()

      Overrides:
        `getJsObj` in class `BaseClass`

    - #### getOrCreateJsObj

          public com.google.gwt.core.client.JavaScriptObject getOrCreateJsObj()

      Overrides:
        `getOrCreateJsObj` in class `BaseClass`

    - #### setData

          public HiddenPalette setData(PaletteNode... data)
                                throws java.lang.IllegalStateException

      A list of `PaletteNodes` for component creation.
      Parameters:
        `data` - New data value. Default value is null
      Returns:
        `HiddenPalette` instance, for chaining setter calls
      Throws:
        `java.lang.IllegalStateException` - this property cannot be changed after the underlying component has been created

    - #### getData

          public PaletteNode[] getData()

      A list of `PaletteNodes` for component creation.
      Returns:
        Current data value. Default value is null

    - #### setDefaultEditContext

          public HiddenPalette setDefaultEditContext(EditContext defaultEditContext)

      Default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      If this method is called after the component has been drawn/initialized: Sets the default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      Specified by:
        `setDefaultEditContext` in interface `Palette`
      Parameters:
        `defaultEditContext` - the default EditContext used by this Palette. Default value is null
      Returns:
        `HiddenPalette` instance, for chaining setter calls

    - #### getDefaultEditContext

          public EditContext getDefaultEditContext()

      Default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      Specified by:
        `getDefaultEditContext` in interface `Palette`
      Returns:
        Current defaultEditContext value. Default value is null

    - #### setDefaultEditContext

          public HiddenPalette setDefaultEditContext(EditTree defaultEditContext)

      Default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      If this method is called after the component has been drawn/initialized: Sets the default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      Specified by:
        `setDefaultEditContext` in interface `Palette`
      Parameters:
        `defaultEditContext` - the default EditContext used by this Palette. Default value is null
      Returns:
        `HiddenPalette` instance, for chaining setter calls

    - #### getDefaultEditContextAsEditTree

          public EditTree getDefaultEditContextAsEditTree()

      Default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      Specified by:
        `getDefaultEditContextAsEditTree` in interface `Palette`
      Returns:
        Current defaultEditContext value. Default value is null

    - #### setDefaultEditContext

          public HiddenPalette setDefaultEditContext(EditPane defaultEditContext)

      Default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      If this method is called after the component has been drawn/initialized: Sets the default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      Specified by:
        `setDefaultEditContext` in interface `Palette`
      Parameters:
        `defaultEditContext` - the default EditContext used by this Palette. Default value is null
      Returns:
        `HiddenPalette` instance, for chaining setter calls

    - #### getDefaultEditContextAsEditPane

          public EditPane getDefaultEditContextAsEditPane()

      Default EditContext that this palette should use. Palettes generally create components via drag and drop, but may also support creation via double-click or other UI idioms when a defaultEditContext is set.
      Specified by:
        `getDefaultEditContextAsEditPane` in interface `Palette`
      Returns:
        Current defaultEditContext value. Default value is null

    - #### setGenerateNames

          public HiddenPalette setGenerateNames(boolean generateNames)
                                         throws java.lang.IllegalStateException

      Whether created components should have their "ID" or "name" property automatically set to a unique value based on the component's type, eg, "ListGrid0".
      Specified by:
        `setGenerateNames` in interface `Palette`
      Parameters:
        `generateNames` - New generateNames value. Default value is true
      Returns:
        `HiddenPalette` instance, for chaining setter calls
      Throws:
        `java.lang.IllegalStateException` - this property cannot be changed after the underlying component has been created
      See Also:
        `Dashboards & Tools Framework Overview`

    - #### getGenerateNames

          public boolean getGenerateNames()

      Whether created components should have their "ID" or "name" property automatically set to a unique value based on the component's type, eg, "ListGrid0".
      Specified by:
        `getGenerateNames` in interface `Palette`
      Returns:
        Current generateNames value. Default value is true
      See Also:
        `Dashboards & Tools Framework Overview`

    - #### makeEditNode

          public EditNode makeEditNode(PaletteNode paletteNode)

      Given a `PaletteNode`, make an `EditNode` from it by creating a `liveObject` from the `PaletteNode.defaults` and copying presentation properties (eg `title` to the editNode.

      If `editNodeProperties` is specified as an object on on the paletteNode, each property in this object will also be copied across to the editNode.

      Specified by:
        `makeEditNode` in interface `Palette`
      Parameters:
        `paletteNode` - paletteNode to create from
      Returns:
        created EditNode

    - #### makeEditNode

          public EditNode makeEditNode(PaletteNode paletteNode,
                                       EditContext editContext)

      Given a `PaletteNode`, make an `EditNode` from it by creating a `liveObject` from the `PaletteNode.defaults` and copying presentation properties (eg `title` to the editNode.

      If `editNodeProperties` is specified as an object on on the paletteNode, each property in this object will also be copied across to the editNode.

      Specified by:
        `makeEditNode` in interface `Palette`
      Parameters:
        `paletteNode` - paletteNode to create from
        `editContext` - the `EditContext` where the node will be added. Only required in +{EditContext.screenMode,screenMode}.
      Returns:
        created EditNode