ARPDAS_QNX6 1.0
|
#include <DG_cmd.h>
Public Member Functions | |
DG_cmd (data_generator *data_gen) | |
~DG_cmd () | |
void | attach () |
int | execute (char *buf) |
int | ready_to_quit () |
Static Public Attributes | |
static int const | DG_CMD_BUFSIZE = 80 |
Private Attributes | |
int | dev_id |
data_generator * | dg |
Static Private Attributes | |
static iofunc_attr_t | cmd_attr |
static resmgr_connect_funcs_t | connect_funcs |
static resmgr_io_funcs_t | io_funcs |
DG_cmd::DG_cmd | ( | data_generator * | data_gen | ) |
void DG_cmd::attach | ( | ) |
Definition at line 35 of file DG_cmd.cc.
References cmd_attr, connect_funcs, dev_id, dg, DG_CMD_BUFSIZE, DG_cmd_io_write(), data_generator::dispatch, DG_dispatch::dpp, dpp, io_funcs, nl_error, resmgr_attr, and tm_dev_name().
Referenced by data_generator::init().
int DG_cmd::execute | ( | char * | buf | ) |
buf is guaranteed to be nul-terminated We will strip any trailing newlines before forwarding to dg->execute()
Definition at line 23 of file DG_cmd.cc.
References assert, dg, and data_generator::execute().
Referenced by DG_cmd_io_write().
int DG_cmd::ready_to_quit | ( | ) | [virtual] |
DG_cmd::ready_to_quit() returns true if we are ready to terminate. For DG/cmd, that means all writers have closed their connections and we have detached the device.
Implements DG_dispatch_client.
Definition at line 97 of file DG_cmd.cc.
References cmd_attr, dev_id, DG_dispatch_client::dispatch, DG_dispatch::dpp, and nl_error.
iofunc_attr_t DG_cmd::cmd_attr [static, private] |
Definition at line 13 of file DG_cmd.h.
Referenced by attach(), and ready_to_quit().
resmgr_connect_funcs_t DG_cmd::connect_funcs [static, private] |
int DG_cmd::dev_id [private] |
Definition at line 11 of file DG_cmd.h.
Referenced by attach(), and ready_to_quit().
data_generator* DG_cmd::dg [private] |
int const DG_cmd::DG_CMD_BUFSIZE = 80 [static] |
Definition at line 22 of file DG_cmd.h.
Referenced by attach(), and DG_cmd_io_write().
resmgr_io_funcs_t DG_cmd::io_funcs [static, private] |