|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.alfresco.repo.domain.query.AbstractCannedQueryDAOImpl
org.alfresco.repo.domain.query.ibatis.CannedQueryDAOImpl
public class CannedQueryDAOImpl
DAO implementation providing canned query support.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface org.alfresco.repo.domain.query.CannedQueryDAO |
---|
CannedQueryDAO.ResultHandler |
Field Summary |
---|
Fields inherited from class org.alfresco.repo.domain.query.AbstractCannedQueryDAOImpl |
---|
controlDAO, logger |
Constructor Summary | |
---|---|
CannedQueryDAOImpl()
|
Method Summary | |
---|---|
java.lang.Long |
executeCountQuery(java.lang.String sqlNamespace,
java.lang.String queryName,
java.lang.Object parameterObj)
Execute a count(*)-style query returning a count value. |
java.util.List |
executeQuery(java.lang.String sqlNamespace,
java.lang.String queryName,
java.lang.Object parameterObj,
int offset,
int limit)
Execute a query that returns one or more results. |
void |
executeQuery(java.lang.String sqlNamespace,
java.lang.String queryName,
java.lang.Object parameterObj,
int offset,
int limit,
CannedQueryDAO.ResultHandler handler)
Execute a query that returns one or more results, processing the results using a handler. |
java.lang.Object |
executeQueryUnique(java.lang.String sqlNamespace,
java.lang.String queryName,
java.lang.Object parameterObj)
Execute a query that returns exactly one result. |
void |
init()
Checks that properties have been set |
void |
setSqlSessionTemplate(org.mybatis.spring.SqlSessionTemplate sqlSessionTemplate)
|
Methods inherited from class org.alfresco.repo.domain.query.AbstractCannedQueryDAOImpl |
---|
setControlDAO |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CannedQueryDAOImpl()
Method Detail |
---|
public final void setSqlSessionTemplate(org.mybatis.spring.SqlSessionTemplate sqlSessionTemplate)
public void init()
AbstractCannedQueryDAOImpl
init
in class AbstractCannedQueryDAOImpl
public java.lang.Long executeCountQuery(java.lang.String sqlNamespace, java.lang.String queryName, java.lang.Object parameterObj)
All exceptions can be safely caught and handled as required.
Only one return value is allowed and is checked to prevent null returns.
sqlNamespace
- the query namespace (defined by config file) e.g. alfresco.query.usagequeryName
- the name of the query e.g. select_userCountparameterObj
- the values to drive the selection (may be null if not required)
public java.lang.Object executeQueryUnique(java.lang.String sqlNamespace, java.lang.String queryName, java.lang.Object parameterObj)
CannedQueryDAO
sqlNamespace
- the query namespace (defined by config file) e.g. alfresco.query.usagequeryName
- the name of the query e.g. select_userCountparameterObj
- the values to drive the selection (may be null if not required)
public java.util.List executeQuery(java.lang.String sqlNamespace, java.lang.String queryName, java.lang.Object parameterObj, int offset, int limit)
CannedQueryDAO
sqlNamespace
- the query namespace (defined by config file) e.g. alfresco.query.usagequeryName
- the name of the query e.g. select_userCountparameterObj
- the values to drive the selection (may be null if not required)offset
- the number of results to skiplimit
- the maximum number of results to retrieve or Integer.MAX_VALUE
for no limit
public void executeQuery(java.lang.String sqlNamespace, java.lang.String queryName, java.lang.Object parameterObj, int offset, int limit, CannedQueryDAO.ResultHandler handler)
CannedQueryDAO
sqlNamespace
- the query namespace (defined by config file) e.g. alfresco.query.usagequeryName
- the name of the query e.g. select_userCountparameterObj
- the values to drive the selection (may be null if not required)offset
- the number of results to skiplimit
- the maximum number of results to retrieve or Integer.MAX_VALUE
for no limit
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |