remove Channel::GetType

This commit is contained in:
Tom Henderson
2007-08-03 08:23:23 -07:00
parent d3f1f2a341
commit 3378f0de19
4 changed files with 0 additions and 27 deletions

View File

@@ -171,12 +171,6 @@ PointToPointChannel::GetDevice (uint32_t i) const
return m_link[i].m_src;
}
Channel::ChannelType
PointToPointChannel::GetType (void) const
{
return Channel::PointToPoint;
}
DataRate
PointToPointChannel::GetDataRate (void)
{

View File

@@ -94,8 +94,6 @@ public:
virtual uint32_t GetNDevices (void) const;
virtual Ptr<NetDevice> GetDevice (uint32_t i) const;
virtual ChannelType GetType (void) const;
virtual DataRate GetDataRate (void);
virtual Time GetDelay (void);

View File

@@ -36,12 +36,6 @@ class Channel : public Object
{
public:
static const InterfaceId iid;
enum ChannelType
{
Unknown = 0,
PointToPoint,
Multipoint
};
Channel ();
Channel (std::string name);
@@ -63,18 +57,9 @@ public:
*/
virtual Ptr<NetDevice> GetDevice (uint32_t i) const = 0;
/**
* \returns the abstract type of this channel. Right now this is only
* PointToPoint (p2p) or Multipoint (Ethernet).
*
* This method must be implemented by subclasses.
*/
virtual ChannelType GetType (void) const = 0;
protected:
virtual ~Channel ();
std::string m_name;
ChannelType m_channelType;
private:
};

View File

@@ -534,10 +534,6 @@ GlobalRouter::GetLSA (uint32_t n, GlobalRouterLSA &lsa) const
Ptr<NetDevice>
GlobalRouter::GetAdjacent(Ptr<NetDevice> nd, Ptr<Channel> ch) const
{
//
// Double-check that channel agrees with device that it's a point-to-point
//
NS_ASSERT(ch->GetType () == Channel::PointToPoint);
uint32_t nDevices = ch->GetNDevices();
NS_ASSERT_MSG(nDevices == 2,