Make the new NetDevice APIs pure virtual methods, by Mathieu's insistence.
This commit is contained in:
@@ -1538,7 +1538,7 @@ def register_Ns3NetDevice_methods(root_module, cls):
|
||||
cls.add_method('SendFrom',
|
||||
'bool',
|
||||
[param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address&', 'source', is_const=True), param('ns3::Address&', 'dest', is_const=True), param('uint16_t', 'protocolNumber')],
|
||||
is_virtual=True)
|
||||
is_pure_virtual=True, is_virtual=True)
|
||||
## net-device.h: ns3::Ptr<ns3::Node> ns3::NetDevice::GetNode() const [member function]
|
||||
cls.add_method('GetNode',
|
||||
'ns3::Ptr< ns3::Node >',
|
||||
@@ -1563,12 +1563,12 @@ def register_Ns3NetDevice_methods(root_module, cls):
|
||||
cls.add_method('SetPromiscReceiveCallback',
|
||||
'void',
|
||||
[param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet >, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType >', 'cb')],
|
||||
is_virtual=True)
|
||||
is_pure_virtual=True, is_virtual=True)
|
||||
## net-device.h: bool ns3::NetDevice::SupportsPromiscuous() const [member function]
|
||||
cls.add_method('SupportsPromiscuous',
|
||||
'bool',
|
||||
[],
|
||||
is_const=True, is_virtual=True)
|
||||
is_pure_virtual=True, is_const=True, is_virtual=True)
|
||||
cls.add_constructor([])
|
||||
return
|
||||
|
||||
@@ -2444,6 +2444,16 @@ def register_Ns3SimpleNetDevice_methods(root_module, cls):
|
||||
'void',
|
||||
[param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet >, unsigned short, ns3::Address const&, ns3::empty, ns3::empty >', 'cb')],
|
||||
is_virtual=True)
|
||||
## simple-net-device.h: void ns3::SimpleNetDevice::SetPromiscReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType> cb) [member function]
|
||||
cls.add_method('SetPromiscReceiveCallback',
|
||||
'void',
|
||||
[param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet >, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType >', 'cb')],
|
||||
is_virtual=True)
|
||||
## simple-net-device.h: bool ns3::SimpleNetDevice::SupportsPromiscuous() const [member function]
|
||||
cls.add_method('SupportsPromiscuous',
|
||||
'bool',
|
||||
[],
|
||||
is_const=True, is_virtual=True)
|
||||
## simple-net-device.h: void ns3::SimpleNetDevice::DoDispose() [member function]
|
||||
cls.add_method('DoDispose',
|
||||
'void',
|
||||
|
||||
@@ -232,6 +232,16 @@ def register_Ns3PointToPointNetDevice_methods(root_module, cls):
|
||||
'void',
|
||||
[param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet >, unsigned short, ns3::Address const&, ns3::empty, ns3::empty >', 'cb')],
|
||||
is_virtual=True)
|
||||
## point-to-point-net-device.h: void ns3::PointToPointNetDevice::SetPromiscReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType> cb) [member function]
|
||||
cls.add_method('SetPromiscReceiveCallback',
|
||||
'void',
|
||||
[param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet >, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType >', 'cb')],
|
||||
is_virtual=True)
|
||||
## point-to-point-net-device.h: bool ns3::PointToPointNetDevice::SupportsPromiscuous() const [member function]
|
||||
cls.add_method('SupportsPromiscuous',
|
||||
'bool',
|
||||
[],
|
||||
is_const=True, is_virtual=True)
|
||||
## point-to-point-net-device.h: void ns3::PointToPointNetDevice::DoDispose() [member function]
|
||||
cls.add_method('DoDispose',
|
||||
'void',
|
||||
|
||||
@@ -333,10 +333,10 @@ def register_Ns3Watchdog_methods(root_module, cls):
|
||||
|
||||
def register_Ns3Simulator_methods(root_module, cls):
|
||||
## simulator.h: static void ns3::Simulator::SetImplementation(ns3::Ptr<ns3::SimulatorImpl> impl) [member function]
|
||||
#cls.add_method('SetImplementation',
|
||||
# 'void',
|
||||
# [param('ns3::Ptr< ns3::SimulatorImpl >', 'impl')],
|
||||
# is_static=True)
|
||||
cls.add_method('SetImplementation',
|
||||
'void',
|
||||
[param('ns3::Ptr< ns3::SimulatorImpl >', 'impl')],
|
||||
is_static=True)
|
||||
## simulator.h: static void ns3::Simulator::SetScheduler(ns3::Ptr<ns3::Scheduler> scheduler) [member function]
|
||||
cls.add_method('SetScheduler',
|
||||
'void',
|
||||
|
||||
@@ -2155,6 +2155,21 @@ def register_Ns3WifiNetDevice_methods(root_module, cls):
|
||||
'void',
|
||||
[param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet >, unsigned short, ns3::Address const&, ns3::empty, ns3::empty >', 'cb')],
|
||||
is_virtual=True)
|
||||
## wifi-net-device.h: bool ns3::WifiNetDevice::SendFrom(ns3::Ptr<ns3::Packet> packet, ns3::Address const & source, ns3::Address const & dest, uint16_t protocolNumber) [member function]
|
||||
cls.add_method('SendFrom',
|
||||
'bool',
|
||||
[param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address&', 'source', is_const=True), param('ns3::Address&', 'dest', is_const=True), param('uint16_t', 'protocolNumber')],
|
||||
is_virtual=True)
|
||||
## wifi-net-device.h: void ns3::WifiNetDevice::SetPromiscReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType> cb) [member function]
|
||||
cls.add_method('SetPromiscReceiveCallback',
|
||||
'void',
|
||||
[param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet >, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType >', 'cb')],
|
||||
is_virtual=True)
|
||||
## wifi-net-device.h: bool ns3::WifiNetDevice::SupportsPromiscuous() const [member function]
|
||||
cls.add_method('SupportsPromiscuous',
|
||||
'bool',
|
||||
[],
|
||||
is_const=True, is_virtual=True)
|
||||
## wifi-net-device.h: void ns3::WifiNetDevice::DoDispose() [member function]
|
||||
cls.add_method('DoDispose',
|
||||
'void',
|
||||
|
||||
Reference in New Issue
Block a user