Class CountingDataSource
- java.lang.Object
-
- com.inductiveautomation.ignition.gateway.localdb.DelegatingDataSource
-
- com.inductiveautomation.ignition.gateway.localdb.CountingDataSource
-
- All Implemented Interfaces:
java.sql.Wrapper,javax.sql.CommonDataSource,javax.sql.DataSource
public class CountingDataSource extends DelegatingDataSource
A delegating DataSource that maintains a count of all update-style queries that go through it.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classCountingDataSource.CountingConnection-
Nested classes/interfaces inherited from class com.inductiveautomation.ignition.gateway.localdb.DelegatingDataSource
DelegatingDataSource.DelegatingConnection
-
-
Field Summary
-
Fields inherited from class com.inductiveautomation.ignition.gateway.localdb.DelegatingDataSource
delegateDatasource
-
-
Constructor Summary
Constructors Constructor Description CountingDataSource(javax.sql.DataSource delegateDatasource)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.sql.DataSourcegetDelegateDatasource()Provides access to the underlying datasource for operations that shouldn't increment the countlonggetUpdateCount()protected java.sql.Connectionwrap(java.sql.Connection con)-
Methods inherited from class com.inductiveautomation.ignition.gateway.localdb.DelegatingDataSource
getConnection, getConnection, getLoginTimeout, getLogWriter, getParentLogger, isWrapperFor, setLoginTimeout, setLogWriter, unwrap
-
-
-
-
Method Detail
-
wrap
protected java.sql.Connection wrap(java.sql.Connection con)
- Overrides:
wrapin classDelegatingDataSource
-
getDelegateDatasource
public javax.sql.DataSource getDelegateDatasource()
Provides access to the underlying datasource for operations that shouldn't increment the count
-
getUpdateCount
public long getUpdateCount()
-
-