public class FixedWidthRecord
extends java.lang.Object
| Constructor and Description |
|---|
FixedWidthRecord(java.lang.String spec)
Formats data into fixed width strings
name begin end filler align, ...
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
get(java.lang.String name)
Gets the value for the given field name, if no value is set returns empty string
|
void |
set(java.lang.String name,
java.lang.String value)
Sets the named value, 'name' should be the same as a field name in the spec
|
java.lang.String |
toString()
Formats the data into a fixed width string using the spec.
|
public FixedWidthRecord(java.lang.String spec)
spec - the field specpublic void set(java.lang.String name,
java.lang.String value)
name - the field namevalue - the field valuepublic java.lang.String get(java.lang.String name)
name - the field name@CheckReturnValue @Nonnull public java.lang.String toString()
toString in class java.lang.ObjectstSoftware Copyright © 2001-2014 stSoftware All Rights Reserved.