|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.jpattern.orm.query.sql.PlainSqlFindQuery
public class PlainSqlFindQuery
| Constructor Summary | |
|---|---|
PlainSqlFindQuery(SessionSqlPerformer session,
String sql,
Object[] args)
|
|
| Method Summary | ||
|---|---|---|
void |
appendValues(List<Object> values)
Append to the list all the values of the expression's elements |
|
|
find(ResultSetReader<T> rse)
Execute the query reading the ResultSet with a ResultSetReader. |
|
|
find(ResultSetRowReader<T> rsrr)
Execute the query reading the ResultSet with a ResultSetRowReader. |
|
BigDecimal |
findBigDecimal()
Execute the query and read the result as a BigDecimal value |
|
boolean |
findBoolean()
Execute the query and read the result as a boolean value |
|
double |
findDouble()
Execute the query and read the result as a double value |
|
float |
findFloat()
Execute the query and read the result as a float value |
|
int |
findInt()
Execute the query and read the result as an int value |
|
List<Object[]> |
findList()
Execute the query and read the result creating a List of all the ordered arrays with the extracted column values for every row. |
|
long |
findLong()
Execute the query and read the result as an long value |
|
String |
findString()
Execute the query and read the result as a String value |
|
Object[] |
findUnique()
Execute the query and read the result creating an ordered array with the extracted column values or null (if no matching bean is found). |
|
|
findUnique(ResultSetRowReader<T> rsrr)
Execute the query reading the ResultSet with a ResultSetRowReader. |
|
int |
getMaxRows()
Return the max rows for this query. |
|
int |
getQueryTimeout()
Return the query timeout for the query. |
|
String |
renderSql()
Return the sql query generated by this IQuery Object |
|
void |
renderSql(StringBuilder stringBuilder)
Append to the string buffer the sql query generated by this IQuery Object |
|
SqlFindQuery |
setMaxRows(int maxRows)
Set the maximum number of rows to return in the query. |
|
SqlFindQuery |
setQueryTimeout(int queryTimeout)
Set the query timeout for the query. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PlainSqlFindQuery(SessionSqlPerformer session,
String sql,
Object[] args)
| Method Detail |
|---|
public final int getMaxRows()
throws OrmException
SqlFindQuery
getMaxRows in interface SqlFindQueryOrmExceptionpublic final SqlFindQuery setQueryTimeout(int queryTimeout)
SqlFindQuery
setQueryTimeout in interface SqlFindQuerypublic final int getQueryTimeout()
SqlFindQuery
getQueryTimeout in interface SqlFindQuery
public final SqlFindQuery setMaxRows(int maxRows)
throws OrmException
SqlFindQuery
setMaxRows in interface SqlFindQueryOrmException
public <T> T find(ResultSetReader<T> rse)
throws OrmException
CustomQueryResultSetReader.
find in interface CustomQueryResultSetReader
OrmException
public <T> List<T> find(ResultSetRowReader<T> rsrr)
throws OrmException
CustomQueryResultSetRowReader.
find in interface CustomQueryrsrr - object that will extract all rows of results
ResultSetRowReader
OrmException
public <T> T findUnique(ResultSetRowReader<T> rsrr)
throws OrmException
CustomQueryResultSetRowReader.
findUnique in interface CustomQueryrsrr - object that will extract the row of result
OrmException
OrmNotUniqueResultException - if the results of the query executions are not exactly 1
public List<Object[]> findList()
throws OrmException
CustomQuery
findList in interface CustomQueryOrmException
public Object[] findUnique()
throws OrmNotUniqueResultException
CustomQuery
findUnique in interface CustomQueryOrmNotUniqueResultException - if not exactly one row is returned from the query
public int findInt()
throws OrmException
CustomQuery
findInt in interface CustomQueryOrmException
public long findLong()
throws OrmException
CustomQuery
findLong in interface CustomQueryOrmException
public double findDouble()
throws OrmException
CustomQuery
findDouble in interface CustomQueryOrmException
public float findFloat()
throws OrmException
CustomQuery
findFloat in interface CustomQueryOrmException
public String findString()
throws OrmException
CustomQuery
findString in interface CustomQueryOrmException
public boolean findBoolean()
throws OrmException
CustomQuery
findBoolean in interface CustomQueryOrmException
public BigDecimal findBigDecimal()
throws OrmException
CustomQuery
findBigDecimal in interface CustomQueryOrmExceptionpublic String renderSql()
RenderableSqlQuery
renderSql in interface RenderableSqlQuerypublic void renderSql(StringBuilder stringBuilder)
RenderableSqlQuery
renderSql in interface RenderableSqlQuerypublic void appendValues(List<Object> values)
RenderableSqlQuery
appendValues in interface RenderableSqlQuery
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||