io.milvus.param.collection

## Class AlterCollectionParam.Builder

- java.lang.Object
- - io.milvus.param.collection.AlterCollectionParam.Builder

Enclosing class:
  AlterCollectionParam

    public static final class AlterCollectionParam.Builder
    extends java.lang.Object

Builder for `AlterCollectionParam` class.

### Method Summary

All Methods Instance Methods Concrete Methods
`AlterCollectionParam` `build()` Verifies parameters and creates a new `AlterCollectionParam` instance.
`AlterCollectionParam.Builder` `withCollectionName(@NonNull java.lang.String collectionName)` Set the collection name.
`AlterCollectionParam.Builder` `withDatabaseName(java.lang.String databaseName)` Sets the database name.
`AlterCollectionParam.Builder` `withMMapEnabled(boolean enabledMMap)` Enable MMap or not for index data files.
`AlterCollectionParam.Builder` `withProperty(@NonNull java.lang.String key, @NonNull java.lang.String value)` Basic method to set a key-value property.
`AlterCollectionParam.Builder` `withTTL(@NonNull java.lang.Integer ttlSeconds)` Collection time to live (TTL) is the expiration time of data in a collection.

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Method Detail

#### withCollectionName

    public AlterCollectionParam.Builder withCollectionName(@NonNull
                                                           @NonNull java.lang.String collectionName)

Set the collection name. Collection name cannot be empty or null.

Parameters:
  `collectionName` - collection name
Returns:
  `Builder`

#### withDatabaseName

    public AlterCollectionParam.Builder withDatabaseName(java.lang.String databaseName)

Sets the database name. database name can be nil.

Parameters:
  `databaseName` - database name
Returns:
  `Builder`

#### withTTL

    public AlterCollectionParam.Builder withTTL(@NonNull
                                                @NonNull java.lang.Integer ttlSeconds)

Collection time to live (TTL) is the expiration time of data in a collection. Expired data in the collection will be cleaned up and will not be involved in searches or queries. In server side, the default value is 0, which means TTL is disabled. Specify TTL in the unit of seconds.

Parameters:
  `ttlSeconds` - TTL seconds, value should be 0 or greater
Returns:
  `Builder`

#### withMMapEnabled

    public AlterCollectionParam.Builder withMMapEnabled(boolean enabledMMap)

Enable MMap or not for index data files.

Parameters:
  `enabledMMap` - enabled or not
Returns:
  `Builder`

#### withProperty

    public AlterCollectionParam.Builder withProperty(@NonNull
                                                     @NonNull java.lang.String key,
                                                     @NonNull
                                                     @NonNull java.lang.String value)

Basic method to set a key-value property.

Parameters:
  `key` - the key
  `value` - the value
Returns:
  `Builder`

#### build

    public AlterCollectionParam build()
                               throws ParamException

Verifies parameters and creates a new `AlterCollectionParam` instance.

Returns:
  `AlterCollectionParam`
Throws:
  `ParamException`