- Enclosing interface:
LoaderFieldMapper
public static interface LoaderFieldMapper.LoaderFieldContext
The argument object for
LoaderFieldMapper.map(LoaderFieldContext)
.-
Method Summary
-
Method Details
-
field
Field<?> field()TheField
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 theRecord
is used.
-
index
int index()The field index in order of specification in the source data.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.
-