public class SQLTemplateMetadata extends Object
CACHE_GROUPS_PROPERTY, CACHE_STRATEGY_PROPERTY, FETCH_LIMIT_DEFAULT, FETCH_LIMIT_PROPERTY, FETCH_OFFSET_DEFAULT, FETCH_OFFSET_PROPERTY, FETCHING_DATA_ROWS_DEFAULT, FETCHING_DATA_ROWS_PROPERTY, PAGE_SIZE_DEFAULT, PAGE_SIZE_PROPERTY, QUERY_TIMEOUT_DEFAULT, STATEMENT_FETCH_SIZE_DEFAULT, STATEMENT_FETCH_SIZE_PROPERTY| Constructor and Description |
|---|
SQLTemplateMetadata() |
| Modifier and Type | Method and Description |
|---|---|
String |
getCacheGroup()
Returns an optional cache "group".
|
String |
getCacheKey()
Returns a String that uniquely identifies this query for the purposes of result
caching.
|
QueryCacheStrategy |
getCacheStrategy()
Returns a caching strategy for this query.
|
ClassDescriptor |
getClassDescriptor() |
DataMap |
getDataMap()
Returns a DataMap associated with a query or null if no such DataMap exists.
|
DbEntity |
getDbEntity()
Returns a DbEntity associated with a query or null if no such entity exists.
|
int |
getFetchLimit()
Returns the limit on the maximum number of records that can be returned by this
query.
|
int |
getFetchOffset()
Specifies a start of a range when fetching a subset of records.
|
ObjEntity |
getObjEntity()
Returns an ObjEntity associated with a query or null if no such entity exists.
|
Query |
getOriginatingQuery()
Returns a query that originated this query.
|
int |
getPageSize()
Returns query page size.
|
Map<String,String> |
getPathSplitAliases()
Returns a map of aliases vs.
|
PrefetchTreeNode |
getPrefetchTree()
Returns a root node of prefetch tree used by this query, or null of no prefetches
are configured.
|
Procedure |
getProcedure()
Returns a Procedure associated with a query or null if no such procedure exists.
|
int |
getQueryTimeout() |
Function<?,?> |
getResultMapper() |
List<Object> |
getResultSetMapping()
Returns an optional list of result set mapping hints.
|
int |
getStatementFetchSize() |
boolean |
isFetchingDataRows()
Returns
true if this query should produce a list of data rows as
opposed to DataObjects, false for DataObjects. |
boolean |
isRefreshingObjects()
Returns
true if the query results should replace any currently cached
values, returns false otherwise. |
boolean |
isSingleResultSetMapping() |
boolean |
isSuppressingDistinct() |
void |
setCacheGroup(String group) |
void |
setResultSetMapping(List<Object> resultSetMapping)
used by select translator
|
public boolean isSingleResultSetMapping()
isSingleResultSetMapping in interface QueryMetadataQueryMetadata.getResultSetMapping()public Function<?,?> getResultMapper()
public String getCacheKey()
QueryMetadatagetCacheKey in interface QueryMetadatapublic DataMap getDataMap()
QueryMetadatagetDataMap in interface QueryMetadatapublic Procedure getProcedure()
QueryMetadatagetProcedure in interface QueryMetadatapublic Map<String,String> getPathSplitAliases()
QueryMetadatagetPathSplitAliases in interface QueryMetadatapublic DbEntity getDbEntity()
QueryMetadatagetDbEntity in interface QueryMetadatapublic ObjEntity getObjEntity()
QueryMetadatagetObjEntity in interface QueryMetadatapublic ClassDescriptor getClassDescriptor()
getClassDescriptor in interface QueryMetadatapublic List<Object> getResultSetMapping()
QueryMetadataEntityResultSegment or ScalarResultSegment. The returned
list can be null.getResultSetMapping in interface QueryMetadatapublic void setResultSetMapping(List<Object> resultSetMapping)
setResultSetMapping in interface QueryMetadatapublic PrefetchTreeNode getPrefetchTree()
QueryMetadatagetPrefetchTree in interface QueryMetadatapublic QueryCacheStrategy getCacheStrategy()
QueryMetadatagetCacheStrategy in interface QueryMetadatapublic String getCacheGroup()
QueryMetadatagetCacheGroup in interface QueryMetadatapublic void setCacheGroup(String group)
public boolean isFetchingDataRows()
QueryMetadatatrue if this query should produce a list of data rows as
opposed to DataObjects, false for DataObjects. This is a hint to
QueryEngine executing this query.isFetchingDataRows in interface QueryMetadatapublic int getFetchLimit()
QueryMetadatagetFetchLimit in interface QueryMetadatapublic int getPageSize()
QueryMetadatagetPageSize in interface QueryMetadatapublic Query getOriginatingQuery()
QueryMetadatagetOriginatingQuery in interface QueryMetadatapublic int getFetchOffset()
QueryMetadatagetFetchOffset in interface QueryMetadatapublic boolean isRefreshingObjects()
QueryMetadatatrue if the query results should replace any currently cached
values, returns false otherwise. If QueryMetadata.isFetchingDataRows()
returns true, this setting is not applicable and has no effect.isRefreshingObjects in interface QueryMetadatapublic int getStatementFetchSize()
getStatementFetchSize in interface QueryMetadatapublic int getQueryTimeout()
getQueryTimeout in interface QueryMetadatapublic boolean isSuppressingDistinct()
isSuppressingDistinct in interface QueryMetadataCopyright © 2001–2021 Apache Cayenne. All rights reserved.