operator []= method

void operator []=(
  1. int index,
  2. ArchiveFile file
)

Set a file in the archive.

Implementation

void operator []=(int index, ArchiveFile file) {
  if (index < 0 || index >= _files.length) {
    return;
  }
  _fileMap.remove(_files[index].name);
  _files[index] = file;
  _fileMap[file.name] = index;
}