IndexingPolicy Class

Definition

Represents the indexing policy configuration for a collection in the Azure Cosmos DB service.

public sealed class IndexingPolicy : Microsoft.Azure.Documents.JsonSerializable, ICloneable
type IndexingPolicy = class
    inherit JsonSerializable
    interface ICloneable
Public NotInheritable Class IndexingPolicy
Inherits JsonSerializable
Implements ICloneable
Inheritance
IndexingPolicy
Implements

Remarks

Indexing policies can used to configure which properties (JSON paths) are included/excluded, whether the index is updated consistently or offline (lazy), automatic vs. opt-in per-document, as well as the precision and type of index per path.

Refer to http://azure.microsoft.com/documentation/articles/documentdb-indexing-policies/ for additional information on how to specify indexing policies.

Constructors

IndexingPolicy()

Initializes a new instance of the IndexingPolicy class for the Azure Cosmos DB service.

IndexingPolicy(Index[])

Initializes a new instance of the IndexingPolicy class with the specified set of indexes as default index specifications for the root path for the Azure Cosmos DB service.

Properties

Automatic

Gets or sets a value that indicates whether automatic indexing is enabled for a collection in the Azure Cosmos DB service.

ExcludedPaths

Gets or sets the collection containing ExcludedPath objects in the Azure Cosmos DB service.

IncludedPaths

Gets or sets the collection containing IncludedPath objects in the Azure Cosmos DB service.

IndexingMode

Gets or sets the indexing mode (consistent or lazy) in the Azure Cosmos DB service.

Methods

Clone()

Performs a deep copy of the indexing policy for the Azure Cosmos DB service.

LoadFrom(JsonReader)

Loads the object from the specified JSON reader in the Azure Cosmos DB service.

(Inherited from JsonSerializable)
LoadFrom(JsonReader, JsonSerializerSettings)

Loads the object from the specified JSON reader in the Azure Cosmos DB service.

(Inherited from JsonSerializable)
SaveTo(Stream, SerializationFormattingPolicy)

Saves the object to the specified stream in the Azure Cosmos DB service.

(Inherited from JsonSerializable)
SaveTo(Stream, SerializationFormattingPolicy, JsonSerializerSettings)

Saves the object to the specified stream in the Azure Cosmos DB service.

(Inherited from JsonSerializable)
ToString()

Returns the string representation of the object in the Azure Cosmos DB service.

(Inherited from JsonSerializable)

Applies to

See also