tcsCMD_PARALLEL
Section: Devices and Network Interfaces (4)
Updated: 2012-04-23 10:08
Index
Return to man pages list
NAME
tcsCMD_PARALLEL - send list of commands in parallel
SYNOPSIS
#include "tcsCMD_PARALLEL.h"
tcsCMD_PARALLEL cmd;
PARENT CLASS
evhSIMPLE_TASK
DESCRIPTION
This class serves to send various commands in parallel to various targets
and collect all the replies. Whan all replies have been received,
a final reply is passed to the user call-backs. The final reply is based on the
original message, passed as the <orgMsg> argument to the Send() method,
such that it looks for the user as getting a reply to <orgMsg>. The final reply
message buffer is "OK" in the case of success.
PUBLIC METHODS
tcsCMD_PARALLEL();
The constructor initializes the object.
~tcsCMD_PARALLEL();
The destructor does a Reset() of the object.
ccsCOMPL_STAT SetCompletedCB(evhCALLBACK &cb);
Install the given call-back <cb> to be called on normal replies.
ccsCOMPL_STAT SetErrorCB(evhCALLBACK &cb);
Install the given call-back <cb> to be called on error replies.
ccsCOMPL_STAT SetTimeoutCB(evhCALLBACK &cb, ccsTIMEVAL &timeout);
Install the given call-back <cb> to be called on command timeout and
defines the timeout interval.
ccsCOMPL_STAT SetTimeout(ccsTIMEVAL &timeout);
Defines just the timeout interval.
ccsTIMEVAL GetTimeout();
Returns the set timeout;
ccsCOMPL_STAT Send();
Send commands as given by AddMessage
reply on <orgMsg>.
virtual ccsCOMPL_STAT Reset();
Reset the object and de-install all call-backs of pending commands.
virtual vltLOGICAL Status();
Returns TRUE if at least one command is still pending, otherwise FALSE.
PROTECTED METHODS
virtual evhCB_COMPL_STAT ReplyCB(msgMESSAGE &msg, void *);
virtual evhCB_COMPL_STAT ErrReplyCB(msgMESSAGE &msg, void *);
virtual evhCB_COMPL_STAT TimeoutCB(msgMESSAGE &msg, void *);
Internal handlers for replies, error replies and timeouts.
virtual const fndLIST &GetCmdList() const;
virtual ccsCOMPL_STAT RunCompleted(const msgMESSAGE &);
virtual ccsCOMPL_STAT RunError(const msgMESSAGE &);
PRIVATE DATA MEMBERS
vltINT32 numCmds; // number of commands handled in parallel
vltINT32 numWait; // number of replies still pending
ccsTIMEVAL timeout; // overall timeout on waiting for replies
fndLIST cmdList; // list of commands handled in parallel
fndLIST msgList; // list of msg handled in parallel
evhCALLBACK *completedCB; // user defined reply handler
evhCALLBACK *errorCB; // user defined error reply handler
evhCALLBACK *timeoutCB; // user defined timeout handler
SEE ALSO
evhSIMPLE_TASK, evhDB_CMD_SERIAL, evhDB_LIST_COMMAND
Index
- NAME
-
- SYNOPSIS
-
- PARENT CLASS
-
- DESCRIPTION
-
- PUBLIC METHODS
-
- PROTECTED METHODS
-
- PRIVATE DATA MEMBERS
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 10:08:47 GMT, April 23, 2012