class SuffixRecordSeparatorPolicy extends DefaultRecordSeparatorPolicy {

	/**
	 * Default value for record terminator suffix.
	 */
	public static final String DEFAULT_SUFFIX = ";";

	private String suffix = DEFAULT_SUFFIX;

	private boolean ignoreWhitespace = true;

	/**
	 * Lines ending in this terminator String signal the end of a record.
	 * @param suffix suffix to indicate the end of a record
	 */
	public void setSuffix(String suffix) {
		this.suffix = suffix;
	}

	/**
	 * Flag to indicate that the decision to terminate a record should ignore whitespace
	 * at the end of the line.
	 * @param ignoreWhitespace indicator
	 */
	public void setIgnoreWhitespace(boolean ignoreWhitespace) {
		this.ignoreWhitespace = ignoreWhitespace;
	}

	/**
	 * Return true if the line ends with the specified substring. By default whitespace is
	 * trimmed before the comparison. Also returns true if the line is null, but not if it
	 * is empty.
	 *
	 * @see org.springframework.batch.item.file.separator.RecordSeparatorPolicy#isEndOfRecord(java.lang.String)
	 */
	@Override
	public boolean isEndOfRecord(String line) {<FILL_FUNCTION_BODY>}

	/**
	 * Remove the suffix from the end of the record.
	 *
	 * @see org.springframework.batch.item.file.separator.SimpleRecordSeparatorPolicy#postProcess(java.lang.String)
	 */
	@Override
	public String postProcess(String record) {
		if (record == null) {
			return null;
		}
		return record.substring(0, record.lastIndexOf(suffix));
	}

}

		if (line == null) {
			return true;
		}
		String trimmed = ignoreWhitespace ? line.trim() : line;
		return trimmed.endsWith(suffix);
	
<methods>public void <init>() ,public void <init>(java.lang.String) ,public void <init>(java.lang.String, java.lang.String) ,public boolean isEndOfRecord(java.lang.String) ,public java.lang.String preProcess(java.lang.String) ,public void setContinuation(java.lang.String) ,public void setQuoteCharacter(java.lang.String) <variables>private static final java.lang.String CONTINUATION,private static final java.lang.String QUOTE,private java.lang.String continuation,private java.lang.String quoteCharacter