public static class JsonIndex.Builder extends com.cloudant.client.internal.query.Builder<JsonIndex,com.cloudant.client.api.query.JsonIndex.Definition,JsonIndex.Builder,JsonIndex.Field>
Modifier and Type | Method and Description |
---|---|
JsonIndex.Builder |
asc(java.lang.String... fieldNames)
Add one or more fields to the JsonIndex configuration in ascending order.
|
JsonIndex.Builder |
desc(java.lang.String... fieldNames)
Add one or more fields to the JsonIndex configuration in descending order.
|
JsonIndex.Builder |
designDocument(java.lang.String designDocumentId)
Configure the design document name, if not set a new design document will be created with
a generated name.
|
JsonIndex.Builder |
name(java.lang.String indexName)
Configure the name of the index, if not set a name will be generated.
|
protected JsonIndex |
newInstance() |
JsonIndex.Builder |
partialFilterSelector(Selector selector)
Configure a selector to choose documents that should be added to the index.
|
protected JsonIndex.Builder |
returnThis() |
protected JsonIndex newInstance()
newInstance
in class com.cloudant.client.internal.query.Builder<JsonIndex,com.cloudant.client.api.query.JsonIndex.Definition,JsonIndex.Builder,JsonIndex.Field>
protected JsonIndex.Builder returnThis()
returnThis
in class com.cloudant.client.internal.query.Builder<JsonIndex,com.cloudant.client.api.query.JsonIndex.Definition,JsonIndex.Builder,JsonIndex.Field>
public JsonIndex.Builder name(java.lang.String indexName)
name
in class com.cloudant.client.internal.query.Builder<JsonIndex,com.cloudant.client.api.query.JsonIndex.Definition,JsonIndex.Builder,JsonIndex.Field>
indexName
- name of the indexpublic JsonIndex.Builder designDocument(java.lang.String designDocumentId)
designDocument
in class com.cloudant.client.internal.query.Builder<JsonIndex,com.cloudant.client.api.query.JsonIndex.Definition,JsonIndex.Builder,JsonIndex.Field>
designDocumentId
- design document ID (the _design prefix is added if not supplied)public JsonIndex.Builder partialFilterSelector(Selector selector)
Configure a selector to choose documents that should be added to the index.
Obtain a selector from an Operation
or Expression
.
partialFilterSelector
in class com.cloudant.client.internal.query.Builder<JsonIndex,com.cloudant.client.api.query.JsonIndex.Definition,JsonIndex.Builder,JsonIndex.Field>
selector
- Selector
object describing criteria used to add
documents to indexSelector
,
selector syntaxpublic JsonIndex.Builder asc(java.lang.String... fieldNames)
fieldNames
- names of the fields to indexpublic JsonIndex.Builder desc(java.lang.String... fieldNames)
fieldNames
- names of the fields to index