public class Query extends SqlUpdate
java.sql.Statement from the ResourceManager
and executes the SQL query.| Constructor and Description |
|---|
Query(java.lang.String sql)
Construct a Query object
|
Query(java.lang.String sql,
java.lang.Object[] par)
Construct a Query object with bind parameters
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the query and result-set objects
|
void |
executeQuery(java.lang.Object[] par)
Execute the Query with new bind parameters.
|
void |
executeQuery(java.lang.String sql)
Execute a SQL query.
|
int |
executeUpdate(java.lang.String sql)
Execute a non-query SQL statement
|
Address |
getAddress(Device dev)
Create a
oracle.lite.resource.Address object from
the query result. |
Application |
getApplication()
Create a
oracle.lite.resource.Application object from
the query result. |
java.sql.Blob |
getBlob(int idx)
Retrieve the blob value from the query result.
|
Device |
getDevice(User usr)
Create a
oracle.lite.resource.Device object from
the query result. |
DeviceCommand |
getDeviceCommand(Device dev)
Create a
oracle.lite.resource.dm.DeviceCommand object from
the query result. |
Group |
getGroup()
Create a
oracle.lite.resource.Group object from
the query result. |
java.io.InputStream |
getInputStream(int idx)
Retrieve the
java.io.InputStream value from the query result. |
int |
getInt(int idx)
Retrieve the 'int' value from the query result.
|
Language |
getLanguage()
Create a
oracle.lite.resource.Language object from
the query result. |
Log |
getLog()
Create a
oracle.lite.resource.Log object from
the query result. |
long |
getLong(int idx)
Retrieve the 'long' value from the query result.
|
Platform |
getPlatform()
Create a
oracle.lite.resource.Platform object from
the query result. |
Provider |
getProvider()
Create a
oracle.lite.resource.Provider object from
the query result. |
QueueData |
getQueueData(Device dev)
Create a
oracle.lite.resource.dm.QueueData object from
the query result. |
Role |
getRole()
Create a
oracle.lite.resource.Role object from
the query result. |
java.lang.String |
getString(int idx)
Retrieve the string value from the query result.
|
java.sql.Timestamp |
getTimestamp(int idx)
Retrieve the
java.sql.Timestamp value from the query result. |
User |
getUser()
Create a
oracle.lite.resource.User object from
the query result. |
boolean |
next()
Move to the next cursor
|
bind, close, executeUpdate, executeUpdate, executeUpdatepublic Query(java.lang.String sql)
throws java.sql.SQLException
sql - SQL statement to be executed (optional)lava.sql.SQLExceptionjava.sql.SQLExceptionpublic Query(java.lang.String sql,
java.lang.Object[] par)
throws java.sql.SQLException
sql - SQL statement to be executedpar - SQL statement bind parameterslava.sql.SQLExceptionjava.sql.SQLExceptionpublic void close()
public void executeQuery(java.lang.Object[] par)
throws java.sql.SQLException
par - Bind parameterslava.sql.SQLExceptionjava.sql.SQLExceptionpublic void executeQuery(java.lang.String sql)
throws java.sql.SQLException
sql - SQL statement to be executedlava.sql.SQLExceptionjava.sql.SQLExceptionpublic int executeUpdate(java.lang.String sql)
throws java.sql.SQLException
sql - SQL statement to be executedlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Address getAddress(Device dev) throws java.sql.SQLException
oracle.lite.resource.Address object from
the query result.oracle.lite.resource.Address objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Application getApplication() throws java.sql.SQLException
oracle.lite.resource.Application object from
the query result.oracle.lite.resource.Application objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic java.sql.Blob getBlob(int idx)
throws java.sql.SQLException
idx - Column indexjava.sql.SQLExceptionpublic Device getDevice(User usr) throws java.sql.SQLException
oracle.lite.resource.Device object from
the query result.usr - Owner of the deviceoracle.lite.resource.Device objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic DeviceCommand getDeviceCommand(Device dev) throws java.sql.SQLException
oracle.lite.resource.dm.DeviceCommand object from
the query result.oracle.lite.resource.dm.DeviceCommand objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Group getGroup() throws java.sql.SQLException
oracle.lite.resource.Group object from
the query result.oracle.lite.resource.Group objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic java.io.InputStream getInputStream(int idx)
throws java.sql.SQLException
java.io.InputStream value from the query result.idx - Column indexlava.sql.SQLExceptionjava.sql.SQLExceptionpublic int getInt(int idx)
throws java.sql.SQLException
idx - Column indexlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Language getLanguage() throws java.sql.SQLException
oracle.lite.resource.Language object from
the query result.oracle.lite.resource.Language objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Log getLog() throws java.sql.SQLException
oracle.lite.resource.Log object from
the query result.oracle.lite.resource.QueueData objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic long getLong(int idx)
throws java.sql.SQLException
idx - Column indexlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Platform getPlatform() throws java.sql.SQLException
oracle.lite.resource.Platform object from
the query result.oracle.lite.resource.Platform objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Provider getProvider() throws java.sql.SQLException
oracle.lite.resource.Provider object from
the query result.oracle.lite.resource.Provider objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic QueueData getQueueData(Device dev) throws java.sql.SQLException
oracle.lite.resource.dm.QueueData object from
the query result.oracle.lite.resource.dm.QueueData objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic Role getRole() throws java.sql.SQLException
oracle.lite.resource.Role object from
the query result.oracle.lite.resource.Role objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic java.lang.String getString(int idx)
throws java.sql.SQLException
idx - Column indexlava.sql.SQLExceptionjava.sql.SQLExceptionpublic java.sql.Timestamp getTimestamp(int idx)
throws java.sql.SQLException
java.sql.Timestamp value from the query result.idx - Column indexlava.sql.SQLExceptionjava.sql.SQLExceptionpublic User getUser() throws java.sql.SQLException
oracle.lite.resource.User object from
the query result.oracle.lite.resource.User objectlava.sql.SQLExceptionjava.sql.SQLExceptionpublic boolean next()
throws java.sql.SQLException
lava.sql.SQLExceptionjava.sql.SQLException