public final class FormattingInfo extends Object
Modifier and Type | Field and Description |
---|---|
private static FormattingInfo |
DEFAULT
Default instance.
|
private boolean |
leftAlign
Alignment.
|
private int |
maxLength
Maximum length.
|
private int |
minLength
Minimum length.
|
private static char[] |
SPACES
Array of spaces.
|
Constructor and Description |
---|
FormattingInfo(boolean leftAlign,
int minLength,
int maxLength)
Creates new instance.
|
Modifier and Type | Method and Description |
---|---|
void |
format(int fieldStart,
StringBuffer buffer)
Adjust the content of the buffer based on the specified lengths and alignment.
|
static FormattingInfo |
getDefault()
Gets default instance.
|
int |
getMaxLength()
Get maximum length.
|
int |
getMinLength()
Get minimum length.
|
boolean |
isLeftAligned()
Determine if left aligned.
|
private static final char[] SPACES
private static final FormattingInfo DEFAULT
private final int minLength
private final int maxLength
private final boolean leftAlign
public FormattingInfo(boolean leftAlign, int minLength, int maxLength)
leftAlign
- left align if true.minLength
- minimum length.maxLength
- maximum length.public static FormattingInfo getDefault()
public boolean isLeftAligned()
public int getMinLength()
public int getMaxLength()
public void format(int fieldStart, StringBuffer buffer)
fieldStart
- start of field in buffer.buffer
- buffer to be modified.WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses