ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

#include <mscab.h>

Inheritance diagram for Grim::MsCabinet:
Collaboration diagram for Grim::MsCabinet:

List of all members.

Classes

class  Decompressor
struct  FileEntry
struct  FolderEntry

Public Member Functions

 MsCabinet (Common::SeekableReadStream *data)
 ~MsCabinet ()
bool hasFile (const Common::String &name) const override
 Check if a member with the given name is present in the Archive.
int listMembers (Common::ArchiveMemberList &list) const override
 Add all members of the Archive to list.
const Common::ArchiveMemberPtr getMember (const Common::String &name) const override
 Returns a ArchiveMember representation of the given file.
Common::SeekableReadStreamcreateReadStreamForMember (const Common::String &name) const override
 Create a stream bound to a member with the specified name in the archive.

Private Types

typedef Common::HashMap
< Common::String, FileEntry,
Common::IgnoreCase_Hash,
Common::IgnoreCase_EqualTo
FileMap
typedef Common::HashMap
< uint16, FolderEntry
FolderMap
typedef Common::HashMap
< Common::String, byte
*, Common::IgnoreCase_Hash,
Common::IgnoreCase_EqualTo
CacheMap

Private Member Functions

Common::String readString (Common::ReadStream *stream)

Private Attributes

Common::SeekableReadStream_data
FileMap _fileMap
FolderMap _folderMap
Decompressor_decompressor
CacheMap _cache

Detailed Description

Definition at line 35 of file mscab.h.


Member Typedef Documentation

Definition at line 64 of file mscab.h.


Constructor & Destructor Documentation

Grim::MsCabinet::MsCabinet ( Common::SeekableReadStream data  ) 

Definition at line 45 of file mscab.cpp.

Grim::MsCabinet::~MsCabinet (  ) 

Definition at line 33 of file mscab.cpp.


Member Function Documentation

Common::SeekableReadStream * Grim::MsCabinet::createReadStreamForMember ( const Common::String name  )  const [override, virtual]

Create a stream bound to a member with the specified name in the archive.

If no member with this name exists, 0 is returned.

Returns:
the newly created input stream

Implements Common::Archive.

Definition at line 164 of file mscab.cpp.

const Common::ArchiveMemberPtr Grim::MsCabinet::getMember ( const Common::String name  )  const [override, virtual]

Returns a ArchiveMember representation of the given file.

Implements Common::Archive.

Definition at line 160 of file mscab.cpp.

bool Grim::MsCabinet::hasFile ( const Common::String name  )  const [override, virtual]

Check if a member with the given name is present in the Archive.

Patterns are not allowed, as this is meant to be a quick File::exists() replacement.

Implements Common::Archive.

Definition at line 149 of file mscab.cpp.

int Grim::MsCabinet::listMembers ( Common::ArchiveMemberList list  )  const [override, virtual]

Add all members of the Archive to list.

Must only append to list, and not remove elements from it.

Returns:
the number of names added to list

Implements Common::Archive.

Definition at line 153 of file mscab.cpp.

Common::String Grim::MsCabinet::readString ( Common::ReadStream stream  )  [private]

Definition at line 138 of file mscab.cpp.


Member Data Documentation

CacheMap Grim::MsCabinet::_cache [mutable, private]

Definition at line 99 of file mscab.h.

Definition at line 47 of file mscab.h.

Definition at line 95 of file mscab.h.

Definition at line 62 of file mscab.h.

Definition at line 65 of file mscab.h.


The documentation for this class was generated from the following files:


Generated on Sat May 18 2019 05:06:37 for ResidualVM by doxygen 1.7.1
curved edge   curved edge