Package org.apache.spark.mllib.linalg
Class VectorUDT
- All Implemented Interfaces:
Serializable
:: AlphaComponent ::
User-defined type for Vector
which allows easy interaction with SQL
via Dataset
.
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondeserialize
(Object datum) Convert a SQL datum to the user typeboolean
int
hashCode()
pyUDT()
Paired Python UDT class, if exists.org.apache.spark.sql.catalyst.InternalRow
Convert the user type to a SQL datumsqlType()
Underlying storage type for this UDTtypeName()
Name of the type used in JSON serialization.Class object for the UserTypeMethods inherited from class org.apache.spark.sql.types.UserDefinedType
catalogString, defaultSize, serializedPyClass, sql
Methods inherited from class org.apache.spark.sql.types.DataType
COLLATIONS_METADATA_KEY, equalsIgnoreCaseAndNullability, equalsIgnoreNullability, equalsStructurally, equalsStructurallyByName, fromDDL, fromJson, json, parseTypeWithFallback, prettyJson, simpleString
-
Constructor Details
-
VectorUDT
public VectorUDT()
-
-
Method Details
-
deserialize
Description copied from class:UserDefinedType
Convert a SQL datum to the user type- Specified by:
deserialize
in classUserDefinedType<Vector>
-
equals
- Overrides:
equals
in classUserDefinedType<Vector>
-
hashCode
public int hashCode()- Overrides:
hashCode
in classUserDefinedType<Vector>
-
pyUDT
Description copied from class:UserDefinedType
Paired Python UDT class, if exists.- Overrides:
pyUDT
in classUserDefinedType<Vector>
-
serialize
Description copied from class:UserDefinedType
Convert the user type to a SQL datum- Specified by:
serialize
in classUserDefinedType<Vector>
- Parameters:
obj
- (undocumented)- Returns:
- (undocumented)
-
sqlType
Description copied from class:UserDefinedType
Underlying storage type for this UDT- Specified by:
sqlType
in classUserDefinedType<Vector>
-
typeName
Description copied from class:DataType
Name of the type used in JSON serialization. -
userClass
Description copied from class:UserDefinedType
Class object for the UserType- Specified by:
userClass
in classUserDefinedType<Vector>
- Returns:
- (undocumented)
-