|
Oracle Application Server TopLink API Reference 10g Release 2 (10.1.2) B15903-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.toplink.publicinterface.Session
oracle.toplink.publicinterface.DatabaseSession
oracle.toplink.sessionbroker.SessionBroker
Purpose: Provide a single view to a TopLink session that transparently accesses multple databases.
Responsibilities:
Field Summary |
Fields inherited from interface oracle.toplink.remotecommand.CommandProcessor |
LOG_DEBUG, LOG_ERROR, LOG_INFO, LOG_WARNING |
Constructor Summary | |
SessionBroker() PUBLIC: Create and return a session broker. |
Method Summary | |
SessionBroker |
acquireClientSessionBroker() PUBLIC: Return a session broker that behaves as a client session broker. |
oracle.toplink.publicinterface.UnitOfWork |
acquireUnitOfWork() PUBLIC: Return a unit of work for this session broker. |
void |
addDescriptor(Descriptor descriptor) PUBLIC: You cannot add a descriptor to a session broker, you must add it to its session. |
void |
addDescriptors(Project project) PUBLIC: You cannot add a project to a session broker, you must add it to its session. |
void |
addDescriptors(java.util.Vector descriptors) PUBLIC: You cannot add descriptors to a session broker, you must add them to its session. |
boolean |
containsQuery(java.lang.String queryName) PUBLIC: Return true if the pre-defined query is defined on the session. |
DatabaseQuery |
getQuery(java.lang.String name) PUBLIC: Return the query from the session pre-defined queries with the given name. |
DatabaseQuery |
getQuery(java.lang.String name, java.util.Vector arguments) PUBLIC: Return the query from the session pre-defined queries with the given name and argument types. |
oracle.toplink.internal.sequencing.Sequencing |
getSequencing() PUBLIC: Return the Sequencing object used by the session. |
java.util.Vector |
getSessionNames() Return the list of sessions associated with this SessionBroker |
void |
initializeAllIdentityMaps() PUBLIC:: Reset the entire object cache. |
void |
initializeIdentityMaps() PUBLIC:: Reset the entire local object caches. |
void |
initializeSequencing() ADVANCED: Creates sequencing object for the session broker. |
boolean |
isClientSessionBroker() PUBLIC: Return if this session is a client session broker. |
boolean |
isConnected() PUBLIC: Return if all sessions are still connected to the database. |
boolean |
isServerSessionBroker() PUBLIC: Return if this session is a server session broker. |
void |
login() PUBLIC: Connect to the database using the predefined login. |
void |
login(java.lang.String userName, java.lang.String password) PUBLIC: Connect to the database using the predefined login. |
void |
logout() PUBLIC: Disconnect from all databases. |
void |
registerSession(java.lang.String name, oracle.toplink.publicinterface.Session session) PUBLIC: Register the session under its name. |
void |
registerSession(java.lang.String name, Session session) PUBLIC: Register the session under its name. |
void |
releaseClientSessionBroker() PUBLIC: Called on a client Session Broker. |
void |
setIntegrityChecker(IntegrityChecker integrityChecker) PUBLIC: set the integrityChecker. |
void |
setLog(java.io.Writer log) PUBLIC: Set the writer to which an accessor writes logged messages. |
void |
setProfiler(SessionProfiler profiler) PUBLIC: Set the profiler for the session. |
void |
setSessionNames(java.util.Vector sessionNames) Set the list of session names associated with this SessionBroker |
void |
setShouldLogMessages(boolean shouldLog) PUBLIC: Log all messages including executed SQL commands to the default output. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface oracle.toplink.sessions.DatabaseSession |
beginTransaction, commitTransaction, deleteAllObjects, deleteAllObjects, deleteObject, insertObject, isInTransaction, refreshAndLockObject, refreshAndLockObject, rollbackTransaction, setExternalTransactionController, setLogin, updateObject, writeObject |
Constructor Detail |
public SessionBroker()
Method Detail |
public SessionBroker acquireClientSessionBroker()
public java.util.Vector getSessionNames()
public void setSessionNames(java.util.Vector sessionNames)
public oracle.toplink.publicinterface.UnitOfWork acquireUnitOfWork()
acquireUnitOfWork
in interface Session
acquireUnitOfWork
in class oracle.toplink.publicinterface.Session
UnitOfWork
public void addDescriptor(Descriptor descriptor)
addDescriptor
in interface DatabaseSession
addDescriptor
in class oracle.toplink.publicinterface.DatabaseSession
DatabaseSession.addDescriptors(Vector)
, DatabaseSession.addDescriptors(Project)
public void addDescriptors(java.util.Vector descriptors) throws ValidationException
addDescriptors
in interface DatabaseSession
addDescriptors
in class oracle.toplink.publicinterface.DatabaseSession
ValidationException
public void addDescriptors(Project project) throws ValidationException
addDescriptors
in interface DatabaseSession
addDescriptors
in class oracle.toplink.publicinterface.DatabaseSession
ValidationException
public boolean containsQuery(java.lang.String queryName)
containsQuery
in interface Session
containsQuery
in class oracle.toplink.publicinterface.Session
public DatabaseQuery getQuery(java.lang.String name)
getQuery
in interface Session
getQuery
in class oracle.toplink.publicinterface.Session
public DatabaseQuery getQuery(java.lang.String name, java.util.Vector arguments)
getQuery
in class oracle.toplink.publicinterface.Session
Session.getQuery(String)
public void initializeAllIdentityMaps()
initializeAllIdentityMaps
in interface Session
initializeAllIdentityMaps
in class oracle.toplink.publicinterface.Session
public void initializeIdentityMaps()
initializeIdentityMaps
in interface Session
initializeIdentityMaps
in class oracle.toplink.publicinterface.Session
public boolean isClientSessionBroker()
public boolean isConnected()
isConnected
in interface Session
isConnected
in class oracle.toplink.publicinterface.Session
public boolean isServerSessionBroker()
public void login() throws DatabaseException
login
in interface DatabaseSession
login
in class oracle.toplink.publicinterface.DatabaseSession
DatabaseException
DatabaseSession.login(Login)
public void login(java.lang.String userName, java.lang.String password) throws DatabaseException
login
in interface DatabaseSession
login
in class oracle.toplink.publicinterface.DatabaseSession
DatabaseException
public void logout() throws DatabaseException
logout
in interface DatabaseSession
logout
in class oracle.toplink.publicinterface.DatabaseSession
TopLinkException
- if a transaction is active, you must rollback any active transaction before logout.DatabaseException
- the database will also raise an error if their is an active transaction, or a general error occurs.public void registerSession(java.lang.String name, oracle.toplink.publicinterface.Session session)
public void registerSession(java.lang.String name, Session session)
public void releaseClientSessionBroker()
public void setIntegrityChecker(IntegrityChecker integrityChecker)
setIntegrityChecker
in interface Session
setIntegrityChecker
in class oracle.toplink.publicinterface.Session
public void setLog(java.io.Writer log)
setLog
in interface Session
setLog
in class oracle.toplink.publicinterface.Session
Session.logMessages()
public void setProfiler(SessionProfiler profiler)
setProfiler
in interface Session
setProfiler
in class oracle.toplink.publicinterface.Session
public void setShouldLogMessages(boolean shouldLog)
setShouldLogMessages
in interface Session
setShouldLogMessages
in class oracle.toplink.publicinterface.Session
Session.setLog(Writer)
public void initializeSequencing()
initializeSequencing
in class oracle.toplink.publicinterface.DatabaseSession
public oracle.toplink.internal.sequencing.Sequencing getSequencing()
getSequencing
in class oracle.toplink.publicinterface.DatabaseSession
|
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |