gusimplewhiteboard
guWhiteboard::iOSWhiteboard Class Reference

compatibility API for accessing the remote whiteboard More...

#include <iOSWhiteboard.h>

Collaboration diagram for guWhiteboard::iOSWhiteboard:

Public Types

enum  remote_wb_id {
  Machine1 = 0 , Machine2 , Machine3 , Machine4 ,
  Global
}
 Remote WB enum. More...
 
enum  wb_method_result { METHOD_OK , METHOD_FAIL }
 Return Type Enum. More...
 
typedef enum guWhiteboard::iOSWhiteboard::remote_wb_id RWBMachine
 Remote WB enum. More...
 
typedef enum guWhiteboard::iOSWhiteboard::wb_method_result WBResult
 Return Type Enum. More...
 

Public Member Functions

 iOSWhiteboard ()
 API Constructor This sets up the API. More...
 
 ~iOSWhiteboard ()
 Destructor. More...
 
void injectRemoteMessage (const std::string &type, const WBMsg &msg, RWBMachine machine)
 Inject Message Adds a message to a remote whiteboard that the API is connected to. More...
 
void addReplicationType (const std::string &type, RWBMachine machine)
 Add Message Adds a message to the whiteboard that the API is connected to. More...
 
WBMsg getMessage (std::string type, RWBMachine machine, WBResult *result=NULL)
 Get Message Gets a message from a remote simple whiteboard. More...
 
std::vector< std::string > getKnownTypesForMachine (RWBMachine machine)
 Get Known Types For Machine Gets all the currently known types for a machine. More...
 

Detailed Description

compatibility API for accessing the remote whiteboard

Definition at line 77 of file iOSWhiteboard.h.

Member Typedef Documentation

◆ RWBMachine

Remote WB enum.

Allows the user specify a remote wb to talk about

◆ WBResult

Return Type Enum.

Allows the user to test if an error has occured

Member Enumeration Documentation

◆ remote_wb_id

Remote WB enum.

Allows the user specify a remote wb to talk about

Enumerator
Machine1 
Machine2 
Machine3 
Machine4 
Global 

Definition at line 102 of file iOSWhiteboard.h.

◆ wb_method_result

Return Type Enum.

Allows the user to test if an error has occured

Enumerator
METHOD_OK 

No errors detected.

METHOD_FAIL 

Errors detected.

Definition at line 115 of file iOSWhiteboard.h.

Constructor & Destructor Documentation

◆ iOSWhiteboard()

iOSWhiteboard::iOSWhiteboard ( )

API Constructor This sets up the API.

Definition at line 68 of file iOSWhiteboard.cc.

◆ ~iOSWhiteboard()

iOSWhiteboard::~iOSWhiteboard ( )

Destructor.

shuts down the whiteboard

Definition at line 104 of file iOSWhiteboard.cc.

Member Function Documentation

◆ addReplicationType()

void iOSWhiteboard::addReplicationType ( const std::string &  type,
RWBMachine  machine 
)

Add Message Adds a message to the whiteboard that the API is connected to.

Parameters
[in]typeThe string type associated with the message object
[in]machineTarget machine id

Definition at line 206 of file iOSWhiteboard.cc.

◆ getKnownTypesForMachine()

std::vector< std::string > iOSWhiteboard::getKnownTypesForMachine ( RWBMachine  machine)

Get Known Types For Machine Gets all the currently known types for a machine.

Parameters
[in]machineThe target machine id / player number
Returns
A vector of string containing the types

Definition at line 216 of file iOSWhiteboard.cc.

◆ getMessage()

WBMsg iOSWhiteboard::getMessage ( std::string  type,
RWBMachine  machine,
WBResult result = NULL 
)

Get Message Gets a message from a remote simple whiteboard.

Parameters
[in]typeThe string type associated with the message object
[in]machineThe target machine id / player number
[out]resultA pointer (!) to WBResult to indicate whether a message existed or not
Returns
The message object

Definition at line 211 of file iOSWhiteboard.cc.

◆ injectRemoteMessage()

void iOSWhiteboard::injectRemoteMessage ( const std::string &  type,
const WBMsg msg,
RWBMachine  machine 
)

Inject Message Adds a message to a remote whiteboard that the API is connected to.

Parameters
[in]typeThe string type associated with the message object
[in]msg
[in]machineTarget machine id

Definition at line 189 of file iOSWhiteboard.cc.


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