StructField¶
-
class
pyspark.sql.types.
StructField
(name, dataType, nullable=True, metadata=None)[source]¶ A field in
StructType
.- Parameters
name – string, name of the field.
dataType –
DataType
of the field.nullable – boolean, whether the field can be null (None) or not.
metadata – a dict from string to simple type that can be toInternald to JSON automatically
Methods
Methods Documentation
-
json
()¶