Method Class Reference

#include <Ample.h>

Inheritance diagram for Method:
Inheritance graph
[legend]
Collaboration diagram for Method:
Collaboration graph
[legend]

List of all members.

Public Types

typedef Observer< MethodObserverObserverType
typedef std::vector
< MethodObserver * > 
ObserverList

Public Member Functions

void destroy (void)
bool call (const MethodArgumentList &arguments, VNodeID senderID=(VNodeID)~0)
uint16 getID (void) const
const std::string & getName (void) const
void setName (const std::string &name)
uint8 getParamCount (void) const
const MethodParamgetParam (uint8 index)
MethodGroupgetGroup (void) const
unsigned int getDataVersion (void) const
unsigned int getStructureVersion (void) const
void addObserver (MethodObserver &observer)
void removeObserver (MethodObserver &observer)
void removeObserver (Observer< MethodObserver > &observer)
const ObserverListgetObservers (void) const

Friends

class MethodGroup

Detailed Description

Object method. Represents a single method in an object node.


Member Typedef Documentation

typedef std::vector<MethodObserver *> ObserverList [inherited]
typedef Observer<MethodObserver > ObserverType [inherited]

Member Function Documentation

void addObserver ( MethodObserver observer  )  [inline, inherited]

Adds the specified observer to this object.

Parameters:
observer The observer to add.
Remarks:
An observer can only be added once. Additional additions are ignored.
bool call ( const MethodArgumentList arguments,
VNodeID  senderID = (VNodeID)~0 
)

Issues a call to this method with the specified arguments.

Remarks:
This call is asynchronous. It will not take effect until, at the earliest, after the first subsequent call to Session::update.
void destroy ( void   ) 

Destroys this method.

Remarks:
This call is asynchronous. It will not take effect until, at the earliest, after the first subsequent call to Session::update.
unsigned int getDataVersion ( void   )  const [inherited]
Returns:
The current version of the internal state.
Remarks:
This value is updated for any kind of change.
MethodGroup& getGroup ( void   )  const
Returns:
The method group containing this method.
uint16 getID ( void   )  const
Returns:
The ID of this object method.
const std::string& getName ( void   )  const
Returns:
The name of this object method.
const ObserverList& getObservers ( void   )  const [inline, inherited]
Returns:
The list of observers attached to this object.
const MethodParam& getParam ( uint8  index  ) 
Parameters:
index The index of the desired parameter.
Returns:
The parameter with the specified index.
uint8 getParamCount ( void   )  const
Returns:
The number of parameters for this method.
unsigned int getStructureVersion ( void   )  const [inherited]
Returns:
The current version of the internal structure.
Remarks:
This value is only updated when the internal structure changes.
void removeObserver ( Observer< MethodObserver > &  observer  )  [inline, inherited]

Removes the specified observer from this object.

Parameters:
observer The observer to remove.
void removeObserver ( MethodObserver observer  )  [inline, inherited]

Removes the specified observer from this object.

Parameters:
observer The observer to remove.
void setName ( const std::string &  name  ) 

Friends And Related Function Documentation

friend class MethodGroup [friend]

Reimplemented from Versioned.


Generated on Thu Nov 19 20:19:28 2009 for Ample by  doxygen 1.6.1