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 class
A builder for constructing an instance ofSimpleHeaderExtractor
. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
Create a builder for constructing an instance of this class.default CaseNormalizationOption
Defaults toCaseNormalizationOption.DO_NOT_NORMALIZE
.extractHeader
(org.apache.poi.ss.usermodel.Sheet sheet) default RowPredicate
After skippingrowsToSkip()
, the first subsequent row for which this function returns true will be treated as the header.default Integer
A 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:
extractHeader
in interfaceHeaderExtractor
-
builder
Create a builder for constructing an instance of this class.
-