Package app.ductape.sdk.vector
Record Class VectorServiceOptions
java.lang.Object
java.lang.Record
app.ductape.sdk.vector.VectorServiceOptions
public record VectorServiceOptions(VectorTypes.VectorDBType type, String endpoint, String apiKey, String index, String namespace, int dimensions, VectorTypes.DistanceMetric metric, String region, Integer timeout, Map<String,Object> extra)
extends Record
Parity with TS
IVectorServiceOptions (see vector.service.ts).
Product-level vector definitions match TS IVectorConfig/IVectorEnvConfig; see VectorConnectionTypes
and VectorConnectionMaps.-
Constructor Summary
ConstructorsConstructorDescriptionVectorServiceOptions(VectorTypes.VectorDBType type, String endpoint, String apiKey, String index, String namespace, int dimensions, VectorTypes.DistanceMetric metric, String region, Integer timeout, Map<String, Object> extra) Creates an instance of aVectorServiceOptionsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionapiKey()Returns the value of theapiKeyrecord component.intReturns the value of thedimensionsrecord component.endpoint()Returns the value of theendpointrecord component.final booleanIndicates whether some other object is "equal to" this one.extra()Returns the value of theextrarecord component.final inthashCode()Returns a hash code value for this object.index()Returns the value of theindexrecord component.metric()Returns the value of themetricrecord component.Returns the value of thenamespacerecord component.region()Returns the value of theregionrecord component.timeout()Returns the value of thetimeoutrecord component.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.
-
Constructor Details
-
VectorServiceOptions
public VectorServiceOptions(VectorTypes.VectorDBType type, String endpoint, String apiKey, String index, String namespace, int dimensions, VectorTypes.DistanceMetric metric, String region, Integer timeout, Map<String, Object> extra) Creates an instance of aVectorServiceOptionsrecord class.- Parameters:
type- the value for thetyperecord componentendpoint- the value for theendpointrecord componentapiKey- the value for theapiKeyrecord componentindex- the value for theindexrecord componentnamespace- the value for thenamespacerecord componentdimensions- the value for thedimensionsrecord componentmetric- the value for themetricrecord componentregion- the value for theregionrecord componenttimeout- the value for thetimeoutrecord componentextra- the value for theextrarecord component
-
-
Method Details
-
toConnectionMap
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
type
Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-
endpoint
Returns the value of theendpointrecord component.- Returns:
- the value of the
endpointrecord component
-
apiKey
Returns the value of theapiKeyrecord component.- Returns:
- the value of the
apiKeyrecord component
-
index
Returns the value of theindexrecord component.- Returns:
- the value of the
indexrecord component
-
namespace
Returns the value of thenamespacerecord component.- Returns:
- the value of the
namespacerecord component
-
dimensions
public int dimensions()Returns the value of thedimensionsrecord component.- Returns:
- the value of the
dimensionsrecord component
-
metric
Returns the value of themetricrecord component.- Returns:
- the value of the
metricrecord component
-
region
Returns the value of theregionrecord component.- Returns:
- the value of the
regionrecord component
-
timeout
Returns the value of thetimeoutrecord component.- Returns:
- the value of the
timeoutrecord component
-
extra
Returns the value of theextrarecord component.- Returns:
- the value of the
extrarecord component
-