Package org.apache.tomcat.dbcp.dbcp2

## Interface ConnectionFactory

All Known Subinterfaces:
  `XAConnectionFactory`

All Known Implementing Classes:
  `DataSourceConnectionFactory`, `DataSourceXAConnectionFactory`, `DriverConnectionFactory`, `DriverManagerConnectionFactory`, `LocalXAConnectionFactory`

    public interface ConnectionFactory

Abstract factory interface for creating `Connection`s.

Since:
  2.0

### Method Summary

All Methods Instance Methods Abstract Methods
`java.sql.Connection` `createConnection()` Create a new `Connection` in an implementation specific fashion.

### Method Detail

#### createConnection

    java.sql.Connection createConnection()
                                  throws java.sql.SQLException

Create a new `Connection` in an implementation specific fashion.

Returns:
  a new `Connection`
Throws:
  `java.sql.SQLException` - if a database error occurs creating the connection