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

Utility class for reading and writing the save file header. More...

#include <savemetadata.h>

Collaboration diagram for Stark::SaveMetadata:

List of all members.

Public Member Functions

 SaveMetadata ()
void setSaveTime (const TimeDate &timeDate)
 Set the time the save was created on.
Common::ErrorCode read (Common::SeekableReadStream *stream, const Common::String &filename)
 Read the metadata from a stream.
void write (Common::WriteStream *stream)
 Write the metadata to a stream.
Graphics::SurfacereadGameScreenThumbnail (Common::SeekableReadStream *stream)
 Read the game screen thumbnail from a stream.
void skipGameScreenThumbnail (Common::SeekableReadStream *stream)
 Skip the game screen thumbnail in a stream.
void writeGameScreenThumbnail (Common::WriteStream *stream)
 Write the game screen thumbnail to a stream.

Public Attributes

Common::String description
uint levelIndex
uint locationIndex
uint version
uint32 totalPlayTime
uint8 saveDay
uint8 saveMonth
uint16 saveYear
uint8 saveHour
uint8 saveMinute
uint8 saveSecond
const Graphics::SurfacegameWindowThumbnail

Private Member Functions

void saveLoad (ResourceSerializer *s)
Common::ErrorCode syncVersion (ResourceSerializer *s)

Static Private Member Functions

static void syncResourceIndexAsString (ResourceSerializer *s, uint &index)

Private Attributes

Common::String _readFilename
Common::ErrorCode _readErrorCode

Detailed Description

Utility class for reading and writing the save file header.

The save file header contains metadata related to the save as well as a thumbnail of the game screen.

Definition at line 39 of file savemetadata.h.


Constructor & Destructor Documentation

Stark::SaveMetadata::SaveMetadata (  ) 

Definition at line 33 of file savemetadata.cpp.


Member Function Documentation

Common::ErrorCode Stark::SaveMetadata::read ( Common::SeekableReadStream stream,
const Common::String filename 
)

Read the metadata from a stream.

Parameters:
filename Save filename, used for the error messages only

Definition at line 72 of file savemetadata.cpp.

Graphics::Surface * Stark::SaveMetadata::readGameScreenThumbnail ( Common::SeekableReadStream stream  ) 

Read the game screen thumbnail from a stream.

Definition at line 133 of file savemetadata.cpp.

void Stark::SaveMetadata::saveLoad ( ResourceSerializer s  )  [private]

Definition at line 48 of file savemetadata.cpp.

void Stark::SaveMetadata::setSaveTime ( const TimeDate timeDate  ) 

Set the time the save was created on.

Definition at line 113 of file savemetadata.cpp.

void Stark::SaveMetadata::skipGameScreenThumbnail ( Common::SeekableReadStream stream  ) 

Skip the game screen thumbnail in a stream.

Definition at line 129 of file savemetadata.cpp.

void Stark::SaveMetadata::syncResourceIndexAsString ( ResourceSerializer s,
uint index 
) [static, private]

Definition at line 84 of file savemetadata.cpp.

Common::ErrorCode Stark::SaveMetadata::syncVersion ( ResourceSerializer s  )  [private]

Definition at line 92 of file savemetadata.cpp.

void Stark::SaveMetadata::write ( Common::WriteStream stream  ) 

Write the metadata to a stream.

Definition at line 79 of file savemetadata.cpp.

void Stark::SaveMetadata::writeGameScreenThumbnail ( Common::WriteStream stream  ) 

Write the game screen thumbnail to a stream.

Definition at line 122 of file savemetadata.cpp.


Member Data Documentation

Definition at line 86 of file savemetadata.h.

Definition at line 47 of file savemetadata.h.

Definition at line 44 of file savemetadata.h.


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


Generated on Sat May 18 2019 05:07:16 for ResidualVM by doxygen 1.7.1
curved edge   curved edge