|
BeanIO 2.0.4 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.beanio.internal.parser.format.flat.FlatFieldFormatSupport
org.beanio.internal.parser.format.fixedlength.FixedLengthFieldFormat
public class FixedLengthFieldFormat
A FieldFormat implementation for a field in a fixed length formatted stream.
| Constructor Summary | |
|---|---|
FixedLengthFieldFormat()
Constructs a new FixedLengthFieldFormat. |
|
| Method Summary | |
|---|---|
String |
extract(UnmarshallingContext context,
boolean reportErrors)
Extracts the field text from a record. |
String |
extractFieldText(UnmarshallingContext context,
boolean reporting)
|
int |
getSize()
Returns the size of the field. |
void |
insertFieldText(MarshallingContext context,
String fieldText,
boolean commit)
|
void |
setKeepPadding(boolean keepPadding)
Set to true to keep field padding during unmarshalling. |
| Methods inherited from class org.beanio.internal.parser.format.flat.FlatFieldFormatSupport |
|---|
getName, getPadding, getPosition, getUntil, insertField, insertValue, isLazy, isNillable, setLazy, setName, setPadding, setPosition, setUntil, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.beanio.internal.parser.FieldFormat |
|---|
insertField, insertValue, isLazy, isNillable |
| Constructor Detail |
|---|
public FixedLengthFieldFormat()
| Method Detail |
|---|
public String extract(UnmarshallingContext context,
boolean reportErrors)
FieldFormatMay return Value.INVALID if the field is invalid, or Value.NIL
if the field is explicitly set to nil or null such as in an XML or JSON formatted
stream.
Implementations should also remove any field padding before returning the text.
extract in interface FieldFormatextract in class FlatFieldFormatSupportcontext - the UnmarshallingContext holding the record
public String extractFieldText(UnmarshallingContext context,
boolean reporting)
extractFieldText in class FlatFieldFormatSupport
public void insertFieldText(MarshallingContext context,
String fieldText,
boolean commit)
insertFieldText in class FlatFieldFormatSupportpublic int getSize()
FieldFormat
getSize in interface FieldFormatgetSize in class FlatFieldFormatSupportpublic void setKeepPadding(boolean keepPadding)
keepPadding - true to keep padding
|
BeanIO 2.0.4 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||