GSI Object Oriented Online Offline (Go4) GO4-6.4.0
Loading...
Searching...
No Matches
TGo4CommandInvoker.h
Go to the documentation of this file.
1// $Id$
2//-----------------------------------------------------------------------
3// The GSI Online Offline Object Oriented (Go4) Project
4// Experiment Data Processing at EE department, GSI
5//-----------------------------------------------------------------------
6// Copyright (C) 2000- GSI Helmholtzzentrum fuer Schwerionenforschung GmbH
7// Planckstr. 1, 64291 Darmstadt, Germany
8// Contact: http://go4.gsi.de
9//-----------------------------------------------------------------------
10// This software can be used under the license agreements as stated
11// in Go4License.txt file which is part of the distribution.
12//-----------------------------------------------------------------------
13
14#ifndef TGO4COMMANDINVOKER_H
15#define TGO4COMMANDINVOKER_H
16
21
22#include "TObject.h"
23#include "TGo4CommandReceiver.h"
24
25class TMutex;
26class TObjArray;
27class TGo4Command;
30
36
37class TGo4CommandInvoker : public TObject, public TGo4CommandReceiver {
38
39 public:
40
42
43 static void Register(const char *name, TGo4CommandReceiver *p);
44
45 static void UnRegister(TGo4CommandReceiver *p);
46
47 virtual void Invoke(TGo4Command *com);
48
49 virtual void Invoke();
50
51 virtual ~TGo4CommandInvoker();
52
55 static void SetCommandList(TGo4CommandProtoList *list);
56
60
61 protected:
62
64
65 static TGo4CommandReceiver *Lookup(const char *name);
66
67 private:
68
71
75
77 static TObjArray *fxArray;
78 static TMutex *fxMutex;
79
80 ClassDefOverride(TGo4CommandInvoker, 2)
81};
82
83#endif //TGO4COMMANDINVOKER_H
static TGo4CommandInvoker * Instance()
static void SetCommandList(TGo4CommandProtoList *list)
Application may exchange standard command list by own subclass with specialized commands,...
static TGo4CommandReceiver * Lookup(const char *name)
static TMutex * fxMutex
TGo4Command * fxCommand
aggregation
static void UnRegister(TGo4CommandReceiver *p)
static TGo4CommandInvoker * fxInstance
Int_t ExecuteFromRemote(TGo4RemoteCommand *remcom)
Create real command from remote command and invoke it.
static TObjArray * fxArray
static TGo4CommandProtoList * fxCommandList
For remote commands, invoker will create the requested slave commands from own command list.
static void Register(const char *name, TGo4CommandReceiver *p)
This is the Go4 Abstract Command Class; part of the Base command pattern.
Definition TGo4Command.h:35
This command is a container for commands to be send from master to slave via inter-process transport.