org.appng.testsupport.persistence

## Class ConnectionInfo

- java.lang.Object
- - org.appng.testsupport.persistence.ConnectionInfo

-     public class ConnectionInfo
      extends Object

  A container for all information about a database connection like the JDBC-Url, user, password etc.
  Author:
    Matthias Müller

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ConnectionInfo(String jdbcUrl, int port, String user, String password, String driverClass, String persistenceUnit, Class<? extends org.dbunit.database.IDatabaseConnection> connection)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `executeSql(String sql)`
    `void` | `executeSqlFromResource(String resourceName)`
    `Class<? extends org.dbunit.database.IDatabaseConnection>` | `getConnection()`
    `String` | `getDriverClass()`
    `String` | `getJdbcUrl()`
    `String` | `getPassword()`
    `String` | `getPersistenceUnit()`
    `int` | `getPort()`
    `List<String>` | `getTableNames()`
    `String` | `getUser()`
    `void` | `setConnection(Class<? extends org.dbunit.database.IDatabaseConnection> connection)`
    `void` | `setDriverClass(String driverClass)`
    `void` | `setJdbcUrl(String jdbcUrl)`
    `void` | `setPassword(String password)`
    `void` | `setPersistenceUnit(String persistenceUnit)`
    `void` | `setPort(int port)`
    `void` | `setTableNames(List<String> tableNames)`
    `void` | `setUser(String user)`

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

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

- - ### Constructor Detail

    - #### ConnectionInfo

          public ConnectionInfo(String jdbcUrl,
                                int port,
                                String user,
                                String password,
                                String driverClass,
                                String persistenceUnit,
                                Class<? extends org.dbunit.database.IDatabaseConnection> connection)

  - ### Method Detail

    - #### getJdbcUrl

          public String getJdbcUrl()

      Returns:
        the jdbcUrl

    - #### setJdbcUrl

          public void setJdbcUrl(String jdbcUrl)

      Parameters:
        `jdbcUrl` - the jdbcUrl to set

    - #### getUser

          public String getUser()

      Returns:
        the user

    - #### setUser

          public void setUser(String user)

      Parameters:
        `user` - the user to set

    - #### getPassword

          public String getPassword()

      Returns:
        the password

    - #### setPassword

          public void setPassword(String password)

      Parameters:
        `password` - the password to set

    - #### getDriverClass

          public String getDriverClass()

      Returns:
        the driverClass

    - #### setDriverClass

          public void setDriverClass(String driverClass)

      Parameters:
        `driverClass` - the driverClass to set

    - #### getConnection

          public Class<? extends org.dbunit.database.IDatabaseConnection> getConnection()

      Returns:
        the connection

    - #### setConnection

          public void setConnection(Class<? extends org.dbunit.database.IDatabaseConnection> connection)

      Parameters:
        `connection` - the connection to set

    - #### getPersistenceUnit

          public String getPersistenceUnit()

      Returns:
        the persistenceUnit

    - #### setPersistenceUnit

          public void setPersistenceUnit(String persistenceUnit)

      Parameters:
        `persistenceUnit` - the persistenceUnit to set

    - #### getTableNames

          public List<String> getTableNames()

      Returns:
        the tableNames

    - #### setTableNames

          public void setTableNames(List<String> tableNames)

      Parameters:
        `tableNames` - the tableNames to set

    - #### getPort

          public int getPort()

    - #### setPort

          public void setPort(int port)

    - #### executeSqlFromResource

          public void executeSqlFromResource(String resourceName)
                                      throws IOException

      Throws:
        `IOException`

    - #### executeSql

          public void executeSql(String sql)

Copyright © 2011–2023 aiticon GmbH. All rights reserved.