## org.eclipse.datatools.sqltools.sqlbuilder.input
Class SQLBuilderInputFactory

    java.lang.Object
      org.eclipse.datatools.sqltools.sqlbuilder.input.SQLBuilderInputFactory

All Implemented Interfaces:
  org.eclipse.ui.IElementFactory

    public class SQLBuilderInputFactory

extends java.lang.Object
implements org.eclipse.ui.IElementFactory

The class implements a factory which is capable of saving and recreating SQLBuilderStorageEditorInputs stored in a memento.

Author:
  Jeremy Lindop

Field Summary
`static java.lang.String` `ID_SQL_BUILDER_STORAGE_EDITOR_INPUT_FACTORY` The Factory ID.
`static java.lang.String` `ID_SQL_BUILDER_STORAGE_EDITOR_INPUT_TYPE` The InputType
`static java.lang.String` `ID_XML_MEMENTO_ROOT_ELEMENT` The root element name used in `XMLMemento` objects representing `SQLBuilderStorageEditorInput` objects.
`static java.lang.String` `KEY_CONN_INFO_CODE` Key used for ConnectionInfo element.
`static java.lang.String` `KEY_EDITOR_INPUT_OPTIONS_CODE` Key used for EditorUsageInputUsageOptions element.
`static java.lang.String` `KEY_EDITOR_INPUT_TYPE` Key used for EditorInputType property.
`static java.lang.String` `KEY_OMIT_SCHEMA_INFO_CODE` Key used for OmitSchemaInfo element.
`static java.lang.String` `KEY_STORAGE_NAME` Key used for StorageName property.
`static java.lang.String` `KEY_STORAGE_SQLCONTENT` Key used for SQLStatement element.
`static java.lang.String` `KEY_STORAGE_VERSION` Key used for Version property.

Constructor Summary
`SQLBuilderInputFactory()`

Method Summary
`org.eclipse.core.runtime.IAdaptable` `createElement(org.eclipse.ui.IMemento memento)` Re-creates and returns an object from the state captured within the given memento.
`static void` `saveState(org.eclipse.ui.IMemento memento, SQLBuilderStorageEditorInput input)` Saves the state of the given storage editor input object in the given memento.

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### ID_SQL_BUILDER_STORAGE_EDITOR_INPUT_FACTORY

    public static final java.lang.String ID_SQL_BUILDER_STORAGE_EDITOR_INPUT_FACTORY

  The Factory ID.

  See Also:
    Constant Field Values

### ID_SQL_BUILDER_STORAGE_EDITOR_INPUT_TYPE

    public static final java.lang.String ID_SQL_BUILDER_STORAGE_EDITOR_INPUT_TYPE

  The InputType

  See Also:
    Constant Field Values

### ID_XML_MEMENTO_ROOT_ELEMENT

    public static final java.lang.String ID_XML_MEMENTO_ROOT_ELEMENT

  The root element name used in `XMLMemento` objects representing `SQLBuilderStorageEditorInput` objects.

  See Also:
    Constant Field Values

### KEY_EDITOR_INPUT_TYPE

    public static final java.lang.String KEY_EDITOR_INPUT_TYPE

  Key used for EditorInputType property.

  See Also:
    Constant Field Values

### KEY_STORAGE_NAME

    public static final java.lang.String KEY_STORAGE_NAME

  Key used for StorageName property.

  See Also:
    Constant Field Values

### KEY_STORAGE_VERSION

    public static final java.lang.String KEY_STORAGE_VERSION

  Key used for Version property.

  See Also:
    Constant Field Values

### KEY_STORAGE_SQLCONTENT

    public static final java.lang.String KEY_STORAGE_SQLCONTENT

  Key used for SQLStatement element.

  See Also:
    Constant Field Values

### KEY_CONN_INFO_CODE

    public static final java.lang.String KEY_CONN_INFO_CODE

  Key used for ConnectionInfo element.

  See Also:
    Constant Field Values

### KEY_OMIT_SCHEMA_INFO_CODE

    public static final java.lang.String KEY_OMIT_SCHEMA_INFO_CODE

  Key used for OmitSchemaInfo element.

  See Also:
    Constant Field Values

### KEY_EDITOR_INPUT_OPTIONS_CODE

    public static final java.lang.String KEY_EDITOR_INPUT_OPTIONS_CODE

  Key used for EditorUsageInputUsageOptions element.

  See Also:
    Constant Field Values

Constructor Detail

### SQLBuilderInputFactory

    public SQLBuilderInputFactory()

Method Detail

### createElement

    public org.eclipse.core.runtime.IAdaptable createElement(org.eclipse.ui.IMemento memento)

  Re-creates and returns an object from the state captured within the given memento. Returns a SQLBuilderStorageEditorInput.

  Specified by:
    `createElement` in interface `org.eclipse.ui.IElementFactory`
  See Also:
    `IElementFactory.createElement(org.eclipse.ui.IMemento)`

### saveState

    public static void saveState(org.eclipse.ui.IMemento memento,
                                 SQLBuilderStorageEditorInput input)

  Saves the state of the given storage editor input object in the given memento.

  Parameters:
    `memento` - the storage area for object's state
    `input` - the storage editor input object that needs to be saved