public class SchemaUtils
extends Object
TODO: Merge this file with SchemaUtils
.
Constructor and Description |
---|
SchemaUtils() |
Modifier and Type | Method and Description |
---|---|
static void |
checkColumnNameDuplication(scala.collection.Seq<String> columnNames,
String colType,
boolean caseSensitiveAnalysis)
Checks if input column names have duplicate identifiers.
|
static void |
checkColumnNameDuplication(scala.collection.Seq<String> columnNames,
String colType,
scala.Function2<String,String,Object> resolver)
Checks if input column names have duplicate identifiers.
|
static void |
checkSchemaColumnNameDuplication(StructType schema,
String colType,
boolean caseSensitiveAnalysis)
Checks if an input schema has duplicate column names.
|
public static void checkSchemaColumnNameDuplication(StructType schema, String colType, boolean caseSensitiveAnalysis)
schema
- schema to checkcolType
- column type name, used in an exception messagecaseSensitiveAnalysis
- whether duplication checks should be case sensitive or notpublic static void checkColumnNameDuplication(scala.collection.Seq<String> columnNames, String colType, scala.Function2<String,String,Object> resolver)
columnNames
- column names to checkcolType
- column type name, used in an exception messageresolver
- resolver used to determine if two identifiers are equalpublic static void checkColumnNameDuplication(scala.collection.Seq<String> columnNames, String colType, boolean caseSensitiveAnalysis)
columnNames
- column names to checkcolType
- column type name, used in an exception messagecaseSensitiveAnalysis
- whether duplication checks should be case sensitive or not