Main Page   Modules   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

agwsCMD_PARALLEL.h

Go to the documentation of this file.
00001 #ifndef agwsCMD_PARALLEL_H
00002 #define agwsCMD_PARALLEL_H
00003 /******************************************************************************
00004 * E.S.O. - VLT project
00005 *
00006 * "@(#) $Id: agwsCMD_PARALLEL.h,v 1.182 2003/11/12 08:34:12 vltsccm Exp $"
00007 *
00008 * who       when      what
00009 * --------  --------  --------------------------------------------------------
00010 * nfiebig   24/06/96  created
00011 */
00012 
00013 /******************************************************************************
00014  * Declaration of the agwsCMD_PARALLEL class. This class serves to send a list
00015  * of commands in parallel (various commands to various targets) and collect
00016  * all the replies.
00017  *-----------------------------------------------------------------------------
00018  */
00019 
00020 #ifndef __cplusplus
00021 #error This is a C++ include file and cannot be used from plain C
00022 #endif
00023 
00024 /*
00025  * eccs and evh includes
00026  */
00027 #include <eccsErr.h>
00028 #include <evhOBJ_CALLBACK.h>
00029 #include <evhCOMMAND.h>
00030 #include <evhTASK.h>
00031 
00032 /*
00033  * module includes
00034  */
00035 #include "agws.h"
00036 
00037 class agwsCMD_PARALLEL : public evhSIMPLE_TASK
00038 {
00039   public:
00040     agwsCMD_PARALLEL();
00041     ~agwsCMD_PARALLEL();
00042 
00043     ccsCOMPL_STAT    Reply(evhCALLBACK &cb);
00044     evhCALLBACK     *Reply();
00045 
00046     ccsCOMPL_STAT    ErrReply(evhCALLBACK &cb);
00047     evhCALLBACK     *ErrReply();
00048 
00049     ccsCOMPL_STAT    Timeout(evhCALLBACK &cb, ccsTIMEVAL &timeout);
00050     ccsCOMPL_STAT    Timeout(ccsTIMEVAL &timeout);
00051     evhCALLBACK     *Timeout();
00052 
00053     ccsCOMPL_STAT    Send(msgMESSAGE &orgMsg, vltINT32 numMsgs, msgMESSAGE msg[]);
00054 
00055     evhCB_COMPL_STAT SendReply(const char *buffer);
00056     evhCB_COMPL_STAT SendErrorReply( ccsMODULEID moduleId, vltINT16 errorNumber, 
00057                                   ccsLOC_ID  location, ...);
00058     virtual ccsCOMPL_STAT Reset();
00059     virtual vltLOGICAL    Status();
00060 
00061   protected:
00062     virtual evhCB_COMPL_STAT ReplyCB(msgMESSAGE &msg, void *);
00063     virtual evhCB_COMPL_STAT ErrReplyCB(msgMESSAGE &msg, void *);
00064     virtual evhCB_COMPL_STAT TimeoutCB(msgMESSAGE &msg, void *);
00065 
00066     vltINT32     numCmds;        // number of commands handled in parallel
00067     evhCOMMAND  *cmdList;        // list of commands handled in parallel
00068 
00069   private:
00070     vltINT32     numWait;        // number of replies still pending
00071     ccsTIMEVAL   timeout;        // overall timeout on waiting for replies
00072     msgMESSAGE   userMsg;        // user message to be used for replies
00073     evhCALLBACK *userReplyCB;    // user defined reply handler
00074     evhCALLBACK *userErrReplyCB; // user defined error reply handler
00075     evhCALLBACK *userTimeoutCB;  // user defined timeout handler
00076 };
00077 
00078 #endif // !agwsCMD_PARALLEL_H

Generated on Wed Dec 3 14:52:05 2003 for ATCS API by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001