|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.basex.server.Query
org.basex.server.ClientQuery
public class ClientQuery
This class defines all methods for iteratively evaluating queries with the
client/server architecture. All sent data is received by the
ClientListener
and interpreted by the QueryListener
.
Field Summary | |
---|---|
protected ClientSession |
cs
Client session. |
protected java.lang.String |
id
Query id. |
Fields inherited from class org.basex.server.Query |
---|
cache, out |
Constructor Summary | |
---|---|
ClientQuery(java.lang.String query,
ClientSession session,
java.io.OutputStream os)
Standard constructor. |
Method Summary | |
---|---|
void |
bind(java.lang.String n,
java.lang.Object v,
java.lang.String t)
Binds a value with an optional type to an external variable. |
protected void |
cache()
Caches the query result. |
void |
close()
Closes the query. |
void |
context(java.lang.Object v,
java.lang.String t)
Binds a value with an optional type to an external variable. |
java.lang.String |
execute()
Returns the complete result of the query. |
java.lang.String |
info()
Returns query info. |
java.lang.String |
options()
Returns the serialization options. |
boolean |
updating()
Returns true if the query may perform updates. |
Methods inherited from class org.basex.server.Query |
---|
bind, cache, context, more, next, type |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final ClientSession cs
protected final java.lang.String id
Constructor Detail |
---|
public ClientQuery(java.lang.String query, ClientSession session, java.io.OutputStream os) throws java.io.IOException
query
- query to be runsession
- client sessionos
- output stream
java.io.IOException
- I/O exceptionMethod Detail |
---|
public java.lang.String info() throws java.io.IOException
Query
info
in class Query
java.io.IOException
- I/O exceptionpublic java.lang.String options() throws java.io.IOException
Query
options
in class Query
java.io.IOException
- I/O exceptionpublic boolean updating() throws java.io.IOException
Query
true
if the query may perform updates.
updating
in class Query
java.io.IOException
- I/O exceptionpublic void bind(java.lang.String n, java.lang.Object v, java.lang.String t) throws java.io.IOException
Query
bind
in class Query
n
- name of variablev
- value to be boundt
- data type (may be null
)
java.io.IOException
- I/O exceptionpublic void context(java.lang.Object v, java.lang.String t) throws java.io.IOException
Query
context
in class Query
v
- value to be boundt
- data type (may be null
)
java.io.IOException
- I/O exceptionpublic java.lang.String execute() throws java.io.IOException
Query
execute
in class Query
null
.
java.io.IOException
- I/O exceptionpublic void close() throws java.io.IOException
Query
close
in class Query
java.io.IOException
- I/O exceptionprotected void cache() throws java.io.IOException
Query
cache
in class Query
java.io.IOException
- I/O exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |