public class SuffixRecordSeparatorPolicy extends DefaultRecordSeparatorPolicy
RecordSeparatorPolicy that looks for an exact match for a String at
the end of a line (e.g. a semicolon).| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DEFAULT_SUFFIX
Default value for record terminator suffix.
|
| Constructor and Description |
|---|
SuffixRecordSeparatorPolicy() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
isEndOfRecord(java.lang.String line)
Return true if the line ends with the specified substring.
|
java.lang.String |
postProcess(java.lang.String record)
Remove the suffix from the end of the record.
|
void |
setIgnoreWhitespace(boolean ignoreWhitespace)
Flag to indicate that the decision to terminate a record should ignore
whitespace at the end of the line.
|
void |
setSuffix(java.lang.String suffix)
Lines ending in this terminator String signal the end of a record.
|
preProcess, setContinuation, setQuoteCharacterpublic static final java.lang.String DEFAULT_SUFFIX
public void setSuffix(java.lang.String suffix)
suffix - public void setIgnoreWhitespace(boolean ignoreWhitespace)
ignoreWhitespace - public boolean isEndOfRecord(java.lang.String line)
isEndOfRecord in interface RecordSeparatorPolicyisEndOfRecord in class DefaultRecordSeparatorPolicyline - a String without a newline character at the end.RecordSeparatorPolicy.isEndOfRecord(java.lang.String)public java.lang.String postProcess(java.lang.String record)
postProcess in interface RecordSeparatorPolicypostProcess in class SimpleRecordSeparatorPolicyrecord - the complete record.SimpleRecordSeparatorPolicy.postProcess(java.lang.String)