|
OMNeT++ API 6.1
Discrete Event Simulation Library
|
|
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 = 0;
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;}
111 virtual bool isGUI()
const override {
return false;}
114 virtual void getImageSize(
const char *imageName,
double& outWidth,
double& outHeight)
override {unsupported();}
115 virtual void getTextExtent(
const cFigure::Font& font,
const char *text,
double& outWidth,
double& outHeight,
double& outAscent)
override {unsupported();}
117 virtual void loadImage(
const char *fileName,
const char *imageName=
nullptr)
override {unsupported();}
119 virtual std::vector<cFigure::Point> getConnectionLine(
const cGate *sourceGate)
override {
return {};}
127 virtual std::string
gets(
const char *prompt,
const char *defaultreply=
nullptr)
override {unsupported();
return "";}
128 virtual cEnvir& flush() {::fflush(stdout);
return *
this;}
158 virtual bool idle()
override {
return false;}
virtual double getAnimationSpeed() const override
Definition: cnullenvir.h:122
virtual void forgetParsedXMLString(const char *content) override
Definition: cnullenvir.h:105
This class represents modules in the simulation.
Definition: cmodule.h:48
virtual void preconfigure(cComponent *component) override
Definition: cnullenvir.h:98
virtual void connectionDeleted(cGate *srcgate) override
Definition: cnullenvir.h:92
Allows returning multiple values from the processMessage() method.
Definition: cchannel.h:33
int simsignal_t
Signal handle.
Definition: clistener.h:27
virtual int getParsimNumPartitions() const override
Definition: cnullenvir.h:154
virtual void recordComponentType(cComponent *component) override
Definition: cnullenvir.h:143
cObject is a lightweight class which serves as the root of the OMNeT++ class hierarchy....
Definition: cobject.h:92
virtual void messageCloned(cMessage *msg, cMessage *clone) override
Definition: cnullenvir.h:82
virtual int getParsimProcId() const override
Definition: cnullenvir.h:153
virtual void configure(cComponent *component) override
Definition: cnullenvir.h:99
virtual void refOsgNode(osg::Node *scene) override
Definition: cnullenvir.h:156
Represents the configuration, as accessed by the simulation kernel.
Definition: cconfiguration.h:76
virtual bool isExpressMode() const override
Definition: cnullenvir.h:112
virtual bool recordInOutputVector(void *vechandle, simtime_t t, double value) override
Definition: cnullenvir.h:137
virtual std::string gets(const char *prompt, const char *defaultreply=nullptr) override
Definition: cnullenvir.h:127
virtual bool askYesNo(const char *prompt) override
Definition: cnullenvir.h:62
Represents an event in the discrete event simulator.
Definition: cevent.h:46
A do-nothing cEnvir implementation.
Definition: cnullenvir.h:49
virtual void recordScalar(cComponent *component, const char *name, double value, opp_string_map *attributes=nullptr) override
Definition: cnullenvir.h:140
virtual void flushXMLDocumentCache() override
Definition: cnullenvir.h:106
virtual cRNG * getRNG(int k) override
Definition: cnullenvir.h:132
virtual void messageSendDirect(cMessage *msg, cGate *toGate, const ChannelResult &result) override
Definition: cnullenvir.h:77
virtual void flushXMLParsedContentCache() override
Definition: cnullenvir.h:107
This class holds various data that is captured when a particular log statement executes....
Definition: clog.h:376
virtual void messageSendHop(cMessage *msg, cGate *srcGate, const cChannel::Result &result) override
Definition: cnullenvir.h:79
virtual void pausePoint() override
Definition: cnullenvir.h:64
virtual std::ostream * getStreamForSnapshot() override
Definition: cnullenvir.h:147
virtual void readParameter(cPar *par) override
Definition: cnullenvir.h:100
virtual void undisposedObject(cObject *obj) override
Definition: cnullenvir.h:94
Lightweight string-to-string map, used internally in some parts of OMNeT++.
Definition: opp_string.h:219
virtual void moduleDeleted(cModule *module) override
Definition: cnullenvir.h:88
virtual void messageCreated(cMessage *msg) override
Definition: cnullenvir.h:81
virtual void loadImage(const char *fileName, const char *imageName=nullptr) override
Definition: cnullenvir.h:117
virtual cXMLElement * getXMLDocument(const char *filename, const char *xpath=nullptr) override
Definition: cnullenvir.h:102
virtual void alert(const char *msg) override
Definition: cnullenvir.h:61
int64_t-based, base-10 fixed-point simulation time.
Definition: simtime.h:66
virtual void releaseStreamForSnapshot(std::ostream *os) override
Definition: cnullenvir.h:148
virtual void objectDeleted(cObject *object) override
Definition: cnullenvir.h:72
virtual void messageScheduled(cMessage *msg) override
Definition: cnullenvir.h:74
virtual void messageDeleted(cMessage *msg) override
Definition: cnullenvir.h:83
virtual void recordStatistic(cComponent *component, const char *name, cStatistic *statistic, opp_string_map *attributes=nullptr) override
Definition: cnullenvir.h:141
virtual void addResultRecorders(cComponent *component, simsignal_t signal, const char *statisticName, cProperty *statisticTemplateProperty) override
Definition: cnullenvir.h:144
virtual std::ostream & getOutputStream() override
Definition: cnullenvir.h:63
Options for the cSimpleModule::send() and cSimpleModule::sendDirect() calls.
Definition: csimplemodule.h:82
virtual cConfiguration * getConfig() override
Definition: cnullenvir.h:109
virtual int getArgCount() const override
Definition: cnullenvir.h:151
virtual void displayStringChanged(cComponent *component) override
Definition: cnullenvir.h:93
virtual void * registerOutputVector(const char *modulename, const char *vectorname, opp_string_map *attributes=nullptr) override
Definition: cnullenvir.h:135
Represents a module gate.
Definition: cgate.h:62
virtual void messageCancelled(cMessage *msg) override
Definition: cnullenvir.h:75
virtual bool idle() override
Definition: cnullenvir.h:158
virtual void forgetXMLDocument(const char *filename) override
Definition: cnullenvir.h:104
Abstract interface for random number generator classes.
Definition: crng.h:48
virtual int getNumRNGs() const override
Definition: cnullenvir.h:131
virtual bool isModuleLocal(cModule *parentmod, const char *modname, int index) override
Definition: cnullenvir.h:101
Represents a module or channel parameter.
Definition: cpar.h:70
virtual void connectionCreated(cGate *srcgate) override
Definition: cnullenvir.h:91
Common base class for cModuleType and cChannelType.
Definition: ccomponenttype.h:49
virtual void deregisterOutputVector(void *vechandle) override
Definition: cnullenvir.h:136
virtual double getAnimationTime() const override
Definition: cnullenvir.h:121
virtual char ** getArgVector() const override
Definition: cnullenvir.h:152
The message class in OMNeT++. cMessage objects may represent events, messages, jobs or other entities...
Definition: cmessage.h:95
virtual unsigned getExtraStackForEnvir() const override
Definition: cnullenvir.h:108
virtual void recordParameter(cPar *par) override
Definition: cnullenvir.h:142
virtual void log(cLogEntry *entry) override
Definition: cnullenvir.h:95
virtual void bubble(cComponent *component, const char *text) override
Definition: cnullenvir.h:126
Represents an XML element in an XML configuration file.
Definition: cxmlelement.h:75
Common base for module and channel classes.
Definition: ccomponent.h:49
virtual void messageSendHop(cMessage *msg, cGate *srcGate) override
Definition: cnullenvir.h:78
virtual bool ensureDebugger(cRuntimeError *) override
Definition: cnullenvir.h:159
virtual double getRemainingAnimationHoldTime() const override
Definition: cnullenvir.h:123
virtual void componentMethodEnd() override
Definition: cnullenvir.h:86
cStatistic is an abstract class for computing statistical properties of a random variable.
Definition: cstatistic.h:34
virtual void getImageSize(const char *imageName, double &outWidth, double &outHeight) override
Definition: cnullenvir.h:114
virtual std::string resolveResourcePath(const char *fileName, cComponentType *context) override
Definition: cnullenvir.h:110
Thrown when the simulation kernel or other components detect a runtime error.
Definition: cexception.h:286
virtual void getTextExtent(const cFigure::Font &font, const char *text, double &outWidth, double &outHeight, double &outAscent) override
Definition: cnullenvir.h:115
virtual void endSend(cMessage *msg) override
Definition: cnullenvir.h:80
virtual void moduleReparented(cModule *module, cModule *oldparent, int oldId) override
Definition: cnullenvir.h:84
virtual void moduleCreated(cModule *newmodule) override
Definition: cnullenvir.h:87
virtual cFigure::Rectangle getSubmoduleBounds(const cModule *submodule) override
Definition: cnullenvir.h:118
cEnvir represents the "environment" or user interface of the simulation.
Definition: cenvir.h:75
Stores a (NED) property with its (possibly compound) value.
Definition: cproperty.h:38
virtual void appendToImagePath(const char *directory) override
Definition: cnullenvir.h:116
virtual void unrefOsgNode(osg::Node *scene) override
Definition: cnullenvir.h:157
virtual unsigned long getUniqueNumber() override
Definition: cnullenvir.h:155
virtual void beginSend(cMessage *msg, const SendOptions &options) override
Definition: cnullenvir.h:76
virtual void simulationEvent(cEvent *event) override
Definition: cnullenvir.h:73
virtual bool isGUI() const override
Definition: cnullenvir.h:111
virtual void gateCreated(cGate *newgate) override
Definition: cnullenvir.h:89
virtual void gateDeleted(cGate *gate) override
Definition: cnullenvir.h:90
virtual void componentMethodBegin(cComponent *from, cComponent *to, const char *methodFmt, va_list va, bool silent) override
Definition: cnullenvir.h:85
virtual cXMLElement * getParsedXMLString(const char *content, const char *xpath=nullptr) override
Definition: cnullenvir.h:103
virtual double getZoomLevel(const cModule *module) override
Definition: cnullenvir.h:120