For the most part use a Wad like you would a std::list, as that is its base class anyway. It adds functions to manage its type and adds operator overloading. It can also read and write to files, including reading from a file in its constructor.
Definition at line 84 of file wad.hpp.
Public Types | |
| enum | wad_type { IWAD, PWAD } |
| Two types of Wads allowed by Doom. | |
Public Member Functions | |
| wad_type | getType (void) const throw () |
| Get the type. | |
| std::string | getWadDirectory (char= '\n') const throw () |
| Get a directory of the wad. | |
| bool | isIwad (void) const throw () |
| See if this is an IWAD. | |
| bool | isPwad (void) const throw () |
| See if this is a PWAD. | |
| bool | operator!= (const Wad &) const throw () |
| Inequality comparison operator. | |
| Wad | operator+ (const Wad &) const throw () |
| Concatenation operator, make new wad. | |
| Wad & | operator+= (const Wad &) throw () |
| Concatenation operator. | |
| bool | operator== (const Wad &) const throw () |
| Equality comparison operator. | |
| bool | readFromFile (const std::string &) throw () |
| Read wad from a file. | |
| bool | setType (wad_type) throw () |
| Set the type. | |
| Wad (const Lump &, wad_type=PWAD) throw () | |
| Construct from a single lump and a type. | |
| Wad (const std::string &) throw () | |
| Construct from a wad file. | |
| Wad (wad_type) throw () | |
| Construct with a type. | |
| Wad (void) throw () | |
| Default constructor. | |
| bool | writeToFile (const std::string &) const throw () |
| Write wad to a file. | |
Protected Attributes | |
| wad_type | m_type |
| Type of this Wad. | |
|
|
Construct with a type.
|
|
|
Construct from a wad file.
Definition at line 69 of file wad.cpp. References readFromFile(). |
|
||||||||||||
|
Construct from a single lump and a type.
|
|
|
Get the type.
Definition at line 193 of file wad.cpp. References m_type. |
|
|
Get a directory of the wad. Returns a std::string object containing the names of the Lumps in this Wad separated by the given delimiter. The default delimiter is a newline.
Definition at line 221 of file wad.cpp. Referenced by Doomwad::WadGroup::getMasterDirectory(). |
|
|
See if this is an IWAD.
Definition at line 173 of file wad.cpp. References m_type. |
|
|
See if this is a PWAD.
Definition at line 183 of file wad.cpp. References m_type. |
|
|
Inequality comparison operator.
|
|
|
Concatenation operator, make new wad.
|
|
|
Concatenation operator.
|
|
|
Equality comparison operator. Compares two wads for equality. Uses short-circuit logic to speed up the operation whenever possible.
|
|
|
Read wad from a file. Reads data from a file and constructs Wad data from it. This operation is not atomic (yet).
Definition at line 352 of file wad.cpp. References Doomwad::Lump::assign(), m_type, and Doomwad::Lump::setName(). Referenced by Wad(). |
|
|
Set the type.
|
|
|
Write wad to a file. Writes this Wad object to a file. If the file exists it erases it.
|
1.4.0