16 #ifndef __OMNETPP_CNULLENVIR_H 17 #define __OMNETPP_CNULLENVIR_H 20 #include "cexception.h" 21 #include "ccomponent.h" 22 #include "cmersennetwister.h" 56 unsigned long nextUniqueNumber;
57 std::vector<cISimulationLifecycleListener*> listeners;
60 void unsupported()
const {
throw cRuntimeError(
"cNullEnvir: Unsupported method called");}
61 virtual void alert(
const char *msg)
override {::printf(
"\n<!> %s\n\n", msg);}
62 virtual bool askYesNo(
const char *prompt)
override {unsupported();
return false;}
109 virtual bool isGUI()
const override {
return false;}
112 virtual void getImageSize(
const char *imageName,
double& outWidth,
double& outHeight)
override {unsupported();}
113 virtual void getTextExtent(
const cFigure::Font& font,
const char *text,
double& outWidth,
double& outHeight,
double& outAscent)
override {unsupported();}
115 virtual void loadImage(
const char *fileName,
const char *imageName=
nullptr)
override {unsupported();}
124 virtual std::string
gets(
const char *prompt,
const char *defaultreply=
nullptr)
override {unsupported();
return "";}
125 virtual cEnvir& flush() {::fflush(stdout);
return *
this;}
132 virtual void *
registerOutputVector(
const char *modulename,
const char *vectorname)
override {
return (
void *)1;}
155 virtual bool idle()
override {
return false;}
virtual double getRemainingAnimationHoldTime() const override
Definition: cnullenvir.h:120
virtual char ** getArgVector() const override
Definition: cnullenvir.h:149
The message class in OMNeT++. cMessage objects may represent events, messages, jobs or other entities...
Definition: cmessage.h:95
virtual void gateCreated(cGate *newgate) override
Definition: cnullenvir.h:87
Thrown when the simulation kernel or other components detect a runtime error.
Definition: cexception.h:283
Common base for module and channel classes.
Definition: ccomponent.h:48
virtual void bubble(cComponent *component, const char *text) override
Definition: cnullenvir.h:123
Represents a module gate.
Definition: cgate.h:63
virtual void forgetXMLDocument(const char *filename) override
Definition: cnullenvir.h:102
Root of the OMNeT++ class hierarchy. cObject is a lightweight class without any data members...
Definition: cobject.h:58
virtual void messageSendHop(cMessage *msg, cGate *srcGate) override
Definition: cnullenvir.h:76
virtual void beginSend(cMessage *msg) override
Definition: cnullenvir.h:74
int64_t-based, base-10 fixed-point simulation time.
Definition: simtime.h:66
virtual std::ostream * getStreamForSnapshot() override
Definition: cnullenvir.h:144
virtual void undisposedObject(cObject *obj) override
Definition: cnullenvir.h:92
virtual void loadImage(const char *fileName, const char *imageName=nullptr) override
Definition: cnullenvir.h:115
virtual void getImageSize(const char *imageName, double &outWidth, double &outHeight) override
Definition: cnullenvir.h:112
virtual std::string resolveResourcePath(const char *fileName, cComponentType *context) override
Definition: cnullenvir.h:108
virtual void addResultRecorders(cComponent *component, simsignal_t signal, const char *statisticName, cProperty *statisticTemplateProperty) override
Definition: cnullenvir.h:141
virtual double getAnimationTime() const override
Definition: cnullenvir.h:118
virtual std::string gets(const char *prompt, const char *defaultreply=nullptr) override
Definition: cnullenvir.h:124
virtual void moduleReparented(cModule *module, cModule *oldparent, int oldId) override
Definition: cnullenvir.h:82
virtual double getAnimationSpeed() const override
Definition: cnullenvir.h:119
Represents an XML element in an XML configuration file.
Definition: cxmlelement.h:73
virtual bool idle() override
Definition: cnullenvir.h:155
Abstract interface for random number generator classes.
Definition: crng.h:49
virtual cRNG * getRNG(int k) override
Definition: cnullenvir.h:129
Represents an event in the discrete event simulator.
Definition: cevent.h:43
virtual void preconfigure(cComponent *component) override
Definition: cnullenvir.h:96
Represents a module or channel parameter.
Definition: cpar.h:68
virtual void setVectorAttribute(void *vechandle, const char *name, const char *value) override
Definition: cnullenvir.h:134
virtual void endSend(cMessage *msg) override
Definition: cnullenvir.h:78
A callback interface for receiving notifications at various stages simulations, including setting up...
Definition: clifecyclelistener.h:186
virtual void readParameter(cPar *par) override
Definition: cnullenvir.h:98
virtual unsigned getExtraStackForEnvir() const override
Definition: cnullenvir.h:106
virtual bool askYesNo(const char *prompt) override
Definition: cnullenvir.h:62
virtual void componentMethodEnd() override
Definition: cnullenvir.h:84
virtual bool recordInOutputVector(void *vechandle, simtime_t t, double value) override
Definition: cnullenvir.h:135
virtual int getParsimProcId() const override
Definition: cnullenvir.h:150
virtual void * registerOutputVector(const char *modulename, const char *vectorname) override
Definition: cnullenvir.h:132
virtual cFigure::Rectangle getSubmoduleBounds(const cModule *submodule) override
Definition: cnullenvir.h:116
virtual void getTextExtent(const cFigure::Font &font, const char *text, double &outWidth, double &outHeight, double &outAscent) override
Definition: cnullenvir.h:113
virtual bool isModuleLocal(cModule *parentmod, const char *modname, int index) override
Definition: cnullenvir.h:99
cEnvir represents the "environment" or user interface of the simulation.
Definition: cenvir.h:73
virtual void releaseStreamForSnapshot(std::ostream *os) override
Definition: cnullenvir.h:145
virtual void messageDeleted(cMessage *msg) override
Definition: cnullenvir.h:81
virtual bool isGUI() const override
Definition: cnullenvir.h:109
virtual void moduleCreated(cModule *newmodule) override
Definition: cnullenvir.h:85
This class holds various data that is captured when a particular log statement executes. It also contains the text written to the log stream.
Definition: clog.h:369
virtual void recordStatistic(cComponent *component, const char *name, cStatistic *statistic, opp_string_map *attributes=nullptr) override
Definition: cnullenvir.h:139
virtual cConfiguration * getConfig() override
Definition: cnullenvir.h:107
virtual void log(cLogEntry *entry) override
Definition: cnullenvir.h:93
virtual int getParsimNumPartitions() const override
Definition: cnullenvir.h:151
This class represents modules in the simulation.
Definition: cmodule.h:47
virtual void refOsgNode(osg::Node *scene) override
Definition: cnullenvir.h:153
virtual void deregisterOutputVector(void *vechandle) override
Definition: cnullenvir.h:133
Stores a (NED) property with its (possibly compound) value.
Definition: cproperty.h:38
virtual void messageSendHop(cMessage *msg, cGate *srcGate, simtime_t propagationDelay, simtime_t transmissionDelay, bool discard) override
Definition: cnullenvir.h:77
A do-nothing cEnvir implementation.
Definition: cnullenvir.h:49
Lightweight string-to-string map, used internally in some parts of OMNeT++.
Definition: opp_string.h:200
virtual void forgetParsedXMLString(const char *content) override
Definition: cnullenvir.h:103
virtual void gateDeleted(cGate *gate) override
Definition: cnullenvir.h:88
virtual void messageCreated(cMessage *msg) override
Definition: cnullenvir.h:79
virtual int getArgCount() const override
Definition: cnullenvir.h:148
virtual int getNumRNGs() const override
Definition: cnullenvir.h:128
virtual void connectionDeleted(cGate *srcgate) override
Definition: cnullenvir.h:90
virtual void simulationEvent(cEvent *event) override
Definition: cnullenvir.h:71
virtual void messageCloned(cMessage *msg, cMessage *clone) override
Definition: cnullenvir.h:80
virtual cXMLElement * getParsedXMLString(const char *content, const char *xpath=nullptr) override
Definition: cnullenvir.h:101
virtual bool isExpressMode() const override
Definition: cnullenvir.h:110
virtual unsigned long getUniqueNumber() override
Definition: cnullenvir.h:152
Common base class for cModuleType and cChannelType.
Definition: ccomponenttype.h:49
Definition: cabstracthistogram.h:21
virtual void connectionCreated(cGate *srcgate) override
Definition: cnullenvir.h:89
virtual void alert(const char *msg) override
Definition: cnullenvir.h:61
virtual void appendToImagePath(const char *directory) override
Definition: cnullenvir.h:114
virtual void recordScalar(cComponent *component, const char *name, double value, opp_string_map *attributes=nullptr) override
Definition: cnullenvir.h:138
virtual void componentMethodBegin(cComponent *from, cComponent *to, const char *methodFmt, va_list va, bool silent) override
Definition: cnullenvir.h:83
virtual void messageScheduled(cMessage *msg) override
Definition: cnullenvir.h:72
virtual void configure(cComponent *component) override
Definition: cnullenvir.h:97
SimulationLifecycleEventType
Event type for cISimulationLifecycleListener's lifecycleEvent() method.
Definition: clifecyclelistener.h:28
virtual bool ensureDebugger(cRuntimeError *) override
Definition: cnullenvir.h:156
int simsignal_t
Signal handle.
Definition: clistener.h:24
virtual void moduleDeleted(cModule *module) override
Definition: cnullenvir.h:86
virtual void unrefOsgNode(osg::Node *scene) override
Definition: cnullenvir.h:154
virtual void objectDeleted(cObject *object) override
Definition: cnullenvir.h:70
virtual cXMLElement * getXMLDocument(const char *filename, const char *xpath=nullptr) override
Definition: cnullenvir.h:100
cStatistic is an abstract class for computing statistical properties of a random variable.
Definition: cstatistic.h:34
virtual void flushXMLDocumentCache() override
Definition: cnullenvir.h:104
virtual void flushXMLParsedContentCache() override
Definition: cnullenvir.h:105
virtual void messageCancelled(cMessage *msg) override
Definition: cnullenvir.h:73
Represents the configuration, as accessed by the simulation kernel.
Definition: cconfiguration.h:70
virtual void messageSendDirect(cMessage *msg, cGate *toGate, simtime_t propagationDelay, simtime_t transmissionDelay) override
Definition: cnullenvir.h:75
virtual double getZoomLevel(const cModule *module) override
Definition: cnullenvir.h:117
virtual void displayStringChanged(cComponent *component) override
Definition: cnullenvir.h:91