public static interface LoaderFieldMapper.LoaderFieldContext
LoaderFieldMapper.map(LoaderFieldContext)
.Modifier and Type | Method and Description |
---|---|
Field<?> |
field()
The
Field of the source data to be mapped. |
int |
index()
The field index in order of specification in the source data.
|
Field<?> field()
Field
of the source data to be mapped.
This returns the following, depending on the data source:
LoaderSourceStep.loadArrays(Object[][])
: A generated,
unspecified field.LoaderSourceStep.loadCSV(String)
: If the first CSV row
specifies headers, those headers are used for field names. Otherwise,
a generated, unspecified field is provided.LoaderSourceStep.loadJSON(String)
: The field specified in
the JSON content is used.LoaderSourceStep.loadRecords(Record...)
: The field from
the Record
is used.int index()
This returns the following, depending on the data source:
LoaderSourceStep.loadArrays(Object[][])
: The array index.
LoaderSourceStep.loadCSV(String)
: The CSV column index.
LoaderSourceStep.loadJSON(String)
: The JSON field
enumeration index (depending on your JSON serialisation, this might
not be reliable!)LoaderSourceStep.loadRecords(Record...)
: The record field
index.Copyright © 2017. All Rights Reserved.