code: public void write(BitOutputStream os, boolean isLast) throws IOException {
  
          os.writeRawUInt(isLast, STREAM_METADATA_IS_LAST_LEN);
          os.writeRawUInt(METADATA_TYPE_STREAMINFO, STREAM_METADATA_TYPE_LEN);
          os.writeRawUInt(calcLength(), STREAM_METADATA_LENGTH_LEN);
  
          os.writeRawUInt(minBlockSize, STREAMINFO_MIN_BLOCK_SIZE_LEN);
          os.writeRawUInt(maxBlockSize, STREAMINFO_MAX_BLOCK_SIZE_LEN);
          os.writeRawUInt(minFrameSize, STREAMINFO_MIN_FRAME_SIZE_LEN);
          os.writeRawUInt(maxFrameSize, STREAMINFO_MAX_FRAME_SIZE_LEN);
          os.writeRawUInt(sampleRate, STREAMINFO_SAMPLE_RATE_LEN);
          os.writeRawUInt(channels - 1, STREAMINFO_CHANNELS_LEN);
          os.writeRawULong(bitsPerSample - 1, STREAMINFO_BITS_PER_SAMPLE_LEN);
          os.writeRawULong(totalSamples, STREAMINFO_TOTAL_SAMPLES_LEN);
          os.writeByteBlock(md5sum, md5sum.length);
          os.flushByteAligned();
      }
docs: Write out the metadata block.
  @param os    The output stream
  @param isLast    True if this is the last metadata block
  @throws IOException  Thrown if error writing data