Planeshift
ProgressionScript Class Reference

ProgressionScript is the imperative script container. More...

#include <scripting.h>

Public Member Functions

const csString & GetName ()
 fetch the name of this progressionscript object More...
 
void Run (MathEnvironment *env)
 Run is executing the internally stored script. More...
 
 ~ProgressionScript ()
 default destructor deletes all internally stored script operation object More...
 

Static Public Member Functions

static ProgressionScriptCreate (EntityManager *entitymanager, CacheManager *cachemanager, const char *name, const char *script)
 create a progressionscript from a string containing a xml script More...
 
static ProgressionScriptCreate (EntityManager *entitymanager, CacheManager *cachemanager, const char *name, iDocumentNode *top)
 create a progressionscript from a xml script More...
 

Protected Member Functions

 ProgressionScript (const char *name)
 internal constructor for Create(). More...
 

Protected Attributes

csString name
 name of the script object (identifier?) More...
 
csArray< ImperativeOp * > ops
 script operation objects, warning: may have objects that contain further arrays of operations More...
 

Detailed Description

ProgressionScript is the imperative script container.

An imperative script is a one-shot script.

Definition at line 78 of file scripting.h.

Constructor & Destructor Documentation

ProgressionScript::~ProgressionScript ( )

default destructor deletes all internally stored script operation object

ProgressionScript::ProgressionScript ( const char *  name)
inlineprotected

internal constructor for Create().

Is constructor only available inside the class.

Parameters
nameof the script object (identifier ?)

Definition at line 126 of file scripting.h.

Member Function Documentation

static ProgressionScript* ProgressionScript::Create ( EntityManager entitymanager,
CacheManager cachemanager,
const char *  name,
const char *  script 
)
static

create a progressionscript from a string containing a xml script

Basically this function creates a xml script from the given string and then passes it on to the other Create function.

Parameters
entitymanagerof the psserver
cachemanagerof the psserver
nameof the progressionscript ?
scriptconst char* string containing the script to parse and store
static ProgressionScript* ProgressionScript::Create ( EntityManager entitymanager,
CacheManager cachemanager,
const char *  name,
iDocumentNode *  top 
)
static

create a progressionscript from a xml script

Parses the supplied xml script and creates and stores an object representation of the script.

Parameters
entitymanagerof the psserver
cachemanagerof the psserver
nameof the progressionscript ?
topxml iDocumentNode containing the script to parse and store
const csString& ProgressionScript::GetName ( )
inline

fetch the name of this progressionscript object

Returns
the name of the ProgressionScript

Definition at line 110 of file scripting.h.

void ProgressionScript::Run ( MathEnvironment env)

Run is executing the internally stored script.

Parameters
envis a container for passing variables to the script

Member Data Documentation

csString ProgressionScript::name
protected

name of the script object (identifier?)

Definition at line 128 of file scripting.h.

csArray<ImperativeOp*> ProgressionScript::ops
protected

script operation objects, warning: may have objects that contain further arrays of operations

Definition at line 129 of file scripting.h.


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