OMNeT++ Simulation Library
6.0.3
|
16 #ifndef __OMNETPP_CCOMPONENTTYPE_H
17 #define __OMNETPP_CCOMPONENTTYPE_H
24 #include "cownedobject.h"
25 #include "clistener.h"
36 class cDatarateChannel;
53 std::string qualifiedName;
54 bool availabilityTested =
false;
55 bool available =
false;
58 typedef std::map<std::string, cParImpl *> StringToParMap;
59 StringToParMap sharedParMap;
62 typedef std::set<cParImpl *, Less> ParImplSet;
63 ParImplSet sharedParSet;
66 std::map<simsignal_t,SignalDesc> signalsSeen;
68 mutable bool sourceFileDirectoryCached =
false;
69 mutable std::string sourceFileDirectory;
82 virtual cProperties *getParamProperties(
const char *paramName)
const = 0;
85 virtual cProperties *getGateProperties(
const char *gateName)
const = 0;
90 virtual cProperties *getSubmoduleProperties(
const char *submoduleName,
const char *submoduleType)
const = 0;
95 virtual cProperties *getConnectionProperties(
int connectionId,
const char *channelType)
const = 0;
98 virtual const char *getImplementationClassName()
const = 0;
101 virtual std::string getCxxNamespaceForType(
const char *type)
const = 0;
104 virtual void applyPatternAssignments(
cComponent *component) = 0;
107 cParImpl *getSharedParImpl(
const char *key)
const;
108 void putSharedParImpl(
const char *key,
cParImpl *value);
115 virtual void clearSharedParImpls();
118 cObjectFactory *lookupClass(
const char *className,
const char *sourceType)
const;
122 virtual std::string getPackageProperty(
const char *name)
const {
return "";}
125 virtual bool isAvailable();
128 virtual bool isInnerType()
const {
return false;}
131 virtual std::string getCxxNamespace()
const {
return "";}
134 virtual const char *getSourceFileName()
const {
return nullptr;}
137 virtual const char *getSourceFileDirectory()
const;
143 virtual cProperty *getSignalDeclaration(
const char *signalName);
177 virtual const char *
getFullName()
const override {
return qualifiedName.c_str();}
183 virtual std::string getNedSource()
const = 0;
211 virtual cModule *createModuleObject() = 0;
216 virtual void addParametersAndGatesTo(
cModule *mod) = 0;
222 virtual void setupGateVectors(
cModule *mod) = 0;
226 virtual void buildInside(
cModule *mod) = 0;
230 cModule *instantiateModuleClass(
const char *classname);
246 virtual bool isNetwork()
const = 0;
252 virtual bool isSimple()
const = 0;
289 virtual cModule *create(
const char *name,
cModule *parentmod,
int index=-1);
304 virtual cModule *createScheduleInit(
const char *name,
cModule *parentmod,
int index=-1);
335 virtual cChannel *createChannelObject() = 0;
338 virtual void addParametersTo(
cChannel *channel) = 0;
342 cChannel *instantiateChannelClass(
const char *classname);
366 virtual cChannel *create(
const char *name);
This class represents modules in the simulation.
Definition: cmodule.h:48
int simsignal_t
Signal handle.
Definition: clistener.h:27
Channel with propagation delay.
Definition: cdelaychannel.h:29
cObject is a lightweight class which serves as the root of the OMNeT++ class hierarchy....
Definition: cobject.h:92
The class behind the createOne() function and the Register_Class() macro.
Definition: cobjectfactory.h:35
A transmission channel model that supports propagation delay, transmission duration computed from a d...
Definition: cdataratechannel.h:69
Simulation manager class.
Definition: csimulation.h:63
Base class for channels.
Definition: cchannel.h:46
Abstract class for creating a module of a specific type.
Definition: ccomponenttype.h:206
virtual const char * getFullName() const override
Definition: ccomponenttype.h:177
Represents a module gate.
Definition: cgate.h:62
A collection of properties (cProperty).
Definition: cproperties.h:34
Represents a module or channel parameter.
Definition: cpar.h:70
Common base class for cModuleType and cChannelType.
Definition: ccomponenttype.h:49
SimsignalType
Signal data types.
Definition: clistener.h:47
Abstract base class for creating a channel of a given type.
Definition: ccomponenttype.h:326
Channel with zero propagation delay, zero transmission delay (infinite datarate), and always enabled.
Definition: cchannel.h:324
Internal class that stores values for cPar objects.
Definition: cparimpl.h:46
Common base for module and channel classes.
Definition: ccomponent.h:49
Base class for cOwnedObject-based classes that do not wish to support assignment and duplication.
Definition: cownedobject.h:242
Stores a (NED) property with its (possibly compound) value.
Definition: cproperty.h:38