Chapter 5. Complete program listings.
}
virtual ~CMyExperiment() {
}
// Copy construction, assignment and comparison
// make no sense and are therefore disallowed:
private:
CMyExperiment(const CMyExperiment& rhs);
CMyExperiment& operator=(const CMyExperiment& rhs);
int operator==(const CMyExperiment& rhs);
int operator!=(const CMyExperiment& rhs);
public:
// The member functions below allow us to override/extend base
// class behavior for experiment specific stuff.
protected:
virtual void SetupReadout(CExperiment& rExperiment);
virtual void SetupScalers(CExperiment& rExperiment);
public:
virtual void SetupRunVariables(CExperiment& rExperiment,
CInterpreterStartup& rStartup,
CInterpreterCore& rCore);
virtual void SetupStateVariables(CExperiment& rExperiment,
CInterpreterStartup& rStartup,
CInterpreterCore& rCore);
virtual void AddUserCommands(CExperiment& rExperiment,
CInterpreterStartup& rStartup,
CInterpreterCore& rCore);
};
// The system relies on a globally accessible instance of a CReadoutMain
// derived object called MyApp so here it is:
CMyExperiment MyApp;
/*!
In SetupReadout, you are expected to add Event segments to your
experiment. Event segments read out logical sections of your
experiment. The following types of event segments are available for your
use:
- Simple event segments: These are derived from the abstract base
class CEventSegment, and are intended to readout a coherent piece
of an experiment.
- Compatibility mode segments: These are objects of type
CTraditionalEventSegment they provide all the callouts to code
that lives in an old-style skeleton.cpp file. You will need to modify
the skeleton makefile to add the oldstyle skeleton.cpp to the build.
There can be only one CTraditionalEventSegment in the system due
to function naming.
- Compound segments: These are objects of type CCompoundEventSegment
They consist of an ordered list of event segments of any type (including
if you like other compound event segments.
49
Kommentare zu diesen Handbüchern