recalcBitMap method

void recalcBitMap([
  1. int bitmapIndex = 1
])

Rebuilds the bitmap component at bitmapIndex from the fields present. A no-op while the message is unchanged, exactly as in the Java.

Implementation

void recalcBitMap([int bitmapIndex = 1]) {
  if (!_dirty || bitmapIndex < 0) return;
  final int highest = maxField < 192 ? maxField : 192;
  final IsoBitSet bitmap = IsoBitSet();
  for (int i = bitmapIndex + 1; i <= highest; i++) {
    if (fields[i] != null) bitmap.set(i);
  }
  setComponent(bitmapIndex, IsoBitMapField(bitmap));
  _dirty = false;
}