de.esprit.netsuite.server.db

## Class ServerDatabaseConfig

- java.lang.Object
- - de.esprit.common.util.DumpableObject
  - - de.esprit.common.util.TransferableObject
    - - de.esprit.netsuite.server.config.AbstractServerConfig
      - - de.esprit.netsuite.server.db.ServerDatabaseConfig

- All Implemented Interfaces:
    Clearable, DeepCloneable, Dumpable, java.io.Serializable, java.lang.Cloneable

      public class ServerDatabaseConfig
      extends AbstractServerConfig
      implements Clearable

  This class encapsulates the database connections defined for the esprit server
  Author:
    Rainer Buesch
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ServerDatabaseConfig()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addDataSourceDefinition(boolean isEnabled, java.lang.String dbName, java.lang.String credential, java.lang.String comment)`
    `void` | `clear()` Clears the content
    `DataSourceEntry` | `findByName(java.lang.String dsName)`
    `java.util.List<DataSourceEntry>` | `getDataSourceDefinitions()` Returns all enabled database connections
    `boolean` | `isEmpty()`
    `void` | `read(ApplicationContext ctx, java.io.File inputFile)`
    `DumpString` | `toDumpString(DumpString s)` This method allows subclasses to add values to the existing DumpString of the superclass.
    `ToString` | `toString(ToString s)` This method allows subclasses to add values to the existing ToString of the superclass.
    `void` | `write(ApplicationContext ctx, java.io.File outputFile)`

    - ### Methods inherited from class de.esprit.netsuite.server.config.AbstractServerConfig

      `equals, getConfigFileIn, getConfigFileName, hashCode, read, write`

    - ### Methods inherited from class de.esprit.common.util.TransferableObject

      `clone, deepClone`

    - ### Methods inherited from class de.esprit.common.util.DumpableObject

      `configureDumpHeadlineLength, configureDumpMaxElementsPrinted, copyDumpStringValues, copyToStringValues, createDumpHeader, toDumpString, toString`

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

      `finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### ServerDatabaseConfig

          public ServerDatabaseConfig()

  - ### Method Detail

    - #### getDataSourceDefinitions

          public java.util.List<DataSourceEntry> getDataSourceDefinitions()

      Returns all enabled database connections

    - #### clear

          public void clear()

      Description copied from interface: `Clearable`
      Clears the content
      Specified by:
        `clear` in interface `Clearable`

    - #### addDataSourceDefinition

          public void addDataSourceDefinition(boolean isEnabled,
                                     java.lang.String dbName,
                                     java.lang.String credential,
                                     java.lang.String comment)

    - #### isEmpty

          public boolean isEmpty()

    - #### findByName

          public DataSourceEntry findByName(java.lang.String dsName)

    - #### read

          public void read(ApplicationContext ctx,
                  java.io.File inputFile)
                    throws java.lang.Exception

      Specified by:
        `read` in class `AbstractServerConfig`
      Throws:
        `java.lang.Exception`

    - #### write

          public void write(ApplicationContext ctx,
                   java.io.File outputFile)
                     throws java.lang.Exception

      Specified by:
        `write` in class `AbstractServerConfig`
      Throws:
        `java.lang.Exception`

    - #### toString

          public ToString toString(ToString s)

      Description copied from interface: `Dumpable`
      This method allows subclasses to add values to the existing ToString of the superclass. Usually subclasses only need to override this method.
      Specified by:
        `toString` in interface `Dumpable`
      Overrides:
        `toString` in class `AbstractServerConfig`

    - #### toDumpString

          public DumpString toDumpString(DumpString s)

      Description copied from interface: `Dumpable`
      This method allows subclasses to add values to the existing DumpString of the superclass. Usually subclasses only need to override this method.
      Specified by:
        `toDumpString` in interface `Dumpable`
      Overrides:
        `toDumpString` in class `DumpableObject`

Copyright © 2014 EsprIT-Systems. All Rights Reserved.