java.lang.Objectorg.objectweb.telosys.common.TelosysObject
org.objectweb.telosys.dal.dao.DummyDatabaseSession
Constructor Summary | |
DummyDatabaseSession()
Constructor for a "dummy database session" (without a real database connection) |
Method Summary | |
void |
close()
Close the session connection |
void |
commit()
Do a commit on the session connection |
java.sql.Connection |
getConnection()
Returns the database connection of the session A dummy session returns null |
int |
getDatabaseId()
Returns the database id of the session 0 to N for a real session -1 for a dummy session |
static DummyDatabaseSession |
getInstance()
|
boolean |
isDummy()
Returns true if the session is a "dummy session" (without real connection) |
void |
rollback()
Do a rollback on the session connection |
Methods inherited from class org.objectweb.telosys.common.TelosysObject |
error, error, error, getFlagTrace, info, setFlagTrace, trace, warn |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DummyDatabaseSession()
Method Detail |
public static final DummyDatabaseSession getInstance()
public boolean isDummy()
DatabaseSession
isDummy
in interface DatabaseSession
public int getDatabaseId()
DatabaseSession
getDatabaseId
in interface DatabaseSession
public java.sql.Connection getConnection()
DatabaseSession
getConnection
in interface DatabaseSession
public void commit() throws TelosysException
DatabaseSession
commit
in interface DatabaseSession
TelosysException
public void rollback() throws TelosysException
DatabaseSession
rollback
in interface DatabaseSession
TelosysException
public void close() throws TelosysException
DatabaseSession
close
in interface DatabaseSession
TelosysException