Class VectorCollectionConfig

java.lang.Object
com.hazelcast.config.vector.VectorCollectionConfig
All Implemented Interfaces:
NamedConfig, DataSerializable, IdentifiedDataSerializable

@Beta public class VectorCollectionConfig extends Object implements NamedConfig, IdentifiedDataSerializable
Configuration object for a vector collection.
Since:
5.5
  • Constructor Details

    • VectorCollectionConfig

      public VectorCollectionConfig()
      Creates a new, empty VectorCollectionConfig.
    • VectorCollectionConfig

      public VectorCollectionConfig(String name)
      Constructs a VectorCollectionConfig with the given name.
      Parameters:
      name - the name of the vector collection
    • VectorCollectionConfig

      public VectorCollectionConfig(VectorCollectionConfig config)
      Constructs a new VectorCollectionConfig instance by copying the values from the provided configuration.
      Parameters:
      config - The VectorCollectionConfig instance to copy. It serves as the source of values for the new configuration.
  • Method Details

    • setName

      public VectorCollectionConfig setName(String name)
      Sets the name of the VectorCollection.
      Specified by:
      setName in interface NamedConfig
      Parameters:
      name - the name to set for this VectorCollection.
    • getName

      public String getName()
      Returns the name of this VectorCollection
      Specified by:
      getName in interface NamedConfig
      Returns:
      the name of the VectorCollection
    • addVectorIndexConfig

      public VectorCollectionConfig addVectorIndexConfig(VectorIndexConfig vectorIndexConfig)
      Adds a vector index configuration to this vector collection configuration.
      Parameters:
      vectorIndexConfig - the vector index configuration to add
      Returns:
      this VectorCollectionConfig instance
    • getVectorIndexConfigs

      public List<VectorIndexConfig> getVectorIndexConfigs()
      Retrieves the list of vector index configurations associated with this vector collection configuration.
      Returns:
      the list of vector index configurations
    • setVectorIndexConfigs

      public void setVectorIndexConfigs(List<VectorIndexConfig> vectorIndexConfigs)
      Sets the list of VectorIndexConfig instances for this vector collection configuration. Clears the existing vector index configurations and replaces them with the provided list.
      Parameters:
      vectorIndexConfigs - The list of VectorIndexConfig instances to set.
    • writeData

      public void writeData(ObjectDataOutput out) throws IOException
      Description copied from interface: DataSerializable
      Writes object fields to output stream
      Specified by:
      writeData in interface DataSerializable
      Parameters:
      out - output
      Throws:
      IOException - if an I/O error occurs. In particular, an IOException may be thrown if the output stream has been closed.
    • readData

      public void readData(ObjectDataInput in) throws IOException
      Description copied from interface: DataSerializable
      Reads fields from the input stream
      Specified by:
      readData in interface DataSerializable
      Parameters:
      in - input
      Throws:
      IOException - if an I/O error occurs. In particular, an IOException may be thrown if the input stream has been closed.
    • getFactoryId

      public int getFactoryId()
      Description copied from interface: IdentifiedDataSerializable
      Returns DataSerializableFactory factory ID for this class.
      Specified by:
      getFactoryId in interface IdentifiedDataSerializable
      Returns:
      factory ID
    • getClassId

      public int getClassId()
      Description copied from interface: IdentifiedDataSerializable
      Returns type identifier for this class. It should be unique per DataSerializableFactory.
      Specified by:
      getClassId in interface IdentifiedDataSerializable
      Returns:
      type ID
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object object)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object