Puts a byte and a short into this byte vector. The byte vector is automatically enlarged if necessary. @param byteValue a byte. @param shortValue a short. @return this byte vector.
(final int byteValue, final int shortValue)
| 127 | * @return this byte vector. |
| 128 | */ |
| 129 | final ByteVector put12(final int byteValue, final int shortValue) { |
| 130 | int currentLength = length; |
| 131 | if (currentLength + 3 > data.length) { |
| 132 | enlarge(3); |
| 133 | } |
| 134 | byte[] currentData = data; |
| 135 | currentData[currentLength++] = (byte) byteValue; |
| 136 | currentData[currentLength++] = (byte) (shortValue >>> 8); |
| 137 | currentData[currentLength++] = (byte) shortValue; |
| 138 | length = currentLength; |
| 139 | return this; |
| 140 | } |
| 141 | |
| 142 | /** |
| 143 | * Puts two bytes and a short into this byte vector. The byte vector is automatically enlarged if |
no test coverage detected