Public Member Functions | Static Public Member Functions

story::Story Class Reference
[Story Library]

This is the high-level story object. More...

#include <story.h>

Inheritance diagram for story::Story:
Inheritance graph

List of all members.

Public Member Functions

virtual ~Story (void) throw ()
virtual const char * getUuid (void) const =0 throw ()
 every story must have a universally unique ID
virtual const char * getTitle (void) const =0 throw ()
 short title (preferably 16 characters or less!)
virtual const char * getStartingMapId (void) const =0 throw ()
 return the ID of the starting map (game starts here)
virtual std::string getObjectPath (const char *objectType, const char *objectId) const =0
 Given an object ID, and type of object, return the path.
virtual smart_ptr< i18n::ManagergetI18nManager (const char *path)=0
 given the locale-relative path, return an i18n::Manager object Example: getI18nManager("converse/system.txt")

Static Public Member Functions

static smart_ptr< Storycreate (const char *locale, const char *story_dir)

Detailed Description

This is the high-level story object.


Story objects exist to help get IDs and absolute paths to local persisted objects relevant to the story being told. The goal is that a story object is pointed at a local directory (containing the full story files), and the Story object handles all the details where objects are persisted within that directory structure. The Story object also understands (and exposes) some Story-level concepts.

For instance, a Story object can tell you the ID of the starting map for the story. Given a map ID, the Story object can tell you the full path that map on local disk.

The Story object can NOT:

The story library should never depend on any aesop libraries. This should be a simple leaf library.

All methods must be threadsafe! This should be no big deal since all methods are typically const anyway.

Definition at line 91 of file story.h.

Constructor & Destructor Documentation

story::Story::~Story ( void   )  throw () [virtual]

Definition at line 43 of file story.cpp.

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