public class ParserUtils extends Object
Modifier and Type | Class and Description |
---|---|
static class |
ParserUtils.StringPosition |
static class |
ParserUtils.TypeFinder |
static interface |
ParserUtils.TypeVisitor |
Constructor and Description |
---|
ParserUtils() |
Modifier and Type | Method and Description |
---|---|
static MaskDescriptionImpl |
buildMaskDescription(String value) |
static void |
findColumn(TypeDescription schema,
List<String> names,
boolean isSchemaEvolutionCaseAware,
ParserUtils.TypeVisitor visitor)
Find a column in a schema by walking down the type tree to find the right column.
|
static void |
findColumn(TypeDescription schema,
ParserUtils.StringPosition source,
boolean isSchemaEvolutionCaseAware,
ParserUtils.TypeVisitor visitor)
Find a column in a schema by walking down the type tree to find the right column.
|
static ColumnVector[] |
findColumnVectors(TypeDescription schema,
ParserUtils.StringPosition source,
boolean isCaseSensitive,
VectorizedRowBatch batch) |
static void |
findSubtype(TypeDescription schema,
int goal,
ParserUtils.TypeVisitor visitor) |
static TypeDescription |
findSubtype(TypeDescription schema,
ParserUtils.StringPosition source) |
static TypeDescription |
findSubtype(TypeDescription schema,
ParserUtils.StringPosition source,
boolean isSchemaEvolutionCaseAware) |
static List<TypeDescription> |
findSubtypeList(TypeDescription schema,
ParserUtils.StringPosition source) |
static void |
parseKeys(ParserUtils.StringPosition source,
TypeDescription schema)
Annotate the given schema with the encryption information.
|
static void |
parseMasks(ParserUtils.StringPosition source,
TypeDescription schema)
Annotate the given schema with the masking information.
|
static String |
parseName(ParserUtils.StringPosition source) |
static TypeDescription |
parseType(ParserUtils.StringPosition source) |
public static String parseName(ParserUtils.StringPosition source)
public static TypeDescription parseType(ParserUtils.StringPosition source)
public static TypeDescription findSubtype(TypeDescription schema, ParserUtils.StringPosition source)
public static TypeDescription findSubtype(TypeDescription schema, ParserUtils.StringPosition source, boolean isSchemaEvolutionCaseAware)
public static void findSubtype(TypeDescription schema, int goal, ParserUtils.TypeVisitor visitor)
public static void findColumn(TypeDescription schema, ParserUtils.StringPosition source, boolean isSchemaEvolutionCaseAware, ParserUtils.TypeVisitor visitor)
schema
- the schema to look insource
- the name of the columnisSchemaEvolutionCaseAware
- should the string compare be case sensitivevisitor
- The visitor, which is called on each levelpublic static void findColumn(TypeDescription schema, List<String> names, boolean isSchemaEvolutionCaseAware, ParserUtils.TypeVisitor visitor)
schema
- the schema to look innames
- the name of the column broken into a list of names per levelisSchemaEvolutionCaseAware
- should the string compare be case sensitivevisitor
- The visitor, which is called on each levelpublic static ColumnVector[] findColumnVectors(TypeDescription schema, ParserUtils.StringPosition source, boolean isCaseSensitive, VectorizedRowBatch batch)
public static List<TypeDescription> findSubtypeList(TypeDescription schema, ParserUtils.StringPosition source)
public static void parseKeys(ParserUtils.StringPosition source, TypeDescription schema)
source
- the string to parseschema
- the top level schemaIllegalArgumentException
- if there are conflicting keys for a fieldpublic static void parseMasks(ParserUtils.StringPosition source, TypeDescription schema)
source
- the string to parseschema
- the top level schemaIllegalArgumentException
- if there are conflicting masks for a fieldpublic static MaskDescriptionImpl buildMaskDescription(String value)
Copyright © 2013–2023 The Apache Software Foundation. All rights reserved.