European
Southern
Observatory

ESO — Reaching New Heights in Astronomy

Countries taking part in the ESO

VLT Software Documentation

tcsCMD_PARALLEL Class Reference

See man page tcsCMD_PARALLEL(4)
More...

#include <tcsCMD_PARALLEL.h>

List of all members.

Public Member Functions

 tcsCMD_PARALLEL ()
virtual ~tcsCMD_PARALLEL ()
virtual ccsCOMPL_STAT SetCompletedCB (evhCALLBACK &cb)
virtual ccsCOMPL_STAT SetErrorCB (evhCALLBACK &cb)
virtual ccsCOMPL_STAT SetTimeoutCB (evhCALLBACK &cb, const ccsTIMEVAL &timeout)
virtual ccsCOMPL_STAT SetTimeout (const ccsTIMEVAL &timeout)
virtual ccsTIMEVAL GetTimeout () const
virtual ccsCOMPL_STAT AddMessage (const msgMESSAGE &msg)
virtual ccsCOMPL_STAT Send ()
virtual ccsCOMPL_STAT Reset ()
virtual ccsCOMPL_STAT Init ()
virtual const vltLOGICAL GetStatus () const
virtual const vltINT32 GetNumCmds () const
virtual const vltINT32 GetNumWait () const

Protected Member Functions

virtual const fndLIST & GetCmdList () const
virtual ccsCOMPL_STAT RunCompleted (const msgMESSAGE &)
virtual ccsCOMPL_STAT RunError (const msgMESSAGE &)
virtual evhCB_COMPL_STAT ReplyCB (msgMESSAGE &, void *)
virtual evhCB_COMPL_STAT ErrReplyCB (msgMESSAGE &, void *)
virtual evhCB_COMPL_STAT TimeoutCB (msgMESSAGE &, void *)

Private Attributes

vltINT32 numWait
ccsTIMEVAL timeout
vltINT32 numCmds
fndLIST cmdList
fndLIST msgList
evhCALLBACK * completedCB
evhCALLBACK * errorCB
evhCALLBACK * timeoutCB

Detailed Description

See man page tcsCMD_PARALLEL(4)
Manpage of tcsCMD_PARALLEL

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

Definition at line 39 of file tcsCMD_PARALLEL.h.


Constructor & Destructor Documentation

tcsCMD_PARALLEL::tcsCMD_PARALLEL (  ) 

Definition at line 112 of file tcsCMD_PARALLEL.C.

References cmdList, msgList, Reset(), and timeout.

tcsCMD_PARALLEL::~tcsCMD_PARALLEL (  )  [virtual]

Definition at line 126 of file tcsCMD_PARALLEL.C.

References Reset().


Member Function Documentation

ccsCOMPL_STAT tcsCMD_PARALLEL::AddMessage ( const msgMESSAGE &  msg  )  [virtual]

Definition at line 469 of file tcsCMD_PARALLEL.C.

References msgList.

evhCB_COMPL_STAT tcsCMD_PARALLEL::ErrReplyCB ( msgMESSAGE &  msg,
void *   
) [protected, virtual]

Definition at line 375 of file tcsCMD_PARALLEL.C.

References RunError().

Referenced by Send().

const fndLIST & tcsCMD_PARALLEL::GetCmdList (  )  const [protected, virtual]

Definition at line 491 of file tcsCMD_PARALLEL.C.

References cmdList.

const vltINT32 tcsCMD_PARALLEL::GetNumCmds (  )  const [virtual]

Definition at line 481 of file tcsCMD_PARALLEL.C.

References numCmds.

const vltINT32 tcsCMD_PARALLEL::GetNumWait (  )  const [virtual]

Definition at line 486 of file tcsCMD_PARALLEL.C.

References numWait.

Referenced by GetStatus(), ReplyCB(), and Send().

const vltLOGICAL tcsCMD_PARALLEL::GetStatus (  )  const [virtual]

Definition at line 302 of file tcsCMD_PARALLEL.C.

References GetNumWait().

Referenced by Send(), SetCompletedCB(), SetErrorCB(), and SetTimeoutCB().

ccsTIMEVAL tcsCMD_PARALLEL::GetTimeout (  )  const [virtual]

Definition at line 496 of file tcsCMD_PARALLEL.C.

References timeout.

ccsCOMPL_STAT tcsCMD_PARALLEL::Init (  )  [virtual]

Definition at line 310 of file tcsCMD_PARALLEL.C.

References Reset().

