LEFT | RIGHT |
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ | 1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ |
2 /* | 2 /* |
3 * Copyright (c) 2007, 2008 University of Washington | 3 * Copyright (c) 2007, 2008 University of Washington |
4 * | 4 * |
5 * This program is free software; you can redistribute it and/or modify | 5 * This program is free software; you can redistribute it and/or modify |
6 * it under the terms of the GNU General Public License version 2 as | 6 * it under the terms of the GNU General Public License version 2 as |
7 * published by the Free Software Foundation; | 7 * published by the Free Software Foundation; |
8 * | 8 * |
9 * This program is distributed in the hope that it will be useful, | 9 * This program is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
507 bool | 507 bool |
508 PointToPointNetDevice::IsMulticast (void) const | 508 PointToPointNetDevice::IsMulticast (void) const |
509 { | 509 { |
510 NS_LOG_FUNCTION (this); | 510 NS_LOG_FUNCTION (this); |
511 return true; | 511 return true; |
512 } | 512 } |
513 | 513 |
514 Address | 514 Address |
515 PointToPointNetDevice::GetMulticast (Ipv4Address multicastGroup) const | 515 PointToPointNetDevice::GetMulticast (Ipv4Address multicastGroup) const |
516 { | 516 { |
517 NS_UNUSED(multicastGroup); | 517 NS_UNUSED (multicastGroup); |
518 NS_LOG_FUNCTION (this); | 518 NS_LOG_FUNCTION (this); |
519 return Mac48Address ("01:00:5e:00:00:00"); | 519 return Mac48Address ("01:00:5e:00:00:00"); |
520 } | 520 } |
521 | 521 |
522 Address | 522 Address |
523 PointToPointNetDevice::GetMulticast (Ipv6Address addr) const | 523 PointToPointNetDevice::GetMulticast (Ipv6Address addr) const |
524 { | 524 { |
525 NS_LOG_FUNCTION (this << addr); | 525 NS_LOG_FUNCTION (this << addr); |
526 return Mac48Address ("33:33:00:00:00:00"); | 526 return Mac48Address ("33:33:00:00:00:00"); |
527 } | 527 } |
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
672 { | 672 { |
673 NS_LOG_FUNCTION (this << mtu); | 673 NS_LOG_FUNCTION (this << mtu); |
674 m_mtu = mtu; | 674 m_mtu = mtu; |
675 return true; | 675 return true; |
676 } | 676 } |
677 | 677 |
678 uint16_t | 678 uint16_t |
679 PointToPointNetDevice::GetMtu (void) const | 679 PointToPointNetDevice::GetMtu (void) const |
680 { | 680 { |
681 NS_LOG_FUNCTION (this); | 681 NS_LOG_FUNCTION (this); |
682 return (uint16_t)m_mtu; | 682 return static_cast<uint16_t> (m_mtu); |
683 } | 683 } |
684 | 684 |
685 uint16_t | 685 uint16_t |
686 PointToPointNetDevice::PppToEther (uint16_t proto) | 686 PointToPointNetDevice::PppToEther (uint16_t proto) |
687 { | 687 { |
688 NS_LOG_FUNCTION_NOARGS(); | 688 NS_LOG_FUNCTION_NOARGS(); |
689 switch(proto) | 689 switch(proto) |
690 { | 690 { |
691 case 0x0021: return 0x0800; //IPv4 | 691 case 0x0021: return 0x0800; //IPv4 |
692 case 0x0057: return 0x86DD; //IPv6 | 692 case 0x0057: return 0x86DD; //IPv6 |
(...skipping 10 matching lines...) Expand all Loading... |
703 { | 703 { |
704 case 0x0800: return 0x0021; //IPv4 | 704 case 0x0800: return 0x0021; //IPv4 |
705 case 0x86DD: return 0x0057; //IPv6 | 705 case 0x86DD: return 0x0057; //IPv6 |
706 default: NS_ASSERT_MSG (false, "PPP Protocol number not defined!"); | 706 default: NS_ASSERT_MSG (false, "PPP Protocol number not defined!"); |
707 } | 707 } |
708 return 0; | 708 return 0; |
709 } | 709 } |
710 | 710 |
711 | 711 |
712 } // namespace ns3 | 712 } // namespace ns3 |
LEFT | RIGHT |