public class VectorUDT extends UserDefinedType<Vector>
User-defined type for Vector
which allows easy interaction with SQL
via Dataset
.
Constructor and Description |
---|
VectorUDT() |
Modifier and Type | Method and Description |
---|---|
Vector |
deserialize(Object datum)
Convert a SQL datum to the user type
|
boolean |
equals(Object o) |
int |
hashCode() |
String |
pyUDT()
Paired Python UDT class, if exists.
|
org.apache.spark.sql.catalyst.InternalRow |
serialize(Vector obj)
Convert the user type to a SQL datum
|
StructType |
sqlType()
Underlying storage type for this UDT
|
String |
typeName()
Name of the type used in JSON serialization.
|
Class<Vector> |
userClass()
Class object for the UserType
|
catalogString, defaultSize, serializedPyClass, sql
canWrite, equalsStructurally, equalsStructurallyByName, fromDDL, fromJson, json, parseTypeWithFallback, prettyJson, simpleString
public Vector deserialize(Object datum)
UserDefinedType
deserialize
in class UserDefinedType<Vector>
public boolean equals(Object o)
equals
in class UserDefinedType<Vector>
public int hashCode()
hashCode
in class UserDefinedType<Vector>
public String pyUDT()
UserDefinedType
pyUDT
in class UserDefinedType<Vector>
public org.apache.spark.sql.catalyst.InternalRow serialize(Vector obj)
UserDefinedType
serialize
in class UserDefinedType<Vector>
obj
- (undocumented)public StructType sqlType()
UserDefinedType
sqlType
in class UserDefinedType<Vector>
public String typeName()
DataType
public Class<Vector> userClass()
UserDefinedType
userClass
in class UserDefinedType<Vector>