evhCB_COMPL_STAT tcsCMD_PARALLEL::ReplyCB ( msgMESSAGE &  msg,
void *   
) [protected, virtual]

Definition at line 340 of file tcsCMD_PARALLEL.C.

References GetNumWait(), numWait, RunCompleted(), tcsMOD, and tcsOK_MSG.

Referenced by Send().

ccsCOMPL_STAT tcsCMD_PARALLEL::Reset (  )  [virtual]
ccsCOMPL_STAT tcsCMD_PARALLEL::RunCompleted ( const msgMESSAGE &  msg  )  [protected, virtual]

Definition at line 417 of file tcsCMD_PARALLEL.C.

References completedCB, and Reset().

Referenced by ReplyCB().

ccsCOMPL_STAT tcsCMD_PARALLEL::RunError ( const msgMESSAGE &  msg  )  [protected, virtual]

Definition at line 441 of file tcsCMD_PARALLEL.C.

References errorCB, and Reset().

Referenced by ErrReplyCB().

ccsCOMPL_STAT tcsCMD_PARALLEL::Send (  )  [virtual]
ccsCOMPL_STAT tcsCMD_PARALLEL::SetCompletedCB ( evhCALLBACK &  cb  )  [virtual]

Definition at line 133 of file tcsCMD_PARALLEL.C.

References completedCB, GetStatus(), tcsERR_BUSY, and tcsMOD.

ccsCOMPL_STAT tcsCMD_PARALLEL::SetErrorCB ( evhCALLBACK &  cb  )  [virtual]

Definition at line 164 of file tcsCMD_PARALLEL.C.

References errorCB, GetStatus(), tcsERR_BUSY, and tcsMOD.

ccsCOMPL_STAT tcsCMD_PARALLEL::SetTimeout ( const ccsTIMEVAL &  timeout  )  [virtual]

Definition at line 227 of file tcsCMD_PARALLEL.C.

ccsCOMPL_STAT tcsCMD_PARALLEL::SetTimeoutCB ( evhCALLBACK &  cb,
const ccsTIMEVAL &  timeout 
) [virtual]

Definition at line 195 of file tcsCMD_PARALLEL.C.

References GetStatus(), tcsERR_BUSY, tcsMOD, and timeoutCB.

evhCB_COMPL_STAT tcsCMD_PARALLEL::TimeoutCB ( msgMESSAGE &  msg,
void *   
) [protected, virtual]

Definition at line 395 of file tcsCMD_PARALLEL.C.

References Reset(), tcsERR_TIMEOUT, tcsMOD, and timeoutCB.

Referenced by Send().


Member Data Documentation

fndLIST tcsCMD_PARALLEL::cmdList [private]

Definition at line 74 of file tcsCMD_PARALLEL.h.

Referenced by GetCmdList(), Reset(), Send(), and tcsCMD_PARALLEL().

evhCALLBACK* tcsCMD_PARALLEL::completedCB [private]

Definition at line 77 of file tcsCMD_PARALLEL.h.

Referenced by Reset(), RunCompleted(), and SetCompletedCB().

evhCALLBACK* tcsCMD_PARALLEL::errorCB [private]

Definition at line 78 of file tcsCMD_PARALLEL.h.

Referenced by Reset(), RunError(), and SetErrorCB().

fndLIST tcsCMD_PARALLEL::msgList [private]

Definition at line 75 of file tcsCMD_PARALLEL.h.

Referenced by AddMessage(), Reset(), Send(), and tcsCMD_PARALLEL().

vltINT32 tcsCMD_PARALLEL::numCmds [private]

Definition at line 73 of file tcsCMD_PARALLEL.h.

Referenced by GetNumCmds(), Reset(), and Send().

vltINT32 tcsCMD_PARALLEL::numWait [private]

Definition at line 70 of file tcsCMD_PARALLEL.h.

Referenced by GetNumWait(), ReplyCB(), Reset(), and Send().

ccsTIMEVAL tcsCMD_PARALLEL::timeout [private]

Definition at line 71 of file tcsCMD_PARALLEL.h.

Referenced by GetTimeout(), Send(), and tcsCMD_PARALLEL().

evhCALLBACK* tcsCMD_PARALLEL::timeoutCB [private]

Definition at line 79 of file tcsCMD_PARALLEL.h.

Referenced by Reset(), SetTimeoutCB(), and TimeoutCB().


The documentation for this class was generated from the following files:
Generated on Mon Apr 23 10:12:44 2012 for INTROOT API by doxygen 1.6.3