Class MongoIndex


  • public final class MongoIndex
    extends Object
    Cosmos DB MongoDB collection index key.
    • Constructor Detail

      • MongoIndex

        public MongoIndex()
    • Method Detail

      • key

        public MongoIndexKeys key()
        Get the key property: Cosmos DB MongoDB collection index keys.
        Returns:
        the key value.
      • withKey

        public MongoIndex withKey​(MongoIndexKeys key)
        Set the key property: Cosmos DB MongoDB collection index keys.
        Parameters:
        key - the key value to set.
        Returns:
        the MongoIndex object itself.
      • options

        public MongoIndexOptions options()
        Get the options property: Cosmos DB MongoDB collection index key options.
        Returns:
        the options value.
      • withOptions

        public MongoIndex withOptions​(MongoIndexOptions options)
        Set the options property: Cosmos DB MongoDB collection index key options.
        Parameters:
        options - the options value to set.
        Returns:
        the MongoIndex object itself.
      • validate

        public void validate()
        Validates the instance.
        Throws:
        IllegalArgumentException - thrown if the instance is not valid.