public class Validator extends Object
| 构造器和说明 |
|---|
Validator() |
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
verifyBachSize(List<Doc> docs)
Verify bach size
|
static void |
verifyCollectionName(@NonNull String name)
Verify DashVectorCollection Name
|
static void |
verifyDimension(int dimension)
Verify DashVectorCollection dimension
|
static void |
verifyDocId(@NonNull String id)
Verify Doc id
|
static void |
verifyDocIdList(List<String> docIds)
Verify DocId List
|
static void |
verifyDocList(List<Doc> docs)
Verify Doc List
|
static void |
verifyDocParam(@NonNull WriteDocRequest<? extends com.google.protobuf.Message> writeDocRequest,
@NonNull CollectionMeta collectionMeta)
Verify Model DocParam
|
static void |
verifyFields(Map<String,?> fieldsSchema)
Verify DashVectorCollection filedsSchema
|
static void |
verifyFilter(String filter)
Verify Filter
|
static void |
verifyOutputFields(List<String> outputFields)
Verify outputFields
|
static void |
verifyPartitionName(@NonNull String name)
Verify Partition Name
|
static void |
verifyQueryParma(@NonNull QueryDocRequest queryDocRequest,
@NonNull CollectionMeta collectionMeta)
Verify Model QueryDocRequest
|
static void |
verifyRequestSize(@NonNull com.google.protobuf.Message message)
Verify request size
|
static void |
verifyTopK(int topk)
Verify topk
|
static void |
verifyVectorType(List<? extends Number> vector)
Verify Doc Vector Type
|
public static void verifyRequestSize(@NonNull
@NonNull com.google.protobuf.Message message)
throws DashVectorException
message - that is proto.MessageDashVectorException - that contains exception code and exception messagepublic static void verifyDocId(@NonNull
@NonNull String id)
throws DashVectorException
id - that is model.Doc idDashVectorException - that contains exception code and exception messagepublic static void verifyOutputFields(List<String> outputFields) throws DashVectorException
outputFields - that is list of fieldDashVectorException - that contains exception code and exception messagepublic static void verifyTopK(int topk)
throws DashVectorException
topk - that is topkDashVectorException - that contains exception code and exception messagepublic static void verifyBachSize(List<Doc> docs) throws DashVectorException
docs - that is list of model.DocDashVectorException - that contains exception code and exception messagepublic static void verifyVectorType(List<? extends Number> vector) throws DashVectorException
vector - that is list of NumberDashVectorException - that contains exception code and exception messagepublic static void verifyCollectionName(@NonNull
@NonNull String name)
throws DashVectorException
name - that is collection nameDashVectorException - that contains exception code and exception messagepublic static void verifyPartitionName(@NonNull
@NonNull String name)
throws DashVectorException
name - that is partition nameDashVectorException - that contains exception code and exception messagepublic static void verifyDimension(int dimension)
throws DashVectorException
dimension - that is dimensionDashVectorException - that contains exception code and exception messagepublic static void verifyFields(Map<String,?> fieldsSchema) throws DashVectorException
fieldsSchema - that is filedsSchema of CollectionDashVectorException - that contains exception code and exception messagepublic static void verifyFilter(String filter) throws DashVectorException
filter - that is filter of QueryDashVectorException - that contains exception code and exception messagepublic static void verifyDocIdList(List<String> docIds) throws DashVectorException
docIds - that is list of model.Doc idDashVectorException - that contains exception code and exception messagepublic static void verifyDocList(List<Doc> docs) throws DashVectorException
docs - that is list of model.DocDashVectorException - that contains exception code and exception messagepublic static void verifyDocParam(@NonNull
@NonNull WriteDocRequest<? extends com.google.protobuf.Message> writeDocRequest,
@NonNull
@NonNull CollectionMeta collectionMeta)
throws DashVectorException
writeDocRequest - that is writeDocRequestcollectionMeta - that is collection metaDashVectorException - that contains exception code and exception messagepublic static void verifyQueryParma(@NonNull
@NonNull QueryDocRequest queryDocRequest,
@NonNull
@NonNull CollectionMeta collectionMeta)
throws DashVectorException
queryDocRequest - that is query doc requestcollectionMeta - that is collection metaDashVectorException - that contains exception code and exception messageCopyright © 2023. All rights reserved.