### YamlMime:JavaType uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery" name: "CosmosQuery" nameWithType: "CosmosQuery" summary: "Class for cosmos query" inheritances: - "" inheritedClassMethods: - classRef: "java.lang.Object" methodsRef: - "clone" - "equals" - "finalize" - "getClass" - "hashCode" - "notify" - "notifyAll" - "toString" - "wait" - "wait" - "wait" syntax: "public class **CosmosQuery**" constructors: - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.CosmosQuery(com.azure.spring.data.cosmos.core.query.Criteria)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.CosmosQuery(Criteria criteria)" name: "CosmosQuery(Criteria criteria)" nameWithType: "CosmosQuery.CosmosQuery(Criteria criteria)" summary: "Initialization" parameters: - description: "object" name: "criteria" type: "" syntax: "public CosmosQuery(Criteria criteria)" desc: "Initialization" methods: - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getPartitionKeyValue(java.lang.Class)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getPartitionKeyValue(Class domainType)" name: "getPartitionKeyValue(Class domainType)" nameWithType: "CosmosQuery.getPartitionKeyValue(Class domainType)" summary: "Returns partition key value based on the criteria." parameters: - description: "domain type" name: "domainType" type: "Class<>" syntax: "public Optional getPartitionKeyValue(Class domainType)" desc: "Returns partition key value based on the criteria." returns: description: "Optional of partition key value" type: "Optional<Object>" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getCriteria()" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getCriteria()" name: "getCriteria()" nameWithType: "CosmosQuery.getCriteria()" summary: "To get Criteria object" syntax: "public Criteria getCriteria()" desc: "To get Criteria object" returns: description: "Criteria" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getCriteriaByType(com.azure.spring.data.cosmos.core.query.CriteriaType)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getCriteriaByType(CriteriaType criteriaType)" name: "getCriteriaByType(CriteriaType criteriaType)" nameWithType: "CosmosQuery.getCriteriaByType(CriteriaType criteriaType)" summary: "To get criteria by type" parameters: - description: "the criteria type" name: "criteriaType" type: "" syntax: "public Optional getCriteriaByType(CriteriaType criteriaType)" desc: "To get criteria by type" returns: description: "Optional" type: "Optional<>" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getLimit()" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getLimit()" name: "getLimit()" nameWithType: "CosmosQuery.getLimit()" summary: "To get limit number" syntax: "public int getLimit()" desc: "To get limit number" returns: description: "int limit" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getOffset()" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getOffset()" name: "getOffset()" nameWithType: "CosmosQuery.getOffset()" summary: "To get offset number" syntax: "public long getOffset()" desc: "To get offset number" returns: description: "long offset" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getPageable()" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getPageable()" name: "getPageable()" nameWithType: "CosmosQuery.getPageable()" summary: "To get Pageable object" syntax: "public Pageable getPageable()" desc: "To get Pageable object" returns: description: "Pageable" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getSort()" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.getSort()" name: "getSort()" nameWithType: "CosmosQuery.getSort()" summary: "To get Sort object" syntax: "public Sort getSort()" desc: "To get Sort object" returns: description: "Sort" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.hasPartitionKeyCriteria(java.lang.String)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.hasPartitionKeyCriteria(String partitionKeyFieldName)" name: "hasPartitionKeyCriteria(String partitionKeyFieldName)" nameWithType: "CosmosQuery.hasPartitionKeyCriteria(String partitionKeyFieldName)" summary: "Returns true if this criteria or sub-criteria has partition key field present as one of the subjects." parameters: - description: "partition key field name" name: "partitionKeyFieldName" type: "String" syntax: "public boolean hasPartitionKeyCriteria(String partitionKeyFieldName)" desc: "Returns true if this criteria or sub-criteria has partition key field present as one of the subjects." returns: description: "returns true if this criteria or sub criteria has partition key field present as one of the subjects." type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.isCrossPartitionQuery(java.util.List)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.isCrossPartitionQuery(List partitionKeys)" name: "isCrossPartitionQuery(List partitionKeys)" nameWithType: "CosmosQuery.isCrossPartitionQuery(List partitionKeys)" summary: "Indicate if DocumentQuery should enable cross partition query." parameters: - description: "The list of partitionKey names." name: "partitionKeys" type: "List<String>" syntax: "public boolean isCrossPartitionQuery(List partitionKeys)" desc: "Indicate if DocumentQuery should enable cross partition query." returns: description: "If DocumentQuery should enable cross partition query" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.setLimit(int)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.setLimit(int limit)" name: "setLimit(int limit)" nameWithType: "CosmosQuery.setLimit(int limit)" summary: "To set limit number" deprecatedTag: "use withLimit instead" parameters: - description: "int" name: "limit" type: "" syntax: "@Deprecated
public void setLimit(int limit)" desc: "To set limit number" hasDeprecatedTag: true - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.with(org.springframework.data.domain.Pageable)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.with(Pageable pageable)" name: "with(Pageable pageable)" nameWithType: "CosmosQuery.with(Pageable pageable)" summary: "With Sort" parameters: - description: "Sort" name: "pageable" type: "" syntax: "public CosmosQuery with(Pageable pageable)" desc: "With Sort" returns: description: "CosmosQuery object" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.with(org.springframework.data.domain.Sort)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.with(Sort sort)" name: "with(Sort sort)" nameWithType: "CosmosQuery.with(Sort sort)" summary: "With Sort" parameters: - description: "Sort" name: "sort" type: "" syntax: "public CosmosQuery with(Sort sort)" desc: "With Sort" returns: description: "CosmosQuery object" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.withLimit(int)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.withLimit(int limit)" name: "withLimit(int limit)" nameWithType: "CosmosQuery.withLimit(int limit)" summary: "To set limit number" parameters: - description: "int" name: "limit" type: "" syntax: "public CosmosQuery withLimit(int limit)" desc: "To set limit number" returns: description: "CosmosQuery object" type: "" - uid: "com.azure.spring.data.cosmos.core.query.CosmosQuery.withOffsetAndLimit(long,int)" fullName: "com.azure.spring.data.cosmos.core.query.CosmosQuery.withOffsetAndLimit(long offset, int limit)" name: "withOffsetAndLimit(long offset, int limit)" nameWithType: "CosmosQuery.withOffsetAndLimit(long offset, int limit)" summary: "To set limit number and offset number" parameters: - description: "long" name: "offset" type: "" - description: "int" name: "limit" type: "" syntax: "public CosmosQuery withOffsetAndLimit(long offset, int limit)" desc: "To set limit number and offset number" returns: description: "CosmosQuery object" type: "" type: "class" desc: "Class for cosmos query" metadata: {} package: "com.azure.spring.data.cosmos.core.query" artifact: com.azure:azure-spring-data-cosmos:5.18.0