|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.caucho.amber.query.UserQuery
public class UserQuery
Represents the application's view of the query.
| Constructor Summary | |
|---|---|
UserQuery(AbstractQuery query)
|
|
| Method Summary | |
|---|---|
java.sql.ResultSet |
executeQuery()
Executes the query returning a result set. |
int |
executeUpdate()
Executes the query returning a result set. |
AmberConnection |
getConnection()
|
int |
getMaxResults()
Returns the max results. |
AbstractQuery |
getQuery()
Returns the compiled query. |
java.lang.String |
getQueryString()
Returns the query string. |
AmberConnection |
getSession()
|
java.lang.Object |
getSingleResult()
Executes the query returning the single result. |
void |
init(AmberConnection aConn)
Initialize with the connection. |
java.util.List<java.lang.Object> |
list()
Executes the query, returning a list. |
void |
list(java.util.List<java.lang.Object> list)
Executes the query, filling the list. |
void |
list(java.util.Map<java.lang.Object,java.lang.Object> map,
java.lang.reflect.Method methodGetMapKey)
Executes the query, filling the map. |
void |
setByte(int index,
byte v)
Sets the argument with a byte |
void |
setCacheMaxAge(long ms)
Sets the cache max age for the query. |
void |
setDate(int index,
java.sql.Date v)
Sets the argument with a date |
void |
setDouble(int index,
double v)
Sets the argument with a double |
void |
setFirstResult(int index)
Sets the first result. |
void |
setFloat(int index,
float v)
Sets the argument with a double |
void |
setInt(int index,
int v)
Sets the argument with an int |
void |
setLoadOnQuery(boolean loadOnQuery)
Sets true for load-on-query. |
void |
setLong(int index,
long v)
Sets the argument with a string |
void |
setMaxResults(int index)
Sets the maximum number of results. |
void |
setNull(int index,
int v)
Sets the argument with a null |
void |
setObject(int index,
java.lang.Object v)
Sets the argument with an object. |
void |
setObject(int index,
java.lang.Object v,
AmberType type)
Sets the argument with an object and its Amber type. |
void |
setSession(AmberConnection aConn)
|
void |
setShort(int index,
short v)
Sets the argument with a short |
void |
setString(int index,
java.lang.String v)
Sets the argument with a string |
void |
setTimestamp(int index,
java.sql.Timestamp v)
Sets the argument with a timestamp |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public UserQuery(AbstractQuery query)
| Method Detail |
|---|
public java.lang.String getQueryString()
getQueryString in interface AmberQuerypublic void init(AmberConnection aConn)
AmberQuery
init in interface AmberQuerypublic void setSession(AmberConnection aConn)
public AmberConnection getSession()
public AmberConnection getConnection()
public void setLoadOnQuery(boolean loadOnQuery)
setLoadOnQuery in interface AmberQuerypublic AbstractQuery getQuery()
public void setString(int index,
java.lang.String v)
setString in interface AmberQuery
public void setByte(int index,
byte v)
setByte in interface AmberQuery
public void setShort(int index,
short v)
setShort in interface AmberQuery
public void setInt(int index,
int v)
setInt in interface AmberQuery
public void setLong(int index,
long v)
setLong in interface AmberQuery
public void setDouble(int index,
double v)
setDouble in interface AmberQuery
public void setFloat(int index,
float v)
setFloat in interface AmberQuery
public void setTimestamp(int index,
java.sql.Timestamp v)
setTimestamp in interface AmberQuery
public void setDate(int index,
java.sql.Date v)
setDate in interface AmberQuery
public void setObject(int index,
java.lang.Object v)
setObject in interface AmberQuery
public void setObject(int index,
java.lang.Object v,
AmberType type)
public void setNull(int index,
int v)
setNull in interface AmberQuerypublic void setFirstResult(int index)
setFirstResult in interface AmberQuerypublic void setMaxResults(int index)
setMaxResults in interface AmberQuerypublic int getMaxResults()
public java.sql.ResultSet executeQuery()
throws java.sql.SQLException
executeQuery in interface AmberQueryjava.sql.SQLException
public int executeUpdate()
throws java.sql.SQLException
executeUpdate in interface AmberQueryjava.sql.SQLExceptionpublic void setCacheMaxAge(long ms)
setCacheMaxAge in interface AmberQuery
public java.util.List<java.lang.Object> list()
throws java.sql.SQLException
list in interface AmberQueryjava.sql.SQLException
public java.lang.Object getSingleResult()
throws java.sql.SQLException
getSingleResult in interface AmberQueryjava.sql.SQLException
public void list(java.util.List<java.lang.Object> list)
throws java.sql.SQLException
list in interface AmberQueryjava.sql.SQLException
public void list(java.util.Map<java.lang.Object,java.lang.Object> map,
java.lang.reflect.Method methodGetMapKey)
throws java.sql.SQLException,
java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException
list in interface AmberQueryjava.sql.SQLException
java.lang.IllegalAccessException
java.lang.reflect.InvocationTargetExceptionpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||