public abstract static class InputFormats.BaseFormatDefn extends Object implements InputFormatDefn
| Constructor and Description |
|---|
BaseFormatDefn(List<TableFunction.ParameterDefn> parameters) |
| Modifier and Type | Method and Description |
|---|---|
InputFormat |
convert(Map<String,Object> jsonMap,
com.fasterxml.jackson.databind.ObjectMapper jsonMapper)
Convert a generic Java map of input format properties to an input format object.
|
protected void |
convertColumns(Map<String,Object> jsonMap,
List<ColumnSpec> columns)
Convert columns from the
ColumnSpec format used by the catalog to the
list of names form requires by input formats. |
InputFormat |
convertFromTable(ResolvedExternalTable table)
Create an input format from a resolved catalog table spec.
|
protected abstract Class<? extends InputFormat> |
inputFormatClass()
The target input format class for Jackson conversions.
|
List<TableFunction.ParameterDefn> |
parameters()
Obtain the parameters used to fully define an input format in a SQL function
that defines an external table from scratch.
|
void |
validate(ResolvedExternalTable table)
Given a resolved table that has the serialized JSON converted to a Java map,
validate the values of that map, typically by converting that map the target
input format object (after adjustments and filling in dummy columns.) THe
goal is to validate the information the user has provided in the table spec.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitconvertFromArgs, typeValuepublic BaseFormatDefn(List<TableFunction.ParameterDefn> parameters)
public List<TableFunction.ParameterDefn> parameters()
InputFormatDefnparameters in interface InputFormatDefnprotected abstract Class<? extends InputFormat> inputFormatClass()
public void validate(ResolvedExternalTable table)
InputFormatDefnvalidate in interface InputFormatDefnprotected void convertColumns(Map<String,Object> jsonMap, List<ColumnSpec> columns)
ColumnSpec format used by the catalog to the
list of names form requires by input formats.public InputFormat convert(Map<String,Object> jsonMap, com.fasterxml.jackson.databind.ObjectMapper jsonMapper)
public InputFormat convertFromTable(ResolvedExternalTable table)
InputFormatDefnconvertFromTable in interface InputFormatDefntable - resolved form of a table spec, with the format JSON parsed into
a JSON mapCopyright © 2011–2023 The Apache Software Foundation. All rights reserved.