dtn::ContactEvent Class Reference

#include <BundleEvent.h>

Inheritance diagram for dtn::ContactEvent:

dtn::BundleEvent oasys::SerializableObject dtn::ContactDownEvent dtn::ContactUpEvent dtn::LinkAvailableEvent dtn::LinkCreatedEvent dtn::LinkDeletedEvent dtn::LinkStateChangeRequest dtn::LinkUnavailableEvent

List of all members.


Detailed Description

Abstract class for the subset of events related to contacts and links that defines a reason code enumerated type.

Definition at line 419 of file BundleEvent.h.


Public Types

enum  reason_t {
  INVALID = 0, NO_INFO, USER, BROKEN,
  CL_ERROR, CL_VERSION, SHUTDOWN, RECONNECT,
  IDLE, TIMEOUT, UNBLOCKED
}
 Reason codes for contact state operations. More...

Public Member Functions

 ContactEvent (event_type_t type, reason_t reason=NO_INFO)
 Constructor.
virtual void serialize (oasys::SerializeAction *)
 This should call v->process() on each of the types that are to be serialized in the object.

Static Public Member Functions

static const char * reason_to_str (int reason)
 Reason to string conversion.

Public Attributes

int reason_
 reason code for the event

Member Enumeration Documentation

enum dtn::ContactEvent::reason_t

Reason codes for contact state operations.

Enumerator:
INVALID  Should not be used.
NO_INFO  No additional info.
USER  User action (i.e. console / config).
BROKEN  Unexpected session interruption.
CL_ERROR  Convergence layer protocol error.
CL_VERSION  Convergence layer version mismatch.
SHUTDOWN  Clean connection shutdown.
RECONNECT  Re-establish link after failure.
IDLE  Idle connection shut down by the CL.
TIMEOUT  Scheduled link ended duration.
UNBLOCKED  No longer busy.

Definition at line 424 of file BundleEvent.h.


Constructor & Destructor Documentation

dtn::ContactEvent::ContactEvent ( event_type_t  type,
reason_t  reason = NO_INFO 
) [inline]

Constructor.

Definition at line 459 of file BundleEvent.h.


Member Function Documentation

static const char* dtn::ContactEvent::reason_to_str ( int  reason  )  [inline, static]

Reason to string conversion.

Definition at line 441 of file BundleEvent.h.

References BROKEN, CL_ERROR, CL_VERSION, IDLE, INVALID, NO_INFO, NOTREACHED, RECONNECT, SHUTDOWN, TIMEOUT, UNBLOCKED, and USER.

Referenced by dtn::CLConnection::break_contact(), dtn::BundleDaemon::handle_contact_down(), dtn::BundleDaemon::handle_link_state_change_request(), and dtn::ContactManager::handle_link_unavailable().

virtual void dtn::ContactEvent::serialize ( oasys::SerializeAction a  )  [inline, virtual]

This should call v->process() on each of the types that are to be serialized in the object.

Reimplemented from dtn::BundleEvent.

Reimplemented in dtn::ContactUpEvent, dtn::ContactDownEvent, dtn::LinkCreatedEvent, dtn::LinkDeletedEvent, dtn::LinkAvailableEvent, dtn::LinkUnavailableEvent, and dtn::LinkStateChangeRequest.

Definition at line 463 of file BundleEvent.h.


Member Data Documentation

int dtn::ContactEvent::reason_

reason code for the event

Definition at line 465 of file BundleEvent.h.

Referenced by dtn::BundleDaemon::handle_link_state_change_request(), dtn::ContactManager::handle_link_unavailable(), dtn::LinkUnavailableEvent::serialize(), dtn::LinkAvailableEvent::serialize(), dtn::LinkDeletedEvent::serialize(), dtn::LinkCreatedEvent::serialize(), and dtn::ContactDownEvent::serialize().


The documentation for this class was generated from the following file:
Generated on Sat Sep 8 08:36:21 2007 for DTN Reference Implementation by  doxygen 1.5.3