protected class AbstractFileItemWriter.OutputState
extends java.lang.Object
| Modifier | Constructor and Description | 
|---|---|
protected  | 
OutputState()  | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
close()
Close the open resource and reset counters. 
 | 
long | 
getLinesWritten()  | 
boolean | 
isInitialized()  | 
long | 
position()
Return the byte offset position of the cursor in the output file as a
 long integer. 
 | 
void | 
restoreFrom(ExecutionContext executionContext)  | 
void | 
setAppendAllowed(boolean append)  | 
void | 
setDeleteIfExists(boolean shouldDeleteIfExists)  | 
void | 
setEncoding(java.lang.String encoding)  | 
void | 
setLinesWritten(long linesWritten)  | 
void | 
truncate()
Truncate the output at the last known good point. 
 | 
void | 
write(java.lang.String line)  | 
public long position()
              throws java.io.IOException
java.io.IOException - If unable to get the offset positionpublic void setAppendAllowed(boolean append)
append - if true, append to previously created filepublic void restoreFrom(ExecutionContext executionContext)
executionContext - state from which to restore writing frompublic void setDeleteIfExists(boolean shouldDeleteIfExists)
shouldDeleteIfExists - indicatorpublic void setEncoding(java.lang.String encoding)
encoding - file encodingpublic long getLinesWritten()
public void setLinesWritten(long linesWritten)
public void close()
public void write(java.lang.String line)
           throws java.io.IOException
line - String to be written to the filejava.io.IOException - If unable to write the String to the filepublic void truncate()
              throws java.io.IOException
java.io.IOException - if unable to work with filepublic boolean isInitialized()