PacketData Class Reference

A class which holds the data that is contained within a packet. More...

#include <packet.hpp>

Inheritance diagram for PacketData:

RfidReaderAppData RfidReaderMacData RfidTagAppData RfidTagMacData List of all members.

Public Types

typedef boost::shared_ptr<
PacketData
PacketDataPtr
 Smart pointer that clients should use.

Public Member Functions

virtual ~PacketData ()
 A destructor.
virtual t_uint getSizeInBytes () const
 Get the size of this data.
virtual ostream & print (ostream &s) const
 Return the stream representation of the object.

Static Public Member Functions

static PacketDataPtr create ()
 A factory method to ensure that all objects are created via new since we are using smart pointers.
static PacketDataPtr create (const PacketData &rhs)
 A factory method to ensure that all objects are created via new since we are using smart pointers.

Protected Member Functions

 PacketData ()
 A constructor.
 PacketData (const PacketData &rhs)
 A copy constructor.
virtual PacketDataPtr clone () const
 Returns a pointer to a deep copy of this object.

Detailed Description

A class which holds the data that is contained within a packet.

Definition at line 18 of file packet.hpp.


Member Function Documentation

virtual PacketDataPtr PacketData::clone (  )  const [inline, protected, virtual]

Returns a pointer to a deep copy of this object.

This is addresses the slicing problem with copy construction.

Returns:
a pointer to a deep copy of this object.

Reimplemented in RfidReaderAppData, RfidReaderMacData, RfidTagAppData, and RfidTagMacData.

Definition at line 76 of file packet.hpp.

References PacketData().

Referenced by create().

virtual t_uint PacketData::getSizeInBytes (  )  const [inline, virtual]

Get the size of this data.

Returns:
the size of the data in bytes.

Reimplemented in RfidReaderAppData, RfidReaderMacData, RfidTagAppData, and RfidTagMacData.

Definition at line 49 of file packet.hpp.

Referenced by print().


The documentation for this class was generated from the following file:
Generated on Tue Dec 12 17:04:40 2006 for rfidsim by  doxygen 1.4.7