| Modifier and Type | Field and Description |
|---|---|
| private int | |
| private int | |
| public static final String | VALUE_DELIMITER
Index range value delimiter. |
| Access | Constructor and Description |
|---|---|
| public | IndexRange(int
The start position of the range. start, int The end position of the range. end)Creates an instance of IndexRange representing the range between
|
| public | IndexRange(IndexRange
The IndexRange instance from which to copy the start and end
values. range)Creates an instance of IndexRange by copying the values from the given IndexRange object. |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | Returns: true if this object is equal to the object argument; false otherwise.the reference object with which to compare. object)Overrides java. Indicates whether some other object is "equal to" this one. |
| public int | Returns: the end position of the range (exclusive)Returns the end position of the range (exclusive). |
| public int | |
| public int | |
| public int | Returns: a hash code for thisRange object.Overrides java. Returns a hash code for this |
| public static IndexRange | Returns: A IndexRange instance where the smaller value is the start, and the larger value is the end.The first value to use in the range. v1, int The second value to use in the range. v2)Convenience method to create an IndexRange instance that has the smaller value as the start index, and the larger value as the end index. |
| public String | Returns: a string representation of thisRange object.Overrides java. Returns a string representation of this |
| public static IndexRange | Returns: An IndexRange instance representing the start and end values provided in the value string.The string to be parsed, and converted to an IndexRange. value)Convenience method to parse in a String of the form '2,6', which will create an IndexRange instance with a start value of 2, and an end value of 6. |
| end | back to summary |
|---|---|
| private int end | |
| start | back to summary |
|---|---|
| private int start | |
| VALUE_DELIMITER | back to summary |
|---|---|
| public static final String VALUE_DELIMITER Index range value delimiter. | |
| IndexRange | back to summary |
|---|---|
| public IndexRange(int start, int end) Creates an instance of IndexRange representing the range between
| |
| IndexRange | back to summary |
|---|---|
| public IndexRange(IndexRange range) Creates an instance of IndexRange by copying the values from the given IndexRange object.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object object) Overrides java. Indicates whether some other object is "equal to" this one. | |
| getEnd | back to summary |
|---|---|
| public int getEnd() Returns the end position of the range (exclusive).
| |
| getLength | back to summary |
|---|---|
| public int getLength() Returns the length of the range.
| |
| getStart | back to summary |
|---|---|
| public int getStart() Returns the start position of the range.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Returns a hash code for this
| |
| normalize | back to summary |
|---|---|
| public static IndexRange normalize(int v1, int v2) Convenience method to create an IndexRange instance that has the smaller value as the start index, and the larger value as the end index.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Returns a string representation of this | |
| valueOf | back to summary |
|---|---|
| public static IndexRange valueOf(String value) Convenience method to parse in a String of the form '2,6', which will create an IndexRange instance with a start value of 2, and an end value of 6.
| |