Class JdbcStatementCacheSizeEvent
java.lang.Object
io.hypersistence.optimizer.core.event.AbstractEvent
io.hypersistence.optimizer.jdbc.event.JdbcDriverEvent
io.hypersistence.optimizer.jdbc.event.caching.JdbcStatementCacheSizeEvent
- All Implemented Interfaces:
Event,Serializable
The
JdbcStatementCacheSizeEvent indicates that the current application
is not using JDBC statement caching.- Since:
- 2.4.0
- Author:
- Vlad Mihalcea
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.hypersistence.optimizer.core.event.Event
Event.Priority -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionJdbcStatementCacheSizeEvent(DatabaseInfo databaseInfo, boolean statementCacheEnabled, int statementCacheSize) Instantiate aJdbcStatementCacheSizeEventusing the provided JDBC Statement cache settings. -
Method Summary
Modifier and TypeMethodDescriptionGet theEvent.Priorityof thisEventintGet the current JDBC statement cache size.booleanCheck if JDBC statement caching is enabled.Methods inherited from class io.hypersistence.optimizer.jdbc.event.JdbcDriverEvent
getDatabaseInfoMethods inherited from class io.hypersistence.optimizer.core.event.AbstractEvent
getInfoUrl
-
Field Details
-
DEFAULT_STATEMENT_CACHE_SIZE
public static final int DEFAULT_STATEMENT_CACHE_SIZE- See Also:
-
-
Constructor Details
-
JdbcStatementCacheSizeEvent
public JdbcStatementCacheSizeEvent(DatabaseInfo databaseInfo, boolean statementCacheEnabled, int statementCacheSize) Instantiate aJdbcStatementCacheSizeEventusing the provided JDBC Statement cache settings.- Parameters:
databaseInfo- the underlying database infostatementCacheEnabled- if JDBC statement caching is enabledstatementCacheSize- the current JDBC statement cache size
-
-
Method Details
-
isStatementCacheEnabled
public boolean isStatementCacheEnabled()Check if JDBC statement caching is enabled.- Returns:
- if JDBC statement caching is enabled
-
getStatementCacheSize
public int getStatementCacheSize()Get the current JDBC statement cache size.- Returns:
- the current JDBC statement cache size
-
getPriority
Get theEvent.Priorityof thisEvent- Returns:
- the
Event.Priorityof thisEvent
-
getDescription
-