public class FirstPosition extends java.lang.Object implements Position
| Constructor and Description |
|---|
FirstPosition(Position one,
Position two)
Constructor
|
FirstPosition(java.lang.String one,
Position two)
Constructor
|
FirstPosition(java.lang.String one,
java.lang.String two)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
int |
getLength()
get the length of the position returned by
Position.getPosition(String, int) |
int |
getPosition(java.lang.String line,
int begin)
get a position in a line, not before begin or return -1
|
public FirstPosition(java.lang.String one,
java.lang.String two)
one - String, the first String to find the position fortwo - String, the second String to find the position forpublic FirstPosition(java.lang.String one,
Position two)
one - String, the first String to find the position fortwo - Position, the second Position to find the position forpublic int getPosition(java.lang.String line,
int begin)
getPosition in interface Positionline - String, the line to find the position inbegin - int, the location to start frompublic int getLength()
PositionPosition.getPosition(String, int)