Skip to content
Snippets Groups Projects
Commit 46db277c authored by Daoyuan Wang's avatar Daoyuan Wang Committed by Michael Armbrust
Browse files

[SPARK-3892][SQL] remove redundant type name

Author: Daoyuan Wang <daoyuan.wang@intel.com>

Closes #2747 from adrian-wang/typename and squashes the following commits:

2824216 [Daoyuan Wang] remove redundant typeName
fbaf340 [Daoyuan Wang] typename
parent 49bbdcb6
No related branches found
No related tags found
No related merge requests found
...@@ -349,7 +349,6 @@ case object FloatType extends FractionalType { ...@@ -349,7 +349,6 @@ case object FloatType extends FractionalType {
object ArrayType { object ArrayType {
/** Construct a [[ArrayType]] object with the given element type. The `containsNull` is true. */ /** Construct a [[ArrayType]] object with the given element type. The `containsNull` is true. */
def apply(elementType: DataType): ArrayType = ArrayType(elementType, true) def apply(elementType: DataType): ArrayType = ArrayType(elementType, true)
def typeName: String = "array"
} }
/** /**
...@@ -395,8 +394,6 @@ case class StructField(name: String, dataType: DataType, nullable: Boolean) { ...@@ -395,8 +394,6 @@ case class StructField(name: String, dataType: DataType, nullable: Boolean) {
object StructType { object StructType {
protected[sql] def fromAttributes(attributes: Seq[Attribute]): StructType = protected[sql] def fromAttributes(attributes: Seq[Attribute]): StructType =
StructType(attributes.map(a => StructField(a.name, a.dataType, a.nullable))) StructType(attributes.map(a => StructField(a.name, a.dataType, a.nullable)))
def typeName = "struct"
} }
case class StructType(fields: Seq[StructField]) extends DataType { case class StructType(fields: Seq[StructField]) extends DataType {
...@@ -459,8 +456,6 @@ object MapType { ...@@ -459,8 +456,6 @@ object MapType {
*/ */
def apply(keyType: DataType, valueType: DataType): MapType = def apply(keyType: DataType, valueType: DataType): MapType =
MapType(keyType: DataType, valueType: DataType, true) MapType(keyType: DataType, valueType: DataType, true)
def simpleName = "map"
} }
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment