src/internet-node/arp-cache.h
changeset 1341 f685d4bf320f
parent 1161 bb72baff8b26
child 1866 e7dbcc4df546
equal deleted inserted replaced
1340:a8d774560c2b 1341:f685d4bf320f
    46   class Entry;
    46   class Entry;
    47   /**
    47   /**
    48    * \param device The hardware NetDevice associated with this ARP chache
    48    * \param device The hardware NetDevice associated with this ARP chache
    49    * \param interface the Ipv4Interface associated with this ARP chache
    49    * \param interface the Ipv4Interface associated with this ARP chache
    50    */
    50    */
    51   ArpCache (Ptr<NetDevice> device, Ipv4Interface *interface);
    51   ArpCache (Ptr<NetDevice> device, Ptr<Ipv4Interface> interface);
    52   ~ArpCache ();
    52   ~ArpCache ();
    53   /**
    53   /**
    54    * \return The NetDevice that this ARP cache is associated with
    54    * \return The NetDevice that this ARP cache is associated with
    55    */
    55    */
    56   Ptr<NetDevice> GetDevice (void) const;
    56   Ptr<NetDevice> GetDevice (void) const;
    57   /**
    57   /**
    58    * \return the Ipv4Interface that this ARP cache is associated with
    58    * \return the Ipv4Interface that this ARP cache is associated with
    59    */
    59    */
    60   Ipv4Interface *GetInterface (void) const;
    60   Ptr<Ipv4Interface> GetInterface (void) const;
    61   
    61   
    62   void SetAliveTimeout (Time aliveTimeout);
    62   void SetAliveTimeout (Time aliveTimeout);
    63   void SetDeadTimeout (Time deadTimeout);
    63   void SetDeadTimeout (Time deadTimeout);
    64   void SetWaitReplyTimeout (Time waitReplyTimeout);
    64   void SetWaitReplyTimeout (Time waitReplyTimeout);
    65   Time GetAliveTimeout (void) const;
    65   Time GetAliveTimeout (void) const;
   150 private:
   150 private:
   151   typedef sgi::hash_map<Ipv4Address, ArpCache::Entry *, Ipv4AddressHash> Cache;
   151   typedef sgi::hash_map<Ipv4Address, ArpCache::Entry *, Ipv4AddressHash> Cache;
   152   typedef sgi::hash_map<Ipv4Address, ArpCache::Entry *, Ipv4AddressHash>::iterator CacheI;
   152   typedef sgi::hash_map<Ipv4Address, ArpCache::Entry *, Ipv4AddressHash>::iterator CacheI;
   153 
   153 
   154   Ptr<NetDevice> m_device;
   154   Ptr<NetDevice> m_device;
   155   Ipv4Interface *m_interface;
   155   Ptr<Ipv4Interface> m_interface;
   156   Time m_aliveTimeout;
   156   Time m_aliveTimeout;
   157   Time m_deadTimeout;
   157   Time m_deadTimeout;
   158   Time m_waitReplyTimeout;
   158   Time m_waitReplyTimeout;
   159   Cache m_arpCache;
   159   Cache m_arpCache;
   160 };
   160 };