public final class FixedWidthStringParser
extends java.lang.Object
FixedWidthStringParser parser = new FixedWidthStringParser (myString); String field1 = parser.getField (12); String field2 = parser.getField (4); parser.reset (); ...
Constructor and Description |
---|
FixedWidthStringParser(java.lang.String string)
Create a new FixedWidthStringParser to parse the given String.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getField(int size)
Get the next field.
|
int |
getIntField(int size)
Get the next field as an int.
|
java.lang.String |
getRemaining()
Get whatever remains.
|
public FixedWidthStringParser(java.lang.String string)
string
- The String to parse.public java.lang.String getField(int size)
size
- The size of the field, in characters.public int getIntField(int size)
size
- The size of the field, in characters.public java.lang.String getRemaining()
Copyright ? 2002 Clarity Systems Group, LLC. All Rights Reserved.