|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.h2.test.unit.TestExit.MyDatabaseEventListener
public static final class TestExit.MyDatabaseEventListener
A database event listener used in this test.
Field Summary |
---|
Fields inherited from interface org.h2.api.DatabaseEventListener |
---|
STATE_BACKUP_FILE, STATE_CREATE_INDEX, STATE_RECONNECTED, STATE_RECOVER, STATE_SCAN_FILE, STATE_STATEMENT_END, STATE_STATEMENT_PROGRESS, STATE_STATEMENT_START |
Constructor Summary | |
---|---|
TestExit.MyDatabaseEventListener()
|
Method Summary | |
---|---|
void |
closingDatabase()
This method is called before the database is closed normally. |
void |
exceptionThrown(java.sql.SQLException e,
java.lang.String sql)
This method is called if an exception occurred. |
void |
init(java.lang.String url)
This method is called just after creating the object. |
void |
opened()
This method is called after the database has been opened. |
void |
setProgress(int state,
java.lang.String name,
int x,
int max)
This method is called for long running events, such as recovering, scanning a file or building an index. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TestExit.MyDatabaseEventListener()
Method Detail |
---|
public void exceptionThrown(java.sql.SQLException e, java.lang.String sql)
DatabaseEventListener
exceptionThrown
in interface DatabaseEventListener
e
- the exceptionsql
- the SQL statementpublic void closingDatabase()
DatabaseEventListener
closingDatabase
in interface DatabaseEventListener
public void setProgress(int state, java.lang.String name, int x, int max)
DatabaseEventListener
More states might be added in future versions, therefore implementations should silently ignore states that they don't understand.
setProgress
in interface DatabaseEventListener
state
- the statename
- the object namex
- the current positionmax
- the highest possible value (might be 0)public void init(java.lang.String url)
DatabaseEventListener
init
in interface DatabaseEventListener
url
- - the database URLpublic void opened()
DatabaseEventListener
opened
in interface DatabaseEventListener
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |