getInitSegmentReference_(playlist, tags, getUris, variables) {
    /** @type {?shaka.hls.Tag} */
    const mapTag = shaka.hls.Utils.getFirstTagWithName(tags, 'EXT-X-MAP');

    if (!mapTag) {
      return null;
    }
    // Map tag example: #EXT-X-MAP:URI="main.mp4",BYTERANGE="720@0"
    const verbatimInitSegmentUri = mapTag.getRequiredAttrValue('URI');
    const absoluteInitSegmentUris = shaka.hls.Utils.constructSegmentUris(
        getUris(), verbatimInitSegmentUri, variables);

    const mapTagKey = [
      absoluteInitSegmentUris.toString(),
      mapTag.getAttributeValue('BYTERANGE', ''),
    ].join('-');
    if (!this.mapTagToInitSegmentRefMap_.has(mapTagKey)) {
      /** @type {shaka.extern.aesKey|undefined} */
      let aesKey = undefined;
      let byteRangeTag = null;
      let encrypted = false;
      for (const tag of tags) {
        if (tag.name == 'EXT-X-KEY') {
          const method = tag.getRequiredAttrValue('METHOD');
          if (this.isAesMethod_(method) && tag.id < mapTag.id) {
            encrypted = false;
            aesKey =
                this.parseAESDrmTag_(tag, playlist, getUris, variables);
          } else {
            encrypted = method != 'NONE';
          }
        } else if (tag.name == 'EXT-X-BYTERANGE' && tag.id < mapTag.id) {
          byteRangeTag = tag;
        }
      }
      const initSegmentRef = this.createInitSegmentReference_(
          absoluteInitSegmentUris, mapTag, byteRangeTag, aesKey, encrypted);
      this.mapTagToInitSegmentRefMap_.set(mapTagKey, initSegmentRef);
    }
    return this.mapTagToInitSegmentRefMap_.get(mapTagKey);
  }
Get the InitSegmentReference for a segment if it has a EXT-X-MAP tag.
@param {!shaka.hls.Playlist} playlist
@param {!Array<!shaka.hls.Tag>} tags Segment tags
@param {function(): !Array<string>} getUris
@param {?Map<string, string>=} variables
@return {shaka.media.InitSegmentReference}
@private