Skip to content

Commit f7bef50

Browse files
committed
feat(gh-562): add blobHash data type
1 parent 3866ce2 commit f7bef50

2 files changed

Lines changed: 20 additions & 0 deletions

File tree

src/main/java/io/weaviate/client6/v1/api/collections/DataType.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ public interface DataType {
1414
public static final String BOOL = "boolean";
1515
public static final String BOOL_ARRAY = "boolean[]";
1616
public static final String BLOB = "blob";
17+
public static final String BLOB_HASH = "blobHash";
1718
public static final String DATE = "date";
1819
public static final String DATE_ARRAY = "date[]";
1920
public static final String UUID = "uuid";

src/main/java/io/weaviate/client6/v1/api/collections/Property.java

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,25 @@ public static Property blob(String name, Function<Builder, ObjectBuilder<Propert
118118
return newProperty(name, DataType.BLOB, fn);
119119
}
120120

121+
/**
122+
* Create a {@code blobHash} property.
123+
*
124+
* @param name Property name.
125+
*/
126+
public static Property blobHash(String name) {
127+
return blobHash(name, ObjectBuilder.identity());
128+
}
129+
130+
/**
131+
* Create a {@code blobHash} property with additional configuration.
132+
*
133+
* @param name Property name.
134+
* @param fn Lambda expression for optional parameters.
135+
*/
136+
public static Property blobHash(String name, Function<Builder, ObjectBuilder<Property>> fn) {
137+
return newProperty(name, DataType.BLOB_HASH, fn);
138+
}
139+
121140
/**
122141
* Create a {@code bool} property.
123142
*

0 commit comments

Comments
 (0)