21 #ifndef ALOHA_NOACK_NET_DEVICE_H 
   22 #define ALOHA_NOACK_NET_DEVICE_H 
   26 #include <ns3/address.h> 
   27 #include <ns3/net-device.h> 
   28 #include <ns3/callback.h> 
   29 #include <ns3/packet.h> 
   30 #include <ns3/traced-callback.h> 
   31 #include <ns3/nstime.h> 
   33 #include <ns3/mac48-address.h> 
   34 #include <ns3/generic-phy.h> 
   39 class SpectrumChannel;
 
   41 class SpectrumErrorModel;
 
  150   virtual void SetIfIndex (
const uint32_t index);
 
  153   virtual bool SetMtu (
const uint16_t mtu);
 
  154   virtual uint16_t 
GetMtu (
void) 
const;
 
  165                      uint16_t protocolNumber);
 
  167                          uint16_t protocolNumber);
 
virtual void SetIfIndex(const uint32_t index)
 
Smart pointer class similar to boost::intrusive_ptr. 
 
void NotifyReceptionStart()
Notify the MAC that the PHY has started a reception. 
 
virtual bool IsBridge(void) const 
Return true if the net device is acting as a bridge. 
 
virtual bool SendFrom(Ptr< Packet > packet, const Address &source, const Address &dest, uint16_t protocolNumber)
 
virtual Address GetMulticast(Ipv4Address addr) const 
Make and return a MAC multicast address using the provided multicast group. 
 
void SetGenericPhyTxStartCallback(GenericPhyTxStartCallback c)
set the callback used to instruct the lower layer to start a TX 
 
Forward calls to a chain of Callback. 
 
virtual Address GetBroadcast(void) const 
 
TracedCallback< Ptr< const Packet > > m_macTxDropTrace
 
virtual bool IsPointToPoint(void) const 
Return true if the net device is on a point-to-point link. 
 
TracedCallback< Ptr< const Packet > > m_macPromiscRxTrace
 
virtual void AddLinkChangeCallback(Callback< void > callback)
 
TracedCallback m_linkChangeCallbacks
List of callbacks to fire if the link changes state (up or down). 
 
a polymophic address class 
 
virtual Ptr< Node > GetNode(void) const 
 
void NotifyReceptionEndOk(Ptr< Packet > p)
Notify the MAC that the PHY finished a reception successfully. 
 
GenericPhyTxStartCallback m_phyMacTxStartCallback
 
virtual void SetReceiveCallback(NetDevice::ReceiveCallback cb)
 
virtual uint16_t GetMtu(void) const 
 
virtual bool IsBroadcast(void) const 
 
void NotifyTransmissionEnd(Ptr< const Packet >)
Notify the MAC that the PHY has finished a previously started transmission. 
 
virtual bool SetMtu(const uint16_t mtu)
 
virtual void DoDispose(void)
Destructor implementation. 
 
TracedCallback< Ptr< const Packet > > m_macRxTrace
 
virtual bool IsLinkUp(void) const 
 
Every class exported by the ns3 library is enclosed in the ns3 namespace. 
 
Callback< bool, Ptr< NetDevice >, Ptr< const Packet >, uint16_t, const Address &, const Address &, enum PacketType > PromiscReceiveCallback
 
virtual bool SupportsSendFrom(void) const 
 
TracedCallback< Ptr< const Packet > > m_macTxTrace
 
void SetChannel(Ptr< Channel > c)
This class doesn't talk directly with the underlying channel (a dedicated PHY class is expected to do...
 
static TypeId GetTypeId(void)
 
void StartTransmission()
start the transmission of a packet by contacting the PHY layer 
 
virtual bool NeedsArp(void) const 
 
Ptr< Object > GetPhy() const 
 
virtual void SetQueue(Ptr< Queue > queue)
set the queue which is going to be used by this device 
 
virtual bool IsMulticast(void) const 
 
This devices implements the following features: 
 
NetDevice::PromiscReceiveCallback m_promiscRxCallback
 
void NotifyReceptionEndError()
Notify the MAC that the PHY finished a reception with an error. 
 
Describes an IPv6 address. 
 
Ipv4 addresses are stored in host order in this class. 
 
Ptr< Packet > m_currentPkt
 
Network layer to device interface. 
 
void SetPhy(Ptr< Object > phy)
Set the Phy object which is attached to this device. 
 
virtual ~AlohaNoackNetDevice()
 
virtual bool Send(Ptr< Packet > packet, const Address &dest, uint16_t protocolNumber)
 
void NotifyGuardIntervalEnd()
 
a unique identifier for an interface. 
 
virtual void SetPromiscReceiveCallback(PromiscReceiveCallback cb)
 
virtual uint32_t GetIfIndex(void) const 
 
virtual void SetNode(Ptr< Node > node)
 
NetDevice::ReceiveCallback m_rxCallback
 
virtual Ptr< Channel > GetChannel(void) const 
 
virtual Address GetAddress(void) const 
 
virtual void SetAddress(Address address)
Set the address of this interface.