MongoDBCollectionResource Class

  • java.lang.Object
    • com.azure.resourcemanager.cosmos.models.MongoDBCollectionResource

public class MongoDBCollectionResource

Cosmos DB MongoDB collection resource object.

Constructor Summary

Constructor Description
MongoDBCollectionResource()

Creates an instance of MongoDBCollectionResource class.

Method Summary

Modifier and Type Method and Description
Integer analyticalStorageTtl()

Get the analyticalStorageTtl property: Analytical TTL.

CreateMode createMode()

Get the createMode property: Enum to indicate the mode of resource creation.

String id()

Get the id property: Name of the Cosmos DB MongoDB collection.

List<MongoIndex> indexes()

Get the indexes property: List of index keys.

ResourceRestoreParameters restoreParameters()

Get the restoreParameters property: Parameters to indicate the information about the restore.

Map<String,String> shardKey()

Get the shardKey property: A key-value pair of shard keys to be applied for the request.

void validate()

Validates the instance.

MongoDBCollectionResource withAnalyticalStorageTtl(Integer analyticalStorageTtl)

Set the analyticalStorageTtl property: Analytical TTL.

MongoDBCollectionResource withCreateMode(CreateMode createMode)

Set the createMode property: Enum to indicate the mode of resource creation.

MongoDBCollectionResource withId(String id)

Set the id property: Name of the Cosmos DB MongoDB collection.

MongoDBCollectionResource withIndexes(List<MongoIndex> indexes)

Set the indexes property: List of index keys.

MongoDBCollectionResource withRestoreParameters(ResourceRestoreParameters restoreParameters)

Set the restoreParameters property: Parameters to indicate the information about the restore.

MongoDBCollectionResource withShardKey(Map<String,String> shardKey)

Set the shardKey property: A key-value pair of shard keys to be applied for the request.

Methods inherited from java.lang.Object

Constructor Details

MongoDBCollectionResource

public MongoDBCollectionResource()

Creates an instance of MongoDBCollectionResource class.

Method Details

analyticalStorageTtl

public Integer analyticalStorageTtl()

Get the analyticalStorageTtl property: Analytical TTL.

Returns:

the analyticalStorageTtl value.

createMode

public CreateMode createMode()

Get the createMode property: Enum to indicate the mode of resource creation.

Returns:

the createMode value.

id

public String id()

Get the id property: Name of the Cosmos DB MongoDB collection.

Returns:

the id value.

indexes

public List indexes()

Get the indexes property: List of index keys.

Returns:

the indexes value.

restoreParameters

public ResourceRestoreParameters restoreParameters()

Get the restoreParameters property: Parameters to indicate the information about the restore.

Returns:

the restoreParameters value.

shardKey

public Map shardKey()

Get the shardKey property: A key-value pair of shard keys to be applied for the request.

Returns:

the shardKey value.

validate

public void validate()

Validates the instance.

withAnalyticalStorageTtl

public MongoDBCollectionResource withAnalyticalStorageTtl(Integer analyticalStorageTtl)

Set the analyticalStorageTtl property: Analytical TTL.

Parameters:

analyticalStorageTtl - the analyticalStorageTtl value to set.

Returns:

the MongoDBCollectionResource object itself.

withCreateMode

public MongoDBCollectionResource withCreateMode(CreateMode createMode)

Set the createMode property: Enum to indicate the mode of resource creation.

Parameters:

createMode - the createMode value to set.

Returns:

the MongoDBCollectionResource object itself.

withId

public MongoDBCollectionResource withId(String id)

Set the id property: Name of the Cosmos DB MongoDB collection.

Parameters:

id - the id value to set.

Returns:

the MongoDBCollectionResource object itself.

withIndexes

public MongoDBCollectionResource withIndexes(List indexes)

Set the indexes property: List of index keys.

Parameters:

indexes - the indexes value to set.

Returns:

the MongoDBCollectionResource object itself.

withRestoreParameters

public MongoDBCollectionResource withRestoreParameters(ResourceRestoreParameters restoreParameters)

Set the restoreParameters property: Parameters to indicate the information about the restore.

Parameters:

restoreParameters - the restoreParameters value to set.

Returns:

the MongoDBCollectionResource object itself.

withShardKey

public MongoDBCollectionResource withShardKey(Map shardKey)

Set the shardKey property: A key-value pair of shard keys to be applied for the request.

Parameters:

shardKey - the shardKey value to set.

Returns:

the MongoDBCollectionResource object itself.

Applies to