vpr::sim::Controller::EventData Struct Reference

#include <Controller.h>

Collaboration diagram for vpr::sim::Controller::EventData:

Collaboration graph
[legend]
List of all members.

Public Types

enum  EventType { MESSAGE, CONNECTION_INIT, CONNECTION_COMPLETE, LOCALHOST_DELIVERY }

Public Member Functions

 EventData (const NetworkGraph::net_edge_t _edge, const NetworkLine::LineDirection _dir)
 EventData (vpr::SocketImplSIM *sock, const EventType _type)
bool operator== (const EventData &obj) const

Public Attributes

EventType type
NetworkGraph::net_edge_t edge
NetworkLine::LineDirection direction
vpr::SocketImplSIMsocket

Detailed Description

Definition at line 284 of file Controller.h.


Member Enumeration Documentation

enum vpr::sim::Controller::EventData::EventType

Enumerator:
MESSAGE  Message arrival event.
CONNECTION_INIT  Connection request event.
CONNECTION_COMPLETE  Connection completion event.
LOCALHOST_DELIVERY  Immediate localhost-delivery-of-crap event.

Definition at line 286 of file Controller.h.

00287       {
00288          MESSAGE,             
00289          CONNECTION_INIT,     
00290          CONNECTION_COMPLETE, 
00291          LOCALHOST_DELIVERY   
00292       };


Constructor & Destructor Documentation

vpr::sim::Controller::EventData::EventData ( const NetworkGraph::net_edge_t  _edge,
const NetworkLine::LineDirection  _dir 
) [inline]

Definition at line 294 of file Controller.h.

00296          : type(MESSAGE), edge(_edge), direction(_dir)
00297       {
00298          ;
00299       }

vpr::sim::Controller::EventData::EventData ( vpr::SocketImplSIM sock,
const EventType  _type 
) [inline]

Definition at line 301 of file Controller.h.

00302          : type(_type), socket(sock)
00303       {
00304          ;
00305       }


Member Function Documentation

bool vpr::sim::Controller::EventData::operator== ( const EventData obj  )  const [inline]

Definition at line 307 of file Controller.h.

References direction, edge, socket, and type.

00308       {
00309          bool status = false;
00310 
00311          if ( type == obj.type )
00312          {
00313             // This may need to be expanded to a full if/else if/else block
00314             // if the possible message data types expands beyond the above
00315             // four.
00316             status = (type == MESSAGE) ? (edge == obj.edge && direction == obj.direction)
00317                                        : (socket == obj.socket);
00318          }
00319 
00320          return status;
00321       }


Member Data Documentation

EventType vpr::sim::Controller::EventData::type

Definition at line 323 of file Controller.h.

Referenced by operator==().

NetworkGraph::net_edge_t vpr::sim::Controller::EventData::edge

Definition at line 324 of file Controller.h.

Referenced by operator==().

NetworkLine::LineDirection vpr::sim::Controller::EventData::direction

Definition at line 325 of file Controller.h.

Referenced by operator==().

vpr::SocketImplSIM* vpr::sim::Controller::EventData::socket

Definition at line 326 of file Controller.h.

Referenced by operator==().


The documentation for this struct was generated from the following file:
Generated on Thu Jan 4 10:56:10 2007 for VR Juggler Portable Runtime by  doxygen 1.5.1