public class DynamicField extends PadJustifyFieldSupport
| Modifier and Type | Class and Description |
|---|---|
static class |
DynamicField.Bounds
Bounds
|
PadJustifyFieldSupport.JustifyFieldSupport.Overflow, FieldSupport.UnderflowDEFAULT_PAD| Constructor and Description |
|---|
DynamicField()
Create a new DynamicField.
|
DynamicField(DynamicField.Bounds bounds)
Create a new DynamicField.
|
| Modifier and Type | Method and Description |
|---|---|
DynamicField |
clone()
Clone oneself.
|
boolean |
equals(Object other) |
DynamicField.Bounds |
getBounds()
Get the bounds.
|
FieldSupport.Overflow |
getOverflow()
Get the overflow.
|
protected int |
getPadJustifyLength()
Provide the desired target length for padding/justification actions.
|
FieldSupport.Underflow |
getUnderflow()
Get the underflow.
|
byte[] |
getValue()
Get the value of this Entity.
|
int |
hashCode() |
protected void |
iSetValue(byte[] value)
Protected inner setValue
|
int |
length()
Get the length of this Entity.
|
void |
readFrom(InputStream is)
Read up to
maximumLength bytes from the specified InputStream or stop at EOF. |
void |
setBounds(DynamicField.Bounds bounds)
Set the bounds.
|
void |
setOverflow(FieldSupport.Overflow overflow)
Set the overflow.
|
void |
setUnderflow(FieldSupport.Underflow underflow)
Set the underflow.
|
void |
setValue(byte[] b)
Implement pad/justify.
|
void |
writeTo(OutputStream os)
Write value to an OutputStream.
|
getJustify, getPad, setJustify, setPaddieOnExceptionReadfill, getValue, setValuepublic DynamicField()
public DynamicField(DynamicField.Bounds bounds)
bounds - boundspublic byte[] getValue()
public int length()
public void readFrom(InputStream is) throws IOException
maximumLength bytes from the specified InputStream or stop at EOF. This will rarely be
what you want. Instead, consider using InputFilteringDynamicField. In the case that <
minimumLength bytes are available from is the justify and
pad options come into play.is - the InputStream from which to read data.IOException - on problems with I/O, duh...public void setValue(byte[] b)
setValue in interface EntitysetValue in class PadJustifyFieldSupportb - value setpublic void writeTo(OutputStream os) throws IOException
os - to write toIOException - on errorpublic FieldSupport.Overflow getOverflow()
public void setOverflow(FieldSupport.Overflow overflow)
overflow - Overflowpublic FieldSupport.Underflow getUnderflow()
public void setUnderflow(FieldSupport.Underflow underflow)
underflow - Underflowprotected int getPadJustifyLength()
getPadJustifyLength in class PadJustifyFieldSupportprotected void iSetValue(byte[] value)
value - byte[]public DynamicField clone()
clone in interface Entityclone in class EntitySupportpublic DynamicField.Bounds getBounds()
public void setBounds(DynamicField.Bounds bounds)
bounds - BoundsCopyright © 2008-2016 The Apache Software Foundation. All Rights Reserved.