Writes an unsigned 16 bit value to the specified position in the stream. @param val The value to be written @param where The position to write the value.
(int val, int where)
| 130 | * @param where The position to write the value. |
| 131 | */ |
| 132 | public void |
| 133 | writeU16At(int val, int where) { |
| 134 | check(val, 16); |
| 135 | if (where > pos - 2) |
| 136 | throw new IllegalArgumentException("cannot write past " + |
| 137 | "end of data"); |
| 138 | array[where++] = (byte)((val >>> 8) & 0xFF); |
| 139 | array[where++] = (byte)(val & 0xFF); |
| 140 | } |
| 141 | |
| 142 | /** |
| 143 | * Writes an unsigned 32 bit value to the stream. |
no test coverage detected