Package io.milvus.param.collection
Class CollectionSchemaParam.Builder
- java.lang.Object
-
- io.milvus.param.collection.CollectionSchemaParam.Builder
-
- Enclosing class:
- CollectionSchemaParam
public static final class CollectionSchemaParam.Builder extends java.lang.Object
Builder forCollectionSchemaParam
class.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CollectionSchemaParam.Builder
addFieldType(@NonNull FieldType fieldType)
Adds a field.CollectionSchemaParam
build()
Verifies parameters and creates a newCollectionSchemaParam
instance.CollectionSchemaParam.Builder
withEnableDynamicField(boolean enableDynamicField)
Sets the collection if enableDynamicField.CollectionSchemaParam.Builder
withFieldTypes(@NonNull java.util.List<FieldType> fieldTypes)
Sets the fieldTypes of the schema.
-
-
-
Method Detail
-
withEnableDynamicField
public CollectionSchemaParam.Builder withEnableDynamicField(boolean enableDynamicField)
Sets the collection if enableDynamicField.- Parameters:
enableDynamicField
- enableDynamicField of the collection- Returns:
Builder
-
withFieldTypes
public CollectionSchemaParam.Builder withFieldTypes(@NonNull @NonNull java.util.List<FieldType> fieldTypes)
Sets the fieldTypes of the schema. The fieldTypes cannot be empty or null.
-
addFieldType
public CollectionSchemaParam.Builder addFieldType(@NonNull @NonNull FieldType fieldType)
Adds a field.
-
build
public CollectionSchemaParam build() throws ParamException
Verifies parameters and creates a newCollectionSchemaParam
instance.- Returns:
CollectionSchemaParam
- Throws:
ParamException
-
-