setIntExtended method

void setIntExtended(
  1. int value,
  2. int numOfBytes,
  3. Endian endianness
)

Implementation

void setIntExtended(int value, int numOfBytes, Endian endianness) {
  var byteListTmp = Uint8List(4);
  var byteArrayTmp = _getByteData(byteListTmp);
  if (numOfBytes == 3) {
    byteArrayTmp.setInt32(0, value, endianness);
  } else {
    throw Exception('Unsupported num of bytes: $numOfBytes');
  }
  byteList.setRange(offset, offset + numOfBytes, byteListTmp);
}