Interface SimpleHeaderExtractor
- All Superinterfaces:
HeaderExtractor,Serializable
A
HeaderExtractor appropriate for extracting a single-row header.
The location of the header can be static or dynamic.
Merged cells are supported; merged cells will be treated as signifying multiple columns with the same name, which
will ultimately become column_name, column_name_2 in the final
ParseResult.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder for constructing an instance ofSimpleHeaderExtractor. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Create a builder for constructing an instance of this class.default CaseNormalizationOptionDefaults toCaseNormalizationOption.DO_NOT_NORMALIZE.extractHeader(org.apache.poi.ss.usermodel.Sheet sheet) default RowPredicateAfter skippingrowsToSkip(), the first subsequent row for which this function returns true will be treated as the header.default IntegerA static number of rows at the top of the sheet to ignore.
-
Method Details
-
rowsToSkip
A static number of rows at the top of the sheet to ignore. Default value is 0. -
predicate
After skippingrowsToSkip(), the first subsequent row for which this function returns true will be treated as the header.Passing a custom function here is convenient for files for which there are a variable number of rows that need to be skipped before the header and there is some logic to identify whether a given row is the header or not. The default behavior if no custom function is passed is to always return
true. -
caseNormalizationOption
Defaults toCaseNormalizationOption.DO_NOT_NORMALIZE. -
extractHeader
- Specified by:
extractHeaderin interfaceHeaderExtractor
-
builder
Create a builder for constructing an instance of this class.
-