|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.seag.qm.SqlDaemon
This object exists only once (singleton) It puts every query into a queue, and executes the query from the queue. Is the resultset of a query available, the caller is called back.
Method Summary | |
void |
addQueryEventListener(QueryEventListener listener)
Adds a QueryEventListener |
static SqlDaemon |
getInstance()
Gets a Reference to the only existing Instance |
static SqlDaemon |
getInstance(java.util.Properties dbP)
Gets a Reference to the only existing Instance |
QueryError |
getQueryError(long key)
gets (removes it from the Queue) a QueryError |
ResultTable[] |
getResultTable(long key)
gets (removes it from the Queue) a ResultTable |
FutureQueryResult |
popFutureQueryResult()
gets an instance from a Future Object |
void |
pushFutureQueryResult(FutureQueryResult fqr)
releases the instance of the Futueobject |
void |
removeQueryEventListener(QueryEventListener listener)
Removes a QueryEventListener |
FutureQueryResult |
submitQuery(SqlQuerySpec query)
Put ing a Query into the Queue, and getting a long key for the Result. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static SqlDaemon getInstance() throws QmInstantiationException
public static SqlDaemon getInstance(java.util.Properties dbP) throws QmInstantiationException
dbP
- DB Properties; has effect only the first time.QmInstantiationException
- if anything happens (DB or Properties)public FutureQueryResult submitQuery(SqlQuerySpec query)
query
- SqlQuerySpec; the Query objectpublic void addQueryEventListener(QueryEventListener listener)
listener
- QueryEventListenerpublic void removeQueryEventListener(QueryEventListener listener)
listener
- QueryEventListenerpublic ResultTable[] getResultTable(long key)
key
- Querykeypublic QueryError getQueryError(long key)
key
- Querykeypublic FutureQueryResult popFutureQueryResult()
public void pushFutureQueryResult(FutureQueryResult fqr)
fqr
- FutureQueryResult
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |