Package org.apache.cayenne.map
Class SelectQueryDescriptor
java.lang.Object
org.apache.cayenne.map.QueryDescriptor
org.apache.cayenne.map.SelectQueryDescriptor
- All Implemented Interfaces:
- Serializable,- ConfigurationNode,- XMLSerializable
public class SelectQueryDescriptor extends QueryDescriptor
- Since:
- 4.0
- See Also:
- Serialized Form
- 
Field SummaryFields Modifier and Type Field Description protected List<Ordering>orderingsprotected Map<String,Integer>prefetchesMapprotected ExpressionqualifierFields inherited from class org.apache.cayenne.map.QueryDescriptorDATA_MAP_ROOT, dataMap, DB_ENTITY_ROOT, EJBQL_QUERY, JAVA_CLASS_ROOT, name, OBJ_ENTITY_ROOT, PROCEDURE_QUERY, PROCEDURE_ROOT, properties, root, SELECT_QUERY, SQL_TEMPLATE, type
- 
Constructor SummaryConstructors Constructor Description SelectQueryDescriptor()
- 
Method SummaryModifier and Type Method Description voidaddOrdering(Ordering ordering)Adds single ordering for this query.voidaddPrefetch(String prefetchPath)Deprecated.voidaddPrefetch(String prefetchPath, int semantics)Adds prefetch path with semantics to this query.SelectQuery<?>buildQuery()Assembles Cayenne query instance of appropriate type from this descriptor.voidencodeAsXML(XMLEncoder encoder, ConfigurationNodeVisitor delegate)Prints itself as XML to the provided XMLEncoder.List<Ordering>getOrderings()Returns list of orderings for this query.List<String>getPrefetches()Deprecated.since 4.1 usegetPrefetchesMap().Map<String,Integer>getPrefetchesMap()Returns map of prefetch paths with semantics for this query.ExpressiongetQualifier()Returns qualifier of this query.booleanisDistinct()voidremoveOrdering(Ordering ordering)Removes single ordering from this query.voidremovePrefetch(String prefetchPath)Removes single prefetch path from this query.voidsetDistinct(boolean value)voidsetOrderings(List<Ordering> orderings)Sets list of orderings for this query.voidsetPrefetches(List<String> prefetches)Deprecated.since 4.1 usesetPrefetchesMap(HashMap).voidsetPrefetchesMap(HashMap<String,Integer> prefetchesMap)Sets map of prefetch paths with semantics for this query.voidsetQualifier(Expression qualifier)Sets qualifier for this query.Methods inherited from class org.apache.cayenne.map.QueryDescriptoracceptVisitor, descriptor, ejbqlQueryDescriptor, getDataMap, getName, getProperties, getProperty, getRoot, getType, procedureQueryDescriptor, selectQueryDescriptor, setDataMap, setName, setProperties, setProperty, setRoot, setType, sqlTemplateDescriptor
- 
Field Details- 
qualifier
- 
orderings
- 
prefetchesMap
 
- 
- 
Constructor Details- 
SelectQueryDescriptorpublic SelectQueryDescriptor()
 
- 
- 
Method Details- 
setDistinctpublic void setDistinct(boolean value)
- 
isDistinctpublic boolean isDistinct()
- 
getQualifierReturns qualifier of this query.
- 
setQualifierSets qualifier for this query.
- 
getOrderingsReturns list of orderings for this query.
- 
setOrderingsSets list of orderings for this query.
- 
addOrderingAdds single ordering for this query.
- 
removeOrderingRemoves single ordering from this query.
- 
getPrefetchesMapReturns map of prefetch paths with semantics for this query.- Since:
- 4.1
 
- 
getPrefetchesDeprecated.since 4.1 usegetPrefetchesMap().Returns list of prefetch paths for this query.
- 
setPrefetchesMapSets map of prefetch paths with semantics for this query.- Since:
- 4.1
 
- 
setPrefetchesDeprecated.since 4.1 usesetPrefetchesMap(HashMap).Sets list of prefetch paths for this query.
- 
addPrefetchAdds prefetch path with semantics to this query.- Since:
- 4.1
 
- 
addPrefetchDeprecated.since 4.1 useaddPrefetch(String, int)Adds single prefetch path to this query.
- 
removePrefetchRemoves single prefetch path from this query.
- 
buildQueryDescription copied from class:QueryDescriptorAssembles Cayenne query instance of appropriate type from this descriptor.- Overrides:
- buildQueryin class- QueryDescriptor
 
- 
encodeAsXMLDescription copied from interface:XMLSerializablePrints itself as XML to the provided XMLEncoder.- Specified by:
- encodeAsXMLin interface- XMLSerializable
- Overrides:
- encodeAsXMLin class- QueryDescriptor
 
 
- 
addPrefetch(String, int)