rllib
1
|
#include <rldataprovider.h>
Public Member Functions | |
rlDataProvider (int numInteger, int numFloat=0, int numString=0) | |
virtual | ~rlDataProvider () |
int | getInt (int id) |
float | getFloat (int id) |
int | getIntArray (int id, int *i, int nmax) |
int | getFloatArray (int id, float *f, int nmax) |
const char * | getString (int id) |
int | setInt (int id, int i) |
int | setFloat (int id, float f) |
int | setIntArray (int id, int *i, int num) |
int | setFloatArray (int id, float *f, int num) |
int | setString (int id, const char *str) |
int | getIntAndReset (int id) |
int | setIntAndWaitForReset (int id, int i) |
int | setInt0Semaphore (int i) |
int | getInt0Semaphore () |
int | run (rlSocket *socket) |
Private Types | |
typedef char * | CHARPTR |
Private Attributes | |
int * | ints |
float * | floats |
char ** | strings |
int | num_integer |
int | num_float |
int | num_string |
rlMutex | mutex |
rlSemaphore | int0semaphore |
This class is a container for data. You can get/set the data identified by id. The run method starts a separate thread that makes rlDataProvider available over TCP.
Definition at line 29 of file rldataprovider.h.
|
private |
Definition at line 50 of file rldataprovider.h.
rlDataProvider::rlDataProvider | ( | int | numInteger, |
int | numFloat = 0 , |
||
int | numString = 0 |
||
) |
Definition at line 20 of file rldataprovider.cpp.
|
virtual |
Definition at line 54 of file rldataprovider.cpp.
float rlDataProvider::getFloat | ( | int | id | ) |
Definition at line 79 of file rldataprovider.cpp.
int rlDataProvider::getFloatArray | ( | int | id, |
float * | f, | ||
int | nmax | ||
) |
Definition at line 116 of file rldataprovider.cpp.
int rlDataProvider::getInt | ( | int | id | ) |
Definition at line 67 of file rldataprovider.cpp.
int rlDataProvider::getInt0Semaphore | ( | ) |
Definition at line 263 of file rldataprovider.cpp.
int rlDataProvider::getIntAndReset | ( | int | id | ) |
Definition at line 223 of file rldataprovider.cpp.
int rlDataProvider::getIntArray | ( | int | id, |
int * | i, | ||
int | nmax | ||
) |
Definition at line 91 of file rldataprovider.cpp.
const char * rlDataProvider::getString | ( | int | id | ) |
Definition at line 141 of file rldataprovider.cpp.
int rlDataProvider::run | ( | rlSocket * | socket | ) |
Definition at line 269 of file rldataprovider.cpp.
int rlDataProvider::setFloat | ( | int | id, |
float | f | ||
) |
Definition at line 163 of file rldataprovider.cpp.
int rlDataProvider::setFloatArray | ( | int | id, |
float * | f, | ||
int | num | ||
) |
Definition at line 192 of file rldataprovider.cpp.
int rlDataProvider::setInt | ( | int | id, |
int | i | ||
) |
Definition at line 153 of file rldataprovider.cpp.
int rlDataProvider::setInt0Semaphore | ( | int | i | ) |
Definition at line 254 of file rldataprovider.cpp.
int rlDataProvider::setIntAndWaitForReset | ( | int | id, |
int | i | ||
) |
Definition at line 236 of file rldataprovider.cpp.
int rlDataProvider::setIntArray | ( | int | id, |
int * | i, | ||
int | num | ||
) |
Definition at line 173 of file rldataprovider.cpp.
int rlDataProvider::setString | ( | int | id, |
const char * | str | ||
) |
Definition at line 211 of file rldataprovider.cpp.
|
private |
Definition at line 52 of file rldataprovider.h.
|
private |
Definition at line 56 of file rldataprovider.h.
|
private |
Definition at line 51 of file rldataprovider.h.
|
private |
Definition at line 55 of file rldataprovider.h.
|
private |
Definition at line 54 of file rldataprovider.h.
|
private |
Definition at line 54 of file rldataprovider.h.
|
private |
Definition at line 54 of file rldataprovider.h.
|
private |
Definition at line 53 of file rldataprovider.h.