• Main Page
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

daemon/src/core/BundleEvent.cpp

Go to the documentation of this file.
00001 /*
00002  * BundleEvent.cpp
00003  *
00004  *  Created on: 06.03.2009
00005  *      Author: morgenro
00006  */
00007 
00008 #include "config.h"
00009 #include "core/BundleEvent.h"
00010 
00011 namespace dtn
00012 {
00013         namespace core
00014         {
00015                 BundleEvent::BundleEvent(const dtn::data::MetaBundle &b, const EventBundleAction action, dtn::data::StatusReportBlock::REASON_CODE reason) : m_bundle(b), m_action(action), m_reason(reason)
00016                 {}
00017 
00018                 BundleEvent::~BundleEvent()
00019                 {}
00020 
00021                 const dtn::data::MetaBundle& BundleEvent::getBundle() const
00022                 {
00023                         return m_bundle;
00024                 }
00025 
00026                 EventBundleAction BundleEvent::getAction() const
00027                 {
00028                         return m_action;
00029                 }
00030 
00031                 dtn::data::StatusReportBlock::REASON_CODE BundleEvent::getReason() const
00032                 {
00033                         return m_reason;
00034                 }
00035 
00036                 const std::string BundleEvent::getName() const
00037                 {
00038                         return BundleEvent::className;
00039                 }
00040 
00041                 std::string BundleEvent::toString() const
00042                 {
00043                         return className;
00044                 }
00045 
00046                 void BundleEvent::raise(const dtn::data::MetaBundle &bundle, EventBundleAction action, dtn::data::StatusReportBlock::REASON_CODE reason)
00047                 {
00048                         // raise the new event
00049                         raiseEvent( new BundleEvent(bundle, action, reason) );
00050                 }
00051 
00052                 const string BundleEvent::className = "BundleEvent";
00053         }
00054 }

Generated on Thu Nov 11 2010 09:49:46 for IBR-DTNSuite by  doxygen 1.7.1