Validates parameters defining a range of this CharArray. @param start the start index, inclusive @param end the end index, exclusive @return A valid end index. @throws IndexOutOfBoundsException if the index is invalid
(int start, int end)
| 2065 | * @return A valid end index. |
| 2066 | * @throws IndexOutOfBoundsException if the index is invalid */ |
| 2067 | protected int validateRange (int start, int end) { |
| 2068 | if (start < 0) throw new IndexOutOfBoundsException("start: " + start); |
| 2069 | if (end > size) throw new IndexOutOfBoundsException("end: " + end + ", size: " + size); |
| 2070 | if (start > end) throw new IndexOutOfBoundsException("start: " + start + ", end: " + end); |
| 2071 | return end; |
| 2072 | } |
| 2073 | |
| 2074 | /** Tests the contents of this CharArray against another to see if they contain the same character content. Returns false if |
| 2075 | * either array is unordered. |
no outgoing calls
no test coverage detected