CueSheet constructor

CueSheet(
  1. bool isLast,
  2. Uint8List rawData,
  3. int dataLength
)

create CueSheet

NULL if num_tracks == 0, else pointer to array of tracks

Implementation

CueSheet(bool isLast, Uint8List rawData, int dataLength)
    : super(BlockType.CUESHEET, isLast, rawData, dataLength) {
  mediaCatalogNumber = _reader.getUint8List(MEDIA_CATALOG_NUMBER_SIZE);
  leadIn = _reader.getInt(LEAD_IN_SIZE);
  isCD = _reader.getInt(IS_CD_SIZE) != 0;
  _reader.skip(RESERVED_SIZE);
  numTracks = _reader.getInt(NUM_TRACKS_SIZE);
  if (numTracks > 0) {
    for (var i = 0; i < numTracks; i++) {
      var cueTrack = CueTrack(_reader);
      tracks.add(cueTrack);
    }
  }
}