(int index)
| 364 | } |
| 365 | |
| 366 | void setIndex(int index) { |
| 367 | if (this.index != -1) { |
| 368 | throw new IllegalStateException("index already set"); |
| 369 | } |
| 370 | if (index < 0) { |
| 371 | throw new IllegalArgumentException( |
| 372 | "index must be 0 or positive number, given: " + index); |
| 373 | } |
| 374 | this.index = index; |
| 375 | } |
| 376 | |
| 377 | @Override |
| 378 | public int getIndex() { |
nothing calls this directly
no outgoing calls
no test coverage detected