org.firebirdsql.ds

## Class FBConnectionPoolDataSource

- java.lang.Object
- - org.firebirdsql.ds.RootCommonDataSource
  - - org.firebirdsql.ds.AbstractConnectionPropertiesDataSource
    - - org.firebirdsql.ds.FBAbstractCommonDataSource
      - - org.firebirdsql.ds.FBConnectionPoolDataSource

All Implemented Interfaces:
  javax.naming.Referenceable, javax.sql.CommonDataSource, javax.sql.ConnectionPoolDataSource, AttachmentProperties, BaseProperties, DatabaseConnectionProperties, FirebirdConnectionProperties

    public class FBConnectionPoolDataSource
    extends FBAbstractCommonDataSource
    implements javax.sql.ConnectionPoolDataSource, javax.naming.Referenceable

Bare-bones implementation of `ConnectionPoolDataSource`.

Please be aware that this is not a connectionpool. This class provides PooledConnection objects for connection pool implementations (eg as provided by a JEE application server). If you need a standalone connectionpool, consider using a connectionpool implementation like HikariCP, c3p0 or DBCP.

Since:
  2.2
Author:
  Mark Rotteveel

### Field Summary

### Fields inherited from class org.firebirdsql.ds.FBAbstractCommonDataSource

`REF_DESCRIPTION, REF_PROPERTIES`

### Constructor Summary

Constructors
Constructor and Description
`FBConnectionPoolDataSource()`

### Method Summary

All Methods Instance Methods Concrete Methods
`protected void` `checkNotStarted()` Method to check if this DataSource has not yet started.
`javax.sql.PooledConnection` `getPooledConnection()`
`javax.sql.PooledConnection` `getPooledConnection(java.lang.String user, java.lang.String password)`
`javax.naming.Reference` `getReference()`

### Methods inherited from class org.firebirdsql.ds.FBAbstractCommonDataSource

`connectionPropertyValues, getBooleanProperty, getConnectionProperties, getDescription, getIntProperty, getProperty, getTransactionParameters, setBooleanProperty, setConnectionProperties, setDescription, setIntProperty, setNonStandardProperty, setProperty, setTransactionParameters, updateReference, withLock`

### Methods inherited from class org.firebirdsql.ds.AbstractConnectionPropertiesDataSource

`getAuthPlugins, getBlobBufferSize, getBuffersNumber, getCharSet, getConnectTimeout, getDatabase, getDatabaseName, getDataTypeBind, getDbCryptConfig, getDecfloatRound, getDecfloatTraps, getDefaultIsolation, getDefaultTransactionIsolation, getEncoding, getGeneratedKeysEnabled, getLoginTimeout, getPageCacheSize, getParallelWorkers, getPassword, getPortNumber, getProcessId, getProcessName, getRoleName, getScrollableCursor, getServerBatchBufferSize, getServerName, getSessionTimeZone, getSocketBufferSize, getSoTimeout, getSqlDialect, getTpbMapping, getType, getUser, getUserName, getWireCrypt, isColumnLabelForName, isDefaultResultSetHoldable, isIgnoreProcedureType, isTimestampUsesLocalTimezone, isUseFirebirdAutocommit, isUseServerBatch, isUseStreamBlobs, isWireCompression, setAuthPlugins, setBlobBufferSize, setBuffersNumber, setCharSet, setColumnLabelForName, setConnectTimeout, setDatabase, setDatabaseName, setDataTypeBind, setDbCryptConfig, setDecfloatRound, setDecfloatTraps, setDefaultIsolation, setDefaultResultSetHoldable, setDefaultTransactionIsolation, setEncoding, setGeneratedKeysEnabled, setIgnoreProcedureType, setLoginTimeout, setPageCacheSize, setParallelWorkers, setPassword, setPortNumber, setProcessId, setProcessName, setRoleName, setScrollableCursor, setServerBatchBufferSize, setServerName, setSessionTimeZone, setSocketBufferSize, setSoTimeout, setSqlDialect, setTimestampUsesLocalTimezone, setTpbMapping, setType, setUseFirebirdAutocommit, setUser, setUserName, setUseServerBatch, setUseStreamBlobs, setWireCompression, setWireCrypt`

### Methods inherited from class org.firebirdsql.ds.RootCommonDataSource

`getLogWriter, getParentLogger, setLogWriter`

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

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

### Methods inherited from interface javax.sql.CommonDataSource

`getLoginTimeout, getLogWriter, getParentLogger, setLoginTimeout, setLogWriter`

### Methods inherited from interface org.firebirdsql.jdbc.FirebirdConnectionProperties

`getNonStandardProperty, setNonStandardProperty`

### Methods inherited from interface org.firebirdsql.jaybird.props.BaseProperties

`getBooleanProperty, getIntProperty, getProperty`

### Constructor Detail

#### FBConnectionPoolDataSource

    public FBConnectionPoolDataSource()

### Method Detail

#### getPooledConnection

    public javax.sql.PooledConnection getPooledConnection()
                                                   throws java.sql.SQLException

Specified by:
  `getPooledConnection` in interface `javax.sql.ConnectionPoolDataSource`
Throws:
  `java.sql.SQLException`

#### getPooledConnection

    public javax.sql.PooledConnection getPooledConnection(java.lang.String user,
                                                          java.lang.String password)
                                                   throws java.sql.SQLException

Specified by:
  `getPooledConnection` in interface `javax.sql.ConnectionPoolDataSource`
Throws:
  `java.sql.SQLException`

#### checkNotStarted

    protected void checkNotStarted()

Description copied from class: `FBAbstractCommonDataSource`
Method to check if this DataSource has not yet started.

Implementations should throw IllegalStateException when the DataSource is already in use and modifying properties is not allowed.

Specified by:
  `checkNotStarted` in class `FBAbstractCommonDataSource`

#### getReference

    public javax.naming.Reference getReference()
                                        throws javax.naming.NamingException

Specified by:
  `getReference` in interface `javax.naming.Referenceable`
Throws:
  `javax.naming.NamingException`