Common base class for cModuleType and cChannelType. More...
#include <ccomponenttype.h>
Public Member Functions | |
Constructors, destructor, assignment | |
cComponentType (const char *qname=NULL) | |
virtual | ~cComponentType () |
Redefined cObject member functions. | |
virtual const char * | getFullName () const |
Static Public Member Functions | |
static cComponentType * | find (const char *qname) |
static cComponentType * | get (const char *qname) |
Friends | |
class | cComponent |
class | cModule |
class | cChannel |
class | cPar |
class | cGate |
Common base class for cModuleType and cChannelType.
The getName() method returns the unqualified name (without namespace, e.g. "Queue"), and getFullName() returns the qualified name (with namespace, e.g. "inet.network.Queue").
cComponentType::cComponentType | ( | const char * | qname = NULL |
) |
Constructor.
Takes the fully qualified component type name.
static cComponentType* cComponentType::find | ( | const char * | qname | ) | [static] |
Finds a component type by fully qualified NED type name.
Returns NULL if not found.
Reimplemented in cModuleType, and cChannelType.
static cComponentType* cComponentType::get | ( | const char * | qname | ) | [static] |
Finds a component type by fully qualified NED type name.
Throws an error if not found.
Reimplemented in cModuleType, and cChannelType.
virtual const char* cComponentType::getFullName | ( | ) | const [inline, virtual] |
Returns the fully qualified name (i.e.
the simple name prefixed with the package name and any existing enclosing NED type names).
Examples:
The fully qualified name for a module named Fifo
which is in the default package is "Fifo"
.
For a module named Host
which is in the package some.package
, the fully qualified name is "some.package.Host"
.
For a channel type Ch
which is defined as an inner type inside the network Network
in a package named some.package
, the fully qualified name is "some.package.Network.Ch"
.
Reimplemented from cObject.