|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.carrotsearch.junitbenchmarks.AutocloseConsumer
com.carrotsearch.junitbenchmarks.db.DbConsumer
com.carrotsearch.junitbenchmarks.h2.H2Consumer
public class H2Consumer
DbConsumer implementation for H2.
| Field Summary | |
|---|---|
protected File |
dbFileName
The database file name. |
| Fields inherited from class com.carrotsearch.junitbenchmarks.db.DbConsumer |
|---|
BENCHMARK_ROUNDS, CLASSNAME, GC_AVG, GC_INVOCATIONS, GC_STDDEV, GC_TIME, NAME, ROUND_AVG, ROUND_STDDEV, RUN_ID, TIME_BENCHMARK, TIME_WARMUP, WARMUP_ROUNDS |
| Constructor Summary | |
|---|---|
H2Consumer()
Creates a consumer with the default file name. |
|
H2Consumer(File dbFileName)
Creates a consumer with the default charts and custom key dirs. |
|
H2Consumer(File dbFileName,
File chartsDir,
String customKeyValue)
Creates a consumer with the specified database file, charts directory, and custom key value. |
|
| Method Summary | |
|---|---|
protected Connection |
createConnection()
Instantiates the database connection. |
protected String |
getAddCustomKeySql()
Gets the SQL for adding a custom key. |
protected String |
getCreateDbVersionSql()
Gets the SQL for creating the DB Version table. |
protected String |
getCreateRunsSql()
Gets the SQL for creating the runs table. |
protected String |
getCreateTestsSql()
Gets the SQL for creating the tests table. |
protected static File |
getDefaultDbName()
Return the global default DB name. |
String |
getMethodChartPropertiesQuery()
Gets the SQL for obtaining method chart properties. |
String |
getMethodChartResultsQuery()
Gets the SQL for obtaining method chart results. |
protected String |
getNewRunSql()
Gets the SQL for inserting into the runs table. |
protected String |
getTestInsertSql()
Gets the SQL for inserting into the test table. |
| Methods inherited from class com.carrotsearch.junitbenchmarks.db.DbConsumer |
|---|
accept, checkSchema, close, getChartsDir, getConnection, getCustomKeyValue, getDbVersion, getDefaultChartsDir, getDefaultCustomKey, getHistoryHtmlTemplate, getMethodHtmlTemplate, getResource, getRunId, getTestInsertStatement, rollback |
| Methods inherited from class com.carrotsearch.junitbenchmarks.AutocloseConsumer |
|---|
addAutoclose, removeAutoclose |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected File dbFileName
| Constructor Detail |
|---|
public H2Consumer()
public H2Consumer(File dbFileName)
dbFileName - the database file name
public H2Consumer(File dbFileName,
File chartsDir,
String customKeyValue)
dbFileName - the database filechartsDir - the charts directorycustomKeyValue - the custom key value| Method Detail |
|---|
protected static File getDefaultDbName()
protected Connection createConnection()
throws SQLException
DbConsumer
createConnection in class DbConsumerSQLException - if the database connection cannot be createdpublic String getMethodChartResultsQuery()
DbConsumer
getMethodChartResultsQuery in class DbConsumerpublic String getMethodChartPropertiesQuery()
DbConsumer
getMethodChartPropertiesQuery in class DbConsumerprotected String getCreateRunsSql()
DbConsumer
getCreateRunsSql in class DbConsumerprotected String getCreateTestsSql()
DbConsumer
getCreateTestsSql in class DbConsumerprotected String getNewRunSql()
DbConsumer
getNewRunSql in class DbConsumerprotected String getTestInsertSql()
DbConsumer
getTestInsertSql in class DbConsumerprotected String getCreateDbVersionSql()
DbConsumer
getCreateDbVersionSql in class DbConsumerprotected String getAddCustomKeySql()
DbConsumer
getAddCustomKeySql in class DbConsumer
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||