IBR-DTNSuite  0.8
dtn::data::StatusReportBlock Class Reference

#include <StatusReportBlock.h>

Inheritance diagram for dtn::data::StatusReportBlock:
Collaboration diagram for dtn::data::StatusReportBlock:

List of all members.

Public Types

enum  TYPE {
  RECEIPT_OF_BUNDLE = 1 << 0, CUSTODY_ACCEPTANCE_OF_BUNDLE = 1 << 1, FORWARDING_OF_BUNDLE = 1 << 2, DELIVERY_OF_BUNDLE = 1 << 3,
  DELETION_OF_BUNDLE = 1 << 4
}
enum  REASON_CODE {
  NO_ADDITIONAL_INFORMATION = 0x00, LIFETIME_EXPIRED = 0x01, FORWARDED_OVER_UNIDIRECTIONAL_LINK = 0x02, TRANSMISSION_CANCELED = 0x03,
  DEPLETED_STORAGE = 0x04, DESTINATION_ENDPOINT_ID_UNINTELLIGIBLE = 0x05, NO_KNOWN_ROUTE_TO_DESTINATION_FROM_HERE = 0x06, NO_TIMELY_CONTACT_WITH_NEXT_NODE_ON_ROUTE = 0x07,
  BLOCK_UNINTELLIGIBLE = 0x08
}

Public Member Functions

 StatusReportBlock ()
virtual ~StatusReportBlock ()
virtual size_t getLength () const
virtual std::ostream & serialize (std::ostream &stream, size_t &length) const
virtual std::istream & deserialize (std::istream &stream, const size_t length)

Public Attributes

char _admfield
char _status
char _reasoncode
SDNV _fragment_offset
SDNV _fragment_length
DTNTime _timeof_receipt
DTNTime _timeof_custodyaccept
DTNTime _timeof_forwarding
DTNTime _timeof_delivery
DTNTime _timeof_deletion
SDNV _bundle_timestamp
SDNV _bundle_sequence
EID _source

Detailed Description

Definition at line 22 of file StatusReportBlock.h.


Member Enumeration Documentation

Enumerator:
NO_ADDITIONAL_INFORMATION 
LIFETIME_EXPIRED 
FORWARDED_OVER_UNIDIRECTIONAL_LINK 
TRANSMISSION_CANCELED 
DEPLETED_STORAGE 
DESTINATION_ENDPOINT_ID_UNINTELLIGIBLE 
NO_KNOWN_ROUTE_TO_DESTINATION_FROM_HERE 
NO_TIMELY_CONTACT_WITH_NEXT_NODE_ON_ROUTE 
BLOCK_UNINTELLIGIBLE 

Definition at line 34 of file StatusReportBlock.h.

Enumerator:
RECEIPT_OF_BUNDLE 
CUSTODY_ACCEPTANCE_OF_BUNDLE 
FORWARDING_OF_BUNDLE 
DELIVERY_OF_BUNDLE 
DELETION_OF_BUNDLE 

Definition at line 25 of file StatusReportBlock.h.


Constructor & Destructor Documentation


Member Function Documentation

std::istream & dtn::data::StatusReportBlock::deserialize ( std::istream &  stream,
const size_t  length 
) [virtual]

Deserialize the derived block payload.

Parameters:
streamA input stream to deserialize from.
Returns:
The same reference as given with the stream parameter.

Implements dtn::data::Block.

Definition at line 103 of file StatusReportBlock.cpp.

References _admfield, _bundle_sequence, _bundle_timestamp, _fragment_length, _fragment_offset, _reasoncode, _source, _status, _timeof_custodyaccept, _timeof_deletion, _timeof_delivery, _timeof_forwarding, _timeof_receipt, CUSTODY_ACCEPTANCE_OF_BUNDLE, DELETION_OF_BUNDLE, DELIVERY_OF_BUNDLE, dtn::data::Block::FORWARDED_WITHOUT_PROCESSED, FORWARDING_OF_BUNDLE, and RECEIPT_OF_BUNDLE.

std::ostream & dtn::data::StatusReportBlock::serialize ( std::ostream &  stream,
size_t &  length 
) const [virtual]

Serialize the derived block payload.

Parameters:
streamA output stream to serialize into.
Returns:
The same reference as given with the stream parameter.

Implements dtn::data::Block.

Definition at line 69 of file StatusReportBlock.cpp.

References _admfield, _bundle_sequence, _bundle_timestamp, _fragment_length, _fragment_offset, _reasoncode, _source, _status, _timeof_custodyaccept, _timeof_deletion, _timeof_delivery, _timeof_forwarding, _timeof_receipt, CUSTODY_ACCEPTANCE_OF_BUNDLE, DELETION_OF_BUNDLE, DELIVERY_OF_BUNDLE, FORWARDING_OF_BUNDLE, dtn::data::EID::getString(), and RECEIPT_OF_BUNDLE.

Here is the call graph for this function:


Member Data Documentation


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