- Main Page
- Classes
- Files
- Directories
- Related Pages

- Class List
- Class Hierarchy
- Class Members

# Txc2 Class Reference

Inheritance diagram for Txc2:

List of all members.

## Detailed Description

In this class we add some debug messages to Txc1. When you run the simulation in the OMNeT++ GUI Tkenv, the output will appear in the main text window, and you can also open separate output windows for `tic' and `toc'.

## Protected Member Functions
virtual void | initialize ()
virtual void | handleMessage (cMessage *msg)

## Member Function Documentation

void Txc2::handleMessage | ( | cMessage * | msg | ) | `[protected, virtual]`

| Reimplemented from cSimpleModule.
    00042 {
    00043     // msg->name() is name of the msg object, here it will be "tictocMsg".
    00044     ev << "Received message `" << msg->name() << "', sending it out again\n";
    00045     send(msg, "out");
    00046 }

void Txc2::initialize | ( |  | ) | `[protected, virtual]`

| Reimplemented from cModule.
    00031 {
    00032     if (strcmp("tic", name()) == 0)
    00033     {
    00034         // The `ev' object works like `cout' in C++.
    00035         ev << "Sending initial message\n";
    00036         cMessage *msg = new cMessage("tictocMsg");
    00037         send(msg, "out");
    00038     }
    00039 }

The documentation for this class was generated from the following file:

- txc2.cc