INET Framework for OMNeT++/OMNEST
inet::physicallayer::RadioFrame Class Reference

#include <RadioFrame.h>

Inheritance diagram for inet::physicallayer::RadioFrame:
inet::physicallayer::IRadioFrame inet::IPhysicalLayerFrame inet::physicallayer::IPrintableObject

Public Member Functions

 RadioFrame (const ITransmission *transmission)
 
 RadioFrame (const RadioFrame &other)
 
virtual RadioFramedup () const override
 
virtual std::ostream & printToStream (std::ostream &stream, int level) const override
 Prints this object to the provided output stream. More...
 
virtual const ITransmissiongetTransmission () const override
 Returns the radio signal transmission that this radio frame represents. More...
 
virtual const IArrivalgetArrival () const override
 This function may return nullptr if this is not yet computed. More...
 
virtual const IListeninggetListening () const override
 This function may return nullptr if this is not yet computed. More...
 
virtual const IReceptiongetReception () const override
 This function may return nullptr if this is not yet computed. More...
 
- Public Member Functions inherited from inet::IPhysicalLayerFrame
virtual ~IPhysicalLayerFrame ()
 
- Public Member Functions inherited from inet::physicallayer::IPrintableObject
virtual ~IPrintableObject ()
 
virtual std::string getInfoStringRepresentation () const
 
virtual std::string getDetailStringRepresentation () const
 
virtual std::string getDebugStringRepresentation () const
 
virtual std::string getTraceStringRepresentation () const
 
virtual std::string getCompleteStringRepresentation () const
 

Protected Attributes

const ITransmissiontransmission = nullptr
 
const IArrivalarrival = nullptr
 
const IListeninglistening = nullptr
 
const IReceptionreception = nullptr
 

Additional Inherited Members

- Public Types inherited from inet::physicallayer::IPrintableObject
enum  PrintLevel {
  PRINT_LEVEL_TRACE, PRINT_LEVEL_DEBUG, PRINT_LEVEL_DETAIL, PRINT_LEVEL_INFO,
  PRINT_LEVEL_COMPLETE = INT_MIN
}
 

Constructor & Destructor Documentation

inet::physicallayer::RadioFrame::RadioFrame ( const ITransmission transmission)
26  :
28 {
29 }
const ITransmission * transmission
Definition: RadioFrame.h:30
inet::physicallayer::RadioFrame::RadioFrame ( const RadioFrame other)
31  :
32  cPacket(other),
33  transmission(other.transmission)
34 {
35 }
const ITransmission * transmission
Definition: RadioFrame.h:30

Member Function Documentation

virtual RadioFrame* inet::physicallayer::RadioFrame::dup ( ) const
inlineoverridevirtual
39 { return new RadioFrame(*this); }
RadioFrame(const ITransmission *transmission)
Definition: RadioFrame.cc:26
const IArrival * inet::physicallayer::RadioFrame::getArrival ( ) const
overridevirtual

This function may return nullptr if this is not yet computed.

Implements inet::physicallayer::IRadioFrame.

Referenced by inet::physicallayer::Radio::continueReception(), inet::physicallayer::Radio::endReception(), and inet::physicallayer::Radio::startReception().

48 {
49  if (arrival == nullptr) {
50  auto receiver = check_and_cast<const IRadio *>(getArrivalModule());
52  }
53  return arrival;
54 }
const ITransmission * transmission
Definition: RadioFrame.h:30
virtual const IArrival * getArrival(const IRadio *receiver, const ITransmission *transmission) const =0
Returns the space and time coordinates of the transmission arriving at the provided receiver...
virtual const IRadioMedium * getMedium() const =0
Returns the radio medium where this radio is transmitting and receiving radio signals.
virtual const IRadio * getTransmitter() const =0
Returns the transmitter that transmitted this radio signal on the radio channel.
const IArrival * arrival
Definition: RadioFrame.h:31
const IListening * inet::physicallayer::RadioFrame::getListening ( ) const
overridevirtual

This function may return nullptr if this is not yet computed.

Implements inet::physicallayer::IRadioFrame.

57 {
58  if (listening == nullptr) {
59  auto receiver = check_and_cast<const IRadio *>(getArrivalModule());
61  }
62  return listening;
63 }
const ITransmission * transmission
Definition: RadioFrame.h:30
virtual const IRadioMedium * getMedium() const =0
Returns the radio medium where this radio is transmitting and receiving radio signals.
virtual const IRadio * getTransmitter() const =0
Returns the transmitter that transmitted this radio signal on the radio channel.
const IListening * listening
Definition: RadioFrame.h:32
virtual const IListening * getListening(const IRadio *receiver, const ITransmission *transmission) const =0
Returns how the radio is listening on the medium when the transmission arrives at the provided receiv...
const IReception * inet::physicallayer::RadioFrame::getReception ( ) const
overridevirtual

This function may return nullptr if this is not yet computed.

Implements inet::physicallayer::IRadioFrame.

Referenced by inet::physicallayer::Radio::abortReception().

66 {
67  if (reception == nullptr) {
68  auto receiver = check_and_cast<const IRadio *>(getArrivalModule());
70  }
71  return reception;
72 }
virtual const IReception * getReception(const IRadio *receiver, const ITransmission *transmission) const =0
Returns the reception of the transmission arriving at the provided receiver.
const ITransmission * transmission
Definition: RadioFrame.h:30
const IReception * reception
Definition: RadioFrame.h:33
virtual const IRadioMedium * getMedium() const =0
Returns the radio medium where this radio is transmitting and receiving radio signals.
virtual const IRadio * getTransmitter() const =0
Returns the transmitter that transmitted this radio signal on the radio channel.
const ITransmission * inet::physicallayer::RadioFrame::getTransmission ( ) const
overridevirtual

Returns the radio signal transmission that this radio frame represents.

This function never returns nullptr.

Implements inet::physicallayer::IRadioFrame.

Referenced by inet::physicallayer::Radio::abortTransmission(), inet::physicallayer::Radio::continueTransmission(), and inet::physicallayer::Radio::endTransmission().

43 {
44  return transmission;
45 }
const ITransmission * transmission
Definition: RadioFrame.h:30
std::ostream & inet::physicallayer::RadioFrame::printToStream ( std::ostream &  stream,
int  level 
) const
overridevirtual

Prints this object to the provided output stream.

Function calls to operator<< with pointers or references either const or not are all forwarded to this function.

Reimplemented from inet::physicallayer::IPrintableObject.

38 {
39  return stream << (cPacket *)this;
40 }

Member Data Documentation

const IArrival* inet::physicallayer::RadioFrame::arrival = nullptr
mutableprotected

Referenced by getArrival().

const IListening* inet::physicallayer::RadioFrame::listening = nullptr
mutableprotected

Referenced by getListening().

const IReception* inet::physicallayer::RadioFrame::reception = nullptr
mutableprotected

Referenced by getReception().

const ITransmission* inet::physicallayer::RadioFrame::transmission = nullptr
protected

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