private void initFixedLengthRecordParameters() {
for (Class<?> cl : models) {
// Get annotation @FixedLengthRecord from the class
FixedLengthRecord record = cl.getAnnotation(FixedLengthRecord.class);
if (record != null) {
LOG.debug("Fixed length record: {}", record);
// Get carriage return parameter
crlf = record.crlf();
LOG.debug("Carriage return defined for the CSV: {}", crlf);
// Get hasHeader parameter
hasHeader = record.hasHeader();
LOG.debug("Has Header: {}", hasHeader);
// Get skipHeader parameter
skipHeader = record.skipHeader();
LOG.debug("Skip Header: {}", skipHeader);
// Get hasFooter parameter
hasFooter = record.hasFooter();
LOG.debug("Has Footer: {}", hasFooter);
// Get skipFooter parameter
skipFooter = record.skipFooter();
LOG.debug("Skip Footer: {}", skipFooter);
// Get isHeader parameter
isHeader = record.isHeader();
LOG.debug("Is Header: {}", isHeader);
// Get isFooter parameter
isFooter = record.isFooter();
LOG.debug("Is Footer: {}", isFooter);
// Get padding character
paddingChar = record.paddingChar();
LOG.debug("Padding char: {}", paddingChar);
// Get length of the record
recordLength = record.length();
LOG.debug("Length of the record: {}", recordLength);
// Get flag for ignore trailing characters
ignoreTrailingChars = record.ignoreTrailingChars();
LOG.debug("Ignore trailing chars: {}", ignoreTrailingChars);
}
}
if (hasHeader && isHeader) {