--- a/CHANGES.html Fri Apr 05 16:50:37 2013 +0200
+++ b/CHANGES.html Fri Apr 05 17:59:11 2013 +0200
@@ -55,7 +55,12 @@
<h2>New API:</h2>
<ul>
-<li></li>
+ <li>In Ipv4ClickRouting, the following APIs were added:
+ <ul>
+ <li>Ipv4ClickRouting::SetDefines(), accessible through ClickInternetStackHelper::SetDefines(), for the user to set Click defines from the ns-3 simulation file.</li>
+ <li>SIMCLICK_GET_RANDOM_INT click-to-simulator command for ns-3 to drive Click's random number generation.</li>
+ </ul>
+ </li>
</ul>
<h2>Changes to existing API:</h2>
--- a/RELEASE_NOTES Fri Apr 05 16:50:37 2013 +0200
+++ b/RELEASE_NOTES Fri Apr 05 17:59:11 2013 +0200
@@ -22,9 +22,15 @@
New user-visible features
-------------------------
+- ns-3-click: it's now possible to (i) have Click pull random numbers from
+ ns-3 and (ii) have ns-3 set "defines" in Click via the simulation file
+ (see src/click/examples/nsclick-defines.cc).
Bugs fixed
----------
+- bug 1566 - WiFi SNR tag improvements
+- Bug 1582 - IPv6 raw socket return value is not like Linux socket
+- bug 1585 - Length field of A-MSDU subframe header endianness
Known issues
------------
--- a/bindings/python/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/bindings/python/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -6,25 +6,17 @@
import shutil
import sys
-import Task
-import Options
-import Configure
-import TaskGen
-import Logs
-import Build
-import Utils
+from waflib import Task, Options, Configure, TaskGen, Logs, Build, Utils, Errors
+from waflib.Errors import WafError
-from waflib.Errors import WafError
+feature = TaskGen.feature
+after = TaskGen.after
## https://launchpad.net/pybindgen/
REQUIRED_PYBINDGEN_VERSION = (0, 15, 0, 809)
REQUIRED_PYGCCXML_VERSION = (0, 9, 5)
-from TaskGen import feature, after
-import Task
-
-
def add_to_python_path(path):
if os.environ.get('PYTHONPATH', ''):
@@ -38,7 +30,7 @@
def options(opt):
- opt.tool_options('python')
+ opt.load('python')
opt.add_option('--disable-python',
help=("Don't build Python bindings."),
action="store_true", default=False,
@@ -76,7 +68,7 @@
available_modules.sort()
all_modules_enabled = (enabled_modules == available_modules)
- conf.check_tool('misc', tooldir=['waf-tools'])
+ conf.load('misc', tooldir=['waf-tools'])
if sys.platform == 'cygwin':
conf.report_optional_feature("python", "Python Bindings", False,
@@ -91,20 +83,20 @@
conf.env.PYTHON = Options.options.with_python
try:
- conf.check_tool('python')
- except Configure.ConfigurationError, ex:
+ conf.load('python')
+ except Errors.ConfigurationError, ex:
conf.report_optional_feature("python", "Python Bindings", False,
"The python interpreter was not found")
return
try:
conf.check_python_version((2,3))
- except Configure.ConfigurationError, ex:
+ except Errors.ConfigurationError, ex:
conf.report_optional_feature("python", "Python Bindings", False,
"The python found version is too low (2.3 required)")
return
try:
conf.check_python_headers()
- except Configure.ConfigurationError, ex:
+ except Errors.ConfigurationError, ex:
conf.report_optional_feature("python", "Python Bindings", False,
"Python library or headers missing")
return
@@ -161,7 +153,7 @@
try:
conf.check_python_module('pybindgen')
- except Configure.ConfigurationError:
+ except Errors.ConfigurationError:
Logs.warn("pybindgen missing => no python bindings")
conf.report_optional_feature("python", "Python Bindings", False,
"PyBindGen missing")
@@ -197,9 +189,9 @@
try:
ret = conf.run_c_code(code=test_program,
- env=conf.env.copy(), compile_filename='test.cc',
+ env=conf.env.derive(), compile_filename='test.cc',
features='cxx cprogram', execute=False)
- except Configure.ConfigurationError:
+ except Errors.ConfigurationError:
ret = 1
conf.msg('Checking for types %s and %s equivalence' % (t1, t2), (ret and 'no' or 'yes'))
return not ret
@@ -250,7 +242,7 @@
## Check for pygccxml
try:
conf.check_python_module('pygccxml')
- except Configure.ConfigurationError:
+ except Errors.ConfigurationError:
conf.report_optional_feature("pygccxml", "Python API Scanning Support", False,
"Missing 'pygccxml' Python module")
return
@@ -322,7 +314,7 @@
"""Uses gccxml to scan the file 'everything.h' and extract API definitions.
"""
after = 'gen_ns3_module_header ns3header'
- before = 'cc cxx command'
+ before = 'cxx command'
color = "BLUE"
def __init__(self, curdirnode, env, bld, target, cflags, module):
self.bld = bld
@@ -393,7 +385,7 @@
"""Tasks that waits for the python-scan-* tasks to complete and then signals WAF to exit
"""
after = 'apiscan'
- before = 'cc cxx'
+ before = 'cxx'
color = "BLUE"
def __init__(self, curdirnode, env, bld):
self.bld = bld
@@ -415,7 +407,7 @@
class gen_ns3_compat_pymod_task(Task.Task):
"""Generates a 'ns3.py' compatibility module."""
- before = 'cc cxx'
+ before = 'cxx'
color = 'BLUE'
def run(self):
@@ -437,8 +429,6 @@
return
env = bld.env
- curdir = bld.path.abspath()
-
set_pybindgen_pythonpath(env)
if Options.options.apiscan:
@@ -489,9 +479,7 @@
grp = bld.get_group(bld.current_group)
grp.append(task)
- bld.new_task_gen(features='copy',
- source="ns__init__.py",
- target='ns/__init__.py')
+ bld(features='copy', source="ns__init__.py", target='ns/__init__.py')
bld.install_as('${PYTHONARCHDIR}/ns/__init__.py', 'ns__init__.py')
--- a/doc/manual/Makefile Fri Apr 05 16:50:37 2013 +0200
+++ b/doc/manual/Makefile Fri Apr 05 17:59:11 2013 +0200
@@ -49,6 +49,8 @@
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest
+.NOTPARALLEL:
+
help:
@echo "Please use \`make <target>' where <target> is one of"
@echo " html to make standalone HTML files"
--- a/doc/models/Makefile Fri Apr 05 16:50:37 2013 +0200
+++ b/doc/models/Makefile Fri Apr 05 17:59:11 2013 +0200
@@ -48,6 +48,7 @@
$(SRC)/propagation/doc/propagation.rst \
$(SRC)/network/doc/network-overview.rst \
$(SRC)/network/doc/packets.rst \
+ $(SRC)/network/doc/error-model.rst \
$(SRC)/network/doc/sockets-api.rst \
$(SRC)/network/doc/simple.rst \
$(SRC)/network/doc/queue.rst \
@@ -280,6 +281,8 @@
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest
+.NOTPARALLEL:
+
help:
@echo "Please use \`make <target>' where <target> is one of"
@echo " html to make standalone HTML files"
--- a/doc/models/source/network.rst Fri Apr 05 16:50:37 2013 +0200
+++ b/doc/models/source/network.rst Fri Apr 05 17:59:11 2013 +0200
@@ -4,6 +4,7 @@
.. toctree::
packets
+ error-model
network-overview
sockets-api
simple
--- a/doc/tutorial-pt-br/Makefile Fri Apr 05 16:50:37 2013 +0200
+++ b/doc/tutorial-pt-br/Makefile Fri Apr 05 17:59:11 2013 +0200
@@ -25,6 +25,8 @@
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest
+.NOTPARALLEL:
+
%.eps : %.dia; $(DIA) -t eps $< -e $@
%.png : %.dia; $(DIA) -t png $< -e $@
%.pdf : %.eps; $(EPSTOPDF) $< -o=$@
--- a/doc/tutorial/Makefile Fri Apr 05 16:50:37 2013 +0200
+++ b/doc/tutorial/Makefile Fri Apr 05 17:59:11 2013 +0200
@@ -25,6 +25,8 @@
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest
+.NOTPARALLEL:
+
%.eps : %.dia; $(DIA) -t eps $< -e $@
%.png : %.dia; $(DIA) -t png $< -e $@
%.pdf : %.eps; $(EPSTOPDF) $< -o=$@
--- a/examples/matrix-topology/matrix-topology.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/examples/matrix-topology/matrix-topology.cc Fri Apr 05 17:59:11 2013 +0200
@@ -44,7 +44,6 @@
#include <string>
#include <vector>
#include <cstdlib>
-#include <time.h>
#include "ns3/core-module.h"
#include "ns3/network-module.h"
--- a/examples/tcp/tcp-large-transfer.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/examples/tcp/tcp-large-transfer.cc Fri Apr 05 17:59:11 2013 +0200
@@ -29,12 +29,9 @@
// numbers respectively
// Usage (e.g.): ./waf --run tcp-large-transfer
-
-#include <ctype.h>
#include <iostream>
#include <fstream>
#include <string>
-#include <cassert>
#include "ns3/core-module.h"
#include "ns3/applications-module.h"
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tcp/tcp-nsc-comparison.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,180 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 NICT
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Hajime Tazaki <tazaki@nict.go.jp>
+ *
+ * This code is a modified version of the code used for the the experiments in the paper
+ * "DCE Cradle: Simulate Network Protocols with Real Stacks for Better Realism"
+ * by Hajime Tazaki, Frederic Urbani and Thierry Turlett presented at WNS3 2013
+ *
+ */
+
+#include "ns3/log.h"
+#include "ns3/core-module.h"
+#include "ns3/network-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/point-to-point-module.h"
+#include "ns3/applications-module.h"
+#include "ns3/flow-monitor-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("TcpNscComparison");
+
+std::string m_stack = "nsc-linux";
+std::string sock_factory;
+int m_seed = 1;
+double startTime = 4.0;
+double stopTime = 20.0;
+uint32_t m_nNodes = 2;
+bool enablePcap = false;
+
+int
+main (int argc, char *argv[])
+{
+
+ //ensure the ns3 TCP default values match what nsc is using
+ Config::SetDefault ("ns3::TcpSocket::SegmentSize", UintegerValue (1448));
+ Config::SetDefault ("ns3::TcpSocket::DelAckCount", UintegerValue (1));
+
+ CommandLine cmd;
+ cmd.AddValue ("stack", "choose network stack", m_stack);
+ cmd.AddValue ("seed", "randomize seed", m_seed);
+ cmd.AddValue ("nNodes", "the number of nodes in left side", m_nNodes);
+ cmd.AddValue ("stopTime", "duration", stopTime);
+ cmd.AddValue ("enablePcap", "pcap", enablePcap);
+ cmd.Parse (argc, argv);
+
+ SeedManager::SetSeed (m_seed);
+
+ NodeContainer lefts, routers, rights, nodes;
+ lefts.Create (m_nNodes);
+ routers.Create (2);
+ rights.Create (m_nNodes);
+ nodes = NodeContainer (lefts, routers, rights);
+
+ InternetStackHelper internetStack;
+
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+ if (m_stack == "ns3")
+ {
+ sock_factory = "ns3::TcpSocketFactory";
+ internetStack.Install (nodes);
+ }
+ else if (m_stack == "nsc-linux")
+ {
+ internetStack.Install (routers);
+ sock_factory = "ns3::TcpSocketFactory";
+ internetStack.SetTcp ("ns3::NscTcpL4Protocol",
+ "Library", StringValue ("liblinux2.6.26.so"));
+ internetStack.Install (lefts);
+ internetStack.Install (rights);
+
+ //these are not implemented in ns3 tcp so disable for comparison
+ Config::Set ("/NodeList/*/$ns3::Ns3NscStack<linux2.6.26>/net.ipv4.tcp_sack", StringValue ("0"));
+ Config::Set ("/NodeList/*/$ns3::Ns3NscStack<linux2.6.26>/net.ipv4.tcp_timestamps", StringValue ("0"));
+ Config::Set ("/NodeList/*/$ns3::Ns3NscStack<linux2.6.26>/net.ipv4.tcp_window_scaling", StringValue ("0"));
+ }
+
+ PointToPointHelper pointToPoint;
+ pointToPoint.SetDeviceAttribute ("DataRate", StringValue ("5Mbps"));
+ pointToPoint.SetChannelAttribute ("Delay", StringValue ("1ns"));
+
+ Ipv4AddressHelper address;
+ Ipv4InterfaceContainer interfaces;
+
+ NetDeviceContainer dev0, dev1, dev2;
+ for (uint32_t i = 0; i < m_nNodes; i++)
+ {
+ std::ostringstream oss;
+ oss << "10.0." << i << ".0";
+ address.SetBase (oss.str ().c_str (), "255.255.255.0");
+ dev0 = pointToPoint.Install (NodeContainer (lefts.Get (i), routers.Get (0)));
+ address.Assign (dev0);
+ }
+
+ // bottle neck link
+ pointToPoint.SetDeviceAttribute ("DataRate", StringValue ("2Mbps"));
+ pointToPoint.SetChannelAttribute ("Delay", StringValue ("100ms"));
+ dev1 = pointToPoint.Install (NodeContainer (routers.Get (0), routers.Get (1)));
+
+ pointToPoint.SetDeviceAttribute ("DataRate", StringValue ("5Mbps"));
+ pointToPoint.SetChannelAttribute ("Delay", StringValue ("1ns"));
+ // for right links
+ for (uint32_t i = 0; i < m_nNodes; i++)
+ {
+ std::ostringstream oss;
+ oss << "10.2." << i << ".0";
+ address.SetBase (oss.str ().c_str (), "255.255.255.0");
+ dev2 = pointToPoint.Install (NodeContainer (routers.Get (1), rights.Get (i)));
+ address.Assign (dev2);
+ }
+
+ // bottle neck link
+ Ptr<RateErrorModel> em1 =
+ CreateObjectWithAttributes<RateErrorModel> (
+ "ErrorRate", DoubleValue (0.05),
+ "ErrorUnit", EnumValue (RateErrorModel::ERROR_UNIT_PACKET)
+ );
+ dev1.Get (1)->SetAttribute ("ReceiveErrorModel", PointerValue (em1));
+
+ address.SetBase ("10.1.0.0", "255.255.255.0");
+ address.Assign (dev1);
+ Ipv4GlobalRoutingHelper::PopulateRoutingTables ();
+
+ ApplicationContainer apps;
+
+ OnOffHelper onoff = OnOffHelper (sock_factory,
+ InetSocketAddress (Ipv4Address ("10.2.0.2"), 2000));
+ onoff.SetAttribute ("OnTime", StringValue ("ns3::ConstantRandomVariable[Constant=1]"));
+ onoff.SetAttribute ("OffTime", StringValue ("ns3::ConstantRandomVariable[Constant=0]"));
+
+ // Flow 1 - n
+ for (uint32_t i = 0; i < m_nNodes; i++)
+ {
+ std::ostringstream oss;
+ oss << "10.2." << i << ".2";
+ onoff.SetAttribute ("Remote", AddressValue (InetSocketAddress (Ipv4Address (oss.str ().c_str ()), 2000)));
+ onoff.SetAttribute ("PacketSize", StringValue ("1024"));
+ onoff.SetAttribute ("DataRate", StringValue ("1Mbps"));
+ onoff.SetAttribute ("StartTime", TimeValue (Seconds (startTime)));
+ apps = onoff.Install (lefts.Get (i));
+ }
+
+ PacketSinkHelper sink = PacketSinkHelper (sock_factory,
+ InetSocketAddress (Ipv4Address::GetAny (), 2000));
+ apps = sink.Install (rights);
+ apps.Start (Seconds (3.9999));
+
+ pointToPoint.EnablePcapAll ("nsc.pcap");
+
+ Simulator::Stop (Seconds (stopTime));
+ Simulator::Run ();
+
+ Ptr<PacketSink> pktsink;
+ std::cout << "Total ";
+ for (uint32_t i = 0; i < m_nNodes; i++)
+ {
+ pktsink = apps.Get (i)->GetObject<PacketSink> ();
+ std::cout << "Rx(" << i << ") = " << pktsink->GetTotalRx () <<
+ " bytes (" << pktsink->GetTotalRx () * 8 / (stopTime - startTime) << " bps), ";
+ }
+ std::cout << std::endl;
+
+ Simulator::Destroy ();
+ return 0;
+}
--- a/examples/tcp/tcp-nsc-lfn.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/examples/tcp/tcp-nsc-lfn.cc Fri Apr 05 17:59:11 2013 +0200
@@ -26,11 +26,9 @@
// - pcap traces generated as tcp-nsc-lfn-0-0.pcap and tcp-nsc-lfn-1-0.pcap
// Usage (e.g.): ./waf --run 'tcp-nsc-lfn --TCP_CONGESTION=hybla --runtime=30'
-#include <ctype.h>
#include <iostream>
#include <fstream>
#include <string>
-#include <cassert>
#include "ns3/core-module.h"
#include "ns3/network-module.h"
--- a/examples/tcp/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/examples/tcp/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -24,3 +24,8 @@
obj = bld.create_ns3_program('tcp-bulk-send',
['point-to-point', 'applications', 'internet'])
obj.source = 'tcp-bulk-send.cc'
+
+ obj = bld.create_ns3_program('tcp-nsc-comparison',
+ ['point-to-point', 'internet', 'applications'])
+
+ obj.source = 'tcp-nsc-comparison.cc'
--- a/examples/wireless/ofdm-validation.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/examples/wireless/ofdm-validation.cc Fri Apr 05 17:59:11 2013 +0200
@@ -24,7 +24,7 @@
#include <fstream>
#include <vector>
-#include <math.h>
+#include <cmath>
using namespace ns3;
@@ -62,9 +62,9 @@
for (double snr = -5.0; snr <= 30.0; snr += 0.1)
{
- double ps = yans->GetChunkSuccessRate (WifiMode (modes[i]), pow (10.0,snr/10.0), FrameSize*8);
+ double ps = yans->GetChunkSuccessRate (WifiMode (modes[i]), std::pow (10.0,snr/10.0), FrameSize*8);
yansdataset.Add (snr, ps);
- ps = nist->GetChunkSuccessRate (WifiMode (modes[i]), pow (10.0,snr/10.0), FrameSize*8);
+ ps = nist->GetChunkSuccessRate (WifiMode (modes[i]), std::pow (10.0,snr/10.0), FrameSize*8);
nistdataset.Add (snr, ps);
}
--- a/src/antenna/test/test-angles.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/antenna/test/test-angles.cc Fri Apr 05 17:59:11 2013 +0200
@@ -120,90 +120,90 @@
AnglesTestSuite::AnglesTestSuite ()
: TestSuite ("angles", UNIT)
{
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, 0, 0), Angles (0, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 0, 0), Angles (M_PI, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 1, 0), Angles (M_PI_2, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, -1, 0), Angles (-M_PI_2, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, 1), Angles (0, 0)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, -1), Angles (0, M_PI)));
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, 0, 0), Angles (0, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 0, 0), Angles (M_PI, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 1, 0), Angles (M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, -1, 0), Angles (-M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, 1), Angles (0, 0)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, -1), Angles (0, M_PI)), TestCase::QUICK);
- AddTestCase (new OneVectorConstructorTestCase (Vector (2, 0, 0), Angles (0, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (-2, 0, 0), Angles (M_PI, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 2, 0), Angles (M_PI_2, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, -2, 0), Angles (-M_PI_2, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, 2), Angles (0, 0)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, -2), Angles (0, M_PI)));
+ AddTestCase (new OneVectorConstructorTestCase (Vector (2, 0, 0), Angles (0, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (-2, 0, 0), Angles (M_PI, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 2, 0), Angles (M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, -2, 0), Angles (-M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, 2), Angles (0, 0)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 0, -2), Angles (0, M_PI)), TestCase::QUICK);
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, 0, 1), Angles (0, M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, 0, -1), Angles (0, 3*M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, 1, 0), Angles (M_PI_4, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, -1, 0), Angles (-M_PI_4, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 0, 1), Angles (M_PI, M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 0, -1), Angles (M_PI, 3*M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 1, 0), Angles (3*M_PI_4, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (-1, -1, 0), Angles (-3*M_PI_4, M_PI_2)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 1, 1), Angles (M_PI_2, M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, 1, -1), Angles (M_PI_2, 3*M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, -1, 1), Angles (-M_PI_2, M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (0, -1, -1), Angles (-M_PI_2, 3*M_PI_4)));
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, 0, 1), Angles (0, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, 0, -1), Angles (0, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, 1, 0), Angles (M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, -1, 0), Angles (-M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 0, 1), Angles (M_PI, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 0, -1), Angles (M_PI, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 1, 0), Angles (3*M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (-1, -1, 0), Angles (-3*M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 1, 1), Angles (M_PI_2, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, 1, -1), Angles (M_PI_2, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, -1, 1), Angles (-M_PI_2, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (0, -1, -1), Angles (-M_PI_2, 3*M_PI_4)), TestCase::QUICK);
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, 1, std::sqrt (2)), Angles (M_PI_4, M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, 1, -std::sqrt (2)), Angles (M_PI_4, 3*M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (1, -1, std::sqrt (2)), Angles (-M_PI_4, M_PI_4)));
- AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 1, std::sqrt (2)), Angles (3*M_PI_4, M_PI_4)));
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, 1, std::sqrt (2)), Angles (M_PI_4, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, 1, -std::sqrt (2)), Angles (M_PI_4, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (1, -1, std::sqrt (2)), Angles (-M_PI_4, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new OneVectorConstructorTestCase (Vector (-1, 1, std::sqrt (2)), Angles (3*M_PI_4, M_PI_4)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 0, 0), Vector (0, 0, 0), Angles (0, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 0, 0), Vector (0, 0, 0), Angles (M_PI, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 1, 0), Vector (0, 0, 0), Angles (M_PI_2, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -1, 0), Vector (0, 0, 0), Angles (-M_PI_2, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, 1), Vector (0, 0, 0), Angles (0, 0)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, -1), Vector (0, 0, 0), Angles (0, M_PI)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 0, 0), Vector (0, 0, 0), Angles (0, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 0, 0), Vector (0, 0, 0), Angles (M_PI, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 1, 0), Vector (0, 0, 0), Angles (M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -1, 0), Vector (0, 0, 0), Angles (-M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, 1), Vector (0, 0, 0), Angles (0, 0)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, -1), Vector (0, 0, 0), Angles (0, M_PI)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (2, 0, 0), Vector (0, 0, 0), Angles (0, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-2, 0, 0), Vector (0, 0, 0), Angles (M_PI, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 2, 0), Vector (0, 0, 0), Angles (M_PI_2, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -2, 0), Vector (0, 0, 0), Angles (-M_PI_2, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, 2), Vector (0, 0, 0), Angles (0, 0)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, -2), Vector (0, 0, 0), Angles (0, M_PI)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (2, 0, 0), Vector (0, 0, 0), Angles (0, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-2, 0, 0), Vector (0, 0, 0), Angles (M_PI, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 2, 0), Vector (0, 0, 0), Angles (M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -2, 0), Vector (0, 0, 0), Angles (-M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, 2), Vector (0, 0, 0), Angles (0, 0)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 0, -2), Vector (0, 0, 0), Angles (0, M_PI)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 0, 1), Vector (0, 0, 0), Angles (0, M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 0, -1), Vector (0, 0, 0), Angles (0, 3*M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 1, 0), Vector (0, 0, 0), Angles (M_PI_4, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, -1, 0), Vector (0, 0, 0), Angles (-M_PI_4, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 0, 1), Vector (0, 0, 0), Angles (M_PI, M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 0, -1), Vector (0, 0, 0), Angles (M_PI, 3*M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 1, 0), Vector (0, 0, 0), Angles (3*M_PI_4, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, -1, 0), Vector (0, 0, 0), Angles (-3*M_PI_4, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 1, 1), Vector (0, 0, 0), Angles (M_PI_2, M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 1, -1), Vector (0, 0, 0), Angles (M_PI_2, 3*M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -1, 1), Vector (0, 0, 0), Angles (-M_PI_2, M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -1, -1), Vector (0, 0, 0), Angles (-M_PI_2, 3*M_PI_4)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 0, 1), Vector (0, 0, 0), Angles (0, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 0, -1), Vector (0, 0, 0), Angles (0, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 1, 0), Vector (0, 0, 0), Angles (M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, -1, 0), Vector (0, 0, 0), Angles (-M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 0, 1), Vector (0, 0, 0), Angles (M_PI, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 0, -1), Vector (0, 0, 0), Angles (M_PI, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 1, 0), Vector (0, 0, 0), Angles (3*M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, -1, 0), Vector (0, 0, 0), Angles (-3*M_PI_4, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 1, 1), Vector (0, 0, 0), Angles (M_PI_2, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, 1, -1), Vector (0, 0, 0), Angles (M_PI_2, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -1, 1), Vector (0, 0, 0), Angles (-M_PI_2, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -1, -1), Vector (0, 0, 0), Angles (-M_PI_2, 3*M_PI_4)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 1, std::sqrt (2)), Vector (0, 0, 0), Angles (M_PI_4, M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 1, -std::sqrt (2)), Vector (0, 0, 0), Angles (M_PI_4, 3*M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, -1, std::sqrt (2)), Vector (0, 0, 0), Angles (-M_PI_4, M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 1, std::sqrt (2)), Vector (0, 0, 0), Angles (3*M_PI_4, M_PI_4)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 1, std::sqrt (2)), Vector (0, 0, 0), Angles (M_PI_4, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 1, -std::sqrt (2)), Vector (0, 0, 0), Angles (M_PI_4, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, -1, std::sqrt (2)), Vector (0, 0, 0), Angles (-M_PI_4, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 1, std::sqrt (2)), Vector (0, 0, 0), Angles (3*M_PI_4, M_PI_4)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (3, 2, 2), Vector (2, 2, 2), Angles (0, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 2, 2), Vector (2, 2, 2), Angles (M_PI, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (2, 3, 2), Vector (2, 2, 2), Angles (M_PI_2, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 2, 2), Vector (-1, 3, 2), Angles (-M_PI_2, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (4, -2, 7), Vector (4, -2, 6), Angles (0, 0)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -5, -1), Vector (0, -5, 0), Angles (0, M_PI)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (3, 2, 2), Vector (2, 2, 2), Angles (0, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (1, 2, 2), Vector (2, 2, 2), Angles (M_PI, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (2, 3, 2), Vector (2, 2, 2), Angles (M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 2, 2), Vector (-1, 3, 2), Angles (-M_PI_2, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (4, -2, 7), Vector (4, -2, 6), Angles (0, 0)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -5, -1), Vector (0, -5, 0), Angles (0, M_PI)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-2, 2, -1), Vector (-4, 2, -1), Angles (0, M_PI_2)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (2, 2, 0), Vector (4, 2, 0), Angles (M_PI, M_PI_2)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-2, 2, -1), Vector (-4, 2, -1), Angles (0, M_PI_2)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (2, 2, 0), Vector (4, 2, 0), Angles (M_PI, M_PI_2)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 4, 4), Vector (-2, 4, 3), Angles (0, M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -2, -6), Vector (-1, -2, -5), Angles (0, 3*M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (77, 3, 43), Vector (78, 2, 43), Angles (3*M_PI_4, M_PI_2)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (-1, 4, 4), Vector (-2, 4, 3), Angles (0, M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0, -2, -6), Vector (-1, -2, -5), Angles (0, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (77, 3, 43), Vector (78, 2, 43), Angles (3*M_PI_4, M_PI_2)), TestCase::QUICK);
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (24, -2, -6 -std::sqrt (2)), Vector (23, -3, -6), Angles (M_PI_4, 3*M_PI_4)));
- AddTestCase (new TwoVectorsConstructorTestCase (Vector (0.5, 11.45, std::sqrt (2)-1), Vector (-0.5, 12.45, -1), Angles (-M_PI_4, M_PI_4)));
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (24, -2, -6 -std::sqrt (2)), Vector (23, -3, -6), Angles (M_PI_4, 3*M_PI_4)), TestCase::QUICK);
+ AddTestCase (new TwoVectorsConstructorTestCase (Vector (0.5, 11.45, std::sqrt (2)-1), Vector (-0.5, 12.45, -1), Angles (-M_PI_4, M_PI_4)), TestCase::QUICK);
};
--- a/src/antenna/test/test-cosine-antenna.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/antenna/test/test-cosine-antenna.cc Fri Apr 05 17:59:11 2013 +0200
@@ -118,88 +118,88 @@
// e.g., with a 60 deg beamwidth, gain is -20dB at +- 74.945 degrees from boresight
// phi, theta, beamwidth, orientation, maxGain, expectedGain, condition
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 60, 0, 0, 0, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 0, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 0, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (100), 0), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (180), 0), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-180), 0), 60, 0, 0, -20, LESSTHAN));
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 60, 0, 0, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 0, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 0, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (100), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (180), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-180), 0), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
// test positive orientation
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 60, 60, 0, 0, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 60, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 60, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (160), 0), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (210), 0), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (240), 0), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-40), 0), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-120), 0), 60, 60, 0, -20, LESSTHAN));
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 60, 60, 0, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 60, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 60, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (160), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (210), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (240), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-40), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-120), 0), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
// test negative orientation and different beamwidths
// with a 100 deg beamwidth, gain is -20dB at +- 117.47 degrees from boresight
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 100, -150, 0, 0, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 100, -150, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), 0), 100, -150, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-32.531), 0), 100, -150, 0, -20, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (92.531), 0), 100, -150, 0, -20, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 100, -150, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 100, -150, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 100, -150, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 100, -150, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 100, -150, 0, -20, LESSTHAN));
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 100, -150, 0, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 100, -150, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), 0), 100, -150, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-32.531), 0), 100, -150, 0, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (92.531), 0), 100, -150, 0, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 100, -150, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 100, -150, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 100, -150, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 100, -150, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 100, -150, 0, -20, LESSTHAN), TestCase::QUICK);
// with a 150 deg beamwidth, gain is -10dB at +- 124.93 degrees from boresight, and -20dB at +- 155.32 degrees from boresight
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 150, -150, 0, 0, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (135), 0), 150, -150, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-75), 0), 150, -150, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (85.070), 0), 150, -150, 0, -10, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-25.070), 0), 150, -150, 0, -10, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (5.3230), 0), 150, -150, 0, -20, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (54.677), 0), 150, -150, 0, -20, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 150, -150, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (20), 0), 150, -150, 0, -20, LESSTHAN));
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 150, -150, 0, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (135), 0), 150, -150, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-75), 0), 150, -150, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (85.070), 0), 150, -150, 0, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-25.070), 0), 150, -150, 0, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (5.3230), 0), 150, -150, 0, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (54.677), 0), 150, -150, 0, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 150, -150, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (20), 0), 150, -150, 0, -20, LESSTHAN), TestCase::QUICK);
// test maxGain
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 60, 0, 10, 10, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 0, 22, 19, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 0, -4, -7, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 0, 10, -10, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 0, -20, -40, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (100), 0), 60, 0, 40, 20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 100, -150, 2, 2, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 100, -150, 4, 1, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), 0), 100, -150, -1, -4, EQUAL));
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 60, 0, 10, 10, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 0, 22, 19, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 0, -4, -7, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 0, 10, -10, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 0, -20, -40, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (100), 0), 60, 0, 40, 20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 100, -150, 2, 2, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 100, -150, 4, 1, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), 0), 100, -150, -1, -4, EQUAL), TestCase::QUICK);
// test elevation angle
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 2), 60, 0, 0, 0, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 2), 60, 0, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 2), 60, 0, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 2), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-180), 2), 60, 0, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (60), -3), 60, 60, 0, 0, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), -3), 60, 60, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), -3), 60, 60, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-120), -3), 60, 60, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), -3), 100, -150, 0, 0, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), -3), 100, -150, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), -3), 100, -150, 0, -3, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), -3), 100, -150, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 9.5), 100, -150, 0, -20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 9.5), 60, 0, 10, 10, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 9.5), 60, 0, 22, 19, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 9.5), 60, 0, -4, -7, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (100), 9.5), 60, 0, 40, 20, LESSTHAN));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 9.5), 100, -150, 2, 2, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 9.5), 100, -150, 4, 1, EQUAL));
- AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), 9.5), 100, -150, -1, -4, EQUAL));
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 2), 60, 0, 0, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 2), 60, 0, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 2), 60, 0, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-90), 2), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-180), 2), 60, 0, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (60), -3), 60, 60, 0, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), -3), 60, 60, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), -3), 60, 60, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-120), -3), 60, 60, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), -3), 100, -150, 0, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), -3), 100, -150, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), -3), 100, -150, 0, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), -3), 100, -150, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (90), 9.5), 100, -150, 0, -20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (0), 9.5), 60, 0, 10, 10, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (30), 9.5), 60, 0, 22, 19, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-30), 9.5), 60, 0, -4, -7, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (100), 9.5), 60, 0, 40, 20, LESSTHAN), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-150), 9.5), 100, -150, 2, 2, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-100), 9.5), 100, -150, 4, 1, EQUAL), TestCase::QUICK);
+ AddTestCase (new CosineAntennaModelTestCase (Angles (DegreesToRadians (-200), 9.5), 100, -150, -1, -4, EQUAL), TestCase::QUICK);
};
--- a/src/antenna/test/test-degrees-radians.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/antenna/test/test-degrees-radians.cc Fri Apr 05 17:59:11 2013 +0200
@@ -113,21 +113,21 @@
DegreesRadiansTestSuite::DegreesRadiansTestSuite ()
: TestSuite ("degrees-radians", UNIT)
{
- AddTestCase (new DegreesToRadiansTestCase (0, 0));
- AddTestCase (new DegreesToRadiansTestCase (90, M_PI_2));
- AddTestCase (new DegreesToRadiansTestCase (180, M_PI));
- AddTestCase (new DegreesToRadiansTestCase (270, M_PI + M_PI_2));
- AddTestCase (new DegreesToRadiansTestCase (360, M_PI + M_PI));
- AddTestCase (new DegreesToRadiansTestCase (-90, -M_PI_2));
- AddTestCase (new DegreesToRadiansTestCase (810, 4.5*M_PI));
+ AddTestCase (new DegreesToRadiansTestCase (0, 0), TestCase::QUICK);
+ AddTestCase (new DegreesToRadiansTestCase (90, M_PI_2), TestCase::QUICK);
+ AddTestCase (new DegreesToRadiansTestCase (180, M_PI), TestCase::QUICK);
+ AddTestCase (new DegreesToRadiansTestCase (270, M_PI + M_PI_2), TestCase::QUICK);
+ AddTestCase (new DegreesToRadiansTestCase (360, M_PI + M_PI), TestCase::QUICK);
+ AddTestCase (new DegreesToRadiansTestCase (-90, -M_PI_2), TestCase::QUICK);
+ AddTestCase (new DegreesToRadiansTestCase (810, 4.5*M_PI), TestCase::QUICK);
- AddTestCase (new RadiansToDegreesTestCase (0, 0));
- AddTestCase (new RadiansToDegreesTestCase (M_PI_2, 90));
- AddTestCase (new RadiansToDegreesTestCase (M_PI, 180));
- AddTestCase (new RadiansToDegreesTestCase (M_PI + M_PI_2, 270));
- AddTestCase (new RadiansToDegreesTestCase (M_PI + M_PI, 360));
- AddTestCase (new RadiansToDegreesTestCase (-M_PI_2, -90));
- AddTestCase (new RadiansToDegreesTestCase (4.5*M_PI, 810));
+ AddTestCase (new RadiansToDegreesTestCase (0, 0), TestCase::QUICK);
+ AddTestCase (new RadiansToDegreesTestCase (M_PI_2, 90), TestCase::QUICK);
+ AddTestCase (new RadiansToDegreesTestCase (M_PI, 180), TestCase::QUICK);
+ AddTestCase (new RadiansToDegreesTestCase (M_PI + M_PI_2, 270), TestCase::QUICK);
+ AddTestCase (new RadiansToDegreesTestCase (M_PI + M_PI, 360), TestCase::QUICK);
+ AddTestCase (new RadiansToDegreesTestCase (-M_PI_2, -90), TestCase::QUICK);
+ AddTestCase (new RadiansToDegreesTestCase (4.5*M_PI, 810), TestCase::QUICK);
};
--- a/src/antenna/test/test-isotropic-antenna.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/antenna/test/test-isotropic-antenna.cc Fri Apr 05 17:59:11 2013 +0200
@@ -77,15 +77,15 @@
IsotropicAntennaModelTestSuite::IsotropicAntennaModelTestSuite ()
: TestSuite ("isotropic-antenna-model", UNIT)
{
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (0, 0), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (0, M_PI), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (0, M_PI_2), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI, 0), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI, M_PI), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI, M_PI_2), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI_2, 0), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI_2, M_PI), 0.0));
- AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI_2, M_PI_2), 0.0));
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (0, 0), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (0, M_PI), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (0, M_PI_2), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI, 0), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI, M_PI), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI, M_PI_2), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI_2, 0), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI_2, M_PI), 0.0), TestCase::QUICK);
+ AddTestCase (new IsotropicAntennaModelTestCase (Angles (M_PI_2, M_PI_2), 0.0), TestCase::QUICK);
};
--- a/src/antenna/test/test-parabolic-antenna.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/antenna/test/test-parabolic-antenna.cc Fri Apr 05 17:59:11 2013 +0200
@@ -116,69 +116,69 @@
// with a 60 deg beamwidth, gain is -20dB at +-77.460 degrees from boresight
// phi, theta, beamwidth, orientation, maxAttn, expectedGain, condition
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 60, 0, 20, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 0, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 0, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (100), 0), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (180), 0), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-180), 0), 60, 0, 20, -20, EQUAL));
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 60, 0, 20, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 0, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 0, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (100), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (180), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-100), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-180), 0), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
// with a 60 deg beamwidth, gain is -10dB at +-54.772 degrees from boresight
// test positive orientation
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 60, 60, 10, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 60, 10, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 60, 10, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 60, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 60, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (160), 0), 60, 60, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (210), 0), 60, 60, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (240), 0), 60, 60, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-40), 0), 60, 60, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 60, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-120), 0), 60, 60, 10, -10, EQUAL));
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 60, 60, 10, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 60, 60, 10, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 60, 60, 10, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (150), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (160), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (210), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (240), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-40), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-90), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-120), 0), 60, 60, 10, -10, EQUAL), TestCase::QUICK);
// test negative orientation and different beamwidths
// with a 80 deg beamwidth, gain is -20dB at +- 73.030 degrees from boresight
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 80, -150, 10, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-110), 0), 80, -150, 10, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-190), 0), 80, -150, 10, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-70), 0), 80, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (92), 0), 80, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 80, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 80, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 80, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 80, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 80, -150, 10, -10, EQUAL));
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), 0), 80, -150, 10, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-110), 0), 80, -150, 10, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-190), 0), 80, -150, 10, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-70), 0), 80, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (92), 0), 80, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 0), 80, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 0), 80, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (60), 0), 80, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 0), 80, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 0), 80, -150, 10, -10, EQUAL), TestCase::QUICK);
// test elevation angle
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 2), 60, 0, 20, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 2), 60, 0, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 2), 60, 0, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-90), 2), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-180), 2), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (60), -3), 60, 60, 20, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), -3), 60, 60, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), -3), 60, 60, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-120), -3), 60, 60, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), -3), 100, -150, 10, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-100), -3), 100, -150, 10, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-200), -3), 100, -150, 10, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), -3), 100, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 9.5), 100, -150, 10, -10, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 9.5), 60, 0, 20, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 9.5), 60, 0, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 9.5), 60, 0, 20, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (100), 9.5), 60, 0, 20, -20, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), 9.5), 100, -150, 30, 0, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-100), 9.5), 100, -150, 30, -3, EQUAL));
- AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-200), 9.5), 100, -150, 30, -3, EQUAL));
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 2), 60, 0, 20, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 2), 60, 0, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 2), 60, 0, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-90), 2), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-180), 2), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (60), -3), 60, 60, 20, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), -3), 60, 60, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), -3), 60, 60, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-120), -3), 60, 60, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), -3), 100, -150, 10, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-100), -3), 100, -150, 10, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-200), -3), 100, -150, 10, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), -3), 100, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (90), 9.5), 100, -150, 10, -10, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (0), 9.5), 60, 0, 20, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (30), 9.5), 60, 0, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-30), 9.5), 60, 0, 20, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (100), 9.5), 60, 0, 20, -20, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-150), 9.5), 100, -150, 30, 0, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-100), 9.5), 100, -150, 30, -3, EQUAL), TestCase::QUICK);
+ AddTestCase (new ParabolicAntennaModelTestCase (Angles (DegreesToRadians (-200), 9.5), 100, -150, 30, -3, EQUAL), TestCase::QUICK);
};
--- a/src/antenna/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/antenna/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -21,7 +21,7 @@
'test/test-parabolic-antenna.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'antenna'
headers.source = [
'model/angles.h',
--- a/src/aodv/examples/aodv.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/aodv/examples/aodv.cc Fri Apr 05 17:59:11 2013 +0200
@@ -38,7 +38,7 @@
*
* This script creates 1-dimensional grid topology and then ping last node from the first one:
*
- * [10.0.0.1] <-- step --> [10.0.0.2] <-- step --> [10.0.0.3] <-- step --> [10.0.04]
+ * [10.0.0.1] <-- step --> [10.0.0.2] <-- step --> [10.0.0.3] <-- step --> [10.0.0.4]
*
* ping 10.0.0.4
*/
--- a/src/aodv/test/aodv-id-cache-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/aodv/test/aodv-id-cache-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -95,7 +95,7 @@
public:
IdCacheTestSuite () : TestSuite ("routing-id-cache", UNIT)
{
- AddTestCase (new IdCacheTest);
+ AddTestCase (new IdCacheTest, TestCase::QUICK);
}
} g_idCacheTestSuite;
--- a/src/aodv/test/aodv-regression.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/aodv/test/aodv-regression.cc Fri Apr 05 17:59:11 2013 +0200
@@ -56,15 +56,15 @@
{
SetDataDir (NS_TEST_SOURCEDIR);
// General RREQ-RREP-RRER test case
- AddTestCase (new ChainRegressionTest ("aodv-chain-regression-test"));
+ AddTestCase (new ChainRegressionTest ("aodv-chain-regression-test"), TestCase::QUICK);
// Bug 606 test case, should crash if bug is not fixed
- AddTestCase (new ChainRegressionTest ("bug-606-test", Seconds (10), 3, Seconds (1)));
+ AddTestCase (new ChainRegressionTest ("bug-606-test", Seconds (10), 3, Seconds (1)), TestCase::QUICK);
// Bug 772 UDP test case
- AddTestCase (new Bug772ChainTest ("udp-chain-test", "ns3::UdpSocketFactory", Seconds (3), 10));
+ AddTestCase (new Bug772ChainTest ("udp-chain-test", "ns3::UdpSocketFactory", Seconds (3), 10), TestCase::QUICK);
// Bug 772 TCP test case
- AddTestCase (new Bug772ChainTest ("tcp-chain-test", "ns3::TcpSocketFactory", Seconds (3), 10));
+ AddTestCase (new Bug772ChainTest ("tcp-chain-test", "ns3::TcpSocketFactory", Seconds (3), 10), TestCase::QUICK);
// Ping loopback test case
- AddTestCase (new LoopbackTestCase ());
+ AddTestCase (new LoopbackTestCase (), TestCase::QUICK);
}
} g_aodvRegressionTestSuite;
--- a/src/aodv/test/aodv-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/aodv/test/aodv-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -525,16 +525,16 @@
public:
AodvTestSuite () : TestSuite ("routing-aodv", UNIT)
{
- AddTestCase (new NeighborTest);
- AddTestCase (new TypeHeaderTest);
- AddTestCase (new RreqHeaderTest);
- AddTestCase (new RrepHeaderTest);
- AddTestCase (new RrepAckHeaderTest);
- AddTestCase (new RerrHeaderTest);
- AddTestCase (new QueueEntryTest);
- AddTestCase (new AodvRqueueTest);
- AddTestCase (new AodvRtableEntryTest);
- AddTestCase (new AodvRtableTest);
+ AddTestCase (new NeighborTest, TestCase::QUICK);
+ AddTestCase (new TypeHeaderTest, TestCase::QUICK);
+ AddTestCase (new RreqHeaderTest, TestCase::QUICK);
+ AddTestCase (new RrepHeaderTest, TestCase::QUICK);
+ AddTestCase (new RrepAckHeaderTest, TestCase::QUICK);
+ AddTestCase (new RerrHeaderTest, TestCase::QUICK);
+ AddTestCase (new QueueEntryTest, TestCase::QUICK);
+ AddTestCase (new AodvRqueueTest, TestCase::QUICK);
+ AddTestCase (new AodvRtableEntryTest, TestCase::QUICK);
+ AddTestCase (new AodvRtableTest, TestCase::QUICK);
}
} g_aodvTestSuite;
--- a/src/aodv/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/aodv/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -23,7 +23,7 @@
'test/loopback.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'aodv'
headers.source = [
'model/aodv-id-cache.h',
@@ -37,6 +37,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/applications/model/bulk-send-application.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/applications/model/bulk-send-application.cc Fri Apr 05 17:59:11 2013 +0200
@@ -126,7 +126,15 @@
"In other words, use TCP instead of UDP.");
}
- m_socket->Bind ();
+ if (Inet6SocketAddress::IsMatchingType (m_peer))
+ {
+ m_socket->Bind6 ();
+ }
+ else if (InetSocketAddress::IsMatchingType (m_peer))
+ {
+ m_socket->Bind ();
+ }
+
m_socket->Connect (m_peer);
m_socket->ShutdownRecv ();
m_socket->SetConnectCallback (
--- a/src/applications/model/onoff-application.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/applications/model/onoff-application.cc Fri Apr 05 17:59:11 2013 +0200
@@ -26,6 +26,7 @@
#include "ns3/address.h"
#include "ns3/inet-socket-address.h"
#include "ns3/inet6-socket-address.h"
+#include "ns3/packet-socket-address.h"
#include "ns3/node.h"
#include "ns3/nstime.h"
#include "ns3/data-rate.h"
@@ -148,7 +149,15 @@
if (!m_socket)
{
m_socket = Socket::CreateSocket (GetNode (), m_tid);
- m_socket->Bind ();
+ if (Inet6SocketAddress::IsMatchingType (m_peer))
+ {
+ m_socket->Bind6 ();
+ }
+ else if (InetSocketAddress::IsMatchingType (m_peer) ||
+ PacketSocketAddress::IsMatchingType (m_peer))
+ {
+ m_socket->Bind ();
+ }
m_socket->Connect (m_peer);
m_socket->SetAllowBroadcast (true);
m_socket->ShutdownRecv ();
--- a/src/applications/model/udp-echo-server.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/applications/model/udp-echo-server.cc Fri Apr 05 17:59:11 2013 +0200
@@ -157,7 +157,7 @@
{
NS_LOG_INFO ("At time " << Simulator::Now ().GetSeconds () << "s server received " << packet->GetSize () << " bytes from " <<
Inet6SocketAddress::ConvertFrom (from).GetIpv6 () << " port " <<
- InetSocketAddress::ConvertFrom (from).GetPort ());
+ Inet6SocketAddress::ConvertFrom (from).GetPort ());
}
packet->RemoveAllPacketTags ();
@@ -176,7 +176,7 @@
{
NS_LOG_INFO ("At time " << Simulator::Now ().GetSeconds () << "s server sent " << packet->GetSize () << " bytes to " <<
Inet6SocketAddress::ConvertFrom (from).GetIpv6 () << " port " <<
- InetSocketAddress::ConvertFrom (from).GetPort ());
+ Inet6SocketAddress::ConvertFrom (from).GetPort ());
}
}
}
--- a/src/applications/test/udp-client-server-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/applications/test/udp-client-server-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -340,10 +340,10 @@
UdpClientServerTestSuite::UdpClientServerTestSuite ()
: TestSuite ("udp-client-server", UNIT)
{
- AddTestCase (new UdpTraceClientServerTestCase);
- AddTestCase (new UdpClientServerTestCase);
- AddTestCase (new PacketLossCounterTestCase);
- AddTestCase (new UdpEchoClientSetFillTestCase);
+ AddTestCase (new UdpTraceClientServerTestCase, TestCase::QUICK);
+ AddTestCase (new UdpClientServerTestCase, TestCase::QUICK);
+ AddTestCase (new PacketLossCounterTestCase, TestCase::QUICK);
+ AddTestCase (new UdpEchoClientSetFillTestCase, TestCase::QUICK);
}
static UdpClientServerTestSuite udpClientServerTestSuite;
--- a/src/applications/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/applications/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -32,7 +32,7 @@
'test/udp-client-server-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'applications'
headers.source = [
'model/bulk-send-application.h',
--- a/src/bridge/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/bridge/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -7,7 +7,7 @@
'model/bridge-channel.cc',
'helper/bridge-helper.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'bridge'
headers.source = [
'model/bridge-net-device.h',
@@ -16,6 +16,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/brite/test/brite-test-topology.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/brite/test/brite-test-topology.cc Fri Apr 05 17:59:11 2013 +0200
@@ -192,8 +192,8 @@
public:
BriteTestSuite () : TestSuite ("brite-testing", UNIT)
{
- AddTestCase (new BriteTopologyStructureTestCase);
- AddTestCase (new BriteTopologyFunctionTestCase);
+ AddTestCase (new BriteTopologyStructureTestCase, TestCase::QUICK);
+ AddTestCase (new BriteTopologyFunctionTestCase, TestCase::QUICK);
}
} g_briteTestSuite;
--- a/src/brite/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/brite/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -1,6 +1,8 @@
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
+
import os
-import Options
+
+from waflib import Options
def options(opt):
@@ -89,7 +91,7 @@
if bld.env['BRITE'] and bld.env['DL']:
module.uselib = 'BRITE DL'
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'brite'
headers.source = [
]
@@ -100,4 +102,4 @@
module_test.source.append('test/brite-test-topology.cc')
if bld.env['ENABLE_EXAMPLES'] and bld.env['ENABLE_BRITE']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
--- a/src/buildings/test/building-position-allocator-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/buildings/test/building-position-allocator-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -231,8 +231,8 @@
{
NS_LOG_FUNCTION (this);
- AddTestCase (new RandomRoomPositionAllocatorTestCase);
- AddTestCase (new SameRoomPositionAllocatorTestCase);
+ AddTestCase (new RandomRoomPositionAllocatorTestCase, TestCase::QUICK);
+ AddTestCase (new SameRoomPositionAllocatorTestCase, TestCase::QUICK);
}
--- a/src/buildings/test/buildings-helper-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/buildings/test/buildings-helper-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -203,25 +203,25 @@
p1.rx = 1;
p1.ry = 1;
p1.fn = 1;
- AddTestCase (new BuildingsHelperOneTestCase (p1, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p1, b1), TestCase::QUICK);
Vector vp2 (1.5, 0.5, 0.5);
PositionInBuilding p2;
p2.pos = vp2;
p2.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (p2, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p2, b1), TestCase::QUICK);
Vector vp3 (1.5, 2.5, 0.5);
PositionInBuilding p3;
p3.pos = vp3;
p3.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (p3, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p3, b1), TestCase::QUICK);
Vector vp4 (1.5, 1.5, 5);
PositionInBuilding p4;
p4.pos = vp4;
p4.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (p4, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p4, b1), TestCase::QUICK);
Vector vp5 (2.5, 1.6, 3.5);
PositionInBuilding p5;
@@ -231,31 +231,31 @@
p5.rx = 1;
p5.ry = 1;
p5.fn = 1;
- AddTestCase (new BuildingsHelperOneTestCase (p5, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p5, b1), TestCase::QUICK);
Vector vp6 (0.9999, 1.5, 1.5);
PositionInBuilding p6;
p6.pos = vp6;
p6.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (p6, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p6, b1), TestCase::QUICK);
Vector vp7 (3.0001, 1.5, 2.5);
PositionInBuilding p7;
p7.pos = vp7;
p7.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (p7, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p7, b1), TestCase::QUICK);
Vector vp8 (1.001, 1.001, -0.01);
PositionInBuilding p8;
p8.pos = vp8;
p8.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (p8, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p8, b1), TestCase::QUICK);
Vector vp9 (1.5, 1.5, 4.001);
PositionInBuilding p9;
p9.pos = vp9;
p9.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (p9, b1));
+ AddTestCase (new BuildingsHelperOneTestCase (p9, b1), TestCase::QUICK);
@@ -279,7 +279,7 @@
q1.rx = 1;
q1.ry = 2;
q1.fn = 3;
- AddTestCase (new BuildingsHelperOneTestCase (q1, b2));
+ AddTestCase (new BuildingsHelperOneTestCase (q1, b2), TestCase::QUICK);
Vector vq2 (0.2, 0.3, 0.2);
PositionInBuilding q2;
@@ -289,37 +289,37 @@
q2.rx = 3;
q2.ry = 5;
q2.fn = 1;
- AddTestCase (new BuildingsHelperOneTestCase (q2, b2));
+ AddTestCase (new BuildingsHelperOneTestCase (q2, b2), TestCase::QUICK);
Vector vq3 (0.6, -1.75, 1.5);
PositionInBuilding q3;
q3.pos = vq3;
q3.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (q3, b2));
+ AddTestCase (new BuildingsHelperOneTestCase (q3, b2), TestCase::QUICK);
Vector vq4 (-1.01, 0.3, 1.99);
PositionInBuilding q4;
q4.pos = vq4;
q4.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (q4, b2));
+ AddTestCase (new BuildingsHelperOneTestCase (q4, b2), TestCase::QUICK);
Vector vq5 (-0.8, 0.7, 0.01);
PositionInBuilding q5;
q5.pos = vq5;
q5.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (q5, b2));
+ AddTestCase (new BuildingsHelperOneTestCase (q5, b2), TestCase::QUICK);
Vector vq6 (0.2, 0.3, -0.2);
PositionInBuilding q6;
q6.pos = vq6;
q6.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (q6, b2));
+ AddTestCase (new BuildingsHelperOneTestCase (q6, b2), TestCase::QUICK);
Vector vq7 (0.2, 0.3, 2.001);
PositionInBuilding q7;
q7.pos = vq7;
q7.indoor = false;
- AddTestCase (new BuildingsHelperOneTestCase (q7, b2));
+ AddTestCase (new BuildingsHelperOneTestCase (q7, b2), TestCase::QUICK);
}
static BuildingsHelperTestSuite buildingsHelperAntennaTestSuiteInstance;
--- a/src/buildings/test/buildings-pathloss-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/buildings/test/buildings-pathloss-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -55,56 +55,56 @@
double freq = 869e6; // E_UTRA BAND #5 see table 5.5-1 of 36.101
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, LargeCity, 137.93, "OH Urban Large city"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, LargeCity, 137.93, "OH Urban Large city"), TestCase::QUICK);
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, SmallCity, 137.88, "OH Urban small city"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, SmallCity, 137.88, "OH Urban small city"), TestCase::QUICK);
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, SubUrbanEnvironment, LargeCity, 128.03, "loss OH SubUrban"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, SubUrbanEnvironment, LargeCity, 128.03, "loss OH SubUrban"), TestCase::QUICK);
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, OpenAreasEnvironment, LargeCity, 110.21, "loss OH OpenAreas"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, OpenAreasEnvironment, LargeCity, 110.21, "loss OH OpenAreas"), TestCase::QUICK);
// Test #2 COST231 Model (1500 < freq < 2000~2170 MHz) (Macro<->UE)
freq = 2.1140e9; // E_UTRA BAND #1 see table 5.5-1 of 36.101
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, LargeCity, 148.55, "COST231 Urban Large city"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, LargeCity, 148.55, "COST231 Urban Large city"), TestCase::QUICK);
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, SmallCity, 150.64, "COST231 Urban small city and suburban"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, SmallCity, 150.64, "COST231 Urban small city and suburban"), TestCase::QUICK);
// Test #3 2.6 GHz model (Macro<->UE)
freq = 2.620e9; // E_UTRA BAND #7 see table 5.5-1 of 36.101
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, SmallCity, 121.83, "2.6GHz model"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 2, UrbanEnvironment, SmallCity, 121.83, "2.6GHz model"), TestCase::QUICK);
// Test #4 ITU1411 LOS model (Macro<->UE)
freq = 2.1140e9; // E_UTRA BAND #1 see table 5.5-1 of 36.101
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 3, UrbanEnvironment, LargeCity, 81.00, "ITU1411 LOS"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 3, UrbanEnvironment, LargeCity, 81.00, "ITU1411 LOS"), TestCase::QUICK);
// Test #5 ITU1411 NLOS model (Macro<->UE)
freq = 2.1140e9; // E_UTRA BAND #1 see table 5.5-1 of 36.101
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 4, UrbanEnvironment, LargeCity, 143.69, "ITU1411 NLOS"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 4, UrbanEnvironment, LargeCity, 143.69, "ITU1411 NLOS"), TestCase::QUICK);
// Test #6 ITUP1238 (HeNB <-> UE)
freq = 2.1140e9; // E_UTRA BAND #1 see table 5.5-1 of 36.101
- AddTestCase (new BuildingsPathlossTestCase (freq, 5, 6, UrbanEnvironment, LargeCity, 88.3855, "ITUP1238"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 5, 6, UrbanEnvironment, LargeCity, 88.3855, "ITUP1238"), TestCase::QUICK);
// Test #7 Outdoor -> Indoor OkumuraHata (Macro<->UE)
freq = 2.1140e9; // E_UTRA BAND #1 see table 5.5-1 of 36.101
// The loss is as in test #2 (large city) plus the building penetration loss
// which for ConcreteWithWindows is equal to 7 dB -> 148.55 + 7 = 155.55
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 7, UrbanEnvironment, LargeCity, 155.55, "Okumura Hata Outdoor -> Indoor"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 7, UrbanEnvironment, LargeCity, 155.55, "Okumura Hata Outdoor -> Indoor"), TestCase::QUICK);
// Test #8 Outdoor -> Indoor ITU1411 (Macro<->UE)
freq = 2.1140e9; // E_UTRA BAND #1 see table 5.5-1 of 36.101
// The loss is as in test #4 plus the building penetration loss
// which for ConcreteWithWindows is equal to 7 dB -> 81.000 + 7 = 88.000
- AddTestCase (new BuildingsPathlossTestCase (freq, 1, 8, UrbanEnvironment, LargeCity, 88.000, "ITU1411 LOS Outdoor -> Indoor"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 1, 8, UrbanEnvironment, LargeCity, 88.000, "ITU1411 LOS Outdoor -> Indoor"), TestCase::QUICK);
// Test #9 Indoor -> Outdoor LOS (HeNB <-> UE)
@@ -112,7 +112,7 @@
// The loss is similar of test #4 plus the building penetration loss
// which for ConcreteWithWindows is equal to 7 dB and the height gain
// (2 floors x 2 dB/floor = 4) -> 81.838 + 7 - 4 = 84.838
- AddTestCase (new BuildingsPathlossTestCase (freq, 9, 10, UrbanEnvironment, LargeCity, 84.838, "ITU1411 LOS Indoor -> Outdoor"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 9, 10, UrbanEnvironment, LargeCity, 84.838, "ITU1411 LOS Indoor -> Outdoor"), TestCase::QUICK);
// Test #10 Indoor -> Outdoor NLOS (HeNB <-> UE)
@@ -120,7 +120,7 @@
// The loss is similar as in test #4 plus the building penetration loss
// which for ConcreteWithWindows is equal to 7 dB and the height gain
// (2 floors x 2 dB/floor = 4) -> 180.90 + 7 - 4 = 183.90
- AddTestCase (new BuildingsPathlossTestCase (freq, 9, 11, UrbanEnvironment, LargeCity, 183.90, "ITU1411 NLOS Indoor -> Outdoor"));
+ AddTestCase (new BuildingsPathlossTestCase (freq, 9, 11, UrbanEnvironment, LargeCity, 183.90, "ITU1411 NLOS Indoor -> Outdoor"), TestCase::QUICK);
}
--- a/src/buildings/test/buildings-shadowing-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/buildings/test/buildings-shadowing-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -54,13 +54,13 @@
LogComponentEnable ("BuildingsShadowingTest", LOG_LEVEL_ALL);
// Test #1 Outdoor Model
- AddTestCase (new BuildingsShadowingTestCase (1, 2, 148.86, 7.0, "Outdoor Shadowing"));
+ AddTestCase (new BuildingsShadowingTestCase (1, 2, 148.86, 7.0, "Outdoor Shadowing"), TestCase::QUICK);
// Test #2 Indoor model
- AddTestCase (new BuildingsShadowingTestCase (5, 6, 88.5724, 8.0, "Indoor Shadowing"));
+ AddTestCase (new BuildingsShadowingTestCase (5, 6, 88.5724, 8.0, "Indoor Shadowing"), TestCase::QUICK);
// Test #3 Indoor -> Outdoor
- AddTestCase (new BuildingsShadowingTestCase (9, 10, 85.0012, 8.6, "Indoor -> Outdoor Shadowing"));
+ AddTestCase (new BuildingsShadowingTestCase (9, 10, 85.0012, 8.6, "Indoor -> Outdoor Shadowing"), TestCase::QUICK);
}
--- a/src/buildings/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/buildings/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -25,7 +25,7 @@
'test/buildings-shadowing-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'buildings'
headers.source = [
'model/building.h',
@@ -42,7 +42,7 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/click/examples/nsclick-defines.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,66 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Authors: Sascha Jopen <jopen@cs.uni-bonn.de>
+ */
+
+
+#include "ns3/core-module.h"
+#include "ns3/ipv4-click-routing.h"
+#include "ns3/click-internet-stack-helper.h"
+#include <map>
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("NsclickRouting");
+
+int
+main (int argc, char *argv[])
+{
+#ifdef NS3_CLICK
+
+//
+// Explicitly create the nodes required by the topology (shown above).
+//
+ NS_LOG_INFO ("Create a node.");
+ NodeContainer n;
+ n.Create (1);
+
+//
+// Install Click on the nodes
+//
+ std::map<std::string, std::string> defines;
+// Strings, especially with blanks in it, have to be enclosed in quotation
+// marks, like in click configuration files.
+ defines["OUTPUT"] = "\"Hello World!\"";
+
+ ClickInternetStackHelper clickinternet;
+ clickinternet.SetClickFile (n, "src/click/examples/nsclick-defines.click");
+ clickinternet.SetRoutingTableElement (n, "rt");
+ clickinternet.SetDefines(n, defines);
+ clickinternet.Install (n);
+
+//
+// Now, do the actual simulation.
+//
+ NS_LOG_INFO ("Run Simulation.");
+ Simulator::Stop (Seconds (20.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+ NS_LOG_INFO ("Done.");
+#else
+ NS_FATAL_ERROR ("Can't use ns-3-click without NSCLICK compiled in");
+#endif
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/click/examples/nsclick-defines.click Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,9 @@
+define($OUTPUT "This is a default value for OUTPUT");
+define($UNDEFINED "UNDEFINED is an undefined variable");
+
+// It is mandatory to use an IPRouteTable element with ns-3-click
+rt :: LinearIPLookup ();
+Idle -> rt;
+
+output :: Message($OUTPUT);
+undefined :: Message($UNDEFINED);
--- a/src/click/examples/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/click/examples/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -20,3 +20,7 @@
obj = bld.create_ns3_program('nsclick-routing',
['click', 'csma', 'internet', 'applications'])
obj.source = 'nsclick-routing.cc'
+
+ obj = bld.create_ns3_program('nsclick-defines',
+ ['click'])
+ obj.source = 'nsclick-defines.cc'
--- a/src/click/helper/click-internet-stack-helper.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/click/helper/click-internet-stack-helper.cc Fri Apr 05 17:59:11 2013 +0200
@@ -125,6 +125,21 @@
}
void
+ClickInternetStackHelper::SetDefines (NodeContainer c, std::map<std::string, std::string> defines)
+{
+ for (NodeContainer::Iterator i = c.Begin (); i != c.End (); ++i)
+ {
+ SetDefines (*i, defines);
+ }
+}
+
+void
+ClickInternetStackHelper::SetDefines (Ptr<Node> node, std::map<std::string, std::string> defines)
+{
+ m_nodeToDefinesMap.insert (std::make_pair (node, defines));
+}
+
+void
ClickInternetStackHelper::SetRoutingTableElement (NodeContainer c, std::string rt)
{
for (NodeContainer::Iterator i = c.Begin (); i != c.End (); ++i)
@@ -193,6 +208,13 @@
ipv4Routing->SetClickFile (it->second);
}
+ std::map<Ptr<Node>, std::map<std::string, std::string> >::const_iterator definesIt;
+ definesIt = m_nodeToDefinesMap.find (node);
+ if (definesIt != m_nodeToDefinesMap.end ())
+ {
+ ipv4Routing->SetDefines (definesIt->second);
+ }
+
it = m_nodeToRoutingTableElementMap.find (node);
if (it != m_nodeToRoutingTableElementMap.end ())
{
--- a/src/click/helper/click-internet-stack-helper.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/click/helper/click-internet-stack-helper.h Fri Apr 05 17:59:11 2013 +0200
@@ -143,6 +143,20 @@
void SetClickFile (Ptr<Node> node, std::string clickfile);
/**
+ * \brief Set defines to be used for a group of nodes.
+ * \param c NodeContainer of nodes
+ * \param defines Defines mapping to be used
+ */
+ void SetDefines (NodeContainer c, std::map<std::string, std::string> defines);
+
+ /**
+ * \brief Set defines to be used for a node.
+ * \param node Node for which the defines are to be set
+ * \param defines Defines mapping to be used
+ */
+ void SetDefines (Ptr<Node> node, std::map<std::string, std::string> defines);
+
+ /**
* \brief Set a Click routing table element for a group of nodes.
* \param c NodeContainer of nodes
* \param rt Click Routing Table element name
@@ -219,6 +233,11 @@
std::map < Ptr<Node>, std::string > m_nodeToClickFileMap;
/**
+ * \brief Node to Click defines mapping
+ */
+ std::map < Ptr<Node>, std::map<std::string, std::string> > m_nodeToDefinesMap;
+
+ /**
* \brief Node to Routing Table Element mapping
*/
std::map < Ptr<Node>, std::string > m_nodeToRoutingTableElementMap;
--- a/src/click/model/ipv4-click-routing.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/click/model/ipv4-click-routing.cc Fri Apr 05 17:59:11 2013 +0200
@@ -24,6 +24,7 @@
#include "ns3/node.h"
#include "ns3/simulator.h"
#include "ns3/log.h"
+#include "ns3/random-variable-stream.h"
#include "ns3/mac48-address.h"
#include "ns3/ipv4-interface.h"
#include "ns3/ipv4-l3-click-protocol.h"
@@ -63,6 +64,11 @@
: m_nonDefaultName (false),
m_ipv4 (0)
{
+ m_random = CreateObject<UniformRandomVariable> ();
+ m_simNode = new simclick_node_t;
+ timerclear (&m_simNode->curtime);
+
+ AddSimNodeToClickMapping ();
}
Ipv4ClickRouting::~Ipv4ClickRouting ()
@@ -81,11 +87,6 @@
m_nodeName = name.str ();
}
- m_simNode = new simclick_node_t;
- timerclear (&m_simNode->curtime);
-
- AddSimNodeToClickMapping ();
-
NS_ASSERT (m_clickFile.length () > 0);
// Even though simclick_click_create() will halt programme execution
@@ -111,6 +112,12 @@
m_ipv4 = ipv4;
}
+Ptr<UniformRandomVariable>
+Ipv4ClickRouting::GetRandomVariable (void)
+{
+ return m_random;
+}
+
void
Ipv4ClickRouting::DoDispose ()
{
@@ -130,6 +137,18 @@
}
void
+Ipv4ClickRouting::SetDefines (std::map<std::string, std::string> defines)
+{
+ m_defines = defines;
+}
+
+std::map<std::string, std::string>
+Ipv4ClickRouting::GetDefines (void)
+{
+ return m_defines;
+}
+
+void
Ipv4ClickRouting::SetClickRoutingTableElement (std::string name)
{
m_clickRoutingTableElement = name;
@@ -606,7 +625,7 @@
case SIMCLICK_SUPPORTS:
{
int othercmd = va_arg (val, int);
- retval = (othercmd >= SIMCLICK_VERSION && othercmd <= SIMCLICK_GET_NODE_ID);
+ retval = (othercmd >= SIMCLICK_VERSION && othercmd <= SIMCLICK_GET_DEFINES);
break;
}
@@ -738,6 +757,59 @@
NS_LOG_DEBUG (clickInstance->GetNodeName () << " Received a call for SIMCLICK_GET_NODE_ID");
break;
}
+
+ case SIMCLICK_GET_RANDOM_INT:
+ {
+ uint32_t *randomValue = va_arg (val, uint32_t *);
+ uint32_t maxValue = va_arg (val, uint32_t);
+
+ *randomValue = static_cast<uint32_t> (clickInstance->GetRandomVariable ()->GetValue (0.0, static_cast<double> (maxValue) + 1.0));
+ retval = 0;
+ NS_LOG_DEBUG (clickInstance->GetNodeName () << " SIMCLICK_RANDOM: " << *randomValue << " " << maxValue << " " << ns3::Simulator::Now ());
+ break;
+ }
+
+ case SIMCLICK_GET_DEFINES:
+ {
+ char *buf = va_arg (val, char *);
+ size_t *size = va_arg (val, size_t *);
+ uint32_t required = 0;
+
+ // Try to fill the buffer with up to size bytes.
+ // If this is not enough space, write the required buffer size into
+ // the size variable and return an error code.
+ // Otherwise return the bytes actually writte into the buffer in size.
+
+ // Append key/value pair, seperated by \0.
+ std::map<std::string, std::string> defines = clickInstance->GetDefines ();
+ std::map<std::string, std::string>::const_iterator it = defines.begin ();
+ while (it != defines.end ())
+ {
+ size_t available = *size - required;
+ if (it->first.length() + it->second.length() + 2 <= available)
+ {
+ simstrlcpy(buf + required, available, it->first);
+ required += it->first.length() + 1;
+ available -= it->first.length() + 1;
+ simstrlcpy(buf + required, available, it->second);
+ required += it->second.length() + 1;
+ }
+ else
+ {
+ required += it->first.length() + it->second.length() + 2;
+ }
+ it++;
+ }
+ if (required > *size)
+ {
+ retval = -1;
+ }
+ else
+ {
+ retval = 0;
+ }
+ *size = required;
+ }
}
return retval;
}
--- a/src/click/model/ipv4-click-routing.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/click/model/ipv4-click-routing.h Fri Apr 05 17:59:11 2013 +0200
@@ -44,6 +44,8 @@
* This section documents the API of the ns-3 click module. For a generic functional description, please refer to the ns-3 manual.
*/
+class UniformRandomVariable;
+
/**
* \ingroup click
* \brief Class to allow a node to use Click for external routing
@@ -63,6 +65,7 @@
Ipv4ClickRouting ();
virtual ~Ipv4ClickRouting ();
+ Ptr<UniformRandomVariable> GetRandomVariable (void);
protected:
virtual void DoStart (void);
@@ -76,6 +79,12 @@
void SetClickFile (std::string clickfile);
/**
+ * \brief Click defines to be used by the node's Click Instance.
+ * \param defines mapping of defines for .click configuration file parsing
+ */
+ void SetDefines (std::map<std::string, std::string> defines);
+
+ /**
* \brief Name of the node as to be used by Click. Required for Click Dumps.
* \param name Name to be assigned to the node.
*/
@@ -129,6 +138,12 @@
public:
/**
+ * \brief Provides for SIMCLICK_GET_DEFINES
+ * \return The defines mapping for .click configuration file parsing
+ */
+ std::map<std::string, std::string> GetDefines (void);
+
+ /**
* \brief Provides for SIMCLICK_IFID_FROM_NAME
* \param ifname The name of the interface
* \return The interface ID which corresponds to ifname
@@ -244,6 +259,7 @@
private:
std::string m_clickFile;
+ std::map < std::string, std::string > m_defines;
std::string m_nodeName;
std::string m_clickRoutingTableElement;
@@ -255,6 +271,7 @@
bool m_nonDefaultName;
Ptr<Ipv4> m_ipv4;
+ Ptr<UniformRandomVariable> m_random;
#endif /* NS3_CLICK */
};
--- a/src/click/test/ipv4-click-routing-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/click/test/ipv4-click-routing-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -197,9 +197,9 @@
public:
ClickIfidFromNameTestSuite () : TestSuite ("routing-click", UNIT)
{
- AddTestCase (new ClickTrivialTest);
- AddTestCase (new ClickIfidFromNameTest);
- AddTestCase (new ClickIpMacAddressFromNameTest);
+ AddTestCase (new ClickTrivialTest, TestCase::QUICK);
+ AddTestCase (new ClickIfidFromNameTest, TestCase::QUICK);
+ AddTestCase (new ClickIpMacAddressFromNameTest, TestCase::QUICK);
}
} g_ipv4ClickRoutingTestSuite;
--- a/src/click/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/click/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -1,7 +1,8 @@
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
import os
-import Options
+
+from waflib import Options
def options(opt):
@@ -107,7 +108,7 @@
module.use.extend(['NSCLICK', 'DL'])
module_test.use.extend(['NSCLICK', 'DL'])
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'click'
headers.source = [
'model/ipv4-click-routing.h',
@@ -116,6 +117,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/config-store/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/config-store/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -11,25 +11,29 @@
def configure(conf):
if Options.options.disable_gtk:
- conf.env['ENABLE_GTK_CONFIG_STORE'] = False
+ conf.env['ENABLE_GTK2'] = False
conf.report_optional_feature("GtkConfigStore", "GtkConfigStore",
- conf.env['ENABLE_GTK_CONFIG_STORE'],
+ conf.env['ENABLE_GTK2'],
"--disable-gtk option given")
else:
- have_gtk = conf.pkg_check_modules('GTK_CONFIG_STORE', 'gtk+-2.0 >= 2.12', mandatory=False)
- conf.env['ENABLE_GTK_CONFIG_STORE'] = have_gtk
+ have_gtk2 = conf.check_cfg(package='gtk+-2.0', atleast_version='2.12',
+ args=['--cflags', '--libs'], uselib_store='GTK2',
+ mandatory=False)
+
+ conf.env['ENABLE_GTK2'] = have_gtk2
conf.report_optional_feature("GtkConfigStore", "GtkConfigStore",
- conf.env['ENABLE_GTK_CONFIG_STORE'],
+ conf.env['ENABLE_GTK2'],
"library 'gtk+-2.0 >= 2.12' not found")
- have_libxml2 = conf.pkg_check_modules('LIBXML2', 'libxml-2.0 >= 2.6', mandatory=False)
- if have_libxml2:
- conf.define('HAVE_LIBXML2', 1)
+ have_libxml2 = conf.check_cfg(package='libxml-2.0', atleast_version='2.7',
+ args=['--cflags', '--libs'], uselib_store='LIBXML2',
+ mandatory=False)
conf.env['ENABLE_LIBXML2'] = have_libxml2
conf.report_optional_feature("XmlIo", "XmlIo",
conf.env['ENABLE_LIBXML2'],
"library 'libxml-2.0 >= 2.7' not found")
+
conf.write_config_header('ns3/config-store-config.h', top=True)
@@ -45,27 +49,27 @@
'model/raw-text-config.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'config-store'
headers.source = [
'model/file-config.h',
'model/config-store.h',
]
- if bld.env['ENABLE_GTK_CONFIG_STORE']:
+ if bld.env['ENABLE_GTK2']:
headers.source.append ('model/gtk-config-store.h')
module.source.extend (['model/gtk-config-store.cc',
'model/model-node-creator.cc',
'model/model-typeid-creator.cc',
'model/display-functions.cc',
])
- module.use.append('GTK_CONFIG_STORE')
+ module.use.append('GTK2')
if bld.env['ENABLE_LIBXML2']:
module.source.append ('model/xml-config.cc')
module.use.append('LIBXML2')
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/core/model/random-variable-stream-helper.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/model/random-variable-stream-helper.cc Fri Apr 05 17:59:11 2013 +0200
@@ -29,7 +29,7 @@
int64_t RandomVariableStreamHelper::AssignStreams (std::string path, int64_t stream)
{
- NS_LOG_FUNCTION (this << path << stream);
+ NS_LOG_FUNCTION_NOARGS ();
NS_ASSERT (stream >= 0);
Config::MatchContainer mc = Config::LookupMatches (path);
int64_t i = 0;
--- a/src/core/model/test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/model/test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -111,7 +111,9 @@
bool printTestType) const;
void PrintTestTypeList (void) const;
void PrintHelp (const char *programName) const;
- std::list<TestCase *> FilterTests (std::string testName, enum TestSuite::Type testType) const;
+ std::list<TestCase *> FilterTests (std::string testName,
+ enum TestSuite::Type testType,
+ enum TestCase::TestDuration maximumTestDuration);
typedef std::vector<TestSuite *> TestSuiteVector;
@@ -147,7 +149,8 @@
m_dataDir (""),
m_runner (0),
m_result (0),
- m_name (name)
+ m_name (name),
+ m_duration (TestCase::QUICK)
{
NS_LOG_FUNCTION (this << name);
}
@@ -168,6 +171,15 @@
void
TestCase::AddTestCase (TestCase *testCase)
{
+ AddTestCase (testCase, TestCase::QUICK);
+}
+
+void
+TestCase::AddTestCase (TestCase *testCase, enum TestCase::TestDuration duration)
+{
+ // Record this for use later when all test cases are run.
+ testCase->m_duration = duration;
+
NS_LOG_FUNCTION (&testCase);
m_children.push_back (testCase);
testCase->m_parent = this;
@@ -591,21 +603,27 @@
NS_LOG_FUNCTION (this << program_name);
std::cout << "Usage: " << program_name << " [OPTIONS]" << std::endl
<< std::endl
- << "Options: "
+ << "Options: " << std::endl
<< " --help : print these options" << std::endl
<< " --print-test-name-list : print the list of names of tests available" << std::endl
<< " --list : an alias for --print-test-name-list" << std::endl
<< " --print-test-types : print the type of tests along with their names" << std::endl
<< " --print-test-type-list : print the list of types of tests available" << std::endl
- << " --print-temp-dir : Print name of temporary directory before running the tests" << std::endl
- << " --test-type=TYPE : Process only tests of type TYPE" << std::endl
- << " --test-name=NAME : Process only test whose name matches NAME" << std::endl
- << " --suite=NAME : an alias (here for compatibility reasons only) "
- << "for --test-name=NAME" << std::endl
+ << " --print-temp-dir : print name of temporary directory before running " << std::endl
+ << " the tests" << std::endl
+ << " --test-type=TYPE : process only tests of type TYPE" << std::endl
+ << " --test-name=NAME : process only test whose name matches NAME" << std::endl
+ << " --suite=NAME : an alias (here for compatibility reasons only) " << std::endl
+ << " for --test-name=NAME" << std::endl
<< " --assert-on-failure : when a test fails, crash immediately (useful" << std::endl
<< " when running under a debugger" << std::endl
<< " --stop-on-failure : when a test fails, stop immediately" << std::endl
- << " --verbose : Print details of test execution" << std::endl
+ << " --fullness=FULLNESS : choose the duration of tests to run: QUICK, " << std::endl
+ << " EXTENSIVE, or TAKES_FOREVER, where EXTENSIVE " << std::endl
+ << " includes QUICK and TAKES_FOREVER includes " << std::endl
+ << " QUICK and EXTENSIVE (only QUICK tests are " << std::endl
+ << " run by default)" << std::endl
+ << " --verbose : print details of test execution" << std::endl
<< " --xml : format test run output as xml" << std::endl
<< " --tempdir=DIR : set temp dir for tests to store output files" << std::endl
<< " --datadir=DIR : set data dir for tests to read reference files" << std::endl
@@ -656,7 +674,9 @@
std::list<TestCase *>
-TestRunnerImpl::FilterTests (std::string testName, enum TestSuite::Type testType) const
+TestRunnerImpl::FilterTests (std::string testName,
+ enum TestSuite::Type testType,
+ enum TestCase::TestDuration maximumTestDuration)
{
NS_LOG_FUNCTION (this << testName << testType);
std::list<TestCase *> tests;
@@ -673,6 +693,32 @@
// skip test
continue;
}
+
+ // Remove any test cases that should be skipped.
+ std::vector<TestCase *>::iterator j;
+ for (j = test->m_children.begin (); j != test->m_children.end ();)
+ {
+ TestCase *testCase = *j;
+
+ // If this test case takes longer than the maximum test
+ // duration that should be run, then don't run it.
+ if (testCase->m_duration > maximumTestDuration)
+ {
+ // Free this test case's memory.
+ delete *j;
+
+ // Remove this test case from the test suite.
+ test->m_children.erase (j);
+ }
+ else
+ {
+ // Only advance through the vector elements if this test
+ // case wasn't deleted.
+ ++j;
+ }
+ }
+
+ // Add this test suite.
tests.push_back (test);
}
return tests;
@@ -686,12 +732,14 @@
std::string testName = "";
std::string testTypeString = "";
std::string out = "";
+ std::string fullness = "";
bool xml = false;
bool append = false;
bool printTempDir = false;
bool printTestTypeList = false;
bool printTestNameList = false;
bool printTestTypeAndName = false;
+ enum TestCase::TestDuration maximumTestDuration = TestCase::QUICK;
char *progname = argv[0];
argv++;
@@ -766,6 +814,24 @@
{
out = arg + strlen("--out=");
}
+ else if (strncmp(arg, "--fullness=", strlen("--fullness=")) == 0)
+ {
+ fullness = arg + strlen("--fullness=");
+
+ // Set the maximum test length allowed.
+ if (fullness == "EXTENSIVE")
+ {
+ maximumTestDuration = TestCase::EXTENSIVE;
+ }
+ else if (fullness == "TAKES_FOREVER")
+ {
+ maximumTestDuration = TestCase::TAKES_FOREVER;
+ }
+ else
+ {
+ maximumTestDuration = TestCase::QUICK;
+ }
+ }
else
{
// un-recognized command-line argument
@@ -810,7 +876,7 @@
return 1;
}
- std::list<TestCase *> tests = FilterTests (testName, testType);
+ std::list<TestCase *> tests = FilterTests (testName, testType, maximumTestDuration);
if (m_tempDir == "")
{
@@ -859,6 +925,7 @@
for (std::list<TestCase *>::const_iterator i = tests.begin (); i != tests.end (); ++i)
{
TestCase *test = *i;
+
test->Run (this);
PrintReport (test, os, xml, 0);
if (test->IsFailed ())
--- a/src/core/model/test.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/model/test.h Fri Apr 05 17:59:11 2013 +0200
@@ -834,6 +834,16 @@
class TestCase
{
public:
+ /**
+ * \enum TestDuration
+ * \brief How long the test takes to execute.
+ */
+ enum TestDuration {
+ QUICK = 1, /// Fast test.
+ EXTENSIVE = 2, /// Medium length test.
+ TAKES_FOREVER = 3 /// Very long running test.
+ };
+
virtual ~TestCase ();
protected:
@@ -846,8 +856,19 @@
* \brief Add an individual test case to this test suite.
*
* \param testCase Pointer to the test case object to be added.
+ *
+ * \deprecated this method will go away in future versions of
+ * ns-3. Please use instead AddTestCase (TestCase, TestDuration)
*/
- void AddTestCase (TestCase *testCase);
+ void AddTestCase (TestCase *testCase) NS_DEPRECATED;
+
+ /**
+ * \brief Add an individual test case to this test suite.
+ *
+ * \param testCase Pointer to the test case object to be added.
+ * \param duration Amount of time this test takes to execute.
+ */
+ void AddTestCase (TestCase *testCase, enum TestDuration duration);
/**
* \param directory the directory where the test data is located
@@ -932,6 +953,7 @@
TestRunnerImpl *m_runner;
struct Result *m_result;
std::string m_name;
+ enum TestDuration m_duration;
};
/**
--- a/src/core/test/attribute-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/attribute-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -1274,19 +1274,19 @@
AttributesTestSuite::AttributesTestSuite ()
: TestSuite ("attributes", UNIT)
{
- AddTestCase (new AttributeTestCase<BooleanValue> ("Check Attributes of type BooleanValue"));
- AddTestCase (new AttributeTestCase<IntegerValue> ("Check Attributes of type IntegerValue"));
- AddTestCase (new AttributeTestCase<UintegerValue> ("Check Attributes of type UintegerValue"));
- AddTestCase (new AttributeTestCase<DoubleValue> ("Check Attributes of type DoubleValue"));
- AddTestCase (new AttributeTestCase<EnumValue> ("Check Attributes of type EnumValue"));
- AddTestCase (new RandomVariableStreamAttributeTestCase ("Check Attributes of type RandomVariableStream"));
- AddTestCase (new ObjectVectorAttributeTestCase ("Check Attributes of type ObjectVectorValue"));
- AddTestCase (new ObjectMapAttributeTestCase ("Check Attributes of type ObjectMapValue"));
- AddTestCase (new IntegerTraceSourceAttributeTestCase ("Ensure TracedValue<uint8_t> can be set like IntegerValue"));
- AddTestCase (new IntegerTraceSourceTestCase ("Ensure TracedValue<uint8_t> also works as trace source"));
- AddTestCase (new TracedCallbackTestCase ("Ensure TracedCallback<double, int, float> works as trace source"));
- AddTestCase (new PointerAttributeTestCase ("Check Attributes of type PointerValue"));
- AddTestCase (new CallbackValueTestCase ("Check Attributes of type CallbackValue"));
+ AddTestCase (new AttributeTestCase<BooleanValue> ("Check Attributes of type BooleanValue"), TestCase::QUICK);
+ AddTestCase (new AttributeTestCase<IntegerValue> ("Check Attributes of type IntegerValue"), TestCase::QUICK);
+ AddTestCase (new AttributeTestCase<UintegerValue> ("Check Attributes of type UintegerValue"), TestCase::QUICK);
+ AddTestCase (new AttributeTestCase<DoubleValue> ("Check Attributes of type DoubleValue"), TestCase::QUICK);
+ AddTestCase (new AttributeTestCase<EnumValue> ("Check Attributes of type EnumValue"), TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamAttributeTestCase ("Check Attributes of type RandomVariableStream"), TestCase::QUICK);
+ AddTestCase (new ObjectVectorAttributeTestCase ("Check Attributes of type ObjectVectorValue"), TestCase::QUICK);
+ AddTestCase (new ObjectMapAttributeTestCase ("Check Attributes of type ObjectMapValue"), TestCase::QUICK);
+ AddTestCase (new IntegerTraceSourceAttributeTestCase ("Ensure TracedValue<uint8_t> can be set like IntegerValue"), TestCase::QUICK);
+ AddTestCase (new IntegerTraceSourceTestCase ("Ensure TracedValue<uint8_t> also works as trace source"), TestCase::QUICK);
+ AddTestCase (new TracedCallbackTestCase ("Ensure TracedCallback<double, int, float> works as trace source"), TestCase::QUICK);
+ AddTestCase (new PointerAttributeTestCase ("Check Attributes of type PointerValue"), TestCase::QUICK);
+ AddTestCase (new CallbackValueTestCase ("Check Attributes of type CallbackValue"), TestCase::QUICK);
}
static AttributesTestSuite attributesTestSuite;
--- a/src/core/test/callback-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/callback-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -568,11 +568,11 @@
CallbackTestSuite::CallbackTestSuite ()
: TestSuite ("callback", UNIT)
{
- AddTestCase (new BasicCallbackTestCase);
- AddTestCase (new MakeCallbackTestCase);
- AddTestCase (new MakeBoundCallbackTestCase);
- AddTestCase (new NullifyCallbackTestCase);
- AddTestCase (new MakeCallbackTemplatesTestCase);
+ AddTestCase (new BasicCallbackTestCase, TestCase::QUICK);
+ AddTestCase (new MakeCallbackTestCase, TestCase::QUICK);
+ AddTestCase (new MakeBoundCallbackTestCase, TestCase::QUICK);
+ AddTestCase (new NullifyCallbackTestCase, TestCase::QUICK);
+ AddTestCase (new MakeCallbackTemplatesTestCase, TestCase::QUICK);
}
static CallbackTestSuite CallbackTestSuite;
--- a/src/core/test/command-line-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/command-line-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -219,10 +219,10 @@
CommandLineTestSuite::CommandLineTestSuite ()
: TestSuite ("command-line", UNIT)
{
- AddTestCase (new CommandLineBooleanTestCase);
- AddTestCase (new CommandLineIntTestCase);
- AddTestCase (new CommandLineUnsignedIntTestCase);
- AddTestCase (new CommandLineStringTestCase);
+ AddTestCase (new CommandLineBooleanTestCase, TestCase::QUICK);
+ AddTestCase (new CommandLineIntTestCase, TestCase::QUICK);
+ AddTestCase (new CommandLineUnsignedIntTestCase, TestCase::QUICK);
+ AddTestCase (new CommandLineStringTestCase, TestCase::QUICK);
}
static CommandLineTestSuite CommandLineTestSuite;
--- a/src/core/test/config-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/config-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -618,9 +618,9 @@
ConfigTestSuite::ConfigTestSuite ()
: TestSuite ("config", UNIT)
{
- AddTestCase (new RootNamespaceConfigTestCase);
- AddTestCase (new UnderRootNamespaceConfigTestCase);
- AddTestCase (new ObjectVectorConfigTestCase);
+ AddTestCase (new RootNamespaceConfigTestCase, TestCase::QUICK);
+ AddTestCase (new UnderRootNamespaceConfigTestCase, TestCase::QUICK);
+ AddTestCase (new ObjectVectorConfigTestCase, TestCase::QUICK);
}
static ConfigTestSuite configTestSuite;
--- a/src/core/test/global-value-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/global-value-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -85,7 +85,7 @@
GlobalValueTestSuite::GlobalValueTestSuite ()
: TestSuite ("global-value", UNIT)
{
- AddTestCase (new GlobalValueTestCase);
+ AddTestCase (new GlobalValueTestCase, TestCase::QUICK);
}
static GlobalValueTestSuite globalValueTestSuite;
--- a/src/core/test/int64x64-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/int64x64-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -325,13 +325,13 @@
Int64x64128TestSuite ()
: TestSuite ("int64x64", UNIT)
{
- AddTestCase (new Int64x64FracTestCase ());
- AddTestCase (new Int64x64InputTestCase ());
- AddTestCase (new Int64x64InputOutputTestCase ());
- AddTestCase (new Int64x64ArithmeticTestCase ());
- AddTestCase (new Int64x64Bug455TestCase ());
- AddTestCase (new Int64x64Bug863TestCase ());
- AddTestCase (new Int64x64CompareTestCase ());
- AddTestCase (new Int64x64InvertTestCase ());
+ AddTestCase (new Int64x64FracTestCase (), TestCase::QUICK);
+ AddTestCase (new Int64x64InputTestCase (), TestCase::QUICK);
+ AddTestCase (new Int64x64InputOutputTestCase (), TestCase::QUICK);
+ AddTestCase (new Int64x64ArithmeticTestCase (), TestCase::QUICK);
+ AddTestCase (new Int64x64Bug455TestCase (), TestCase::QUICK);
+ AddTestCase (new Int64x64Bug863TestCase (), TestCase::QUICK);
+ AddTestCase (new Int64x64CompareTestCase (), TestCase::QUICK);
+ AddTestCase (new Int64x64InvertTestCase (), TestCase::QUICK);
}
} g_int64x64TestSuite;
--- a/src/core/test/many-uniform-random-variables-one-get-value-call-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/many-uniform-random-variables-one-get-value-call-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -82,7 +82,7 @@
ManyUniformRandomVariablesOneGetValueCallTestSuite::ManyUniformRandomVariablesOneGetValueCallTestSuite ()
: TestSuite ("many-uniform-random-variables-one-get-value-call", PERFORMANCE)
{
- AddTestCase (new ManyUniformRandomVariablesOneGetValueCallTestCase);
+ AddTestCase (new ManyUniformRandomVariablesOneGetValueCallTestCase, TestCase::QUICK);
}
static ManyUniformRandomVariablesOneGetValueCallTestSuite manyUniformRandomVariablesOneGetValueCallTestSuite;
--- a/src/core/test/names-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/names-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -928,20 +928,20 @@
NamesTestSuite::NamesTestSuite ()
: TestSuite ("object-name-service", UNIT)
{
- AddTestCase (new BasicAddTestCase);
- AddTestCase (new StringContextAddTestCase);
- AddTestCase (new FullyQualifiedAddTestCase);
- AddTestCase (new RelativeAddTestCase);
- AddTestCase (new BasicRenameTestCase);
- AddTestCase (new StringContextRenameTestCase);
- AddTestCase (new FullyQualifiedRenameTestCase);
- AddTestCase (new RelativeRenameTestCase);
- AddTestCase (new FindPathTestCase);
- AddTestCase (new BasicFindTestCase);
- AddTestCase (new StringContextFindTestCase);
- AddTestCase (new FullyQualifiedFindTestCase);
- AddTestCase (new RelativeFindTestCase);
- AddTestCase (new AlternateFindTestCase);
+ AddTestCase (new BasicAddTestCase, TestCase::QUICK);
+ AddTestCase (new StringContextAddTestCase, TestCase::QUICK);
+ AddTestCase (new FullyQualifiedAddTestCase, TestCase::QUICK);
+ AddTestCase (new RelativeAddTestCase, TestCase::QUICK);
+ AddTestCase (new BasicRenameTestCase, TestCase::QUICK);
+ AddTestCase (new StringContextRenameTestCase, TestCase::QUICK);
+ AddTestCase (new FullyQualifiedRenameTestCase, TestCase::QUICK);
+ AddTestCase (new RelativeRenameTestCase, TestCase::QUICK);
+ AddTestCase (new FindPathTestCase, TestCase::QUICK);
+ AddTestCase (new BasicFindTestCase, TestCase::QUICK);
+ AddTestCase (new StringContextFindTestCase, TestCase::QUICK);
+ AddTestCase (new FullyQualifiedFindTestCase, TestCase::QUICK);
+ AddTestCase (new RelativeFindTestCase, TestCase::QUICK);
+ AddTestCase (new AlternateFindTestCase, TestCase::QUICK);
}
static NamesTestSuite namesTestSuite;
--- a/src/core/test/object-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/object-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -419,9 +419,9 @@
ObjectTestSuite::ObjectTestSuite ()
: TestSuite ("object", UNIT)
{
- AddTestCase (new CreateObjectTestCase);
- AddTestCase (new AggregateObjectTestCase);
- AddTestCase (new ObjectFactoryTestCase);
+ AddTestCase (new CreateObjectTestCase, TestCase::QUICK);
+ AddTestCase (new AggregateObjectTestCase, TestCase::QUICK);
+ AddTestCase (new ObjectFactoryTestCase, TestCase::QUICK);
}
static ObjectTestSuite objectTestSuite;
--- a/src/core/test/one-uniform-random-variable-many-get-value-calls-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/one-uniform-random-variable-many-get-value-calls-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -82,7 +82,7 @@
OneUniformRandomVariableManyGetValueCallsTestSuite::OneUniformRandomVariableManyGetValueCallsTestSuite ()
: TestSuite ("one-uniform-random-variable-many-get-value-calls", PERFORMANCE)
{
- AddTestCase (new OneUniformRandomVariableManyGetValueCallsTestCase);
+ AddTestCase (new OneUniformRandomVariableManyGetValueCallsTestCase, TestCase::QUICK);
}
static OneUniformRandomVariableManyGetValueCallsTestSuite oneUniformRandomVariableManyGetValueCallsTestSuite;
--- a/src/core/test/ptr-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/ptr-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -269,6 +269,6 @@
PtrTestSuite ()
: TestSuite ("ptr", UNIT)
{
- AddTestCase (new PtrTestCase ());
+ AddTestCase (new PtrTestCase (), TestCase::QUICK);
}
} g_ptrTestSuite;
--- a/src/core/test/random-variable-stream-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/random-variable-stream-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -2785,41 +2785,41 @@
RandomVariableStreamTestSuite::RandomVariableStreamTestSuite ()
: TestSuite ("random-variable-stream-generators", UNIT)
{
- AddTestCase (new RandomVariableStreamUniformTestCase);
- AddTestCase (new RandomVariableStreamUniformAntitheticTestCase);
- AddTestCase (new RandomVariableStreamConstantTestCase);
- AddTestCase (new RandomVariableStreamSequentialTestCase);
- AddTestCase (new RandomVariableStreamNormalTestCase);
- AddTestCase (new RandomVariableStreamNormalAntitheticTestCase);
- AddTestCase (new RandomVariableStreamExponentialTestCase);
- AddTestCase (new RandomVariableStreamExponentialAntitheticTestCase);
- AddTestCase (new RandomVariableStreamParetoTestCase);
- AddTestCase (new RandomVariableStreamParetoAntitheticTestCase);
- AddTestCase (new RandomVariableStreamWeibullTestCase);
- AddTestCase (new RandomVariableStreamWeibullAntitheticTestCase);
- AddTestCase (new RandomVariableStreamLogNormalTestCase);
+ AddTestCase (new RandomVariableStreamUniformTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamUniformAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamConstantTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamSequentialTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamNormalTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamNormalAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamExponentialTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamExponentialAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamParetoTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamParetoAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamWeibullTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamWeibullAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamLogNormalTestCase, TestCase::QUICK);
// XXX This test is currently disabled because it fails sometimes.
// A possible reason for the failure is that the antithetic code is
// not implemented properly for this log-normal case.
/*
- AddTestCase (new RandomVariableStreamLogNormalAntitheticTestCase);
+ AddTestCase (new RandomVariableStreamLogNormalAntitheticTestCase, TestCase::QUICK);
*/
- AddTestCase (new RandomVariableStreamGammaTestCase);
+ AddTestCase (new RandomVariableStreamGammaTestCase, TestCase::QUICK);
// XXX This test is currently disabled because it fails sometimes.
// A possible reason for the failure is that the antithetic code is
// not implemented properly for this gamma case.
/*
- AddTestCase (new RandomVariableStreamGammaAntitheticTestCase);
+ AddTestCase (new RandomVariableStreamGammaAntitheticTestCase, TestCase::QUICK);
*/
- AddTestCase (new RandomVariableStreamErlangTestCase);
- AddTestCase (new RandomVariableStreamErlangAntitheticTestCase);
- AddTestCase (new RandomVariableStreamZipfTestCase);
- AddTestCase (new RandomVariableStreamZipfAntitheticTestCase);
- AddTestCase (new RandomVariableStreamZetaTestCase);
- AddTestCase (new RandomVariableStreamZetaAntitheticTestCase);
- AddTestCase (new RandomVariableStreamDeterministicTestCase);
- AddTestCase (new RandomVariableStreamEmpiricalTestCase);
- AddTestCase (new RandomVariableStreamEmpiricalAntitheticTestCase);
+ AddTestCase (new RandomVariableStreamErlangTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamErlangAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamZipfTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamZipfAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamZetaTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamZetaAntitheticTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamDeterministicTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamEmpiricalTestCase, TestCase::QUICK);
+ AddTestCase (new RandomVariableStreamEmpiricalAntitheticTestCase, TestCase::QUICK);
}
static RandomVariableStreamTestSuite randomVariableStreamTestSuite;
--- a/src/core/test/random-variable-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/random-variable-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -138,8 +138,8 @@
BasicRandomNumberTestSuite::BasicRandomNumberTestSuite ()
: TestSuite ("basic-random-number", UNIT)
{
- AddTestCase (new BasicRandomNumberTestCase);
- AddTestCase (new RandomNumberSerializationTestCase);
+ AddTestCase (new BasicRandomNumberTestCase, TestCase::QUICK);
+ AddTestCase (new RandomNumberSerializationTestCase, TestCase::QUICK);
}
static BasicRandomNumberTestSuite BasicRandomNumberTestSuite;
--- a/src/core/test/rng-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/rng-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -421,10 +421,10 @@
RngTestSuite::RngTestSuite ()
: TestSuite ("random-number-generators", UNIT)
{
- AddTestCase (new RngUniformTestCase);
- AddTestCase (new RngNormalTestCase);
- AddTestCase (new RngExponentialTestCase);
- AddTestCase (new RngParetoTestCase);
+ AddTestCase (new RngUniformTestCase, TestCase::QUICK);
+ AddTestCase (new RngNormalTestCase, TestCase::QUICK);
+ AddTestCase (new RngExponentialTestCase, TestCase::QUICK);
+ AddTestCase (new RngParetoTestCase, TestCase::QUICK);
}
static RngTestSuite rngTestSuite;
--- a/src/core/test/sample-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/sample-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -56,7 +56,7 @@
SampleTestSuite::SampleTestSuite ()
: TestSuite ("sample", UNIT)
{
- AddTestCase (new SampleTestCase1);
+ AddTestCase (new SampleTestCase1, TestCase::QUICK);
}
// Do not forget to allocate an instance of this TestSuite
--- a/src/core/test/simulator-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/simulator-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -468,12 +468,12 @@
ObjectFactory factory;
factory.SetTypeId (ListScheduler::GetTypeId ());
- AddTestCase (new SimulatorEventsTestCase (factory));
+ AddTestCase (new SimulatorEventsTestCase (factory), TestCase::QUICK);
factory.SetTypeId (MapScheduler::GetTypeId ());
- AddTestCase (new SimulatorEventsTestCase (factory));
+ AddTestCase (new SimulatorEventsTestCase (factory), TestCase::QUICK);
factory.SetTypeId (HeapScheduler::GetTypeId ());
- AddTestCase (new SimulatorEventsTestCase (factory));
+ AddTestCase (new SimulatorEventsTestCase (factory), TestCase::QUICK);
factory.SetTypeId (CalendarScheduler::GetTypeId ());
- AddTestCase (new SimulatorEventsTestCase (factory));
+ AddTestCase (new SimulatorEventsTestCase (factory), TestCase::QUICK);
}
} g_simulatorTestSuite;
--- a/src/core/test/threaded-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/threaded-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -258,7 +258,7 @@
for (unsigned int k=0; k < (sizeof(schedulerTypes) / sizeof(schedulerTypes[0])); ++k)
{
factory.SetTypeId(schedulerTypes[k]);
- AddTestCase (new ThreadedSimulatorEventsTestCase (factory, simulatorTypes[i], threadcounts[j]));
+ AddTestCase (new ThreadedSimulatorEventsTestCase (factory, simulatorTypes[i], threadcounts[j]), TestCase::QUICK);
}
}
}
--- a/src/core/test/time-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/time-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -139,7 +139,7 @@
TimeTestSuite ()
: TestSuite ("time", UNIT)
{
- AddTestCase (new TimeSimpleTestCase (Time::US));
- AddTestCase (new TimesWithSignsTestCase ());
+ AddTestCase (new TimeSimpleTestCase (Time::US), TestCase::QUICK);
+ AddTestCase (new TimesWithSignsTestCase (), TestCase::QUICK);
}
} g_timeTestSuite;
--- a/src/core/test/timer-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/timer-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -214,7 +214,7 @@
TimerTestSuite ()
: TestSuite ("timer", UNIT)
{
- AddTestCase (new TimerStateTestCase ());
- AddTestCase (new TimerTemplateTestCase ());
+ AddTestCase (new TimerStateTestCase (), TestCase::QUICK);
+ AddTestCase (new TimerTemplateTestCase (), TestCase::QUICK);
}
} g_timerTestSuite;
--- a/src/core/test/traced-callback-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/traced-callback-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -117,7 +117,7 @@
TracedCallbackTestSuite::TracedCallbackTestSuite ()
: TestSuite ("traced-callback", UNIT)
{
- AddTestCase (new BasicTracedCallbackTestCase);
+ AddTestCase (new BasicTracedCallbackTestCase, TestCase::QUICK);
}
static TracedCallbackTestSuite tracedCallbackTestSuite;
--- a/src/core/test/type-traits-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/type-traits-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -56,7 +56,7 @@
TypeTraitsTestSuite::TypeTraitsTestSuite ()
: TestSuite ("type-traits", UNIT)
{
- AddTestCase (new TypeTraitsTestCase);
+ AddTestCase (new TypeTraitsTestCase, TestCase::QUICK);
}
static TypeTraitsTestSuite typeTraitsTestSuite;
--- a/src/core/test/watchdog-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/test/watchdog-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -74,6 +74,6 @@
WatchdogTestSuite()
: TestSuite ("watchdog", UNIT)
{
- AddTestCase (new WatchdogTestCase ());
+ AddTestCase (new WatchdogTestCase (), TestCase::QUICK);
}
} g_watchdogTestSuite;
--- a/src/core/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/core/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -1,8 +1,7 @@
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
import sys
-import Options
-
+from waflib import Options
import wutils
def options(opt):
@@ -49,7 +48,7 @@
conf.check_nonfatal(header_name='signal.h', define_name='HAVE_SIGNAL_H')
# Check for POSIX threads
- test_env = conf.env.copy()
+ test_env = conf.env.derive()
if Options.platform != 'darwin' and Options.platform != 'cygwin':
test_env.append_value('LINKFLAGS', '-pthread')
test_env.append_value('CXXFLAGS', '-pthread')
@@ -173,7 +172,7 @@
'test/watchdog-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'core'
headers.source = [
'model/nstime.h',
@@ -309,7 +308,7 @@
core_test.source.extend(['test/rng-test-suite.cc'])
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
pymod = bld.ns3_python_bindings()
if pymod is not None:
--- a/src/create-module.py Fri Apr 05 16:50:37 2013 +0200
+++ b/src/create-module.py Fri Apr 05 17:59:11 2013 +0200
@@ -24,7 +24,7 @@
'test/%(MODULE)s-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = %(MODULE)r
headers.source = [
'model/%(MODULE)s.h',
@@ -32,7 +32,7 @@
]
if bld.env.ENABLE_EXAMPLES:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
# bld.ns3_python_bindings()
@@ -213,18 +213,24 @@
DOC_RST_TEMPLATE = '''Example Module Documentation
----------------------------
+.. include:: replace.txt
+
.. heading hierarchy:
------------- Chapter
************* Section (#.#)
============= Subsection (#.#.#)
############# Paragraph (no number)
-This is a suggested outline for adding new module documentation to ns-3.
+This is a suggested outline for adding new module documentation to |ns3|.
See ``src/click/doc/click.rst`` for an example.
The introductory paragraph is for describing what this code is trying to
model.
+For consistency (italicized formatting), please use |ns3| to refer to
+ns-3 in the documentation (and likewise, |ns2| for ns-2). These macros
+are defined in the file ``replace.txt``.
+
Model Description
*****************
@@ -338,7 +344,7 @@
model_cc.close()
model_h = file(os.path.join(moduledir, "model", "%s.h" % modname), "wt")
- model_h.write(MODEL_H_TEMPLATE % dict(MODULE=modname, INCLUDE_GUARD="__%s_H__" % (modname.upper()),))
+ model_h.write(MODEL_H_TEMPLATE % dict(MODULE=modname, INCLUDE_GUARD="%s_H" % (modname.replace("-", "_").upper()),))
model_h.close()
@@ -349,7 +355,7 @@
testdir = os.path.join(moduledir, "test")
os.mkdir(testdir)
test_cc = file(os.path.join(moduledir, "test", "%s-test-suite.cc" % modname), "wt")
- test_cc.write(TEST_CC_TEMPLATE % dict(MODULE=modname,CAPITALIZED=modname.capitalize()))
+ test_cc.write(TEST_CC_TEMPLATE % dict(MODULE=modname, CAPITALIZED=''.join([word.capitalize() for word in modname.split('-')])))
test_cc.close()
@@ -365,7 +371,7 @@
helper_cc.close()
helper_h = file(os.path.join(moduledir, "helper", "%s-helper.h" % modname), "wt")
- helper_h.write(HELPER_H_TEMPLATE % dict(MODULE=modname, INCLUDE_GUARD="__%s_HELPER_H__" % (modname.upper()),))
+ helper_h.write(HELPER_H_TEMPLATE % dict(MODULE=modname, INCLUDE_GUARD="%s_HELPER_H" % (modname.replace("-", "_").upper()),))
helper_h.close()
#
--- a/src/csma-layout/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/csma-layout/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -5,14 +5,14 @@
obj.source = [
'model/csma-star-helper.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'csma-layout'
headers.source = [
'model/csma-star-helper.h',
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/csma/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/csma/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -8,7 +8,7 @@
'model/csma-channel.cc',
'helper/csma-helper.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'csma'
headers.source = [
'model/backoff.h',
@@ -18,6 +18,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/dsdv/test/dsdv-testcase.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsdv/test/dsdv-testcase.cc Fri Apr 05 17:59:11 2013 +0200
@@ -188,8 +188,8 @@
public:
DsdvTestSuite () : TestSuite ("routing-dsdv", UNIT)
{
- AddTestCase (new DsdvHeaderTestCase ());
- AddTestCase (new DsdvTableTestCase ());
+ AddTestCase (new DsdvHeaderTestCase (), TestCase::QUICK);
+ AddTestCase (new DsdvTableTestCase (), TestCase::QUICK);
}
} g_dsdvTestSuite;
}
--- a/src/dsdv/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsdv/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -16,7 +16,7 @@
'test/dsdv-testcase.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'dsdv'
headers.source = [
'model/dsdv-rtable.h',
@@ -26,6 +26,6 @@
'helper/dsdv-helper.h',
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/dsr/bindings/modulegen__gcc_ILP32.py Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/bindings/modulegen__gcc_ILP32.py Fri Apr 05 17:59:11 2013 +0200
@@ -1315,14 +1315,6 @@
cls.add_method('SetDsrHelper',
'void',
[param('ns3::DsrHelper &', 'dsrHelper')])
- ## dsr-main-helper.h (module 'dsr'): void ns3::DsrMainHelper::SetRouteCache(ns3::Ptr<ns3::dsr::RouteCache> routeCache) [member function]
- cls.add_method('SetRouteCache',
- 'void',
- [param('ns3::Ptr< ns3::dsr::RouteCache >', 'routeCache')])
- ## dsr-main-helper.h (module 'dsr'): void ns3::DsrMainHelper::SetRreqTable(ns3::Ptr<ns3::dsr::RreqTable> rreqTable) [member function]
- cls.add_method('SetRreqTable',
- 'void',
- [param('ns3::Ptr< ns3::dsr::RreqTable >', 'rreqTable')])
return
def register_Ns3EventGarbageCollector_methods(root_module, cls):
@@ -4723,11 +4715,6 @@
'int',
[param('ns3::Time const &', 'o')],
is_const=True)
- ## nstime.h (module 'core'): static void ns3::Time::FreezeResolution() [member function]
- cls.add_method('FreezeResolution',
- 'void',
- [],
- is_static=True)
## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & from, ns3::Time::Unit timeUnit) [member function]
cls.add_method('From',
'ns3::Time',
@@ -10012,10 +9999,6 @@
'void',
[param('std::ostream &', 'os')],
is_const=True, is_virtual=True)
- ## dsr-option-header.h (module 'dsr'): ns3::Ipv4Address ns3::dsr::DsrOptionRrepHeader::SearchNextHop(ns3::Ipv4Address ipv4Address) [member function]
- cls.add_method('SearchNextHop',
- 'ns3::Ipv4Address',
- [param('ns3::Ipv4Address', 'ipv4Address')])
## dsr-option-header.h (module 'dsr'): void ns3::dsr::DsrOptionRrepHeader::Serialize(ns3::Buffer::Iterator start) const [member function]
cls.add_method('Serialize',
'void',
@@ -10054,11 +10037,6 @@
'ns3::dsr::DsrOptionHeader::Alignment',
[],
is_const=True, is_virtual=True)
- ## dsr-option-header.h (module 'dsr'): uint32_t ns3::dsr::DsrOptionRreqHeader::GetDataLength() const [member function]
- cls.add_method('GetDataLength',
- 'uint32_t',
- [],
- is_const=True)
## dsr-option-header.h (module 'dsr'): uint16_t ns3::dsr::DsrOptionRreqHeader::GetId() const [member function]
cls.add_method('GetId',
'uint16_t',
@@ -10108,10 +10086,6 @@
'void',
[param('ns3::Buffer::Iterator', 'start')],
is_const=True, is_virtual=True)
- ## dsr-option-header.h (module 'dsr'): void ns3::dsr::DsrOptionRreqHeader::SetDataLength(uint32_t dataLength) [member function]
- cls.add_method('SetDataLength',
- 'void',
- [param('uint32_t', 'dataLength')])
## dsr-option-header.h (module 'dsr'): void ns3::dsr::DsrOptionRreqHeader::SetId(uint16_t identification) [member function]
cls.add_method('SetId',
'void',
@@ -10287,10 +10261,6 @@
cls.add_method('ReverseSearchNextHop',
'ns3::Ipv4Address',
[param('ns3::Ipv4Address', 'ipv4Address'), param('std::vector< ns3::Ipv4Address > &', 'vec')])
- ## dsr-options.h (module 'dsr'): void ns3::dsr::DsrOptions::ScheduleReply(ns3::Ptr<ns3::Packet> & packet, std::vector<ns3::Ipv4Address, std::allocator<ns3::Ipv4Address> > & nodeList, ns3::Ipv4Address & source, ns3::Ipv4Address & destination) [member function]
- cls.add_method('ScheduleReply',
- 'void',
- [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('std::vector< ns3::Ipv4Address > &', 'nodeList'), param('ns3::Ipv4Address &', 'source'), param('ns3::Ipv4Address &', 'destination')])
## dsr-options.h (module 'dsr'): ns3::Ipv4Address ns3::dsr::DsrOptions::SearchNextHop(ns3::Ipv4Address ipv4Address, std::vector<ns3::Ipv4Address, std::allocator<ns3::Ipv4Address> > & vec) [member function]
cls.add_method('SearchNextHop',
'ns3::Ipv4Address',
@@ -10377,11 +10347,6 @@
'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv6Address, ns3::Ipv6Address, unsigned char, ns3::Ptr< ns3::Ipv6Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >',
[],
is_const=True, is_virtual=True)
- ## dsr-routing.h (module 'dsr'): uint8_t ns3::dsr::DsrRouting::GetExtensionNumber() const [member function]
- cls.add_method('GetExtensionNumber',
- 'uint8_t',
- [],
- is_const=True)
## dsr-routing.h (module 'dsr'): uint16_t ns3::dsr::DsrRouting::GetIDfromIP(ns3::Ipv4Address address) [member function]
cls.add_method('GetIDfromIP',
'uint16_t',
@@ -10399,10 +10364,6 @@
'ns3::Ptr< ns3::Node >',
[],
is_const=True)
- ## dsr-routing.h (module 'dsr'): ns3::Ptr<ns3::Node> ns3::dsr::DsrRouting::GetNodeWithAddress(ns3::Ipv4Address ipv4Address) [member function]
- cls.add_method('GetNodeWithAddress',
- 'ns3::Ptr< ns3::Node >',
- [param('ns3::Ipv4Address', 'ipv4Address')])
## dsr-routing.h (module 'dsr'): ns3::Ptr<ns3::dsr::DsrOptions> ns3::dsr::DsrRouting::GetOption(int optionNumber) [member function]
cls.add_method('GetOption',
'ns3::Ptr< ns3::dsr::DsrOptions >',
@@ -10565,10 +10526,6 @@
cls.add_method('SendRequest',
'void',
[param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source')])
- ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SendRequestAndIncrement(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Address source, ns3::Ipv4Address destination) [member function]
- cls.add_method('SendRequestAndIncrement',
- 'void',
- [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source'), param('ns3::Ipv4Address', 'destination')])
## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SendUnreachError(ns3::Ipv4Address errorHop, ns3::Ipv4Address destination, ns3::Ipv4Address originalDst, uint8_t salvage, uint8_t protocol) [member function]
cls.add_method('SendUnreachError',
'void',
@@ -10962,10 +10919,6 @@
cls.add_method('Find',
'bool',
[param('ns3::Ipv4Address', 'nextHop')])
- ## dsr-maintain-buff.h (module 'dsr'): bool ns3::dsr::MaintainBuffer::FindMaintainEntry(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Address ourAdd, ns3::Ipv4Address src, ns3::Ipv4Address nextHop, ns3::Ipv4Address dst, ns3::dsr::NetworkKey networkKey) [member function]
- cls.add_method('FindMaintainEntry',
- 'bool',
- [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'ourAdd'), param('ns3::Ipv4Address', 'src'), param('ns3::Ipv4Address', 'nextHop'), param('ns3::Ipv4Address', 'dst'), param('ns3::dsr::NetworkKey', 'networkKey')])
## dsr-maintain-buff.h (module 'dsr'): ns3::Time ns3::dsr::MaintainBuffer::GetMaintainBufferTimeout() const [member function]
cls.add_method('GetMaintainBufferTimeout',
'ns3::Time',
@@ -11093,10 +11046,6 @@
cls.add_method('DeleteRoute',
'bool',
[param('ns3::Ipv4Address', 'dst')])
- ## dsr-rcache.h (module 'dsr'): void ns3::dsr::RouteCache::DropPathWithDst(ns3::Ipv4Address dst) [member function]
- cls.add_method('DropPathWithDst',
- 'void',
- [param('ns3::Ipv4Address', 'dst')])
## dsr-rcache.h (module 'dsr'): bool ns3::dsr::RouteCache::FindSameRoute(ns3::dsr::RouteCacheEntry & rt, std::list<ns3::dsr::RouteCacheEntry, std::allocator<ns3::dsr::RouteCacheEntry> > & rtVector) [member function]
cls.add_method('FindSameRoute',
'bool',
@@ -11120,11 +11069,6 @@
'ns3::Callback< void, ns3::Ipv4Address, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >',
[],
is_const=True)
- ## dsr-rcache.h (module 'dsr'): ns3::Ipv4Address ns3::dsr::RouteCache::GetDestination() const [member function]
- cls.add_method('GetDestination',
- 'ns3::Ipv4Address',
- [],
- is_const=True)
## dsr-rcache.h (module 'dsr'): ns3::Time ns3::dsr::RouteCache::GetExpireTime(ns3::Ipv4Address addr) [member function]
cls.add_method('GetExpireTime',
'ns3::Time',
@@ -11179,10 +11123,6 @@
'ns3::Time',
[],
is_const=True)
- ## dsr-rcache.h (module 'dsr'): bool ns3::dsr::RouteCache::IsEqual(ns3::dsr::RouteCacheEntry ca) [member function]
- cls.add_method('IsEqual',
- 'bool',
- [param('ns3::dsr::RouteCacheEntry', 'ca')])
## dsr-rcache.h (module 'dsr'): bool ns3::dsr::RouteCache::IsLinkCache() [member function]
cls.add_method('IsLinkCache',
'bool',
--- a/src/dsr/bindings/modulegen__gcc_LP64.py Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/bindings/modulegen__gcc_LP64.py Fri Apr 05 17:59:11 2013 +0200
@@ -1315,14 +1315,6 @@
cls.add_method('SetDsrHelper',
'void',
[param('ns3::DsrHelper &', 'dsrHelper')])
- ## dsr-main-helper.h (module 'dsr'): void ns3::DsrMainHelper::SetRouteCache(ns3::Ptr<ns3::dsr::RouteCache> routeCache) [member function]
- cls.add_method('SetRouteCache',
- 'void',
- [param('ns3::Ptr< ns3::dsr::RouteCache >', 'routeCache')])
- ## dsr-main-helper.h (module 'dsr'): void ns3::DsrMainHelper::SetRreqTable(ns3::Ptr<ns3::dsr::RreqTable> rreqTable) [member function]
- cls.add_method('SetRreqTable',
- 'void',
- [param('ns3::Ptr< ns3::dsr::RreqTable >', 'rreqTable')])
return
def register_Ns3EventGarbageCollector_methods(root_module, cls):
@@ -4723,11 +4715,6 @@
'int',
[param('ns3::Time const &', 'o')],
is_const=True)
- ## nstime.h (module 'core'): static void ns3::Time::FreezeResolution() [member function]
- cls.add_method('FreezeResolution',
- 'void',
- [],
- is_static=True)
## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & from, ns3::Time::Unit timeUnit) [member function]
cls.add_method('From',
'ns3::Time',
@@ -10012,10 +9999,6 @@
'void',
[param('std::ostream &', 'os')],
is_const=True, is_virtual=True)
- ## dsr-option-header.h (module 'dsr'): ns3::Ipv4Address ns3::dsr::DsrOptionRrepHeader::SearchNextHop(ns3::Ipv4Address ipv4Address) [member function]
- cls.add_method('SearchNextHop',
- 'ns3::Ipv4Address',
- [param('ns3::Ipv4Address', 'ipv4Address')])
## dsr-option-header.h (module 'dsr'): void ns3::dsr::DsrOptionRrepHeader::Serialize(ns3::Buffer::Iterator start) const [member function]
cls.add_method('Serialize',
'void',
@@ -10054,11 +10037,6 @@
'ns3::dsr::DsrOptionHeader::Alignment',
[],
is_const=True, is_virtual=True)
- ## dsr-option-header.h (module 'dsr'): uint32_t ns3::dsr::DsrOptionRreqHeader::GetDataLength() const [member function]
- cls.add_method('GetDataLength',
- 'uint32_t',
- [],
- is_const=True)
## dsr-option-header.h (module 'dsr'): uint16_t ns3::dsr::DsrOptionRreqHeader::GetId() const [member function]
cls.add_method('GetId',
'uint16_t',
@@ -10108,10 +10086,6 @@
'void',
[param('ns3::Buffer::Iterator', 'start')],
is_const=True, is_virtual=True)
- ## dsr-option-header.h (module 'dsr'): void ns3::dsr::DsrOptionRreqHeader::SetDataLength(uint32_t dataLength) [member function]
- cls.add_method('SetDataLength',
- 'void',
- [param('uint32_t', 'dataLength')])
## dsr-option-header.h (module 'dsr'): void ns3::dsr::DsrOptionRreqHeader::SetId(uint16_t identification) [member function]
cls.add_method('SetId',
'void',
@@ -10287,10 +10261,6 @@
cls.add_method('ReverseSearchNextHop',
'ns3::Ipv4Address',
[param('ns3::Ipv4Address', 'ipv4Address'), param('std::vector< ns3::Ipv4Address > &', 'vec')])
- ## dsr-options.h (module 'dsr'): void ns3::dsr::DsrOptions::ScheduleReply(ns3::Ptr<ns3::Packet> & packet, std::vector<ns3::Ipv4Address, std::allocator<ns3::Ipv4Address> > & nodeList, ns3::Ipv4Address & source, ns3::Ipv4Address & destination) [member function]
- cls.add_method('ScheduleReply',
- 'void',
- [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('std::vector< ns3::Ipv4Address > &', 'nodeList'), param('ns3::Ipv4Address &', 'source'), param('ns3::Ipv4Address &', 'destination')])
## dsr-options.h (module 'dsr'): ns3::Ipv4Address ns3::dsr::DsrOptions::SearchNextHop(ns3::Ipv4Address ipv4Address, std::vector<ns3::Ipv4Address, std::allocator<ns3::Ipv4Address> > & vec) [member function]
cls.add_method('SearchNextHop',
'ns3::Ipv4Address',
@@ -10377,11 +10347,6 @@
'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv6Address, ns3::Ipv6Address, unsigned char, ns3::Ptr< ns3::Ipv6Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >',
[],
is_const=True, is_virtual=True)
- ## dsr-routing.h (module 'dsr'): uint8_t ns3::dsr::DsrRouting::GetExtensionNumber() const [member function]
- cls.add_method('GetExtensionNumber',
- 'uint8_t',
- [],
- is_const=True)
## dsr-routing.h (module 'dsr'): uint16_t ns3::dsr::DsrRouting::GetIDfromIP(ns3::Ipv4Address address) [member function]
cls.add_method('GetIDfromIP',
'uint16_t',
@@ -10399,10 +10364,6 @@
'ns3::Ptr< ns3::Node >',
[],
is_const=True)
- ## dsr-routing.h (module 'dsr'): ns3::Ptr<ns3::Node> ns3::dsr::DsrRouting::GetNodeWithAddress(ns3::Ipv4Address ipv4Address) [member function]
- cls.add_method('GetNodeWithAddress',
- 'ns3::Ptr< ns3::Node >',
- [param('ns3::Ipv4Address', 'ipv4Address')])
## dsr-routing.h (module 'dsr'): ns3::Ptr<ns3::dsr::DsrOptions> ns3::dsr::DsrRouting::GetOption(int optionNumber) [member function]
cls.add_method('GetOption',
'ns3::Ptr< ns3::dsr::DsrOptions >',
@@ -10565,10 +10526,6 @@
cls.add_method('SendRequest',
'void',
[param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source')])
- ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SendRequestAndIncrement(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Address source, ns3::Ipv4Address destination) [member function]
- cls.add_method('SendRequestAndIncrement',
- 'void',
- [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source'), param('ns3::Ipv4Address', 'destination')])
## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SendUnreachError(ns3::Ipv4Address errorHop, ns3::Ipv4Address destination, ns3::Ipv4Address originalDst, uint8_t salvage, uint8_t protocol) [member function]
cls.add_method('SendUnreachError',
'void',
@@ -10962,10 +10919,6 @@
cls.add_method('Find',
'bool',
[param('ns3::Ipv4Address', 'nextHop')])
- ## dsr-maintain-buff.h (module 'dsr'): bool ns3::dsr::MaintainBuffer::FindMaintainEntry(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Address ourAdd, ns3::Ipv4Address src, ns3::Ipv4Address nextHop, ns3::Ipv4Address dst, ns3::dsr::NetworkKey networkKey) [member function]
- cls.add_method('FindMaintainEntry',
- 'bool',
- [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'ourAdd'), param('ns3::Ipv4Address', 'src'), param('ns3::Ipv4Address', 'nextHop'), param('ns3::Ipv4Address', 'dst'), param('ns3::dsr::NetworkKey', 'networkKey')])
## dsr-maintain-buff.h (module 'dsr'): ns3::Time ns3::dsr::MaintainBuffer::GetMaintainBufferTimeout() const [member function]
cls.add_method('GetMaintainBufferTimeout',
'ns3::Time',
@@ -11093,10 +11046,6 @@
cls.add_method('DeleteRoute',
'bool',
[param('ns3::Ipv4Address', 'dst')])
- ## dsr-rcache.h (module 'dsr'): void ns3::dsr::RouteCache::DropPathWithDst(ns3::Ipv4Address dst) [member function]
- cls.add_method('DropPathWithDst',
- 'void',
- [param('ns3::Ipv4Address', 'dst')])
## dsr-rcache.h (module 'dsr'): bool ns3::dsr::RouteCache::FindSameRoute(ns3::dsr::RouteCacheEntry & rt, std::list<ns3::dsr::RouteCacheEntry, std::allocator<ns3::dsr::RouteCacheEntry> > & rtVector) [member function]
cls.add_method('FindSameRoute',
'bool',
@@ -11120,11 +11069,6 @@
'ns3::Callback< void, ns3::Ipv4Address, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >',
[],
is_const=True)
- ## dsr-rcache.h (module 'dsr'): ns3::Ipv4Address ns3::dsr::RouteCache::GetDestination() const [member function]
- cls.add_method('GetDestination',
- 'ns3::Ipv4Address',
- [],
- is_const=True)
## dsr-rcache.h (module 'dsr'): ns3::Time ns3::dsr::RouteCache::GetExpireTime(ns3::Ipv4Address addr) [member function]
cls.add_method('GetExpireTime',
'ns3::Time',
@@ -11179,10 +11123,6 @@
'ns3::Time',
[],
is_const=True)
- ## dsr-rcache.h (module 'dsr'): bool ns3::dsr::RouteCache::IsEqual(ns3::dsr::RouteCacheEntry ca) [member function]
- cls.add_method('IsEqual',
- 'bool',
- [param('ns3::dsr::RouteCacheEntry', 'ca')])
## dsr-rcache.h (module 'dsr'): bool ns3::dsr::RouteCache::IsLinkCache() [member function]
cls.add_method('IsLinkCache',
'bool',
--- a/src/dsr/helper/dsr-main-helper.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/helper/dsr-main-helper.h Fri Apr 05 17:59:11 2013 +0200
@@ -58,8 +58,6 @@
DsrMainHelper (const DsrMainHelper &);
void Install (DsrHelper &dsrHelper, NodeContainer nodes);
void SetDsrHelper (DsrHelper &dsrHelper);
- void SetRouteCache (Ptr<dsr::RouteCache> routeCache);
- void SetRreqTable (Ptr<dsr::RreqTable> rreqTable);
private:
void Install (Ptr<Node> node);
--- a/src/dsr/model/dsr-maintain-buff.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/model/dsr-maintain-buff.h Fri Apr 05 17:59:11 2013 +0200
@@ -213,7 +213,6 @@
bool Dequeue (Ipv4Address dst, MaintainBuffEntry & entry);
// / Remove all packets with destination IP address dst
void DropPacketWithNextHop (Ipv4Address nextHop);
- bool FindMaintainEntry (Ptr<Packet> packet, Ipv4Address ourAdd, Ipv4Address src, Ipv4Address nextHop, Ipv4Address dst, NetworkKey networkKey);
// / Finds whether a packet with destination dst exists in the queue
bool Find (Ipv4Address nextHop);
// / Number of entries
--- a/src/dsr/model/dsr-option-header.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/model/dsr-option-header.h Fri Apr 05 17:59:11 2013 +0200
@@ -338,16 +338,6 @@
*/
Ipv4Address GetNodeAddress (uint8_t index) const;
/**
- * \brief Set the data length.
- * \param dataLength the data length
- */
- void SetDataLength (uint32_t dataLength);
- /**
- * \brief Get the data length.
- * \return the data length
- */
- uint32_t GetDataLength () const;
- /**
* \brief Set the request id number.
* \param the identification number
*/
@@ -512,12 +502,6 @@
* \return the router IPv4 Address
*/
Ipv4Address GetNodeAddress (uint8_t index) const;
- /*
- * \brief Search the next hop Ipv4 address
- * \param Our own IP address
- * \return The next hop address of the route
- */
- Ipv4Address SearchNextHop (Ipv4Address ipv4Address);
/**
* \brief Print some informations about the packet.
* \param os output stream
--- a/src/dsr/model/dsr-options.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/model/dsr-options.h Fri Apr 05 17:59:11 2013 +0200
@@ -153,14 +153,6 @@
*/
void RemoveDuplicates (std::vector<Ipv4Address>& vec);
/*
- * \brief Schedule the intermediate node route request broadcast
- * \param the original packet
- * \param rrepHeader The rrep header
- * \param source address
- * \param destination address
- */
- void ScheduleReply (Ptr<Packet> &packet, std::vector<Ipv4Address> &nodeList, Ipv4Address &source, Ipv4Address &destination);
- /*
* \brief Get the node id with Ipv4Address
* \return the id of the node
*/
--- a/src/dsr/model/dsr-rcache.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/model/dsr-rcache.h Fri Apr 05 17:59:11 2013 +0200
@@ -320,12 +320,6 @@
void RemoveLastEntry (std::list<RouteCacheEntry> & rtVector);
// / Define the vector of route entries.
typedef std::list<RouteCacheEntry::IP_VECTOR> routeVector;
- // / Get the destination address of the route.
- Ipv4Address GetDestination (void) const;
- // / Remove all packets with destination IP address dst
- void DropPathWithDst (Ipv4Address dst);
- // / To know if the two entries are the same
- bool IsEqual (RouteCacheEntry ca);
// /\name Fields
// \{
bool GetSubRoute () const
--- a/src/dsr/model/dsr-routing.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/model/dsr-routing.h Fri Apr 05 17:59:11 2013 +0200
@@ -327,15 +327,6 @@
*/
void SendErrorRequest (DsrOptionRerrUnreachHeader &rerr, uint8_t protocol);
/*
- * \brief Send the route request and increment the request count
- * \param the original packet
- * \param source address
- * \param destination address
- */
- void SendRequestAndIncrement (Ptr<Packet> packet,
- Ipv4Address source,
- Ipv4Address destination);
- /*
* \brief Forward the route request if the node is not the destination
* \param the original packet
* \param source address
@@ -390,10 +381,6 @@
Ipv4Address realDst,
uint8_t protocol,
Ptr<Ipv4Route> route);
- /*
- * Get the node using the ip address
- */
- Ptr<Node> GetNodeWithAddress (Ipv4Address ipv4Address);
/**
* \param p packet to forward up
* \param header IPv4 Header information
@@ -423,11 +410,6 @@
IpL4Protocol::DownTargetCallback GetDownTarget (void) const;
IpL4Protocol::DownTargetCallback6 GetDownTarget6 (void) const;
/**
- * \brief Get the extension number.
- * \return extension number
- */
- uint8_t GetExtensionNumber () const;
- /**
* \brief Process method
* Called from Ipv4L3Protocol::Receive.
*
--- a/src/dsr/test/dsr-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/test/dsr-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -508,15 +508,15 @@
public:
DsrTestSuite () : TestSuite ("routing-dsr", UNIT)
{
- AddTestCase (new DsrFsHeaderTest);
- AddTestCase (new DsrRreqHeaderTest);
- AddTestCase (new DsrRrepHeaderTest);
- AddTestCase (new DsrSRHeaderTest);
- AddTestCase (new DsrRerrHeaderTest);
- AddTestCase (new DsrAckReqHeaderTest);
- AddTestCase (new DsrAckHeaderTest);
- AddTestCase (new DsrCacheEntryTest);
- AddTestCase (new DsrSendBuffTest);
+ AddTestCase (new DsrFsHeaderTest, TestCase::QUICK);
+ AddTestCase (new DsrRreqHeaderTest, TestCase::QUICK);
+ AddTestCase (new DsrRrepHeaderTest, TestCase::QUICK);
+ AddTestCase (new DsrSRHeaderTest, TestCase::QUICK);
+ AddTestCase (new DsrRerrHeaderTest, TestCase::QUICK);
+ AddTestCase (new DsrAckReqHeaderTest, TestCase::QUICK);
+ AddTestCase (new DsrAckHeaderTest, TestCase::QUICK);
+ AddTestCase (new DsrCacheEntryTest, TestCase::QUICK);
+ AddTestCase (new DsrSendBuffTest, TestCase::QUICK);
}
} g_dsrTestSuite;
} // namespace dsr
--- a/src/dsr/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/dsr/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -24,7 +24,7 @@
'test/dsr-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'dsr'
headers.source = [
'model/dsr-routing.h',
@@ -43,6 +43,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/emu/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/emu/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -36,7 +36,7 @@
'helper/emu-helper.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'emu'
headers.source = [
'model/emu-net-device.h',
@@ -52,6 +52,6 @@
module.env.append_value("DEFINES", "EMU_SOCK_CREATOR=\"%s\"" % (creator.target,))
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/energy/model/basic-energy-source.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/basic-energy-source.cc Fri Apr 05 17:59:11 2013 +0200
@@ -64,11 +64,13 @@
BasicEnergySource::BasicEnergySource ()
{
+ NS_LOG_FUNCTION (this);
m_lastUpdateTime = Seconds (0.0);
}
BasicEnergySource::~BasicEnergySource ()
{
+ NS_LOG_FUNCTION (this);
}
void
@@ -97,18 +99,21 @@
Time
BasicEnergySource::GetEnergyUpdateInterval (void) const
{
+ NS_LOG_FUNCTION (this);
return m_energyUpdateInterval;
}
double
BasicEnergySource::GetSupplyVoltage (void) const
{
+ NS_LOG_FUNCTION (this);
return m_supplyVoltageV;
}
double
BasicEnergySource::GetInitialEnergy (void) const
{
+ NS_LOG_FUNCTION (this);
return m_initialEnergyJ;
}
--- a/src/energy/model/device-energy-model-container.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/device-energy-model-container.cc Fri Apr 05 17:59:11 2013 +0200
@@ -22,21 +22,27 @@
#include "device-energy-model-container.h"
#include "ns3/names.h"
+#include "ns3/log.h"
+
+NS_LOG_COMPONENT_DEFINE ("DeviceEnergyModelContainer");
namespace ns3 {
DeviceEnergyModelContainer::DeviceEnergyModelContainer ()
{
+ NS_LOG_FUNCTION (this);
}
DeviceEnergyModelContainer::DeviceEnergyModelContainer (Ptr<DeviceEnergyModel> model)
{
+ NS_LOG_FUNCTION (this << model);
NS_ASSERT (model != NULL);
m_models.push_back (model);
}
DeviceEnergyModelContainer::DeviceEnergyModelContainer (std::string modelName)
{
+ NS_LOG_FUNCTION (this << modelName);
Ptr<DeviceEnergyModel> model = Names::Find<DeviceEnergyModel> (modelName);
NS_ASSERT (model != NULL);
m_models.push_back (model);
@@ -45,6 +51,7 @@
DeviceEnergyModelContainer::DeviceEnergyModelContainer (const DeviceEnergyModelContainer &a,
const DeviceEnergyModelContainer &b)
{
+ NS_LOG_FUNCTION (this << &a << &b);
*this = a;
Add (b);
}
@@ -52,30 +59,35 @@
DeviceEnergyModelContainer::Iterator
DeviceEnergyModelContainer::Begin (void) const
{
+ NS_LOG_FUNCTION (this);
return m_models.begin ();
}
DeviceEnergyModelContainer::Iterator
DeviceEnergyModelContainer::End (void) const
{
+ NS_LOG_FUNCTION (this);
return m_models.end ();
}
uint32_t
DeviceEnergyModelContainer::GetN (void) const
{
+ NS_LOG_FUNCTION (this);
return m_models.size ();
}
Ptr<DeviceEnergyModel>
DeviceEnergyModelContainer::Get (uint32_t i) const
{
+ NS_LOG_FUNCTION (this << i);
return m_models[i];
}
void
DeviceEnergyModelContainer::Add (DeviceEnergyModelContainer container)
{
+ NS_LOG_FUNCTION (this << &container);
for (Iterator i = container.Begin (); i != container.End (); i++)
{
m_models.push_back (*i);
@@ -85,6 +97,7 @@
void
DeviceEnergyModelContainer::Add (Ptr<DeviceEnergyModel> model)
{
+ NS_LOG_FUNCTION (this << model);
NS_ASSERT (model != NULL);
m_models.push_back (model);
}
@@ -92,6 +105,7 @@
void
DeviceEnergyModelContainer::Add (std::string modelName)
{
+ NS_LOG_FUNCTION (this << modelName);
Ptr<DeviceEnergyModel> model = Names::Find<DeviceEnergyModel> (modelName);
NS_ASSERT (model != NULL);
m_models.push_back (model);
@@ -100,6 +114,7 @@
void
DeviceEnergyModelContainer::Clear (void)
{
+ NS_LOG_FUNCTION (this);
m_models.clear ();
}
--- a/src/energy/model/device-energy-model.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/device-energy-model.cc Fri Apr 05 17:59:11 2013 +0200
@@ -19,6 +19,9 @@
*/
#include "device-energy-model.h"
+#include "ns3/log.h"
+
+NS_LOG_COMPONENT_DEFINE ("DeviceEnergyModel");
namespace ns3 {
@@ -35,15 +38,18 @@
DeviceEnergyModel::DeviceEnergyModel ()
{
+ NS_LOG_FUNCTION (this);
}
DeviceEnergyModel::~DeviceEnergyModel ()
{
+ NS_LOG_FUNCTION (this);
}
double
DeviceEnergyModel::GetCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return DoGetCurrentA ();
}
@@ -54,6 +60,7 @@
double
DeviceEnergyModel::DoGetCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return 0.0;
}
--- a/src/energy/model/energy-source.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/energy-source.cc Fri Apr 05 17:59:11 2013 +0200
@@ -38,15 +38,18 @@
EnergySource::EnergySource ()
{
+ NS_LOG_FUNCTION (this);
}
EnergySource::~EnergySource ()
{
+ NS_LOG_FUNCTION (this);
}
void
EnergySource::SetNode (Ptr<Node> node)
{
+ NS_LOG_FUNCTION (this);
NS_ASSERT (node != NULL);
m_node = node;
}
@@ -54,6 +57,7 @@
Ptr<Node>
EnergySource::GetNode (void) const
{
+ NS_LOG_FUNCTION (this);
return m_node;
}
@@ -100,6 +104,7 @@
void
EnergySource::StartDeviceModels (void)
{
+ NS_LOG_FUNCTION (this);
/*
* Device models are not aggregated to the node, hence we have to manually
* call dispose method here.
@@ -114,6 +119,7 @@
void
EnergySource::DisposeDeviceModels (void)
{
+ NS_LOG_FUNCTION (this);
/*
* Device models are not aggregated to the node, hence we have to manually
* call dispose method here.
--- a/src/energy/model/li-ion-energy-source.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/li-ion-energy-source.cc Fri Apr 05 17:59:11 2013 +0200
@@ -108,10 +108,12 @@
: m_drainedCapacity (0.0),
m_lastUpdateTime (Seconds (0.0))
{
+ NS_LOG_FUNCTION (this);
}
LiIonEnergySource::~LiIonEnergySource ()
{
+ NS_LOG_FUNCTION (this);
}
void
@@ -134,6 +136,7 @@
void
LiIonEnergySource::SetInitialSupplyVoltage (double supplyVoltageV)
{
+ NS_LOG_FUNCTION (this << supplyVoltageV);
m_eFull = supplyVoltageV;
m_supplyVoltageV = supplyVoltageV;
}
@@ -148,7 +151,7 @@
void
LiIonEnergySource::SetEnergyUpdateInterval (Time interval)
{
- NS_LOG_FUNCTION (this);
+ NS_LOG_FUNCTION (this << interval);
m_energyUpdateInterval = interval;
}
--- a/src/energy/model/rv-battery-model.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/rv-battery-model.cc Fri Apr 05 17:59:11 2013 +0200
@@ -86,6 +86,7 @@
RvBatteryModel::RvBatteryModel ()
{
+ NS_LOG_FUNCTION (this);
m_lastSampleTime = Seconds (0.0);
m_previousLoad = 0.0;
m_batteryLevel = 1; // fully charged
@@ -94,17 +95,20 @@
RvBatteryModel::~RvBatteryModel ()
{
+ NS_LOG_FUNCTION (this);
}
double
RvBatteryModel::GetInitialEnergy (void) const
{
+ NS_LOG_FUNCTION (this);
return m_alpha * GetSupplyVoltage ();
}
double
RvBatteryModel::GetSupplyVoltage (void) const
{
+ NS_LOG_FUNCTION (this);
// average of Voc and Vcutoff
return (m_openCircuitVoltage - m_cutoffVoltage) / 2 + m_cutoffVoltage;
}
@@ -120,6 +124,7 @@
double
RvBatteryModel::GetEnergyFraction (void)
{
+ NS_LOG_FUNCTION (this);
return GetBatteryLevel ();
}
@@ -184,6 +189,7 @@
Time
RvBatteryModel::GetSamplingInterval (void) const
{
+ NS_LOG_FUNCTION (this);
return m_samplingInterval;
}
@@ -198,6 +204,7 @@
double
RvBatteryModel::GetOpenCircuitVoltage (void) const
{
+ NS_LOG_FUNCTION (this);
return m_openCircuitVoltage;
}
@@ -212,6 +219,7 @@
double
RvBatteryModel::GetCutoffVoltage (void) const
{
+ NS_LOG_FUNCTION (this);
return m_cutoffVoltage;
}
@@ -226,6 +234,7 @@
double
RvBatteryModel::GetAlpha (void) const
{
+ NS_LOG_FUNCTION (this);
return m_alpha;
}
@@ -240,6 +249,7 @@
double
RvBatteryModel::GetBeta (void) const
{
+ NS_LOG_FUNCTION (this);
return m_beta;
}
@@ -254,6 +264,7 @@
Time
RvBatteryModel::GetLifetime (void) const
{
+ NS_LOG_FUNCTION (this);
return m_lifetime;
}
@@ -267,6 +278,7 @@
int
RvBatteryModel::GetNumOfTerms (void) const
{
+ NS_LOG_FUNCTION (this);
return m_numOfTerms;
}
@@ -277,6 +289,7 @@
void
RvBatteryModel::DoStart (void)
{
+ NS_LOG_FUNCTION (this);
NS_LOG_DEBUG ("RvBatteryModel:Starting battery level update!");
UpdateEnergySource (); // start periodic sampling of load (total current)
}
@@ -284,6 +297,7 @@
void
RvBatteryModel::DoDispose (void)
{
+ NS_LOG_FUNCTION (this);
BreakDeviceEnergyModelRefCycle (); // break reference cycle
}
--- a/src/energy/model/simple-device-energy-model.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/simple-device-energy-model.cc Fri Apr 05 17:59:11 2013 +0200
@@ -1,8 +1,30 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2010 Andrea Sacco
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Andrea Sacco <andrea.sacco85@gmail.com>
+ */
+
#include "ns3/simulator.h"
#include "ns3/trace-source-accessor.h"
#include "ns3/energy-source.h"
#include "simple-device-energy-model.h"
+#include "ns3/log.h"
+NS_LOG_COMPONENT_DEFINE ("SimpleDeviceEnergyModel");
namespace ns3 {
@@ -23,6 +45,7 @@
SimpleDeviceEnergyModel::SimpleDeviceEnergyModel ()
{
+ NS_LOG_FUNCTION (this);
m_lastUpdateTime = Seconds (0.0);
m_actualCurrentA = 0.0;
m_source = 0;
@@ -30,11 +53,13 @@
SimpleDeviceEnergyModel::~SimpleDeviceEnergyModel ()
{
+ NS_LOG_FUNCTION (this);
}
void
SimpleDeviceEnergyModel::SetEnergySource (Ptr<EnergySource> source)
{
+ NS_LOG_FUNCTION (this << source);
NS_ASSERT (source != NULL);
m_source = source;
}
@@ -42,6 +67,7 @@
void
SimpleDeviceEnergyModel::SetNode (Ptr<Node> node)
{
+ NS_LOG_FUNCTION (this << node);
NS_ASSERT (node != NULL);
m_node = node;
}
@@ -49,18 +75,21 @@
Ptr<Node>
SimpleDeviceEnergyModel::GetNode () const
{
+ NS_LOG_FUNCTION (this);
return m_node;
}
double
SimpleDeviceEnergyModel::GetTotalEnergyConsumption (void) const
{
+ NS_LOG_FUNCTION (this);
return m_totalEnergyConsumption;
}
void
SimpleDeviceEnergyModel::SetCurrentA (double current)
{
+ NS_LOG_FUNCTION (this << current);
Time duration = Simulator::Now () - m_lastUpdateTime;
double energyToDecrease = 0.0;
@@ -80,12 +109,14 @@
void
SimpleDeviceEnergyModel::DoDispose (void)
{
+ NS_LOG_FUNCTION (this);
m_source = 0;
}
double
SimpleDeviceEnergyModel::DoGetCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return m_actualCurrentA;
}
--- a/src/energy/model/simple-device-energy-model.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/simple-device-energy-model.h Fri Apr 05 17:59:11 2013 +0200
@@ -1,8 +1,21 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/*
- * simple-device-energy-model.h
+ * Copyright (c) 2010 Andrea Sacco
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
*
- * Created on: 09/ago/2010
- * Author: socket
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Andrea Sacco <andrea.sacco85@gmail.com>
*/
#ifndef SIMPLE_DEVICE_ENERGY_MODEL_H
--- a/src/energy/model/wifi-radio-energy-model.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/model/wifi-radio-energy-model.cc Fri Apr 05 17:59:11 2013 +0200
@@ -88,6 +88,7 @@
WifiRadioEnergyModel::~WifiRadioEnergyModel ()
{
+ NS_LOG_FUNCTION (this);
delete m_listener;
}
@@ -102,12 +103,14 @@
double
WifiRadioEnergyModel::GetTotalEnergyConsumption (void) const
{
+ NS_LOG_FUNCTION (this);
return m_totalEnergyConsumption;
}
double
WifiRadioEnergyModel::GetIdleCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return m_idleCurrentA;
}
@@ -121,6 +124,7 @@
double
WifiRadioEnergyModel::GetCcaBusyCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return m_ccaBusyCurrentA;
}
@@ -134,6 +138,7 @@
double
WifiRadioEnergyModel::GetTxCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return m_txCurrentA;
}
@@ -147,6 +152,7 @@
double
WifiRadioEnergyModel::GetRxCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return m_rxCurrentA;
}
@@ -160,6 +166,7 @@
double
WifiRadioEnergyModel::GetSwitchingCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
return m_switchingCurrentA;
}
@@ -174,6 +181,7 @@
WifiPhy::State
WifiRadioEnergyModel::GetCurrentState (void) const
{
+ NS_LOG_FUNCTION (this);
return m_currentState;
}
@@ -241,6 +249,7 @@
void
WifiRadioEnergyModel::HandleEnergyDepletion (void)
{
+ NS_LOG_FUNCTION (this);
NS_LOG_DEBUG ("WifiRadioEnergyModel:Energy is depleted!");
// invoke energy depletion callback, if set.
if (!m_energyDepletionCallback.IsNull ())
@@ -252,6 +261,7 @@
WifiRadioEnergyModelPhyListener *
WifiRadioEnergyModel::GetPhyListener (void)
{
+ NS_LOG_FUNCTION (this);
return m_listener;
}
@@ -262,6 +272,7 @@
void
WifiRadioEnergyModel::DoDispose (void)
{
+ NS_LOG_FUNCTION (this);
m_source = NULL;
m_energyDepletionCallback.Nullify ();
}
@@ -269,6 +280,7 @@
double
WifiRadioEnergyModel::DoGetCurrentA (void) const
{
+ NS_LOG_FUNCTION (this);
switch (m_currentState)
{
case WifiPhy::IDLE:
@@ -318,16 +330,19 @@
WifiRadioEnergyModelPhyListener::WifiRadioEnergyModelPhyListener ()
{
+ NS_LOG_FUNCTION (this);
m_changeStateCallback.Nullify ();
}
WifiRadioEnergyModelPhyListener::~WifiRadioEnergyModelPhyListener ()
{
+ NS_LOG_FUNCTION (this);
}
void
WifiRadioEnergyModelPhyListener::SetChangeStateCallback (DeviceEnergyModel::ChangeStateCallback callback)
{
+ NS_LOG_FUNCTION (this << &callback);
NS_ASSERT (!callback.IsNull ());
m_changeStateCallback = callback;
}
@@ -335,6 +350,7 @@
void
WifiRadioEnergyModelPhyListener::NotifyRxStart (Time duration)
{
+ NS_LOG_FUNCTION (this << duration);
if (m_changeStateCallback.IsNull ())
{
NS_FATAL_ERROR ("WifiRadioEnergyModelPhyListener:Change state callback not set!");
@@ -346,6 +362,7 @@
void
WifiRadioEnergyModelPhyListener::NotifyRxEndOk (void)
{
+ NS_LOG_FUNCTION (this);
if (m_changeStateCallback.IsNull ())
{
NS_FATAL_ERROR ("WifiRadioEnergyModelPhyListener:Change state callback not set!");
@@ -356,6 +373,7 @@
void
WifiRadioEnergyModelPhyListener::NotifyRxEndError (void)
{
+ NS_LOG_FUNCTION (this);
if (m_changeStateCallback.IsNull ())
{
NS_FATAL_ERROR ("WifiRadioEnergyModelPhyListener:Change state callback not set!");
@@ -366,6 +384,7 @@
void
WifiRadioEnergyModelPhyListener::NotifyTxStart (Time duration)
{
+ NS_LOG_FUNCTION (this << duration);
if (m_changeStateCallback.IsNull ())
{
NS_FATAL_ERROR ("WifiRadioEnergyModelPhyListener:Change state callback not set!");
@@ -379,6 +398,7 @@
void
WifiRadioEnergyModelPhyListener::NotifyMaybeCcaBusyStart (Time duration)
{
+ NS_LOG_FUNCTION (this << duration);
if (m_changeStateCallback.IsNull ())
{
NS_FATAL_ERROR ("WifiRadioEnergyModelPhyListener:Change state callback not set!");
@@ -392,6 +412,7 @@
void
WifiRadioEnergyModelPhyListener::NotifySwitchingStart (Time duration)
{
+ NS_LOG_FUNCTION (this << duration);
if (m_changeStateCallback.IsNull ())
{
NS_FATAL_ERROR ("WifiRadioEnergyModelPhyListener:Change state callback not set!");
@@ -409,6 +430,7 @@
void
WifiRadioEnergyModelPhyListener::SwitchToIdle (void)
{
+ NS_LOG_FUNCTION (this);
if (m_changeStateCallback.IsNull ())
{
NS_FATAL_ERROR ("WifiRadioEnergyModelPhyListener:Change state callback not set!");
--- a/src/energy/test/basic-energy-model-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/test/basic-energy-model-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -380,8 +380,8 @@
BasicEnergyModelTestSuite::BasicEnergyModelTestSuite ()
: TestSuite ("basic-energy-model", UNIT)
{
- AddTestCase (new BasicEnergyUpdateTest);
- AddTestCase (new BasicEnergyDepletionTest);
+ AddTestCase (new BasicEnergyUpdateTest, TestCase::QUICK);
+ AddTestCase (new BasicEnergyDepletionTest, TestCase::QUICK);
}
// create an instance of the test suite
--- a/src/energy/test/li-ion-energy-source-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/test/li-ion-energy-source-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -87,7 +87,7 @@
LiIonEnergySourceTestSuite::LiIonEnergySourceTestSuite ()
: TestSuite ("li-ion-energy-source", UNIT)
{
- AddTestCase (new LiIonEnergyTestCase);
+ AddTestCase (new LiIonEnergyTestCase, TestCase::QUICK);
}
// create an instance of the test suite
--- a/src/energy/test/rv-battery-model-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/test/rv-battery-model-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -883,7 +883,7 @@
RvBatteryModelTestSuite::RvBatteryModelTestSuite ()
: TestSuite ("rv-battery-model", SYSTEM)
{
- AddTestCase (new BatteryLifetimeTest);
+ AddTestCase (new BatteryLifetimeTest, TestCase::QUICK);
}
// create an instance of the test suite
--- a/src/energy/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/energy/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -25,7 +25,7 @@
'test/li-ion-energy-source-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'energy'
headers.source = [
'model/wifi-radio-energy-model.h',
@@ -44,6 +44,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/bindings/callbacks_list.py Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,7 @@
+callback_classes = [
+ ['bool', 'ns3::Ptr<ns3::NetDevice>', 'ns3::Ptr<ns3::Packet const>', 'unsigned short', 'ns3::Address const&', 'ns3::Address const&', 'ns3::NetDevice::PacketType', 'ns3::empty', 'ns3::empty', 'ns3::empty'],
+ ['bool', 'ns3::Ptr<ns3::NetDevice>', 'ns3::Ptr<ns3::Packet const>', 'unsigned short', 'ns3::Address const&', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'],
+ ['void', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'],
+ ['void', 'unsigned char*', 'long', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'],
+ ['void', 'ns3::Ptr<ns3::NetDevice>', 'ns3::Ptr<ns3::Packet const>', 'unsigned short', 'ns3::Address const&', 'ns3::Address const&', 'ns3::NetDevice::PacketType', 'ns3::empty', 'ns3::empty', 'ns3::empty'],
+]
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/bindings/modulegen__gcc_ILP32.py Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,4574 @@
+from pybindgen import Module, FileCodeSink, param, retval, cppclass, typehandlers
+
+
+import pybindgen.settings
+import warnings
+
+class ErrorHandler(pybindgen.settings.ErrorHandler):
+ def handle_error(self, wrapper, exception, traceback_):
+ warnings.warn("exception %r in wrapper %s" % (exception, wrapper))
+ return True
+pybindgen.settings.error_handler = ErrorHandler()
+
+
+import sys
+
+def module_init():
+ root_module = Module('ns.fd_net_device', cpp_namespace='::ns3')
+ return root_module
+
+def register_types(module):
+ root_module = module.get_root()
+
+ ## address.h (module 'network'): ns3::Address [class]
+ module.add_class('Address', import_from_module='ns.network')
+ ## address.h (module 'network'): ns3::Address::MaxSize_e [enumeration]
+ module.add_enum('MaxSize_e', ['MAX_SIZE'], outer_class=root_module['ns3::Address'], import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelper [class]
+ module.add_class('AsciiTraceHelper', import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelperForDevice [class]
+ module.add_class('AsciiTraceHelperForDevice', allow_subclassing=True, import_from_module='ns.network')
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList [class]
+ module.add_class('AttributeConstructionList', import_from_module='ns.core')
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item [struct]
+ module.add_class('Item', import_from_module='ns.core', outer_class=root_module['ns3::AttributeConstructionList'])
+ ## buffer.h (module 'network'): ns3::Buffer [class]
+ module.add_class('Buffer', import_from_module='ns.network')
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator [class]
+ module.add_class('Iterator', import_from_module='ns.network', outer_class=root_module['ns3::Buffer'])
+ ## packet.h (module 'network'): ns3::ByteTagIterator [class]
+ module.add_class('ByteTagIterator', import_from_module='ns.network')
+ ## packet.h (module 'network'): ns3::ByteTagIterator::Item [class]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagIterator'])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList [class]
+ module.add_class('ByteTagList', import_from_module='ns.network')
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator [class]
+ module.add_class('Iterator', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagList'])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item [struct]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagList::Iterator'])
+ ## callback.h (module 'core'): ns3::CallbackBase [class]
+ module.add_class('CallbackBase', import_from_module='ns.core')
+ ## system-mutex.h (module 'core'): ns3::CriticalSection [class]
+ module.add_class('CriticalSection', import_from_module='ns.core')
+ ## data-rate.h (module 'network'): ns3::DataRate [class]
+ module.add_class('DataRate', import_from_module='ns.network')
+ ## event-id.h (module 'core'): ns3::EventId [class]
+ module.add_class('EventId', import_from_module='ns.core')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address [class]
+ module.add_class('Ipv4Address', import_from_module='ns.network')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address [class]
+ root_module['ns3::Ipv4Address'].implicitly_converts_to(root_module['ns3::Address'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask [class]
+ module.add_class('Ipv4Mask', import_from_module='ns.network')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address [class]
+ module.add_class('Ipv6Address', import_from_module='ns.network')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address [class]
+ root_module['ns3::Ipv6Address'].implicitly_converts_to(root_module['ns3::Address'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix [class]
+ module.add_class('Ipv6Prefix', import_from_module='ns.network')
+ ## mac48-address.h (module 'network'): ns3::Mac48Address [class]
+ module.add_class('Mac48Address', import_from_module='ns.network')
+ ## mac48-address.h (module 'network'): ns3::Mac48Address [class]
+ root_module['ns3::Mac48Address'].implicitly_converts_to(root_module['ns3::Address'])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer [class]
+ module.add_class('NetDeviceContainer', import_from_module='ns.network')
+ ## node-container.h (module 'network'): ns3::NodeContainer [class]
+ module.add_class('NodeContainer', import_from_module='ns.network')
+ ## object-base.h (module 'core'): ns3::ObjectBase [class]
+ module.add_class('ObjectBase', allow_subclassing=True, import_from_module='ns.core')
+ ## object.h (module 'core'): ns3::ObjectDeleter [struct]
+ module.add_class('ObjectDeleter', import_from_module='ns.core')
+ ## object-factory.h (module 'core'): ns3::ObjectFactory [class]
+ module.add_class('ObjectFactory', import_from_module='ns.core')
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata [class]
+ module.add_class('PacketMetadata', import_from_module='ns.network')
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item [struct]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::PacketMetadata'])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item [enumeration]
+ module.add_enum('', ['PAYLOAD', 'HEADER', 'TRAILER'], outer_class=root_module['ns3::PacketMetadata::Item'], import_from_module='ns.network')
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator [class]
+ module.add_class('ItemIterator', import_from_module='ns.network', outer_class=root_module['ns3::PacketMetadata'])
+ ## packet.h (module 'network'): ns3::PacketTagIterator [class]
+ module.add_class('PacketTagIterator', import_from_module='ns.network')
+ ## packet.h (module 'network'): ns3::PacketTagIterator::Item [class]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::PacketTagIterator'])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList [class]
+ module.add_class('PacketTagList', import_from_module='ns.network')
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData [struct]
+ module.add_class('TagData', import_from_module='ns.network', outer_class=root_module['ns3::PacketTagList'])
+ ## pcap-file.h (module 'network'): ns3::PcapFile [class]
+ module.add_class('PcapFile', import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::PcapHelper [class]
+ module.add_class('PcapHelper', import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::PcapHelper [enumeration]
+ module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO'], outer_class=root_module['ns3::PcapHelper'], import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::PcapHelperForDevice [class]
+ module.add_class('PcapHelperForDevice', allow_subclassing=True, import_from_module='ns.network')
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter> [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Object', 'ns3::ObjectBase', 'ns3::ObjectDeleter'], parent=root_module['ns3::ObjectBase'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simulator.h (module 'core'): ns3::Simulator [class]
+ module.add_class('Simulator', destructor_visibility='private', import_from_module='ns.core')
+ ## system-condition.h (module 'core'): ns3::SystemCondition [class]
+ module.add_class('SystemCondition', import_from_module='ns.core')
+ ## system-mutex.h (module 'core'): ns3::SystemMutex [class]
+ module.add_class('SystemMutex', import_from_module='ns.core')
+ ## tag.h (module 'network'): ns3::Tag [class]
+ module.add_class('Tag', import_from_module='ns.network', parent=root_module['ns3::ObjectBase'])
+ ## tag-buffer.h (module 'network'): ns3::TagBuffer [class]
+ module.add_class('TagBuffer', import_from_module='ns.network')
+ ## type-id.h (module 'core'): ns3::TypeId [class]
+ module.add_class('TypeId', import_from_module='ns.core')
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeFlag [enumeration]
+ module.add_enum('AttributeFlag', ['ATTR_GET', 'ATTR_SET', 'ATTR_CONSTRUCT', 'ATTR_SGC'], outer_class=root_module['ns3::TypeId'], import_from_module='ns.core')
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation [struct]
+ module.add_class('AttributeInformation', import_from_module='ns.core', outer_class=root_module['ns3::TypeId'])
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation [struct]
+ module.add_class('TraceSourceInformation', import_from_module='ns.core', outer_class=root_module['ns3::TypeId'])
+ ## empty.h (module 'core'): ns3::empty [class]
+ module.add_class('empty', import_from_module='ns.core')
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t [class]
+ module.add_class('int64x64_t', import_from_module='ns.core')
+ ## chunk.h (module 'network'): ns3::Chunk [class]
+ module.add_class('Chunk', import_from_module='ns.network', parent=root_module['ns3::ObjectBase'])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::FdNetDeviceHelper [class]
+ module.add_class('FdNetDeviceHelper', parent=[root_module['ns3::PcapHelperForDevice'], root_module['ns3::AsciiTraceHelperForDevice']])
+ ## header.h (module 'network'): ns3::Header [class]
+ module.add_class('Header', import_from_module='ns.network', parent=root_module['ns3::Chunk'])
+ ## object.h (module 'core'): ns3::Object [class]
+ module.add_class('Object', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >'])
+ ## object.h (module 'core'): ns3::Object::AggregateIterator [class]
+ module.add_class('AggregateIterator', import_from_module='ns.core', outer_class=root_module['ns3::Object'])
+ ## pcap-file-wrapper.h (module 'network'): ns3::PcapFileWrapper [class]
+ module.add_class('PcapFileWrapper', import_from_module='ns.network', parent=root_module['ns3::Object'])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeAccessor', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeAccessor>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeChecker', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeChecker>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeValue', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeValue>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::CallbackImplBase', 'ns3::empty', 'ns3::DefaultDeleter<ns3::CallbackImplBase>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::EventImpl', 'ns3::empty', 'ns3::DefaultDeleter<ns3::EventImpl>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::FdReader', 'ns3::empty', 'ns3::DefaultDeleter<ns3::FdReader>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::NixVector', 'ns3::empty', 'ns3::DefaultDeleter<ns3::NixVector>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::OutputStreamWrapper', 'ns3::empty', 'ns3::DefaultDeleter<ns3::OutputStreamWrapper>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Packet', 'ns3::empty', 'ns3::DefaultDeleter<ns3::Packet>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::SystemThread', 'ns3::empty', 'ns3::DefaultDeleter<ns3::SystemThread>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::TraceSourceAccessor', 'ns3::empty', 'ns3::DefaultDeleter<ns3::TraceSourceAccessor>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## system-thread.h (module 'core'): ns3::SystemThread [class]
+ module.add_class('SystemThread', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >'])
+ ## nstime.h (module 'core'): ns3::Time [class]
+ module.add_class('Time', import_from_module='ns.core')
+ ## nstime.h (module 'core'): ns3::Time::Unit [enumeration]
+ module.add_enum('Unit', ['S', 'MS', 'US', 'NS', 'PS', 'FS', 'LAST'], outer_class=root_module['ns3::Time'], import_from_module='ns.core')
+ ## nstime.h (module 'core'): ns3::Time [class]
+ root_module['ns3::Time'].implicitly_converts_to(root_module['ns3::int64x64_t'])
+ ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor [class]
+ module.add_class('TraceSourceAccessor', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >'])
+ ## trailer.h (module 'network'): ns3::Trailer [class]
+ module.add_class('Trailer', import_from_module='ns.network', parent=root_module['ns3::Chunk'])
+ ## attribute.h (module 'core'): ns3::AttributeAccessor [class]
+ module.add_class('AttributeAccessor', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >'])
+ ## attribute.h (module 'core'): ns3::AttributeChecker [class]
+ module.add_class('AttributeChecker', allow_subclassing=False, automatic_type_narrowing=True, import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >'])
+ ## attribute.h (module 'core'): ns3::AttributeValue [class]
+ module.add_class('AttributeValue', allow_subclassing=False, automatic_type_narrowing=True, import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >'])
+ ## callback.h (module 'core'): ns3::CallbackChecker [class]
+ module.add_class('CallbackChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## callback.h (module 'core'): ns3::CallbackImplBase [class]
+ module.add_class('CallbackImplBase', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >'])
+ ## callback.h (module 'core'): ns3::CallbackValue [class]
+ module.add_class('CallbackValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## data-rate.h (module 'network'): ns3::DataRateChecker [class]
+ module.add_class('DataRateChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## data-rate.h (module 'network'): ns3::DataRateValue [class]
+ module.add_class('DataRateValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## attribute.h (module 'core'): ns3::EmptyAttributeValue [class]
+ module.add_class('EmptyAttributeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::EmuFdNetDeviceHelper [class]
+ module.add_class('EmuFdNetDeviceHelper', parent=root_module['ns3::FdNetDeviceHelper'])
+ ## event-impl.h (module 'core'): ns3::EventImpl [class]
+ module.add_class('EventImpl', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >'])
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader [class]
+ module.add_class('FdReader', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class]
+ module.add_class('Ipv4AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue [class]
+ module.add_class('Ipv4AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker [class]
+ module.add_class('Ipv4MaskChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue [class]
+ module.add_class('Ipv4MaskValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker [class]
+ module.add_class('Ipv6AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue [class]
+ module.add_class('Ipv6AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker [class]
+ module.add_class('Ipv6PrefixChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue [class]
+ module.add_class('Ipv6PrefixValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker [class]
+ module.add_class('Mac48AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue [class]
+ module.add_class('Mac48AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## net-device.h (module 'network'): ns3::NetDevice [class]
+ module.add_class('NetDevice', import_from_module='ns.network', parent=root_module['ns3::Object'])
+ ## net-device.h (module 'network'): ns3::NetDevice::PacketType [enumeration]
+ module.add_enum('PacketType', ['PACKET_HOST', 'NS3_PACKET_HOST', 'PACKET_BROADCAST', 'NS3_PACKET_BROADCAST', 'PACKET_MULTICAST', 'NS3_PACKET_MULTICAST', 'PACKET_OTHERHOST', 'NS3_PACKET_OTHERHOST'], outer_class=root_module['ns3::NetDevice'], import_from_module='ns.network')
+ ## nix-vector.h (module 'network'): ns3::NixVector [class]
+ module.add_class('NixVector', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >'])
+ ## node.h (module 'network'): ns3::Node [class]
+ module.add_class('Node', import_from_module='ns.network', parent=root_module['ns3::Object'])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker [class]
+ module.add_class('ObjectFactoryChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue [class]
+ module.add_class('ObjectFactoryValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper [class]
+ module.add_class('OutputStreamWrapper', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >'])
+ ## packet.h (module 'network'): ns3::Packet [class]
+ module.add_class('Packet', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >'])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::PlanetLabFdNetDeviceHelper [class]
+ module.add_class('PlanetLabFdNetDeviceHelper', parent=root_module['ns3::EmuFdNetDeviceHelper'])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::TapFdNetDeviceHelper [class]
+ module.add_class('TapFdNetDeviceHelper', parent=root_module['ns3::EmuFdNetDeviceHelper'])
+ ## nstime.h (module 'core'): ns3::TimeChecker [class]
+ module.add_class('TimeChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## nstime.h (module 'core'): ns3::TimeValue [class]
+ module.add_class('TimeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## type-id.h (module 'core'): ns3::TypeIdChecker [class]
+ module.add_class('TypeIdChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## type-id.h (module 'core'): ns3::TypeIdValue [class]
+ module.add_class('TypeIdValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## address.h (module 'network'): ns3::AddressChecker [class]
+ module.add_class('AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## address.h (module 'network'): ns3::AddressValue [class]
+ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice [class]
+ module.add_class('FdNetDevice', parent=root_module['ns3::NetDevice'])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice::EncapsulationMode [enumeration]
+ module.add_enum('EncapsulationMode', ['DIX', 'LLC', 'DIXPI'], outer_class=root_module['ns3::FdNetDevice'])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDeviceFdReader [class]
+ module.add_class('FdNetDeviceFdReader', parent=root_module['ns3::FdReader'])
+
+ ## Register a nested module for the namespace FatalImpl
+
+ nested_module = module.add_cpp_namespace('FatalImpl')
+ register_types_ns3_FatalImpl(nested_module)
+
+
+def register_types_ns3_FatalImpl(module):
+ root_module = module.get_root()
+
+
+def register_methods(root_module):
+ register_Ns3Address_methods(root_module, root_module['ns3::Address'])
+ register_Ns3AsciiTraceHelper_methods(root_module, root_module['ns3::AsciiTraceHelper'])
+ register_Ns3AsciiTraceHelperForDevice_methods(root_module, root_module['ns3::AsciiTraceHelperForDevice'])
+ register_Ns3AttributeConstructionList_methods(root_module, root_module['ns3::AttributeConstructionList'])
+ register_Ns3AttributeConstructionListItem_methods(root_module, root_module['ns3::AttributeConstructionList::Item'])
+ register_Ns3Buffer_methods(root_module, root_module['ns3::Buffer'])
+ register_Ns3BufferIterator_methods(root_module, root_module['ns3::Buffer::Iterator'])
+ register_Ns3ByteTagIterator_methods(root_module, root_module['ns3::ByteTagIterator'])
+ register_Ns3ByteTagIteratorItem_methods(root_module, root_module['ns3::ByteTagIterator::Item'])
+ register_Ns3ByteTagList_methods(root_module, root_module['ns3::ByteTagList'])
+ register_Ns3ByteTagListIterator_methods(root_module, root_module['ns3::ByteTagList::Iterator'])
+ register_Ns3ByteTagListIteratorItem_methods(root_module, root_module['ns3::ByteTagList::Iterator::Item'])
+ register_Ns3CallbackBase_methods(root_module, root_module['ns3::CallbackBase'])
+ register_Ns3CriticalSection_methods(root_module, root_module['ns3::CriticalSection'])
+ register_Ns3DataRate_methods(root_module, root_module['ns3::DataRate'])
+ register_Ns3EventId_methods(root_module, root_module['ns3::EventId'])
+ register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address'])
+ register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask'])
+ register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address'])
+ register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix'])
+ register_Ns3Mac48Address_methods(root_module, root_module['ns3::Mac48Address'])
+ register_Ns3NetDeviceContainer_methods(root_module, root_module['ns3::NetDeviceContainer'])
+ register_Ns3NodeContainer_methods(root_module, root_module['ns3::NodeContainer'])
+ register_Ns3ObjectBase_methods(root_module, root_module['ns3::ObjectBase'])
+ register_Ns3ObjectDeleter_methods(root_module, root_module['ns3::ObjectDeleter'])
+ register_Ns3ObjectFactory_methods(root_module, root_module['ns3::ObjectFactory'])
+ register_Ns3PacketMetadata_methods(root_module, root_module['ns3::PacketMetadata'])
+ register_Ns3PacketMetadataItem_methods(root_module, root_module['ns3::PacketMetadata::Item'])
+ register_Ns3PacketMetadataItemIterator_methods(root_module, root_module['ns3::PacketMetadata::ItemIterator'])
+ register_Ns3PacketTagIterator_methods(root_module, root_module['ns3::PacketTagIterator'])
+ register_Ns3PacketTagIteratorItem_methods(root_module, root_module['ns3::PacketTagIterator::Item'])
+ register_Ns3PacketTagList_methods(root_module, root_module['ns3::PacketTagList'])
+ register_Ns3PacketTagListTagData_methods(root_module, root_module['ns3::PacketTagList::TagData'])
+ register_Ns3PcapFile_methods(root_module, root_module['ns3::PcapFile'])
+ register_Ns3PcapHelper_methods(root_module, root_module['ns3::PcapHelper'])
+ register_Ns3PcapHelperForDevice_methods(root_module, root_module['ns3::PcapHelperForDevice'])
+ register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >'])
+ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator'])
+ register_Ns3SystemCondition_methods(root_module, root_module['ns3::SystemCondition'])
+ register_Ns3SystemMutex_methods(root_module, root_module['ns3::SystemMutex'])
+ register_Ns3Tag_methods(root_module, root_module['ns3::Tag'])
+ register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer'])
+ register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId'])
+ register_Ns3TypeIdAttributeInformation_methods(root_module, root_module['ns3::TypeId::AttributeInformation'])
+ register_Ns3TypeIdTraceSourceInformation_methods(root_module, root_module['ns3::TypeId::TraceSourceInformation'])
+ register_Ns3Empty_methods(root_module, root_module['ns3::empty'])
+ register_Ns3Int64x64_t_methods(root_module, root_module['ns3::int64x64_t'])
+ register_Ns3Chunk_methods(root_module, root_module['ns3::Chunk'])
+ register_Ns3FdNetDeviceHelper_methods(root_module, root_module['ns3::FdNetDeviceHelper'])
+ register_Ns3Header_methods(root_module, root_module['ns3::Header'])
+ register_Ns3Object_methods(root_module, root_module['ns3::Object'])
+ register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator'])
+ register_Ns3PcapFileWrapper_methods(root_module, root_module['ns3::PcapFileWrapper'])
+ register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >'])
+ register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >'])
+ register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >'])
+ register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >'])
+ register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >'])
+ register_Ns3SimpleRefCount__Ns3FdReader_Ns3Empty_Ns3DefaultDeleter__lt__ns3FdReader__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >'])
+ register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >'])
+ register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >'])
+ register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >'])
+ register_Ns3SimpleRefCount__Ns3SystemThread_Ns3Empty_Ns3DefaultDeleter__lt__ns3SystemThread__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >'])
+ register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >'])
+ register_Ns3SystemThread_methods(root_module, root_module['ns3::SystemThread'])
+ register_Ns3Time_methods(root_module, root_module['ns3::Time'])
+ register_Ns3TraceSourceAccessor_methods(root_module, root_module['ns3::TraceSourceAccessor'])
+ register_Ns3Trailer_methods(root_module, root_module['ns3::Trailer'])
+ register_Ns3AttributeAccessor_methods(root_module, root_module['ns3::AttributeAccessor'])
+ register_Ns3AttributeChecker_methods(root_module, root_module['ns3::AttributeChecker'])
+ register_Ns3AttributeValue_methods(root_module, root_module['ns3::AttributeValue'])
+ register_Ns3CallbackChecker_methods(root_module, root_module['ns3::CallbackChecker'])
+ register_Ns3CallbackImplBase_methods(root_module, root_module['ns3::CallbackImplBase'])
+ register_Ns3CallbackValue_methods(root_module, root_module['ns3::CallbackValue'])
+ register_Ns3DataRateChecker_methods(root_module, root_module['ns3::DataRateChecker'])
+ register_Ns3DataRateValue_methods(root_module, root_module['ns3::DataRateValue'])
+ register_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue'])
+ register_Ns3EmuFdNetDeviceHelper_methods(root_module, root_module['ns3::EmuFdNetDeviceHelper'])
+ register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl'])
+ register_Ns3FdReader_methods(root_module, root_module['ns3::FdReader'])
+ register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker'])
+ register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue'])
+ register_Ns3Ipv4MaskChecker_methods(root_module, root_module['ns3::Ipv4MaskChecker'])
+ register_Ns3Ipv4MaskValue_methods(root_module, root_module['ns3::Ipv4MaskValue'])
+ register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker'])
+ register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue'])
+ register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker'])
+ register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue'])
+ register_Ns3Mac48AddressChecker_methods(root_module, root_module['ns3::Mac48AddressChecker'])
+ register_Ns3Mac48AddressValue_methods(root_module, root_module['ns3::Mac48AddressValue'])
+ register_Ns3NetDevice_methods(root_module, root_module['ns3::NetDevice'])
+ register_Ns3NixVector_methods(root_module, root_module['ns3::NixVector'])
+ register_Ns3Node_methods(root_module, root_module['ns3::Node'])
+ register_Ns3ObjectFactoryChecker_methods(root_module, root_module['ns3::ObjectFactoryChecker'])
+ register_Ns3ObjectFactoryValue_methods(root_module, root_module['ns3::ObjectFactoryValue'])
+ register_Ns3OutputStreamWrapper_methods(root_module, root_module['ns3::OutputStreamWrapper'])
+ register_Ns3Packet_methods(root_module, root_module['ns3::Packet'])
+ register_Ns3PlanetLabFdNetDeviceHelper_methods(root_module, root_module['ns3::PlanetLabFdNetDeviceHelper'])
+ register_Ns3TapFdNetDeviceHelper_methods(root_module, root_module['ns3::TapFdNetDeviceHelper'])
+ register_Ns3TimeChecker_methods(root_module, root_module['ns3::TimeChecker'])
+ register_Ns3TimeValue_methods(root_module, root_module['ns3::TimeValue'])
+ register_Ns3TypeIdChecker_methods(root_module, root_module['ns3::TypeIdChecker'])
+ register_Ns3TypeIdValue_methods(root_module, root_module['ns3::TypeIdValue'])
+ register_Ns3AddressChecker_methods(root_module, root_module['ns3::AddressChecker'])
+ register_Ns3AddressValue_methods(root_module, root_module['ns3::AddressValue'])
+ register_Ns3FdNetDevice_methods(root_module, root_module['ns3::FdNetDevice'])
+ register_Ns3FdNetDeviceFdReader_methods(root_module, root_module['ns3::FdNetDeviceFdReader'])
+ return
+
+def register_Ns3Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## address.h (module 'network'): ns3::Address::Address() [constructor]
+ cls.add_constructor([])
+ ## address.h (module 'network'): ns3::Address::Address(uint8_t type, uint8_t const * buffer, uint8_t len) [constructor]
+ cls.add_constructor([param('uint8_t', 'type'), param('uint8_t const *', 'buffer'), param('uint8_t', 'len')])
+ ## address.h (module 'network'): ns3::Address::Address(ns3::Address const & address) [copy constructor]
+ cls.add_constructor([param('ns3::Address const &', 'address')])
+ ## address.h (module 'network'): bool ns3::Address::CheckCompatible(uint8_t type, uint8_t len) const [member function]
+ cls.add_method('CheckCompatible',
+ 'bool',
+ [param('uint8_t', 'type'), param('uint8_t', 'len')],
+ is_const=True)
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyAllFrom(uint8_t const * buffer, uint8_t len) [member function]
+ cls.add_method('CopyAllFrom',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint8_t', 'len')])
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyAllTo(uint8_t * buffer, uint8_t len) const [member function]
+ cls.add_method('CopyAllTo',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint8_t', 'len')],
+ is_const=True)
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyFrom(uint8_t const * buffer, uint8_t len) [member function]
+ cls.add_method('CopyFrom',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint8_t', 'len')])
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyTo(uint8_t * buffer) const [member function]
+ cls.add_method('CopyTo',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer')],
+ is_const=True)
+ ## address.h (module 'network'): void ns3::Address::Deserialize(ns3::TagBuffer buffer) [member function]
+ cls.add_method('Deserialize',
+ 'void',
+ [param('ns3::TagBuffer', 'buffer')])
+ ## address.h (module 'network'): uint8_t ns3::Address::GetLength() const [member function]
+ cls.add_method('GetLength',
+ 'uint8_t',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): uint32_t ns3::Address::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): bool ns3::Address::IsInvalid() const [member function]
+ cls.add_method('IsInvalid',
+ 'bool',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): bool ns3::Address::IsMatchingType(uint8_t type) const [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('uint8_t', 'type')],
+ is_const=True)
+ ## address.h (module 'network'): static uint8_t ns3::Address::Register() [member function]
+ cls.add_method('Register',
+ 'uint8_t',
+ [],
+ is_static=True)
+ ## address.h (module 'network'): void ns3::Address::Serialize(ns3::TagBuffer buffer) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::TagBuffer', 'buffer')],
+ is_const=True)
+ return
+
+def register_Ns3AsciiTraceHelper_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelper::AsciiTraceHelper(ns3::AsciiTraceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AsciiTraceHelper const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelper::AsciiTraceHelper() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): ns3::Ptr<ns3::OutputStreamWrapper> ns3::AsciiTraceHelper::CreateFileStream(std::string filename, std::_Ios_Openmode filemode=std::ios_base::out) [member function]
+ cls.add_method('CreateFileStream',
+ 'ns3::Ptr< ns3::OutputStreamWrapper >',
+ [param('std::string', 'filename'), param('std::_Ios_Openmode', 'filemode', default_value='std::ios_base::out')])
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDequeueSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDequeueSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDequeueSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDequeueSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDropSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDropSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDropSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDropSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultEnqueueSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultEnqueueSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultEnqueueSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultEnqueueSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultReceiveSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultReceiveSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultReceiveSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultReceiveSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): std::string ns3::AsciiTraceHelper::GetFilenameFromDevice(std::string prefix, ns3::Ptr<ns3::NetDevice> device, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromDevice',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'device'), param('bool', 'useObjectNames', default_value='true')])
+ ## trace-helper.h (module 'network'): std::string ns3::AsciiTraceHelper::GetFilenameFromInterfacePair(std::string prefix, ns3::Ptr<ns3::Object> object, uint32_t interface, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromInterfacePair',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::Object >', 'object'), param('uint32_t', 'interface'), param('bool', 'useObjectNames', default_value='true')])
+ return
+
+def register_Ns3AsciiTraceHelperForDevice_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelperForDevice::AsciiTraceHelperForDevice(ns3::AsciiTraceHelperForDevice const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AsciiTraceHelperForDevice const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelperForDevice::AsciiTraceHelperForDevice() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool explicitFilename=false) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Ptr<ns3::NetDevice> nd) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Ptr< ns3::NetDevice >', 'nd')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, std::string ndName, bool explicitFilename=false) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('std::string', 'ndName'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, std::string ndName) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('std::string', 'ndName')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, ns3::NetDeviceContainer d) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NetDeviceContainer', 'd')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::NetDeviceContainer d) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::NetDeviceContainer', 'd')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, ns3::NodeContainer n) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NodeContainer', 'n')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::NodeContainer n) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::NodeContainer', 'n')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, uint32_t nodeid, uint32_t deviceid, bool explicitFilename) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('uint32_t', 'nodeid'), param('uint32_t', 'deviceid'), param('bool', 'explicitFilename')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, uint32_t nodeid, uint32_t deviceid) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('uint32_t', 'nodeid'), param('uint32_t', 'deviceid')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAsciiAll(std::string prefix) [member function]
+ cls.add_method('EnableAsciiAll',
+ 'void',
+ [param('std::string', 'prefix')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAsciiAll(ns3::Ptr<ns3::OutputStreamWrapper> stream) [member function]
+ cls.add_method('EnableAsciiAll',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAsciiInternal(ns3::Ptr<ns3::OutputStreamWrapper> stream, std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool explicitFilename) [member function]
+ cls.add_method('EnableAsciiInternal',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'explicitFilename')],
+ is_pure_virtual=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeConstructionList_methods(root_module, cls):
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::AttributeConstructionList(ns3::AttributeConstructionList const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeConstructionList const &', 'arg0')])
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::AttributeConstructionList() [constructor]
+ cls.add_constructor([])
+ ## attribute-construction-list.h (module 'core'): void ns3::AttributeConstructionList::Add(std::string name, ns3::Ptr<ns3::AttributeChecker const> checker, ns3::Ptr<ns3::AttributeValue> value) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('std::string', 'name'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker'), param('ns3::Ptr< ns3::AttributeValue >', 'value')])
+ ## attribute-construction-list.h (module 'core'): std::_List_const_iterator<ns3::AttributeConstructionList::Item> ns3::AttributeConstructionList::Begin() const [member function]
+ cls.add_method('Begin',
+ 'std::_List_const_iterator< ns3::AttributeConstructionList::Item >',
+ [],
+ is_const=True)
+ ## attribute-construction-list.h (module 'core'): std::_List_const_iterator<ns3::AttributeConstructionList::Item> ns3::AttributeConstructionList::End() const [member function]
+ cls.add_method('End',
+ 'std::_List_const_iterator< ns3::AttributeConstructionList::Item >',
+ [],
+ is_const=True)
+ ## attribute-construction-list.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeConstructionList::Find(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('Find',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True)
+ return
+
+def register_Ns3AttributeConstructionListItem_methods(root_module, cls):
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::Item() [constructor]
+ cls.add_constructor([])
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::Item(ns3::AttributeConstructionList::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeConstructionList::Item const &', 'arg0')])
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::checker [variable]
+ cls.add_instance_attribute('checker', 'ns3::Ptr< ns3::AttributeChecker const >', is_const=False)
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::name [variable]
+ cls.add_instance_attribute('name', 'std::string', is_const=False)
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::value [variable]
+ cls.add_instance_attribute('value', 'ns3::Ptr< ns3::AttributeValue >', is_const=False)
+ return
+
+def register_Ns3Buffer_methods(root_module, cls):
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer() [constructor]
+ cls.add_constructor([])
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer(uint32_t dataSize) [constructor]
+ cls.add_constructor([param('uint32_t', 'dataSize')])
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer(uint32_t dataSize, bool initialize) [constructor]
+ cls.add_constructor([param('uint32_t', 'dataSize'), param('bool', 'initialize')])
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer(ns3::Buffer const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Buffer const &', 'o')])
+ ## buffer.h (module 'network'): bool ns3::Buffer::AddAtEnd(uint32_t end) [member function]
+ cls.add_method('AddAtEnd',
+ 'bool',
+ [param('uint32_t', 'end')])
+ ## buffer.h (module 'network'): void ns3::Buffer::AddAtEnd(ns3::Buffer const & o) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('ns3::Buffer const &', 'o')])
+ ## buffer.h (module 'network'): bool ns3::Buffer::AddAtStart(uint32_t start) [member function]
+ cls.add_method('AddAtStart',
+ 'bool',
+ [param('uint32_t', 'start')])
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator ns3::Buffer::Begin() const [member function]
+ cls.add_method('Begin',
+ 'ns3::Buffer::Iterator',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): void ns3::Buffer::CopyData(std::ostream * os, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'void',
+ [param('std::ostream *', 'os'), param('uint32_t', 'size')],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::CopyData(uint8_t * buffer, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')],
+ is_const=True)
+ ## buffer.h (module 'network'): ns3::Buffer ns3::Buffer::CreateFragment(uint32_t start, uint32_t length) const [member function]
+ cls.add_method('CreateFragment',
+ 'ns3::Buffer',
+ [param('uint32_t', 'start'), param('uint32_t', 'length')],
+ is_const=True)
+ ## buffer.h (module 'network'): ns3::Buffer ns3::Buffer::CreateFullCopy() const [member function]
+ cls.add_method('CreateFullCopy',
+ 'ns3::Buffer',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Deserialize(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator ns3::Buffer::End() const [member function]
+ cls.add_method('End',
+ 'ns3::Buffer::Iterator',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): int32_t ns3::Buffer::GetCurrentEndOffset() const [member function]
+ cls.add_method('GetCurrentEndOffset',
+ 'int32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): int32_t ns3::Buffer::GetCurrentStartOffset() const [member function]
+ cls.add_method('GetCurrentStartOffset',
+ 'int32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::GetSize() const [member function]
+ cls.add_method('GetSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint8_t const * ns3::Buffer::PeekData() const [member function]
+ cls.add_method('PeekData',
+ 'uint8_t const *',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): void ns3::Buffer::RemoveAtEnd(uint32_t end) [member function]
+ cls.add_method('RemoveAtEnd',
+ 'void',
+ [param('uint32_t', 'end')])
+ ## buffer.h (module 'network'): void ns3::Buffer::RemoveAtStart(uint32_t start) [member function]
+ cls.add_method('RemoveAtStart',
+ 'void',
+ [param('uint32_t', 'start')])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ return
+
+def register_Ns3BufferIterator_methods(root_module, cls):
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator::Iterator(ns3::Buffer::Iterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Buffer::Iterator const &', 'arg0')])
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator::Iterator() [constructor]
+ cls.add_constructor([])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::CalculateIpChecksum(uint16_t size) [member function]
+ cls.add_method('CalculateIpChecksum',
+ 'uint16_t',
+ [param('uint16_t', 'size')])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::CalculateIpChecksum(uint16_t size, uint32_t initialChecksum) [member function]
+ cls.add_method('CalculateIpChecksum',
+ 'uint16_t',
+ [param('uint16_t', 'size'), param('uint32_t', 'initialChecksum')])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::GetDistanceFrom(ns3::Buffer::Iterator const & o) const [member function]
+ cls.add_method('GetDistanceFrom',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator const &', 'o')],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::GetSize() const [member function]
+ cls.add_method('GetSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): bool ns3::Buffer::Iterator::IsEnd() const [member function]
+ cls.add_method('IsEnd',
+ 'bool',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): bool ns3::Buffer::Iterator::IsStart() const [member function]
+ cls.add_method('IsStart',
+ 'bool',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Next() [member function]
+ cls.add_method('Next',
+ 'void',
+ [])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Next(uint32_t delta) [member function]
+ cls.add_method('Next',
+ 'void',
+ [param('uint32_t', 'delta')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function]
+ cls.add_method('Prev',
+ 'void',
+ [])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev(uint32_t delta) [member function]
+ cls.add_method('Prev',
+ 'void',
+ [param('uint32_t', 'delta')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(uint8_t * buffer, uint32_t size) [member function]
+ cls.add_method('Read',
+ 'void',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function]
+ cls.add_method('ReadLsbtohU16',
+ 'uint16_t',
+ [])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadLsbtohU32() [member function]
+ cls.add_method('ReadLsbtohU32',
+ 'uint32_t',
+ [])
+ ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadLsbtohU64() [member function]
+ cls.add_method('ReadLsbtohU64',
+ 'uint64_t',
+ [])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadNtohU16() [member function]
+ cls.add_method('ReadNtohU16',
+ 'uint16_t',
+ [])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadNtohU32() [member function]
+ cls.add_method('ReadNtohU32',
+ 'uint32_t',
+ [])
+ ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadNtohU64() [member function]
+ cls.add_method('ReadNtohU64',
+ 'uint64_t',
+ [])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadU16() [member function]
+ cls.add_method('ReadU16',
+ 'uint16_t',
+ [])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadU32() [member function]
+ cls.add_method('ReadU32',
+ 'uint32_t',
+ [])
+ ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadU64() [member function]
+ cls.add_method('ReadU64',
+ 'uint64_t',
+ [])
+ ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::ReadU8() [member function]
+ cls.add_method('ReadU8',
+ 'uint8_t',
+ [])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Write(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Write(ns3::Buffer::Iterator start, ns3::Buffer::Iterator end) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Buffer::Iterator', 'start'), param('ns3::Buffer::Iterator', 'end')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU16(uint16_t data) [member function]
+ cls.add_method('WriteHtolsbU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU32(uint32_t data) [member function]
+ cls.add_method('WriteHtolsbU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU64(uint64_t data) [member function]
+ cls.add_method('WriteHtolsbU64',
+ 'void',
+ [param('uint64_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU16(uint16_t data) [member function]
+ cls.add_method('WriteHtonU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU32(uint32_t data) [member function]
+ cls.add_method('WriteHtonU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU64(uint64_t data) [member function]
+ cls.add_method('WriteHtonU64',
+ 'void',
+ [param('uint64_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU16(uint16_t data) [member function]
+ cls.add_method('WriteU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU32(uint32_t data) [member function]
+ cls.add_method('WriteU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU64(uint64_t data) [member function]
+ cls.add_method('WriteU64',
+ 'void',
+ [param('uint64_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU8(uint8_t data) [member function]
+ cls.add_method('WriteU8',
+ 'void',
+ [param('uint8_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU8(uint8_t data, uint32_t len) [member function]
+ cls.add_method('WriteU8',
+ 'void',
+ [param('uint8_t', 'data'), param('uint32_t', 'len')])
+ return
+
+def register_Ns3ByteTagIterator_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::ByteTagIterator::ByteTagIterator(ns3::ByteTagIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagIterator const &', 'arg0')])
+ ## packet.h (module 'network'): bool ns3::ByteTagIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::ByteTagIterator::Item ns3::ByteTagIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::ByteTagIterator::Item',
+ [])
+ return
+
+def register_Ns3ByteTagIteratorItem_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::ByteTagIterator::Item::Item(ns3::ByteTagIterator::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagIterator::Item const &', 'arg0')])
+ ## packet.h (module 'network'): uint32_t ns3::ByteTagIterator::Item::GetEnd() const [member function]
+ cls.add_method('GetEnd',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::ByteTagIterator::Item::GetStart() const [member function]
+ cls.add_method('GetStart',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::ByteTagIterator::Item::GetTag(ns3::Tag & tag) const [member function]
+ cls.add_method('GetTag',
+ 'void',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::TypeId ns3::ByteTagIterator::Item::GetTypeId() const [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3ByteTagList_methods(root_module, cls):
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::ByteTagList() [constructor]
+ cls.add_constructor([])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::ByteTagList(ns3::ByteTagList const & o) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagList const &', 'o')])
+ ## byte-tag-list.h (module 'network'): ns3::TagBuffer ns3::ByteTagList::Add(ns3::TypeId tid, uint32_t bufferSize, int32_t start, int32_t end) [member function]
+ cls.add_method('Add',
+ 'ns3::TagBuffer',
+ [param('ns3::TypeId', 'tid'), param('uint32_t', 'bufferSize'), param('int32_t', 'start'), param('int32_t', 'end')])
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::Add(ns3::ByteTagList const & o) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::ByteTagList const &', 'o')])
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::AddAtEnd(int32_t adjustment, int32_t appendOffset) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('int32_t', 'adjustment'), param('int32_t', 'appendOffset')])
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::AddAtStart(int32_t adjustment, int32_t prependOffset) [member function]
+ cls.add_method('AddAtStart',
+ 'void',
+ [param('int32_t', 'adjustment'), param('int32_t', 'prependOffset')])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator ns3::ByteTagList::Begin(int32_t offsetStart, int32_t offsetEnd) const [member function]
+ cls.add_method('Begin',
+ 'ns3::ByteTagList::Iterator',
+ [param('int32_t', 'offsetStart'), param('int32_t', 'offsetEnd')],
+ is_const=True)
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::RemoveAll() [member function]
+ cls.add_method('RemoveAll',
+ 'void',
+ [])
+ return
+
+def register_Ns3ByteTagListIterator_methods(root_module, cls):
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Iterator(ns3::ByteTagList::Iterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagList::Iterator const &', 'arg0')])
+ ## byte-tag-list.h (module 'network'): uint32_t ns3::ByteTagList::Iterator::GetOffsetStart() const [member function]
+ cls.add_method('GetOffsetStart',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## byte-tag-list.h (module 'network'): bool ns3::ByteTagList::Iterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item ns3::ByteTagList::Iterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::ByteTagList::Iterator::Item',
+ [])
+ return
+
+def register_Ns3ByteTagListIteratorItem_methods(root_module, cls):
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::Item(ns3::ByteTagList::Iterator::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagList::Iterator::Item const &', 'arg0')])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::Item(ns3::TagBuffer buf) [constructor]
+ cls.add_constructor([param('ns3::TagBuffer', 'buf')])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::buf [variable]
+ cls.add_instance_attribute('buf', 'ns3::TagBuffer', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::end [variable]
+ cls.add_instance_attribute('end', 'int32_t', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::size [variable]
+ cls.add_instance_attribute('size', 'uint32_t', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::start [variable]
+ cls.add_instance_attribute('start', 'int32_t', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::tid [variable]
+ cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False)
+ return
+
+def register_Ns3CallbackBase_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase(ns3::CallbackBase const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackBase const &', 'arg0')])
+ ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::Ptr<ns3::CallbackImplBase> ns3::CallbackBase::GetImpl() const [member function]
+ cls.add_method('GetImpl',
+ 'ns3::Ptr< ns3::CallbackImplBase >',
+ [],
+ is_const=True)
+ ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase(ns3::Ptr<ns3::CallbackImplBase> impl) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::CallbackImplBase >', 'impl')],
+ visibility='protected')
+ ## callback.h (module 'core'): static std::string ns3::CallbackBase::Demangle(std::string const & mangled) [member function]
+ cls.add_method('Demangle',
+ 'std::string',
+ [param('std::string const &', 'mangled')],
+ is_static=True, visibility='protected')
+ return
+
+def register_Ns3CriticalSection_methods(root_module, cls):
+ ## system-mutex.h (module 'core'): ns3::CriticalSection::CriticalSection(ns3::CriticalSection const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CriticalSection const &', 'arg0')])
+ ## system-mutex.h (module 'core'): ns3::CriticalSection::CriticalSection(ns3::SystemMutex & mutex) [constructor]
+ cls.add_constructor([param('ns3::SystemMutex &', 'mutex')])
+ return
+
+def register_Ns3DataRate_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('!=')
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('<=')
+ cls.add_binary_comparison_operator('==')
+ cls.add_binary_comparison_operator('>')
+ cls.add_binary_comparison_operator('>=')
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate(ns3::DataRate const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::DataRate const &', 'arg0')])
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate() [constructor]
+ cls.add_constructor([])
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate(uint64_t bps) [constructor]
+ cls.add_constructor([param('uint64_t', 'bps')])
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate(std::string rate) [constructor]
+ cls.add_constructor([param('std::string', 'rate')])
+ ## data-rate.h (module 'network'): double ns3::DataRate::CalculateTxTime(uint32_t bytes) const [member function]
+ cls.add_method('CalculateTxTime',
+ 'double',
+ [param('uint32_t', 'bytes')],
+ is_const=True)
+ ## data-rate.h (module 'network'): uint64_t ns3::DataRate::GetBitRate() const [member function]
+ cls.add_method('GetBitRate',
+ 'uint64_t',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3EventId_methods(root_module, cls):
+ cls.add_binary_comparison_operator('!=')
+ cls.add_binary_comparison_operator('==')
+ ## event-id.h (module 'core'): ns3::EventId::EventId(ns3::EventId const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EventId const &', 'arg0')])
+ ## event-id.h (module 'core'): ns3::EventId::EventId() [constructor]
+ cls.add_constructor([])
+ ## event-id.h (module 'core'): ns3::EventId::EventId(ns3::Ptr<ns3::EventImpl> const & impl, uint64_t ts, uint32_t context, uint32_t uid) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::EventImpl > const &', 'impl'), param('uint64_t', 'ts'), param('uint32_t', 'context'), param('uint32_t', 'uid')])
+ ## event-id.h (module 'core'): void ns3::EventId::Cancel() [member function]
+ cls.add_method('Cancel',
+ 'void',
+ [])
+ ## event-id.h (module 'core'): uint32_t ns3::EventId::GetContext() const [member function]
+ cls.add_method('GetContext',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): uint64_t ns3::EventId::GetTs() const [member function]
+ cls.add_method('GetTs',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): uint32_t ns3::EventId::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): bool ns3::EventId::IsExpired() const [member function]
+ cls.add_method('IsExpired',
+ 'bool',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): bool ns3::EventId::IsRunning() const [member function]
+ cls.add_method('IsRunning',
+ 'bool',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): ns3::EventImpl * ns3::EventId::PeekEventImpl() const [member function]
+ cls.add_method('PeekEventImpl',
+ 'ns3::EventImpl *',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3Ipv4Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(ns3::Ipv4Address const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4Address const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(uint32_t address) [constructor]
+ cls.add_constructor([param('uint32_t', 'address')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(char const * address) [constructor]
+ cls.add_constructor([param('char const *', 'address')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4Address::CombineMask(ns3::Ipv4Mask const & mask) const [member function]
+ cls.add_method('CombineMask',
+ 'ns3::Ipv4Address',
+ [param('ns3::Ipv4Mask const &', 'mask')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::ConvertFrom(ns3::Address const & address) [member function]
+ cls.add_method('ConvertFrom',
+ 'ns3::Ipv4Address',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::Deserialize(uint8_t const * buf) [member function]
+ cls.add_method('Deserialize',
+ 'ns3::Ipv4Address',
+ [param('uint8_t const *', 'buf')],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Address::Get() const [member function]
+ cls.add_method('Get',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetAny() [member function]
+ cls.add_method('GetAny',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetBroadcast() [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4Address::GetSubnetDirectedBroadcast(ns3::Ipv4Mask const & mask) const [member function]
+ cls.add_method('GetSubnetDirectedBroadcast',
+ 'ns3::Ipv4Address',
+ [param('ns3::Ipv4Mask const &', 'mask')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsEqual(ns3::Ipv4Address const & other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv4Address const &', 'other')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsLocalMulticast() const [member function]
+ cls.add_method('IsLocalMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static bool ns3::Ipv4Address::IsMatchingType(ns3::Address const & address) [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsSubnetDirectedBroadcast(ns3::Ipv4Mask const & mask) const [member function]
+ cls.add_method('IsSubnetDirectedBroadcast',
+ 'bool',
+ [param('ns3::Ipv4Mask const &', 'mask')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Serialize(uint8_t * buf) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Set(uint32_t address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('uint32_t', 'address')])
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Set(char const * address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('char const *', 'address')])
+ return
+
+def register_Ns3Ipv4Mask_methods(root_module, cls):
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(ns3::Ipv4Mask const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4Mask const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(uint32_t mask) [constructor]
+ cls.add_constructor([param('uint32_t', 'mask')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(char const * mask) [constructor]
+ cls.add_constructor([param('char const *', 'mask')])
+ ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Mask::Get() const [member function]
+ cls.add_method('Get',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Mask::GetInverse() const [member function]
+ cls.add_method('GetInverse',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv4Mask',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetOnes() [member function]
+ cls.add_method('GetOnes',
+ 'ns3::Ipv4Mask',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): uint16_t ns3::Ipv4Mask::GetPrefixLength() const [member function]
+ cls.add_method('GetPrefixLength',
+ 'uint16_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv4Mask',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Mask::IsEqual(ns3::Ipv4Mask other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv4Mask', 'other')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Mask::IsMatch(ns3::Ipv4Address a, ns3::Ipv4Address b) const [member function]
+ cls.add_method('IsMatch',
+ 'bool',
+ [param('ns3::Ipv4Address', 'a'), param('ns3::Ipv4Address', 'b')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Mask::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Mask::Set(uint32_t mask) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('uint32_t', 'mask')])
+ return
+
+def register_Ns3Ipv6Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(char const * address) [constructor]
+ cls.add_constructor([param('char const *', 'address')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(uint8_t * address) [constructor]
+ cls.add_constructor([param('uint8_t *', 'address')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(ns3::Ipv6Address const & addr) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6Address const &', 'addr')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(ns3::Ipv6Address const * addr) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Address const *', 'addr')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address ns3::Ipv6Address::CombinePrefix(ns3::Ipv6Prefix const & prefix) [member function]
+ cls.add_method('CombinePrefix',
+ 'ns3::Ipv6Address',
+ [param('ns3::Ipv6Prefix const &', 'prefix')])
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::ConvertFrom(ns3::Address const & address) [member function]
+ cls.add_method('ConvertFrom',
+ 'ns3::Ipv6Address',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::Deserialize(uint8_t const * buf) [member function]
+ cls.add_method('Deserialize',
+ 'ns3::Ipv6Address',
+ [param('uint8_t const *', 'buf')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllHostsMulticast() [member function]
+ cls.add_method('GetAllHostsMulticast',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllNodesMulticast() [member function]
+ cls.add_method('GetAllNodesMulticast',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllRoutersMulticast() [member function]
+ cls.add_method('GetAllRoutersMulticast',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAny() [member function]
+ cls.add_method('GetAny',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::GetBytes(uint8_t * buf) const [member function]
+ cls.add_method('GetBytes',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv6Address::GetIpv4MappedAddress() const [member function]
+ cls.add_method('GetIpv4MappedAddress',
+ 'ns3::Ipv4Address',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetOnes() [member function]
+ cls.add_method('GetOnes',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllHostsMulticast() const [member function]
+ cls.add_method('IsAllHostsMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllNodesMulticast() const [member function]
+ cls.add_method('IsAllNodesMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllRoutersMulticast() const [member function]
+ cls.add_method('IsAllRoutersMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAny() const [member function]
+ cls.add_method('IsAny',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsEqual(ns3::Ipv6Address const & other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv6Address const &', 'other')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsIpv4MappedAddress() [member function]
+ cls.add_method('IsIpv4MappedAddress',
+ 'bool',
+ [])
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocal() const [member function]
+ cls.add_method('IsLinkLocal',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocalMulticast() const [member function]
+ cls.add_method('IsLinkLocalMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLocalhost() const [member function]
+ cls.add_method('IsLocalhost',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static bool ns3::Ipv6Address::IsMatchingType(ns3::Address const & address) [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsSolicitedMulticast() const [member function]
+ cls.add_method('IsSolicitedMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredAddress(ns3::Mac48Address addr, ns3::Ipv6Address prefix) [member function]
+ cls.add_method('MakeAutoconfiguredAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Mac48Address', 'addr'), param('ns3::Ipv6Address', 'prefix')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredLinkLocalAddress(ns3::Mac48Address mac) [member function]
+ cls.add_method('MakeAutoconfiguredLinkLocalAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Mac48Address', 'mac')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeIpv4MappedAddress(ns3::Ipv4Address addr) [member function]
+ cls.add_method('MakeIpv4MappedAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Ipv4Address', 'addr')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeSolicitedAddress(ns3::Ipv6Address addr) [member function]
+ cls.add_method('MakeSolicitedAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Ipv6Address', 'addr')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Serialize(uint8_t * buf) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Set(char const * address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('char const *', 'address')])
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Set(uint8_t * address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('uint8_t *', 'address')])
+ return
+
+def register_Ns3Ipv6Prefix_methods(root_module, cls):
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(uint8_t * prefix) [constructor]
+ cls.add_constructor([param('uint8_t *', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(char const * prefix) [constructor]
+ cls.add_constructor([param('char const *', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(uint8_t prefix) [constructor]
+ cls.add_constructor([param('uint8_t', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(ns3::Ipv6Prefix const & prefix) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6Prefix const &', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(ns3::Ipv6Prefix const * prefix) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Prefix const *', 'prefix')])
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Prefix::GetBytes(uint8_t * buf) const [member function]
+ cls.add_method('GetBytes',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetOnes() [member function]
+ cls.add_method('GetOnes',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): uint8_t ns3::Ipv6Prefix::GetPrefixLength() const [member function]
+ cls.add_method('GetPrefixLength',
+ 'uint8_t',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Prefix::IsEqual(ns3::Ipv6Prefix const & other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv6Prefix const &', 'other')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Prefix::IsMatch(ns3::Ipv6Address a, ns3::Ipv6Address b) const [member function]
+ cls.add_method('IsMatch',
+ 'bool',
+ [param('ns3::Ipv6Address', 'a'), param('ns3::Ipv6Address', 'b')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Prefix::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ return
+
+def register_Ns3Mac48Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address(ns3::Mac48Address const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Mac48Address const &', 'arg0')])
+ ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address() [constructor]
+ cls.add_constructor([])
+ ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address(char const * str) [constructor]
+ cls.add_constructor([param('char const *', 'str')])
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::Allocate() [member function]
+ cls.add_method('Allocate',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::ConvertFrom(ns3::Address const & address) [member function]
+ cls.add_method('ConvertFrom',
+ 'ns3::Mac48Address',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## mac48-address.h (module 'network'): void ns3::Mac48Address::CopyFrom(uint8_t const * buffer) [member function]
+ cls.add_method('CopyFrom',
+ 'void',
+ [param('uint8_t const *', 'buffer')])
+ ## mac48-address.h (module 'network'): void ns3::Mac48Address::CopyTo(uint8_t * buffer) const [member function]
+ cls.add_method('CopyTo',
+ 'void',
+ [param('uint8_t *', 'buffer')],
+ is_const=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetBroadcast() [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast(ns3::Ipv4Address address) [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Mac48Address',
+ [param('ns3::Ipv4Address', 'address')],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast(ns3::Ipv6Address address) [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Mac48Address',
+ [param('ns3::Ipv6Address', 'address')],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast6Prefix() [member function]
+ cls.add_method('GetMulticast6Prefix',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticastPrefix() [member function]
+ cls.add_method('GetMulticastPrefix',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): bool ns3::Mac48Address::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_const=True)
+ ## mac48-address.h (module 'network'): bool ns3::Mac48Address::IsGroup() const [member function]
+ cls.add_method('IsGroup',
+ 'bool',
+ [],
+ is_const=True)
+ ## mac48-address.h (module 'network'): static bool ns3::Mac48Address::IsMatchingType(ns3::Address const & address) [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ return
+
+def register_Ns3NetDeviceContainer_methods(root_module, cls):
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(ns3::NetDeviceContainer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::NetDeviceContainer const &', 'arg0')])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer() [constructor]
+ cls.add_constructor([])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(ns3::Ptr<ns3::NetDevice> dev) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::NetDevice >', 'dev')])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(std::string devName) [constructor]
+ cls.add_constructor([param('std::string', 'devName')])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(ns3::NetDeviceContainer const & a, ns3::NetDeviceContainer const & b) [constructor]
+ cls.add_constructor([param('ns3::NetDeviceContainer const &', 'a'), param('ns3::NetDeviceContainer const &', 'b')])
+ ## net-device-container.h (module 'network'): void ns3::NetDeviceContainer::Add(ns3::NetDeviceContainer other) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::NetDeviceContainer', 'other')])
+ ## net-device-container.h (module 'network'): void ns3::NetDeviceContainer::Add(ns3::Ptr<ns3::NetDevice> device) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::Ptr< ns3::NetDevice >', 'device')])
+ ## net-device-container.h (module 'network'): void ns3::NetDeviceContainer::Add(std::string deviceName) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('std::string', 'deviceName')])
+ ## net-device-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::NetDevice>*,std::vector<ns3::Ptr<ns3::NetDevice>, std::allocator<ns3::Ptr<ns3::NetDevice> > > > ns3::NetDeviceContainer::Begin() const [member function]
+ cls.add_method('Begin',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::NetDevice > const, std::vector< ns3::Ptr< ns3::NetDevice > > >',
+ [],
+ is_const=True)
+ ## net-device-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::NetDevice>*,std::vector<ns3::Ptr<ns3::NetDevice>, std::allocator<ns3::Ptr<ns3::NetDevice> > > > ns3::NetDeviceContainer::End() const [member function]
+ cls.add_method('End',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::NetDevice > const, std::vector< ns3::Ptr< ns3::NetDevice > > >',
+ [],
+ is_const=True)
+ ## net-device-container.h (module 'network'): ns3::Ptr<ns3::NetDevice> ns3::NetDeviceContainer::Get(uint32_t i) const [member function]
+ cls.add_method('Get',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## net-device-container.h (module 'network'): uint32_t ns3::NetDeviceContainer::GetN() const [member function]
+ cls.add_method('GetN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3NodeContainer_methods(root_module, cls):
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'arg0')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer() [constructor]
+ cls.add_constructor([])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::Ptr<ns3::Node> node) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::Node >', 'node')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(std::string nodeName) [constructor]
+ cls.add_constructor([param('std::string', 'nodeName')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c, ns3::NodeContainer const & d) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c'), param('ns3::NodeContainer const &', 'd')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c, ns3::NodeContainer const & d, ns3::NodeContainer const & e) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c'), param('ns3::NodeContainer const &', 'd'), param('ns3::NodeContainer const &', 'e')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Add(ns3::NodeContainer other) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::NodeContainer', 'other')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Add(ns3::Ptr<ns3::Node> node) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::Ptr< ns3::Node >', 'node')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Add(std::string nodeName) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('std::string', 'nodeName')])
+ ## node-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::Node>*,std::vector<ns3::Ptr<ns3::Node>, std::allocator<ns3::Ptr<ns3::Node> > > > ns3::NodeContainer::Begin() const [member function]
+ cls.add_method('Begin',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::Node > const, std::vector< ns3::Ptr< ns3::Node > > >',
+ [],
+ is_const=True)
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Create(uint32_t n) [member function]
+ cls.add_method('Create',
+ 'void',
+ [param('uint32_t', 'n')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Create(uint32_t n, uint32_t systemId) [member function]
+ cls.add_method('Create',
+ 'void',
+ [param('uint32_t', 'n'), param('uint32_t', 'systemId')])
+ ## node-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::Node>*,std::vector<ns3::Ptr<ns3::Node>, std::allocator<ns3::Ptr<ns3::Node> > > > ns3::NodeContainer::End() const [member function]
+ cls.add_method('End',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::Node > const, std::vector< ns3::Ptr< ns3::Node > > >',
+ [],
+ is_const=True)
+ ## node-container.h (module 'network'): ns3::Ptr<ns3::Node> ns3::NodeContainer::Get(uint32_t i) const [member function]
+ cls.add_method('Get',
+ 'ns3::Ptr< ns3::Node >',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## node-container.h (module 'network'): static ns3::NodeContainer ns3::NodeContainer::GetGlobal() [member function]
+ cls.add_method('GetGlobal',
+ 'ns3::NodeContainer',
+ [],
+ is_static=True)
+ ## node-container.h (module 'network'): uint32_t ns3::NodeContainer::GetN() const [member function]
+ cls.add_method('GetN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3ObjectBase_methods(root_module, cls):
+ ## object-base.h (module 'core'): ns3::ObjectBase::ObjectBase() [constructor]
+ cls.add_constructor([])
+ ## object-base.h (module 'core'): ns3::ObjectBase::ObjectBase(ns3::ObjectBase const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectBase const &', 'arg0')])
+ ## object-base.h (module 'core'): void ns3::ObjectBase::GetAttribute(std::string name, ns3::AttributeValue & value) const [member function]
+ cls.add_method('GetAttribute',
+ 'void',
+ [param('std::string', 'name'), param('ns3::AttributeValue &', 'value')],
+ is_const=True)
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::GetAttributeFailSafe(std::string name, ns3::AttributeValue & attribute) const [member function]
+ cls.add_method('GetAttributeFailSafe',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::AttributeValue &', 'attribute')],
+ is_const=True)
+ ## object-base.h (module 'core'): ns3::TypeId ns3::ObjectBase::GetInstanceTypeId() const [member function]
+ cls.add_method('GetInstanceTypeId',
+ 'ns3::TypeId',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## object-base.h (module 'core'): static ns3::TypeId ns3::ObjectBase::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## object-base.h (module 'core'): void ns3::ObjectBase::SetAttribute(std::string name, ns3::AttributeValue const & value) [member function]
+ cls.add_method('SetAttribute',
+ 'void',
+ [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::SetAttributeFailSafe(std::string name, ns3::AttributeValue const & value) [member function]
+ cls.add_method('SetAttributeFailSafe',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceConnect(std::string name, std::string context, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceConnect',
+ 'bool',
+ [param('std::string', 'name'), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceConnectWithoutContext(std::string name, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceConnectWithoutContext',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceDisconnect(std::string name, std::string context, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceDisconnect',
+ 'bool',
+ [param('std::string', 'name'), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceDisconnectWithoutContext(std::string name, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceDisconnectWithoutContext',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): void ns3::ObjectBase::ConstructSelf(ns3::AttributeConstructionList const & attributes) [member function]
+ cls.add_method('ConstructSelf',
+ 'void',
+ [param('ns3::AttributeConstructionList const &', 'attributes')],
+ visibility='protected')
+ ## object-base.h (module 'core'): void ns3::ObjectBase::NotifyConstructionCompleted() [member function]
+ cls.add_method('NotifyConstructionCompleted',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3ObjectDeleter_methods(root_module, cls):
+ ## object.h (module 'core'): ns3::ObjectDeleter::ObjectDeleter() [constructor]
+ cls.add_constructor([])
+ ## object.h (module 'core'): ns3::ObjectDeleter::ObjectDeleter(ns3::ObjectDeleter const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectDeleter const &', 'arg0')])
+ ## object.h (module 'core'): static void ns3::ObjectDeleter::Delete(ns3::Object * object) [member function]
+ cls.add_method('Delete',
+ 'void',
+ [param('ns3::Object *', 'object')],
+ is_static=True)
+ return
+
+def register_Ns3ObjectFactory_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory(ns3::ObjectFactory const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectFactory const &', 'arg0')])
+ ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory() [constructor]
+ cls.add_constructor([])
+ ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory(std::string typeId) [constructor]
+ cls.add_constructor([param('std::string', 'typeId')])
+ ## object-factory.h (module 'core'): ns3::Ptr<ns3::Object> ns3::ObjectFactory::Create() const [member function]
+ cls.add_method('Create',
+ 'ns3::Ptr< ns3::Object >',
+ [],
+ is_const=True)
+ ## object-factory.h (module 'core'): ns3::TypeId ns3::ObjectFactory::GetTypeId() const [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::Set(std::string name, ns3::AttributeValue const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')])
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(ns3::TypeId tid) [member function]
+ cls.add_method('SetTypeId',
+ 'void',
+ [param('ns3::TypeId', 'tid')])
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(char const * tid) [member function]
+ cls.add_method('SetTypeId',
+ 'void',
+ [param('char const *', 'tid')])
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(std::string tid) [member function]
+ cls.add_method('SetTypeId',
+ 'void',
+ [param('std::string', 'tid')])
+ return
+
+def register_Ns3PacketMetadata_methods(root_module, cls):
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::PacketMetadata(uint64_t uid, uint32_t size) [constructor]
+ cls.add_constructor([param('uint64_t', 'uid'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::PacketMetadata(ns3::PacketMetadata const & o) [copy constructor]
+ cls.add_constructor([param('ns3::PacketMetadata const &', 'o')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddAtEnd(ns3::PacketMetadata const & o) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('ns3::PacketMetadata const &', 'o')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddHeader(ns3::Header const & header, uint32_t size) [member function]
+ cls.add_method('AddHeader',
+ 'void',
+ [param('ns3::Header const &', 'header'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddPaddingAtEnd(uint32_t end) [member function]
+ cls.add_method('AddPaddingAtEnd',
+ 'void',
+ [param('uint32_t', 'end')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddTrailer(ns3::Trailer const & trailer, uint32_t size) [member function]
+ cls.add_method('AddTrailer',
+ 'void',
+ [param('ns3::Trailer const &', 'trailer'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator ns3::PacketMetadata::BeginItem(ns3::Buffer buffer) const [member function]
+ cls.add_method('BeginItem',
+ 'ns3::PacketMetadata::ItemIterator',
+ [param('ns3::Buffer', 'buffer')],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata ns3::PacketMetadata::CreateFragment(uint32_t start, uint32_t end) const [member function]
+ cls.add_method('CreateFragment',
+ 'ns3::PacketMetadata',
+ [param('uint32_t', 'start'), param('uint32_t', 'end')],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::Deserialize(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): static void ns3::PacketMetadata::Enable() [member function]
+ cls.add_method('Enable',
+ 'void',
+ [],
+ is_static=True)
+ ## packet-metadata.h (module 'network'): static void ns3::PacketMetadata::EnableChecking() [member function]
+ cls.add_method('EnableChecking',
+ 'void',
+ [],
+ is_static=True)
+ ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): uint64_t ns3::PacketMetadata::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveAtEnd(uint32_t end) [member function]
+ cls.add_method('RemoveAtEnd',
+ 'void',
+ [param('uint32_t', 'end')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveAtStart(uint32_t start) [member function]
+ cls.add_method('RemoveAtStart',
+ 'void',
+ [param('uint32_t', 'start')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveHeader(ns3::Header const & header, uint32_t size) [member function]
+ cls.add_method('RemoveHeader',
+ 'void',
+ [param('ns3::Header const &', 'header'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveTrailer(ns3::Trailer const & trailer, uint32_t size) [member function]
+ cls.add_method('RemoveTrailer',
+ 'void',
+ [param('ns3::Trailer const &', 'trailer'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ return
+
+def register_Ns3PacketMetadataItem_methods(root_module, cls):
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::Item() [constructor]
+ cls.add_constructor([])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::Item(ns3::PacketMetadata::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketMetadata::Item const &', 'arg0')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::current [variable]
+ cls.add_instance_attribute('current', 'ns3::Buffer::Iterator', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentSize [variable]
+ cls.add_instance_attribute('currentSize', 'uint32_t', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentTrimedFromEnd [variable]
+ cls.add_instance_attribute('currentTrimedFromEnd', 'uint32_t', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentTrimedFromStart [variable]
+ cls.add_instance_attribute('currentTrimedFromStart', 'uint32_t', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::isFragment [variable]
+ cls.add_instance_attribute('isFragment', 'bool', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::tid [variable]
+ cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False)
+ return
+
+def register_Ns3PacketMetadataItemIterator_methods(root_module, cls):
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator::ItemIterator(ns3::PacketMetadata::ItemIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketMetadata::ItemIterator const &', 'arg0')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator::ItemIterator(ns3::PacketMetadata const * metadata, ns3::Buffer buffer) [constructor]
+ cls.add_constructor([param('ns3::PacketMetadata const *', 'metadata'), param('ns3::Buffer', 'buffer')])
+ ## packet-metadata.h (module 'network'): bool ns3::PacketMetadata::ItemIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item ns3::PacketMetadata::ItemIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::PacketMetadata::Item',
+ [])
+ return
+
+def register_Ns3PacketTagIterator_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::PacketTagIterator::PacketTagIterator(ns3::PacketTagIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagIterator const &', 'arg0')])
+ ## packet.h (module 'network'): bool ns3::PacketTagIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::PacketTagIterator::Item ns3::PacketTagIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::PacketTagIterator::Item',
+ [])
+ return
+
+def register_Ns3PacketTagIteratorItem_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::PacketTagIterator::Item::Item(ns3::PacketTagIterator::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagIterator::Item const &', 'arg0')])
+ ## packet.h (module 'network'): void ns3::PacketTagIterator::Item::GetTag(ns3::Tag & tag) const [member function]
+ cls.add_method('GetTag',
+ 'void',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::TypeId ns3::PacketTagIterator::Item::GetTypeId() const [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3PacketTagList_methods(root_module, cls):
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::PacketTagList() [constructor]
+ cls.add_constructor([])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::PacketTagList(ns3::PacketTagList const & o) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagList const &', 'o')])
+ ## packet-tag-list.h (module 'network'): void ns3::PacketTagList::Add(ns3::Tag const & tag) const [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::Tag const &', 'tag')],
+ is_const=True)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData const * ns3::PacketTagList::Head() const [member function]
+ cls.add_method('Head',
+ 'ns3::PacketTagList::TagData const *',
+ [],
+ is_const=True)
+ ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Peek(ns3::Tag & tag) const [member function]
+ cls.add_method('Peek',
+ 'bool',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Remove(ns3::Tag & tag) [member function]
+ cls.add_method('Remove',
+ 'bool',
+ [param('ns3::Tag &', 'tag')])
+ ## packet-tag-list.h (module 'network'): void ns3::PacketTagList::RemoveAll() [member function]
+ cls.add_method('RemoveAll',
+ 'void',
+ [])
+ return
+
+def register_Ns3PacketTagListTagData_methods(root_module, cls):
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData() [constructor]
+ cls.add_constructor([])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData(ns3::PacketTagList::TagData const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagList::TagData const &', 'arg0')])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::count [variable]
+ cls.add_instance_attribute('count', 'uint32_t', is_const=False)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::data [variable]
+ cls.add_instance_attribute('data', 'uint8_t [ 20 ]', is_const=False)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::next [variable]
+ cls.add_instance_attribute('next', 'ns3::PacketTagList::TagData *', is_const=False)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::tid [variable]
+ cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False)
+ return
+
+def register_Ns3PcapFile_methods(root_module, cls):
+ ## pcap-file.h (module 'network'): ns3::PcapFile::PcapFile() [constructor]
+ cls.add_constructor([])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Clear() [member function]
+ cls.add_method('Clear',
+ 'void',
+ [])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Close() [member function]
+ cls.add_method('Close',
+ 'void',
+ [])
+ ## pcap-file.h (module 'network'): static bool ns3::PcapFile::Diff(std::string const & f1, std::string const & f2, uint32_t & sec, uint32_t & usec, uint32_t snapLen=ns3::PcapFile::SNAPLEN_DEFAULT) [member function]
+ cls.add_method('Diff',
+ 'bool',
+ [param('std::string const &', 'f1'), param('std::string const &', 'f2'), param('uint32_t &', 'sec'), param('uint32_t &', 'usec'), param('uint32_t', 'snapLen', default_value='ns3::PcapFile::SNAPLEN_DEFAULT')],
+ is_static=True)
+ ## pcap-file.h (module 'network'): bool ns3::PcapFile::Eof() const [member function]
+ cls.add_method('Eof',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file.h (module 'network'): bool ns3::PcapFile::Fail() const [member function]
+ cls.add_method('Fail',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetDataLinkType() [member function]
+ cls.add_method('GetDataLinkType',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetMagic() [member function]
+ cls.add_method('GetMagic',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetSigFigs() [member function]
+ cls.add_method('GetSigFigs',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetSnapLen() [member function]
+ cls.add_method('GetSnapLen',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): bool ns3::PcapFile::GetSwapMode() [member function]
+ cls.add_method('GetSwapMode',
+ 'bool',
+ [])
+ ## pcap-file.h (module 'network'): int32_t ns3::PcapFile::GetTimeZoneOffset() [member function]
+ cls.add_method('GetTimeZoneOffset',
+ 'int32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint16_t ns3::PcapFile::GetVersionMajor() [member function]
+ cls.add_method('GetVersionMajor',
+ 'uint16_t',
+ [])
+ ## pcap-file.h (module 'network'): uint16_t ns3::PcapFile::GetVersionMinor() [member function]
+ cls.add_method('GetVersionMinor',
+ 'uint16_t',
+ [])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Init(uint32_t dataLinkType, uint32_t snapLen=ns3::PcapFile::SNAPLEN_DEFAULT, int32_t timeZoneCorrection=ns3::PcapFile::ZONE_DEFAULT, bool swapMode=false) [member function]
+ cls.add_method('Init',
+ 'void',
+ [param('uint32_t', 'dataLinkType'), param('uint32_t', 'snapLen', default_value='ns3::PcapFile::SNAPLEN_DEFAULT'), param('int32_t', 'timeZoneCorrection', default_value='ns3::PcapFile::ZONE_DEFAULT'), param('bool', 'swapMode', default_value='false')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Open(std::string const & filename, std::_Ios_Openmode mode) [member function]
+ cls.add_method('Open',
+ 'void',
+ [param('std::string const &', 'filename'), param('std::_Ios_Openmode', 'mode')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Read(uint8_t * const data, uint32_t maxBytes, uint32_t & tsSec, uint32_t & tsUsec, uint32_t & inclLen, uint32_t & origLen, uint32_t & readLen) [member function]
+ cls.add_method('Read',
+ 'void',
+ [param('uint8_t * const', 'data'), param('uint32_t', 'maxBytes'), param('uint32_t &', 'tsSec'), param('uint32_t &', 'tsUsec'), param('uint32_t &', 'inclLen'), param('uint32_t &', 'origLen'), param('uint32_t &', 'readLen')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Write(uint32_t tsSec, uint32_t tsUsec, uint8_t const * const data, uint32_t totalLen) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint32_t', 'tsSec'), param('uint32_t', 'tsUsec'), param('uint8_t const * const', 'data'), param('uint32_t', 'totalLen')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Write(uint32_t tsSec, uint32_t tsUsec, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint32_t', 'tsSec'), param('uint32_t', 'tsUsec'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Write(uint32_t tsSec, uint32_t tsUsec, ns3::Header & header, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint32_t', 'tsSec'), param('uint32_t', 'tsUsec'), param('ns3::Header &', 'header'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file.h (module 'network'): ns3::PcapFile::SNAPLEN_DEFAULT [variable]
+ cls.add_static_attribute('SNAPLEN_DEFAULT', 'uint32_t const', is_const=True)
+ ## pcap-file.h (module 'network'): ns3::PcapFile::ZONE_DEFAULT [variable]
+ cls.add_static_attribute('ZONE_DEFAULT', 'int32_t const', is_const=True)
+ return
+
+def register_Ns3PcapHelper_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::PcapHelper::PcapHelper(ns3::PcapHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PcapHelper const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::PcapHelper::PcapHelper() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): ns3::Ptr<ns3::PcapFileWrapper> ns3::PcapHelper::CreateFile(std::string filename, std::_Ios_Openmode filemode, uint32_t dataLinkType, uint32_t snapLen=65535, int32_t tzCorrection=0) [member function]
+ cls.add_method('CreateFile',
+ 'ns3::Ptr< ns3::PcapFileWrapper >',
+ [param('std::string', 'filename'), param('std::_Ios_Openmode', 'filemode'), param('uint32_t', 'dataLinkType'), param('uint32_t', 'snapLen', default_value='65535'), param('int32_t', 'tzCorrection', default_value='0')])
+ ## trace-helper.h (module 'network'): std::string ns3::PcapHelper::GetFilenameFromDevice(std::string prefix, ns3::Ptr<ns3::NetDevice> device, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromDevice',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'device'), param('bool', 'useObjectNames', default_value='true')])
+ ## trace-helper.h (module 'network'): std::string ns3::PcapHelper::GetFilenameFromInterfacePair(std::string prefix, ns3::Ptr<ns3::Object> object, uint32_t interface, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromInterfacePair',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::Object >', 'object'), param('uint32_t', 'interface'), param('bool', 'useObjectNames', default_value='true')])
+ return
+
+def register_Ns3PcapHelperForDevice_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::PcapHelperForDevice::PcapHelperForDevice(ns3::PcapHelperForDevice const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PcapHelperForDevice const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::PcapHelperForDevice::PcapHelperForDevice() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool promiscuous=false, bool explicitFilename=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'promiscuous', default_value='false'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, std::string ndName, bool promiscuous=false, bool explicitFilename=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('std::string', 'ndName'), param('bool', 'promiscuous', default_value='false'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, ns3::NetDeviceContainer d, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NetDeviceContainer', 'd'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, ns3::NodeContainer n, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NodeContainer', 'n'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, uint32_t nodeid, uint32_t deviceid, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('uint32_t', 'nodeid'), param('uint32_t', 'deviceid'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcapAll(std::string prefix, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcapAll',
+ 'void',
+ [param('std::string', 'prefix'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcapInternal(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool promiscuous, bool explicitFilename) [member function]
+ cls.add_method('EnablePcapInternal',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'promiscuous'), param('bool', 'explicitFilename')],
+ is_pure_virtual=True, is_virtual=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::SimpleRefCount(ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter> const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3Simulator_methods(root_module, cls):
+ ## simulator.h (module 'core'): ns3::Simulator::Simulator(ns3::Simulator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Simulator const &', 'arg0')])
+ ## simulator.h (module 'core'): static void ns3::Simulator::Cancel(ns3::EventId const & id) [member function]
+ cls.add_method('Cancel',
+ 'void',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Destroy() [member function]
+ cls.add_method('Destroy',
+ 'void',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static uint32_t ns3::Simulator::GetContext() [member function]
+ cls.add_method('GetContext',
+ 'uint32_t',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::GetDelayLeft(ns3::EventId const & id) [member function]
+ cls.add_method('GetDelayLeft',
+ 'ns3::Time',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Ptr<ns3::SimulatorImpl> ns3::Simulator::GetImplementation() [member function]
+ cls.add_method('GetImplementation',
+ 'ns3::Ptr< ns3::SimulatorImpl >',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::GetMaximumSimulationTime() [member function]
+ cls.add_method('GetMaximumSimulationTime',
+ 'ns3::Time',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static uint32_t ns3::Simulator::GetSystemId() [member function]
+ cls.add_method('GetSystemId',
+ 'uint32_t',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static bool ns3::Simulator::IsExpired(ns3::EventId const & id) [member function]
+ cls.add_method('IsExpired',
+ 'bool',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): static bool ns3::Simulator::IsFinished() [member function]
+ cls.add_method('IsFinished',
+ 'bool',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::Now() [member function]
+ cls.add_method('Now',
+ 'ns3::Time',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Remove(ns3::EventId const & id) [member function]
+ cls.add_method('Remove',
+ 'void',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): 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)
+ ## simulator.h (module 'core'): static void ns3::Simulator::SetScheduler(ns3::ObjectFactory schedulerFactory) [member function]
+ cls.add_method('SetScheduler',
+ 'void',
+ [param('ns3::ObjectFactory', 'schedulerFactory')],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Stop() [member function]
+ cls.add_method('Stop',
+ 'void',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Stop(ns3::Time const & time) [member function]
+ cls.add_method('Stop',
+ 'void',
+ [param('ns3::Time const &', 'time')],
+ is_static=True)
+ return
+
+def register_Ns3SystemCondition_methods(root_module, cls):
+ ## system-condition.h (module 'core'): ns3::SystemCondition::SystemCondition(ns3::SystemCondition const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::SystemCondition const &', 'arg0')])
+ ## system-condition.h (module 'core'): ns3::SystemCondition::SystemCondition() [constructor]
+ cls.add_constructor([])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::Broadcast() [member function]
+ cls.add_method('Broadcast',
+ 'void',
+ [])
+ ## system-condition.h (module 'core'): bool ns3::SystemCondition::GetCondition() [member function]
+ cls.add_method('GetCondition',
+ 'bool',
+ [])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::SetCondition(bool condition) [member function]
+ cls.add_method('SetCondition',
+ 'void',
+ [param('bool', 'condition')])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::Signal() [member function]
+ cls.add_method('Signal',
+ 'void',
+ [])
+ ## system-condition.h (module 'core'): bool ns3::SystemCondition::TimedWait(uint64_t ns) [member function]
+ cls.add_method('TimedWait',
+ 'bool',
+ [param('uint64_t', 'ns')])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::Wait() [member function]
+ cls.add_method('Wait',
+ 'void',
+ [])
+ return
+
+def register_Ns3SystemMutex_methods(root_module, cls):
+ ## system-mutex.h (module 'core'): ns3::SystemMutex::SystemMutex(ns3::SystemMutex const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::SystemMutex const &', 'arg0')])
+ ## system-mutex.h (module 'core'): ns3::SystemMutex::SystemMutex() [constructor]
+ cls.add_constructor([])
+ ## system-mutex.h (module 'core'): void ns3::SystemMutex::Lock() [member function]
+ cls.add_method('Lock',
+ 'void',
+ [])
+ ## system-mutex.h (module 'core'): void ns3::SystemMutex::Unlock() [member function]
+ cls.add_method('Unlock',
+ 'void',
+ [])
+ return
+
+def register_Ns3Tag_methods(root_module, cls):
+ ## tag.h (module 'network'): ns3::Tag::Tag() [constructor]
+ cls.add_constructor([])
+ ## tag.h (module 'network'): ns3::Tag::Tag(ns3::Tag const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Tag const &', 'arg0')])
+ ## tag.h (module 'network'): void ns3::Tag::Deserialize(ns3::TagBuffer i) [member function]
+ cls.add_method('Deserialize',
+ 'void',
+ [param('ns3::TagBuffer', 'i')],
+ is_pure_virtual=True, is_virtual=True)
+ ## tag.h (module 'network'): uint32_t ns3::Tag::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## tag.h (module 'network'): static ns3::TypeId ns3::Tag::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## tag.h (module 'network'): void ns3::Tag::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## tag.h (module 'network'): void ns3::Tag::Serialize(ns3::TagBuffer i) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::TagBuffer', 'i')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3TagBuffer_methods(root_module, cls):
+ ## tag-buffer.h (module 'network'): ns3::TagBuffer::TagBuffer(ns3::TagBuffer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TagBuffer const &', 'arg0')])
+ ## tag-buffer.h (module 'network'): ns3::TagBuffer::TagBuffer(uint8_t * start, uint8_t * end) [constructor]
+ cls.add_constructor([param('uint8_t *', 'start'), param('uint8_t *', 'end')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::CopyFrom(ns3::TagBuffer o) [member function]
+ cls.add_method('CopyFrom',
+ 'void',
+ [param('ns3::TagBuffer', 'o')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::Read(uint8_t * buffer, uint32_t size) [member function]
+ cls.add_method('Read',
+ 'void',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')])
+ ## tag-buffer.h (module 'network'): double ns3::TagBuffer::ReadDouble() [member function]
+ cls.add_method('ReadDouble',
+ 'double',
+ [])
+ ## tag-buffer.h (module 'network'): uint16_t ns3::TagBuffer::ReadU16() [member function]
+ cls.add_method('ReadU16',
+ 'uint16_t',
+ [])
+ ## tag-buffer.h (module 'network'): uint32_t ns3::TagBuffer::ReadU32() [member function]
+ cls.add_method('ReadU32',
+ 'uint32_t',
+ [])
+ ## tag-buffer.h (module 'network'): uint64_t ns3::TagBuffer::ReadU64() [member function]
+ cls.add_method('ReadU64',
+ 'uint64_t',
+ [])
+ ## tag-buffer.h (module 'network'): uint8_t ns3::TagBuffer::ReadU8() [member function]
+ cls.add_method('ReadU8',
+ 'uint8_t',
+ [])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::TrimAtEnd(uint32_t trim) [member function]
+ cls.add_method('TrimAtEnd',
+ 'void',
+ [param('uint32_t', 'trim')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::Write(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteDouble(double v) [member function]
+ cls.add_method('WriteDouble',
+ 'void',
+ [param('double', 'v')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU16(uint16_t data) [member function]
+ cls.add_method('WriteU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU32(uint32_t data) [member function]
+ cls.add_method('WriteU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU64(uint64_t v) [member function]
+ cls.add_method('WriteU64',
+ 'void',
+ [param('uint64_t', 'v')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU8(uint8_t v) [member function]
+ cls.add_method('WriteU8',
+ 'void',
+ [param('uint8_t', 'v')])
+ return
+
+def register_Ns3TypeId_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## type-id.h (module 'core'): ns3::TypeId::TypeId(char const * name) [constructor]
+ cls.add_constructor([param('char const *', 'name')])
+ ## type-id.h (module 'core'): ns3::TypeId::TypeId() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeId::TypeId(ns3::TypeId const & o) [copy constructor]
+ cls.add_constructor([param('ns3::TypeId const &', 'o')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddAttribute(std::string name, std::string help, ns3::AttributeValue const & initialValue, ns3::Ptr<ns3::AttributeAccessor const> accessor, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('AddAttribute',
+ 'ns3::TypeId',
+ [param('std::string', 'name'), param('std::string', 'help'), param('ns3::AttributeValue const &', 'initialValue'), param('ns3::Ptr< ns3::AttributeAccessor const >', 'accessor'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddAttribute(std::string name, std::string help, uint32_t flags, ns3::AttributeValue const & initialValue, ns3::Ptr<ns3::AttributeAccessor const> accessor, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('AddAttribute',
+ 'ns3::TypeId',
+ [param('std::string', 'name'), param('std::string', 'help'), param('uint32_t', 'flags'), param('ns3::AttributeValue const &', 'initialValue'), param('ns3::Ptr< ns3::AttributeAccessor const >', 'accessor'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddTraceSource(std::string name, std::string help, ns3::Ptr<ns3::TraceSourceAccessor const> accessor) [member function]
+ cls.add_method('AddTraceSource',
+ 'ns3::TypeId',
+ [param('std::string', 'name'), param('std::string', 'help'), param('ns3::Ptr< ns3::TraceSourceAccessor const >', 'accessor')])
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation ns3::TypeId::GetAttribute(uint32_t i) const [member function]
+ cls.add_method('GetAttribute',
+ 'ns3::TypeId::AttributeInformation',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeId::GetAttributeFullName(uint32_t i) const [member function]
+ cls.add_method('GetAttributeFullName',
+ 'std::string',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## type-id.h (module 'core'): uint32_t ns3::TypeId::GetAttributeN() const [member function]
+ cls.add_method('GetAttributeN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): ns3::Callback<ns3::ObjectBase*,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::TypeId::GetConstructor() const [member function]
+ cls.add_method('GetConstructor',
+ 'ns3::Callback< ns3::ObjectBase *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeId::GetGroupName() const [member function]
+ cls.add_method('GetGroupName',
+ 'std::string',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeId::GetName() const [member function]
+ cls.add_method('GetName',
+ 'std::string',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::GetParent() const [member function]
+ cls.add_method('GetParent',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): static ns3::TypeId ns3::TypeId::GetRegistered(uint32_t i) [member function]
+ cls.add_method('GetRegistered',
+ 'ns3::TypeId',
+ [param('uint32_t', 'i')],
+ is_static=True)
+ ## type-id.h (module 'core'): static uint32_t ns3::TypeId::GetRegisteredN() [member function]
+ cls.add_method('GetRegisteredN',
+ 'uint32_t',
+ [],
+ is_static=True)
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation ns3::TypeId::GetTraceSource(uint32_t i) const [member function]
+ cls.add_method('GetTraceSource',
+ 'ns3::TypeId::TraceSourceInformation',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## type-id.h (module 'core'): uint32_t ns3::TypeId::GetTraceSourceN() const [member function]
+ cls.add_method('GetTraceSourceN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): uint16_t ns3::TypeId::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint16_t',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::HasConstructor() const [member function]
+ cls.add_method('HasConstructor',
+ 'bool',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::HasParent() const [member function]
+ cls.add_method('HasParent',
+ 'bool',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::HideFromDocumentation() [member function]
+ cls.add_method('HideFromDocumentation',
+ 'ns3::TypeId',
+ [])
+ ## type-id.h (module 'core'): bool ns3::TypeId::IsChildOf(ns3::TypeId other) const [member function]
+ cls.add_method('IsChildOf',
+ 'bool',
+ [param('ns3::TypeId', 'other')],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::LookupAttributeByName(std::string name, ns3::TypeId::AttributeInformation * info) const [member function]
+ cls.add_method('LookupAttributeByName',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::TypeId::AttributeInformation *', 'info', transfer_ownership=False)],
+ is_const=True)
+ ## type-id.h (module 'core'): static ns3::TypeId ns3::TypeId::LookupByName(std::string name) [member function]
+ cls.add_method('LookupByName',
+ 'ns3::TypeId',
+ [param('std::string', 'name')],
+ is_static=True)
+ ## type-id.h (module 'core'): ns3::Ptr<ns3::TraceSourceAccessor const> ns3::TypeId::LookupTraceSourceByName(std::string name) const [member function]
+ cls.add_method('LookupTraceSourceByName',
+ 'ns3::Ptr< ns3::TraceSourceAccessor const >',
+ [param('std::string', 'name')],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::MustHideFromDocumentation() const [member function]
+ cls.add_method('MustHideFromDocumentation',
+ 'bool',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::SetAttributeInitialValue(uint32_t i, ns3::Ptr<ns3::AttributeValue const> initialValue) [member function]
+ cls.add_method('SetAttributeInitialValue',
+ 'bool',
+ [param('uint32_t', 'i'), param('ns3::Ptr< ns3::AttributeValue const >', 'initialValue')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::SetGroupName(std::string groupName) [member function]
+ cls.add_method('SetGroupName',
+ 'ns3::TypeId',
+ [param('std::string', 'groupName')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::SetParent(ns3::TypeId tid) [member function]
+ cls.add_method('SetParent',
+ 'ns3::TypeId',
+ [param('ns3::TypeId', 'tid')])
+ ## type-id.h (module 'core'): void ns3::TypeId::SetUid(uint16_t tid) [member function]
+ cls.add_method('SetUid',
+ 'void',
+ [param('uint16_t', 'tid')])
+ return
+
+def register_Ns3TypeIdAttributeInformation_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::AttributeInformation() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::AttributeInformation(ns3::TypeId::AttributeInformation const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeId::AttributeInformation const &', 'arg0')])
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::accessor [variable]
+ cls.add_instance_attribute('accessor', 'ns3::Ptr< ns3::AttributeAccessor const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::checker [variable]
+ cls.add_instance_attribute('checker', 'ns3::Ptr< ns3::AttributeChecker const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::flags [variable]
+ cls.add_instance_attribute('flags', 'uint32_t', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::help [variable]
+ cls.add_instance_attribute('help', 'std::string', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::initialValue [variable]
+ cls.add_instance_attribute('initialValue', 'ns3::Ptr< ns3::AttributeValue const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::name [variable]
+ cls.add_instance_attribute('name', 'std::string', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::originalInitialValue [variable]
+ cls.add_instance_attribute('originalInitialValue', 'ns3::Ptr< ns3::AttributeValue const >', is_const=False)
+ return
+
+def register_Ns3TypeIdTraceSourceInformation_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::TraceSourceInformation() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::TraceSourceInformation(ns3::TypeId::TraceSourceInformation const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeId::TraceSourceInformation const &', 'arg0')])
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::accessor [variable]
+ cls.add_instance_attribute('accessor', 'ns3::Ptr< ns3::TraceSourceAccessor const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::help [variable]
+ cls.add_instance_attribute('help', 'std::string', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::name [variable]
+ cls.add_instance_attribute('name', 'std::string', is_const=False)
+ return
+
+def register_Ns3Empty_methods(root_module, cls):
+ ## empty.h (module 'core'): ns3::empty::empty() [constructor]
+ cls.add_constructor([])
+ ## empty.h (module 'core'): ns3::empty::empty(ns3::empty const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::empty const &', 'arg0')])
+ return
+
+def register_Ns3Int64x64_t_methods(root_module, cls):
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_unary_numeric_operator('-')
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('>')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('<=')
+ cls.add_binary_comparison_operator('==')
+ cls.add_binary_comparison_operator('>=')
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t() [constructor]
+ cls.add_constructor([])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(double v) [constructor]
+ cls.add_constructor([param('double', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(int v) [constructor]
+ cls.add_constructor([param('int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long int v) [constructor]
+ cls.add_constructor([param('long int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long long int v) [constructor]
+ cls.add_constructor([param('long long int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(unsigned int v) [constructor]
+ cls.add_constructor([param('unsigned int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long unsigned int v) [constructor]
+ cls.add_constructor([param('long unsigned int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long long unsigned int v) [constructor]
+ cls.add_constructor([param('long long unsigned int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(int64_t hi, uint64_t lo) [constructor]
+ cls.add_constructor([param('int64_t', 'hi'), param('uint64_t', 'lo')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(ns3::int64x64_t const & o) [copy constructor]
+ cls.add_constructor([param('ns3::int64x64_t const &', 'o')])
+ ## int64x64-double.h (module 'core'): double ns3::int64x64_t::GetDouble() const [member function]
+ cls.add_method('GetDouble',
+ 'double',
+ [],
+ is_const=True)
+ ## int64x64-double.h (module 'core'): int64_t ns3::int64x64_t::GetHigh() const [member function]
+ cls.add_method('GetHigh',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## int64x64-double.h (module 'core'): uint64_t ns3::int64x64_t::GetLow() const [member function]
+ cls.add_method('GetLow',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## int64x64-double.h (module 'core'): static ns3::int64x64_t ns3::int64x64_t::Invert(uint64_t v) [member function]
+ cls.add_method('Invert',
+ 'ns3::int64x64_t',
+ [param('uint64_t', 'v')],
+ is_static=True)
+ ## int64x64-double.h (module 'core'): void ns3::int64x64_t::MulByInvert(ns3::int64x64_t const & o) [member function]
+ cls.add_method('MulByInvert',
+ 'void',
+ [param('ns3::int64x64_t const &', 'o')])
+ return
+
+def register_Ns3Chunk_methods(root_module, cls):
+ ## chunk.h (module 'network'): ns3::Chunk::Chunk() [constructor]
+ cls.add_constructor([])
+ ## chunk.h (module 'network'): ns3::Chunk::Chunk(ns3::Chunk const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Chunk const &', 'arg0')])
+ ## chunk.h (module 'network'): uint32_t ns3::Chunk::Deserialize(ns3::Buffer::Iterator start) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_virtual=True)
+ ## chunk.h (module 'network'): static ns3::TypeId ns3::Chunk::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## chunk.h (module 'network'): void ns3::Chunk::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3FdNetDeviceHelper_methods(root_module, cls):
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::FdNetDeviceHelper::FdNetDeviceHelper(ns3::FdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::FdNetDeviceHelper const &', 'arg0')])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::FdNetDeviceHelper::FdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::NetDeviceContainer ns3::FdNetDeviceHelper::Install(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('Install',
+ 'ns3::NetDeviceContainer',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::NetDeviceContainer ns3::FdNetDeviceHelper::Install(std::string name) const [member function]
+ cls.add_method('Install',
+ 'ns3::NetDeviceContainer',
+ [param('std::string', 'name')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::NetDeviceContainer ns3::FdNetDeviceHelper::Install(ns3::NodeContainer const & c) const [member function]
+ cls.add_method('Install',
+ 'ns3::NetDeviceContainer',
+ [param('ns3::NodeContainer const &', 'c')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): void ns3::FdNetDeviceHelper::SetAttribute(std::string n1, ns3::AttributeValue const & v1) [member function]
+ cls.add_method('SetAttribute',
+ 'void',
+ [param('std::string', 'n1'), param('ns3::AttributeValue const &', 'v1')])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::FdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): void ns3::FdNetDeviceHelper::EnableAsciiInternal(ns3::Ptr<ns3::OutputStreamWrapper> stream, std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool explicitFilename) [member function]
+ cls.add_method('EnableAsciiInternal',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'explicitFilename')],
+ visibility='private', is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): void ns3::FdNetDeviceHelper::EnablePcapInternal(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool promiscuous, bool explicitFilename) [member function]
+ cls.add_method('EnablePcapInternal',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'promiscuous'), param('bool', 'explicitFilename')],
+ visibility='private', is_virtual=True)
+ return
+
+def register_Ns3Header_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## header.h (module 'network'): ns3::Header::Header() [constructor]
+ cls.add_constructor([])
+ ## header.h (module 'network'): ns3::Header::Header(ns3::Header const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Header const &', 'arg0')])
+ ## header.h (module 'network'): uint32_t ns3::Header::Deserialize(ns3::Buffer::Iterator start) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_virtual=True)
+ ## header.h (module 'network'): uint32_t ns3::Header::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## header.h (module 'network'): static ns3::TypeId ns3::Header::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## header.h (module 'network'): void ns3::Header::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## header.h (module 'network'): void ns3::Header::Serialize(ns3::Buffer::Iterator start) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3Object_methods(root_module, cls):
+ ## object.h (module 'core'): ns3::Object::Object() [constructor]
+ cls.add_constructor([])
+ ## object.h (module 'core'): void ns3::Object::AggregateObject(ns3::Ptr<ns3::Object> other) [member function]
+ cls.add_method('AggregateObject',
+ 'void',
+ [param('ns3::Ptr< ns3::Object >', 'other')])
+ ## object.h (module 'core'): void ns3::Object::Dispose() [member function]
+ cls.add_method('Dispose',
+ 'void',
+ [])
+ ## object.h (module 'core'): ns3::Object::AggregateIterator ns3::Object::GetAggregateIterator() const [member function]
+ cls.add_method('GetAggregateIterator',
+ 'ns3::Object::AggregateIterator',
+ [],
+ is_const=True)
+ ## object.h (module 'core'): ns3::TypeId ns3::Object::GetInstanceTypeId() const [member function]
+ cls.add_method('GetInstanceTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True, is_virtual=True)
+ ## object.h (module 'core'): static ns3::TypeId ns3::Object::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## object.h (module 'core'): void ns3::Object::Start() [member function]
+ cls.add_method('Start',
+ 'void',
+ [])
+ ## object.h (module 'core'): ns3::Object::Object(ns3::Object const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Object const &', 'o')],
+ visibility='protected')
+ ## object.h (module 'core'): void ns3::Object::DoDispose() [member function]
+ cls.add_method('DoDispose',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ ## object.h (module 'core'): void ns3::Object::DoStart() [member function]
+ cls.add_method('DoStart',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ ## object.h (module 'core'): void ns3::Object::NotifyNewAggregate() [member function]
+ cls.add_method('NotifyNewAggregate',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3ObjectAggregateIterator_methods(root_module, cls):
+ ## object.h (module 'core'): ns3::Object::AggregateIterator::AggregateIterator(ns3::Object::AggregateIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Object::AggregateIterator const &', 'arg0')])
+ ## object.h (module 'core'): ns3::Object::AggregateIterator::AggregateIterator() [constructor]
+ cls.add_constructor([])
+ ## object.h (module 'core'): bool ns3::Object::AggregateIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## object.h (module 'core'): ns3::Ptr<ns3::Object const> ns3::Object::AggregateIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::Ptr< ns3::Object const >',
+ [])
+ return
+
+def register_Ns3PcapFileWrapper_methods(root_module, cls):
+ ## pcap-file-wrapper.h (module 'network'): static ns3::TypeId ns3::PcapFileWrapper::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## pcap-file-wrapper.h (module 'network'): ns3::PcapFileWrapper::PcapFileWrapper() [constructor]
+ cls.add_constructor([])
+ ## pcap-file-wrapper.h (module 'network'): bool ns3::PcapFileWrapper::Fail() const [member function]
+ cls.add_method('Fail',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file-wrapper.h (module 'network'): bool ns3::PcapFileWrapper::Eof() const [member function]
+ cls.add_method('Eof',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Clear() [member function]
+ cls.add_method('Clear',
+ 'void',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Open(std::string const & filename, std::_Ios_Openmode mode) [member function]
+ cls.add_method('Open',
+ 'void',
+ [param('std::string const &', 'filename'), param('std::_Ios_Openmode', 'mode')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Close() [member function]
+ cls.add_method('Close',
+ 'void',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Init(uint32_t dataLinkType, uint32_t snapLen=std::numeric_limits<unsigned int>::max(), int32_t tzCorrection=ns3::PcapFile::ZONE_DEFAULT) [member function]
+ cls.add_method('Init',
+ 'void',
+ [param('uint32_t', 'dataLinkType'), param('uint32_t', 'snapLen', default_value='std::numeric_limits<unsigned int>::max()'), param('int32_t', 'tzCorrection', default_value='ns3::PcapFile::ZONE_DEFAULT')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Write(ns3::Time t, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Time', 't'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Write(ns3::Time t, ns3::Header & header, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Time', 't'), param('ns3::Header &', 'header'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Write(ns3::Time t, uint8_t const * buffer, uint32_t length) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Time', 't'), param('uint8_t const *', 'buffer'), param('uint32_t', 'length')])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetMagic() [member function]
+ cls.add_method('GetMagic',
+ 'uint32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint16_t ns3::PcapFileWrapper::GetVersionMajor() [member function]
+ cls.add_method('GetVersionMajor',
+ 'uint16_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint16_t ns3::PcapFileWrapper::GetVersionMinor() [member function]
+ cls.add_method('GetVersionMinor',
+ 'uint16_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): int32_t ns3::PcapFileWrapper::GetTimeZoneOffset() [member function]
+ cls.add_method('GetTimeZoneOffset',
+ 'int32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetSigFigs() [member function]
+ cls.add_method('GetSigFigs',
+ 'uint32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetSnapLen() [member function]
+ cls.add_method('GetSnapLen',
+ 'uint32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetDataLinkType() [member function]
+ cls.add_method('GetDataLinkType',
+ 'uint32_t',
+ [])
+ return
+
+def register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter< ns3::AttributeAccessor > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter< ns3::AttributeChecker > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter< ns3::AttributeValue > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::SimpleRefCount(ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter< ns3::CallbackImplBase > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::SimpleRefCount(ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter< ns3::EventImpl > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3FdReader_Ns3Empty_Ns3DefaultDeleter__lt__ns3FdReader__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >::SimpleRefCount(ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::FdReader, ns3::empty, ns3::DefaultDeleter< ns3::FdReader > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::SimpleRefCount(ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter< ns3::NixVector > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::SimpleRefCount(ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter< ns3::OutputStreamWrapper > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::SimpleRefCount(ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter< ns3::Packet > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3SystemThread_Ns3Empty_Ns3DefaultDeleter__lt__ns3SystemThread__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >::SimpleRefCount(ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::SystemThread, ns3::empty, ns3::DefaultDeleter< ns3::SystemThread > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::SimpleRefCount(ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter< ns3::TraceSourceAccessor > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SystemThread_methods(root_module, cls):
+ ## system-thread.h (module 'core'): ns3::SystemThread::SystemThread(ns3::SystemThread const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::SystemThread const &', 'arg0')])
+ ## system-thread.h (module 'core'): ns3::SystemThread::SystemThread(ns3::Callback<void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [constructor]
+ cls.add_constructor([param('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'callback')])
+ ## system-thread.h (module 'core'): static bool ns3::SystemThread::Equals(pthread_t id) [member function]
+ cls.add_method('Equals',
+ 'bool',
+ [param('pthread_t', 'id')],
+ is_static=True)
+ ## system-thread.h (module 'core'): void ns3::SystemThread::Join() [member function]
+ cls.add_method('Join',
+ 'void',
+ [])
+ ## system-thread.h (module 'core'): static pthread_t ns3::SystemThread::Self() [member function]
+ cls.add_method('Self',
+ 'pthread_t',
+ [],
+ is_static=True)
+ ## system-thread.h (module 'core'): void ns3::SystemThread::Start() [member function]
+ cls.add_method('Start',
+ 'void',
+ [])
+ return
+
+def register_Ns3Time_methods(root_module, cls):
+ cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right'))
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('>')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', 'right'))
+ cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', 'right'))
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('<=')
+ cls.add_binary_comparison_operator('==')
+ cls.add_binary_comparison_operator('>=')
+ ## nstime.h (module 'core'): ns3::Time::Time() [constructor]
+ cls.add_constructor([])
+ ## nstime.h (module 'core'): ns3::Time::Time(ns3::Time const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Time const &', 'o')])
+ ## nstime.h (module 'core'): ns3::Time::Time(double v) [constructor]
+ cls.add_constructor([param('double', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(int v) [constructor]
+ cls.add_constructor([param('int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long int v) [constructor]
+ cls.add_constructor([param('long int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long long int v) [constructor]
+ cls.add_constructor([param('long long int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(unsigned int v) [constructor]
+ cls.add_constructor([param('unsigned int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long unsigned int v) [constructor]
+ cls.add_constructor([param('long unsigned int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long long unsigned int v) [constructor]
+ cls.add_constructor([param('long long unsigned int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(std::string const & s) [constructor]
+ cls.add_constructor([param('std::string const &', 's')])
+ ## nstime.h (module 'core'): ns3::Time::Time(ns3::int64x64_t const & value) [constructor]
+ cls.add_constructor([param('ns3::int64x64_t const &', 'value')])
+ ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function]
+ cls.add_method('Compare',
+ 'int',
+ [param('ns3::Time const &', 'o')],
+ is_const=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & from, ns3::Time::Unit timeUnit) [member function]
+ cls.add_method('From',
+ 'ns3::Time',
+ [param('ns3::int64x64_t const &', 'from'), param('ns3::Time::Unit', 'timeUnit')],
+ is_static=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & value) [member function]
+ cls.add_method('From',
+ 'ns3::Time',
+ [param('ns3::int64x64_t const &', 'value')],
+ is_static=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::FromDouble(double value, ns3::Time::Unit timeUnit) [member function]
+ cls.add_method('FromDouble',
+ 'ns3::Time',
+ [param('double', 'value'), param('ns3::Time::Unit', 'timeUnit')],
+ is_static=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::FromInteger(uint64_t value, ns3::Time::Unit timeUnit) [member function]
+ cls.add_method('FromInteger',
+ 'ns3::Time',
+ [param('uint64_t', 'value'), param('ns3::Time::Unit', 'timeUnit')],
+ is_static=True)
+ ## nstime.h (module 'core'): double ns3::Time::GetDouble() const [member function]
+ cls.add_method('GetDouble',
+ 'double',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetFemtoSeconds() const [member function]
+ cls.add_method('GetFemtoSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetInteger() const [member function]
+ cls.add_method('GetInteger',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetMicroSeconds() const [member function]
+ cls.add_method('GetMicroSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetMilliSeconds() const [member function]
+ cls.add_method('GetMilliSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetNanoSeconds() const [member function]
+ cls.add_method('GetNanoSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetPicoSeconds() const [member function]
+ cls.add_method('GetPicoSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): static ns3::Time::Unit ns3::Time::GetResolution() [member function]
+ cls.add_method('GetResolution',
+ 'ns3::Time::Unit',
+ [],
+ is_static=True)
+ ## nstime.h (module 'core'): double ns3::Time::GetSeconds() const [member function]
+ cls.add_method('GetSeconds',
+ 'double',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetTimeStep() const [member function]
+ cls.add_method('GetTimeStep',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsNegative() const [member function]
+ cls.add_method('IsNegative',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsPositive() const [member function]
+ cls.add_method('IsPositive',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsStrictlyNegative() const [member function]
+ cls.add_method('IsStrictlyNegative',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsStrictlyPositive() const [member function]
+ cls.add_method('IsStrictlyPositive',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsZero() const [member function]
+ cls.add_method('IsZero',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): static void ns3::Time::SetResolution(ns3::Time::Unit resolution) [member function]
+ cls.add_method('SetResolution',
+ 'void',
+ [param('ns3::Time::Unit', 'resolution')],
+ is_static=True)
+ ## nstime.h (module 'core'): ns3::int64x64_t ns3::Time::To(ns3::Time::Unit timeUnit) const [member function]
+ cls.add_method('To',
+ 'ns3::int64x64_t',
+ [param('ns3::Time::Unit', 'timeUnit')],
+ is_const=True)
+ ## nstime.h (module 'core'): double ns3::Time::ToDouble(ns3::Time::Unit timeUnit) const [member function]
+ cls.add_method('ToDouble',
+ 'double',
+ [param('ns3::Time::Unit', 'timeUnit')],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::ToInteger(ns3::Time::Unit timeUnit) const [member function]
+ cls.add_method('ToInteger',
+ 'int64_t',
+ [param('ns3::Time::Unit', 'timeUnit')],
+ is_const=True)
+ return
+
+def register_Ns3TraceSourceAccessor_methods(root_module, cls):
+ ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor::TraceSourceAccessor(ns3::TraceSourceAccessor const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TraceSourceAccessor const &', 'arg0')])
+ ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor::TraceSourceAccessor() [constructor]
+ cls.add_constructor([])
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::Connect(ns3::ObjectBase * obj, std::string context, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('Connect',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::ConnectWithoutContext(ns3::ObjectBase * obj, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('ConnectWithoutContext',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::Disconnect(ns3::ObjectBase * obj, std::string context, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('Disconnect',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::DisconnectWithoutContext(ns3::ObjectBase * obj, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('DisconnectWithoutContext',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3Trailer_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## trailer.h (module 'network'): ns3::Trailer::Trailer() [constructor]
+ cls.add_constructor([])
+ ## trailer.h (module 'network'): ns3::Trailer::Trailer(ns3::Trailer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Trailer const &', 'arg0')])
+ ## trailer.h (module 'network'): uint32_t ns3::Trailer::Deserialize(ns3::Buffer::Iterator end) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator', 'end')],
+ is_pure_virtual=True, is_virtual=True)
+ ## trailer.h (module 'network'): uint32_t ns3::Trailer::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trailer.h (module 'network'): static ns3::TypeId ns3::Trailer::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## trailer.h (module 'network'): void ns3::Trailer::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trailer.h (module 'network'): void ns3::Trailer::Serialize(ns3::Buffer::Iterator start) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeAccessor_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::AttributeAccessor::AttributeAccessor(ns3::AttributeAccessor const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeAccessor const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::AttributeAccessor::AttributeAccessor() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::Get(ns3::ObjectBase const * object, ns3::AttributeValue & attribute) const [member function]
+ cls.add_method('Get',
+ 'bool',
+ [param('ns3::ObjectBase const *', 'object'), param('ns3::AttributeValue &', 'attribute')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::HasGetter() const [member function]
+ cls.add_method('HasGetter',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::HasSetter() const [member function]
+ cls.add_method('HasSetter',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::Set(ns3::ObjectBase * object, ns3::AttributeValue const & value) const [member function]
+ cls.add_method('Set',
+ 'bool',
+ [param('ns3::ObjectBase *', 'object', transfer_ownership=False), param('ns3::AttributeValue const &', 'value')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeChecker_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::AttributeChecker::AttributeChecker(ns3::AttributeChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeChecker const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::AttributeChecker::AttributeChecker() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): bool ns3::AttributeChecker::Check(ns3::AttributeValue const & value) const [member function]
+ cls.add_method('Check',
+ 'bool',
+ [param('ns3::AttributeValue const &', 'value')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeChecker::Copy(ns3::AttributeValue const & source, ns3::AttributeValue & destination) const [member function]
+ cls.add_method('Copy',
+ 'bool',
+ [param('ns3::AttributeValue const &', 'source'), param('ns3::AttributeValue &', 'destination')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeChecker::Create() const [member function]
+ cls.add_method('Create',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeChecker::CreateValidValue(ns3::AttributeValue const & value) const [member function]
+ cls.add_method('CreateValidValue',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [param('ns3::AttributeValue const &', 'value')],
+ is_const=True)
+ ## attribute.h (module 'core'): std::string ns3::AttributeChecker::GetUnderlyingTypeInformation() const [member function]
+ cls.add_method('GetUnderlyingTypeInformation',
+ 'std::string',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): std::string ns3::AttributeChecker::GetValueTypeName() const [member function]
+ cls.add_method('GetValueTypeName',
+ 'std::string',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeChecker::HasUnderlyingTypeInformation() const [member function]
+ cls.add_method('HasUnderlyingTypeInformation',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeValue_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::AttributeValue::AttributeValue(ns3::AttributeValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeValue const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::AttributeValue::AttributeValue() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_pure_virtual=True, is_virtual=True)
+ ## attribute.h (module 'core'): std::string ns3::AttributeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3CallbackChecker_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackChecker::CallbackChecker() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::CallbackChecker::CallbackChecker(ns3::CallbackChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackChecker const &', 'arg0')])
+ return
+
+def register_Ns3CallbackImplBase_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackImplBase::CallbackImplBase() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::CallbackImplBase::CallbackImplBase(ns3::CallbackImplBase const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackImplBase const &', 'arg0')])
+ ## callback.h (module 'core'): bool ns3::CallbackImplBase::IsEqual(ns3::Ptr<ns3::CallbackImplBase const> other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ptr< ns3::CallbackImplBase const >', 'other')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3CallbackValue_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue(ns3::CallbackValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackValue const &', 'arg0')])
+ ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue(ns3::CallbackBase const & base) [constructor]
+ cls.add_constructor([param('ns3::CallbackBase const &', 'base')])
+ ## callback.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::CallbackValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## callback.h (module 'core'): bool ns3::CallbackValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## callback.h (module 'core'): std::string ns3::CallbackValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## callback.h (module 'core'): void ns3::CallbackValue::Set(ns3::CallbackBase base) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::CallbackBase', 'base')])
+ return
+
+def register_Ns3DataRateChecker_methods(root_module, cls):
+ ## data-rate.h (module 'network'): ns3::DataRateChecker::DataRateChecker() [constructor]
+ cls.add_constructor([])
+ ## data-rate.h (module 'network'): ns3::DataRateChecker::DataRateChecker(ns3::DataRateChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::DataRateChecker const &', 'arg0')])
+ return
+
+def register_Ns3DataRateValue_methods(root_module, cls):
+ ## data-rate.h (module 'network'): ns3::DataRateValue::DataRateValue() [constructor]
+ cls.add_constructor([])
+ ## data-rate.h (module 'network'): ns3::DataRateValue::DataRateValue(ns3::DataRateValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::DataRateValue const &', 'arg0')])
+ ## data-rate.h (module 'network'): ns3::DataRateValue::DataRateValue(ns3::DataRate const & value) [constructor]
+ cls.add_constructor([param('ns3::DataRate const &', 'value')])
+ ## data-rate.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::DataRateValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## data-rate.h (module 'network'): bool ns3::DataRateValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## data-rate.h (module 'network'): ns3::DataRate ns3::DataRateValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::DataRate',
+ [],
+ is_const=True)
+ ## data-rate.h (module 'network'): std::string ns3::DataRateValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## data-rate.h (module 'network'): void ns3::DataRateValue::Set(ns3::DataRate const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::DataRate const &', 'value')])
+ return
+
+def register_Ns3EmptyAttributeValue_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::EmptyAttributeValue::EmptyAttributeValue(ns3::EmptyAttributeValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EmptyAttributeValue const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::EmptyAttributeValue::EmptyAttributeValue() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::EmptyAttributeValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, visibility='private', is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::EmptyAttributeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ visibility='private', is_virtual=True)
+ ## attribute.h (module 'core'): std::string ns3::EmptyAttributeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, visibility='private', is_virtual=True)
+ return
+
+def register_Ns3EmuFdNetDeviceHelper_methods(root_module, cls):
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::EmuFdNetDeviceHelper::EmuFdNetDeviceHelper(ns3::EmuFdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EmuFdNetDeviceHelper const &', 'arg0')])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::EmuFdNetDeviceHelper::EmuFdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): std::string ns3::EmuFdNetDeviceHelper::GetDeviceName() [member function]
+ cls.add_method('GetDeviceName',
+ 'std::string',
+ [])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): void ns3::EmuFdNetDeviceHelper::SetDeviceName(std::string deviceName) [member function]
+ cls.add_method('SetDeviceName',
+ 'void',
+ [param('std::string', 'deviceName')])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): int ns3::EmuFdNetDeviceHelper::CreateFileDescriptor() const [member function]
+ cls.add_method('CreateFileDescriptor',
+ 'int',
+ [],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::EmuFdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): void ns3::EmuFdNetDeviceHelper::SetFileDescriptor(ns3::Ptr<ns3::FdNetDevice> device) const [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('ns3::Ptr< ns3::FdNetDevice >', 'device')],
+ is_const=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3EventImpl_methods(root_module, cls):
+ ## event-impl.h (module 'core'): ns3::EventImpl::EventImpl(ns3::EventImpl const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EventImpl const &', 'arg0')])
+ ## event-impl.h (module 'core'): ns3::EventImpl::EventImpl() [constructor]
+ cls.add_constructor([])
+ ## event-impl.h (module 'core'): void ns3::EventImpl::Cancel() [member function]
+ cls.add_method('Cancel',
+ 'void',
+ [])
+ ## event-impl.h (module 'core'): void ns3::EventImpl::Invoke() [member function]
+ cls.add_method('Invoke',
+ 'void',
+ [])
+ ## event-impl.h (module 'core'): bool ns3::EventImpl::IsCancelled() [member function]
+ cls.add_method('IsCancelled',
+ 'bool',
+ [])
+ ## event-impl.h (module 'core'): void ns3::EventImpl::Notify() [member function]
+ cls.add_method('Notify',
+ 'void',
+ [],
+ is_pure_virtual=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3FdReader_methods(root_module, cls):
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader::FdReader(ns3::FdReader const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::FdReader const &', 'arg0')])
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader::FdReader() [constructor]
+ cls.add_constructor([])
+ ## unix-fd-reader.h (module 'core'): void ns3::FdReader::Start(int fd, ns3::Callback<void, unsigned char*, int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> readCallback) [member function]
+ cls.add_method('Start',
+ 'void',
+ [param('int', 'fd'), param('ns3::Callback< void, unsigned char *, int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'readCallback')])
+ ## unix-fd-reader.h (module 'core'): void ns3::FdReader::Stop() [member function]
+ cls.add_method('Stop',
+ 'void',
+ [])
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader::Data ns3::FdReader::DoRead() [member function]
+ cls.add_method('DoRead',
+ 'ns3::FdReader::Data',
+ [],
+ is_pure_virtual=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3Ipv4AddressChecker_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker::Ipv4AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker::Ipv4AddressChecker(ns3::Ipv4AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv4AddressValue_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue(ns3::Ipv4AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4AddressValue const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue(ns3::Ipv4Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv4Address const &', 'value')])
+ ## ipv4-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv4AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv4Address',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): std::string ns3::Ipv4AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4AddressValue::Set(ns3::Ipv4Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv4Address const &', 'value')])
+ return
+
+def register_Ns3Ipv4MaskChecker_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker::Ipv4MaskChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker::Ipv4MaskChecker(ns3::Ipv4MaskChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4MaskChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv4MaskValue_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue(ns3::Ipv4MaskValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4MaskValue const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue(ns3::Ipv4Mask const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv4Mask const &', 'value')])
+ ## ipv4-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv4MaskValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4MaskValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask ns3::Ipv4MaskValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv4Mask',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): std::string ns3::Ipv4MaskValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4MaskValue::Set(ns3::Ipv4Mask const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv4Mask const &', 'value')])
+ return
+
+def register_Ns3Ipv6AddressChecker_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker(ns3::Ipv6AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv6AddressValue_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue(ns3::Ipv6AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6AddressValue const &', 'arg0')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue(ns3::Ipv6Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Address const &', 'value')])
+ ## ipv6-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv6AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address ns3::Ipv6AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv6Address',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): std::string ns3::Ipv6AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6AddressValue::Set(ns3::Ipv6Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv6Address const &', 'value')])
+ return
+
+def register_Ns3Ipv6PrefixChecker_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker(ns3::Ipv6PrefixChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6PrefixChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv6PrefixValue_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue(ns3::Ipv6PrefixValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6PrefixValue const &', 'arg0')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue(ns3::Ipv6Prefix const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Prefix const &', 'value')])
+ ## ipv6-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv6PrefixValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6PrefixValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix ns3::Ipv6PrefixValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): std::string ns3::Ipv6PrefixValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6PrefixValue::Set(ns3::Ipv6Prefix const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv6Prefix const &', 'value')])
+ return
+
+def register_Ns3Mac48AddressChecker_methods(root_module, cls):
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker::Mac48AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker::Mac48AddressChecker(ns3::Mac48AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Mac48AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3Mac48AddressValue_methods(root_module, cls):
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue() [constructor]
+ cls.add_constructor([])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue(ns3::Mac48AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Mac48AddressValue const &', 'arg0')])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue(ns3::Mac48Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Mac48Address const &', 'value')])
+ ## mac48-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Mac48AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## mac48-address.h (module 'network'): bool ns3::Mac48AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## mac48-address.h (module 'network'): ns3::Mac48Address ns3::Mac48AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Mac48Address',
+ [],
+ is_const=True)
+ ## mac48-address.h (module 'network'): std::string ns3::Mac48AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## mac48-address.h (module 'network'): void ns3::Mac48AddressValue::Set(ns3::Mac48Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Mac48Address const &', 'value')])
+ return
+
+def register_Ns3NetDevice_methods(root_module, cls):
+ ## net-device.h (module 'network'): ns3::NetDevice::NetDevice() [constructor]
+ cls.add_constructor([])
+ ## net-device.h (module 'network'): ns3::NetDevice::NetDevice(ns3::NetDevice const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::NetDevice const &', 'arg0')])
+ ## net-device.h (module 'network'): void ns3::NetDevice::AddLinkChangeCallback(ns3::Callback<void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [member function]
+ cls.add_method('AddLinkChangeCallback',
+ 'void',
+ [param('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'callback')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetAddress() const [member function]
+ cls.add_method('GetAddress',
+ 'ns3::Address',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetBroadcast() const [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Address',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Ptr<ns3::Channel> ns3::NetDevice::GetChannel() const [member function]
+ cls.add_method('GetChannel',
+ 'ns3::Ptr< ns3::Channel >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): uint32_t ns3::NetDevice::GetIfIndex() const [member function]
+ cls.add_method('GetIfIndex',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): uint16_t ns3::NetDevice::GetMtu() const [member function]
+ cls.add_method('GetMtu',
+ 'uint16_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetMulticast(ns3::Ipv4Address multicastGroup) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv4Address', 'multicastGroup')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetMulticast(ns3::Ipv6Address addr) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv6Address', 'addr')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Ptr<ns3::Node> ns3::NetDevice::GetNode() const [member function]
+ cls.add_method('GetNode',
+ 'ns3::Ptr< ns3::Node >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): static ns3::TypeId ns3::NetDevice::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsBridge() const [member function]
+ cls.add_method('IsBridge',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsLinkUp() const [member function]
+ cls.add_method('IsLinkUp',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsPointToPoint() const [member function]
+ cls.add_method('IsPointToPoint',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::NeedsArp() const [member function]
+ cls.add_method('NeedsArp',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::Send(ns3::Ptr<ns3::Packet> packet, ns3::Address const & dest, uint16_t protocolNumber) [member function]
+ cls.add_method('Send',
+ 'bool',
+ [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::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 const &', 'source'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetAddress(ns3::Address address) [member function]
+ cls.add_method('SetAddress',
+ 'void',
+ [param('ns3::Address', 'address')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetIfIndex(uint32_t const index) [member function]
+ cls.add_method('SetIfIndex',
+ 'void',
+ [param('uint32_t const', 'index')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::SetMtu(uint16_t const mtu) [member function]
+ cls.add_method('SetMtu',
+ 'bool',
+ [param('uint16_t const', 'mtu')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetNode(ns3::Ptr<ns3::Node> node) [member function]
+ cls.add_method('SetNode',
+ 'void',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetPromiscReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetPromiscReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::SupportsSendFrom() const [member function]
+ cls.add_method('SupportsSendFrom',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3NixVector_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## nix-vector.h (module 'network'): ns3::NixVector::NixVector() [constructor]
+ cls.add_constructor([])
+ ## nix-vector.h (module 'network'): ns3::NixVector::NixVector(ns3::NixVector const & o) [copy constructor]
+ cls.add_constructor([param('ns3::NixVector const &', 'o')])
+ ## nix-vector.h (module 'network'): void ns3::NixVector::AddNeighborIndex(uint32_t newBits, uint32_t numberOfBits) [member function]
+ cls.add_method('AddNeighborIndex',
+ 'void',
+ [param('uint32_t', 'newBits'), param('uint32_t', 'numberOfBits')])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::BitCount(uint32_t numberOfNeighbors) const [member function]
+ cls.add_method('BitCount',
+ 'uint32_t',
+ [param('uint32_t', 'numberOfNeighbors')],
+ is_const=True)
+ ## nix-vector.h (module 'network'): ns3::Ptr<ns3::NixVector> ns3::NixVector::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::NixVector >',
+ [],
+ is_const=True)
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::Deserialize(uint32_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('uint32_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::ExtractNeighborIndex(uint32_t numberOfBits) [member function]
+ cls.add_method('ExtractNeighborIndex',
+ 'uint32_t',
+ [param('uint32_t', 'numberOfBits')])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::GetRemainingBits() [member function]
+ cls.add_method('GetRemainingBits',
+ 'uint32_t',
+ [])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::Serialize(uint32_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint32_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ return
+
+def register_Ns3Node_methods(root_module, cls):
+ ## node.h (module 'network'): ns3::Node::Node(ns3::Node const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Node const &', 'arg0')])
+ ## node.h (module 'network'): ns3::Node::Node() [constructor]
+ cls.add_constructor([])
+ ## node.h (module 'network'): ns3::Node::Node(uint32_t systemId) [constructor]
+ cls.add_constructor([param('uint32_t', 'systemId')])
+ ## node.h (module 'network'): uint32_t ns3::Node::AddApplication(ns3::Ptr<ns3::Application> application) [member function]
+ cls.add_method('AddApplication',
+ 'uint32_t',
+ [param('ns3::Ptr< ns3::Application >', 'application')])
+ ## node.h (module 'network'): uint32_t ns3::Node::AddDevice(ns3::Ptr<ns3::NetDevice> device) [member function]
+ cls.add_method('AddDevice',
+ 'uint32_t',
+ [param('ns3::Ptr< ns3::NetDevice >', 'device')])
+ ## node.h (module 'network'): static bool ns3::Node::ChecksumEnabled() [member function]
+ cls.add_method('ChecksumEnabled',
+ 'bool',
+ [],
+ is_static=True)
+ ## node.h (module 'network'): ns3::Ptr<ns3::Application> ns3::Node::GetApplication(uint32_t index) const [member function]
+ cls.add_method('GetApplication',
+ 'ns3::Ptr< ns3::Application >',
+ [param('uint32_t', 'index')],
+ is_const=True)
+ ## node.h (module 'network'): ns3::Ptr<ns3::NetDevice> ns3::Node::GetDevice(uint32_t index) const [member function]
+ cls.add_method('GetDevice',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('uint32_t', 'index')],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetId() const [member function]
+ cls.add_method('GetId',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetNApplications() const [member function]
+ cls.add_method('GetNApplications',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetNDevices() const [member function]
+ cls.add_method('GetNDevices',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetSystemId() const [member function]
+ cls.add_method('GetSystemId',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): static ns3::TypeId ns3::Node::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## node.h (module 'network'): void ns3::Node::RegisterDeviceAdditionListener(ns3::Callback<void,ns3::Ptr<ns3::NetDevice>,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> listener) [member function]
+ cls.add_method('RegisterDeviceAdditionListener',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'listener')])
+ ## node.h (module 'network'): void ns3::Node::RegisterProtocolHandler(ns3::Callback<void, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler, uint16_t protocolType, ns3::Ptr<ns3::NetDevice> device, bool promiscuous=false) [member function]
+ cls.add_method('RegisterProtocolHandler',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'handler'), param('uint16_t', 'protocolType'), param('ns3::Ptr< ns3::NetDevice >', 'device'), param('bool', 'promiscuous', default_value='false')])
+ ## node.h (module 'network'): void ns3::Node::UnregisterDeviceAdditionListener(ns3::Callback<void,ns3::Ptr<ns3::NetDevice>,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> listener) [member function]
+ cls.add_method('UnregisterDeviceAdditionListener',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'listener')])
+ ## node.h (module 'network'): void ns3::Node::UnregisterProtocolHandler(ns3::Callback<void, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler) [member function]
+ cls.add_method('UnregisterProtocolHandler',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'handler')])
+ ## node.h (module 'network'): void ns3::Node::DoDispose() [member function]
+ cls.add_method('DoDispose',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ ## node.h (module 'network'): void ns3::Node::DoStart() [member function]
+ cls.add_method('DoStart',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3ObjectFactoryChecker_methods(root_module, cls):
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker::ObjectFactoryChecker() [constructor]
+ cls.add_constructor([])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker::ObjectFactoryChecker(ns3::ObjectFactoryChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectFactoryChecker const &', 'arg0')])
+ return
+
+def register_Ns3ObjectFactoryValue_methods(root_module, cls):
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue() [constructor]
+ cls.add_constructor([])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue(ns3::ObjectFactoryValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectFactoryValue const &', 'arg0')])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue(ns3::ObjectFactory const & value) [constructor]
+ cls.add_constructor([param('ns3::ObjectFactory const &', 'value')])
+ ## object-factory.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::ObjectFactoryValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## object-factory.h (module 'core'): bool ns3::ObjectFactoryValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## object-factory.h (module 'core'): ns3::ObjectFactory ns3::ObjectFactoryValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::ObjectFactory',
+ [],
+ is_const=True)
+ ## object-factory.h (module 'core'): std::string ns3::ObjectFactoryValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## object-factory.h (module 'core'): void ns3::ObjectFactoryValue::Set(ns3::ObjectFactory const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::ObjectFactory const &', 'value')])
+ return
+
+def register_Ns3OutputStreamWrapper_methods(root_module, cls):
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(ns3::OutputStreamWrapper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::OutputStreamWrapper const &', 'arg0')])
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(std::string filename, std::_Ios_Openmode filemode) [constructor]
+ cls.add_constructor([param('std::string', 'filename'), param('std::_Ios_Openmode', 'filemode')])
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(std::ostream * os) [constructor]
+ cls.add_constructor([param('std::ostream *', 'os')])
+ ## output-stream-wrapper.h (module 'network'): std::ostream * ns3::OutputStreamWrapper::GetStream() [member function]
+ cls.add_method('GetStream',
+ 'std::ostream *',
+ [])
+ return
+
+def register_Ns3Packet_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## packet.h (module 'network'): ns3::Packet::Packet() [constructor]
+ cls.add_constructor([])
+ ## packet.h (module 'network'): ns3::Packet::Packet(ns3::Packet const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Packet const &', 'o')])
+ ## packet.h (module 'network'): ns3::Packet::Packet(uint32_t size) [constructor]
+ cls.add_constructor([param('uint32_t', 'size')])
+ ## packet.h (module 'network'): ns3::Packet::Packet(uint8_t const * buffer, uint32_t size, bool magic) [constructor]
+ cls.add_constructor([param('uint8_t const *', 'buffer'), param('uint32_t', 'size'), param('bool', 'magic')])
+ ## packet.h (module 'network'): ns3::Packet::Packet(uint8_t const * buffer, uint32_t size) [constructor]
+ cls.add_constructor([param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## packet.h (module 'network'): void ns3::Packet::AddAtEnd(ns3::Ptr<const ns3::Packet> packet) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('ns3::Ptr< ns3::Packet const >', 'packet')])
+ ## packet.h (module 'network'): void ns3::Packet::AddByteTag(ns3::Tag const & tag) const [member function]
+ cls.add_method('AddByteTag',
+ 'void',
+ [param('ns3::Tag const &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::AddHeader(ns3::Header const & header) [member function]
+ cls.add_method('AddHeader',
+ 'void',
+ [param('ns3::Header const &', 'header')])
+ ## packet.h (module 'network'): void ns3::Packet::AddPacketTag(ns3::Tag const & tag) const [member function]
+ cls.add_method('AddPacketTag',
+ 'void',
+ [param('ns3::Tag const &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::AddPaddingAtEnd(uint32_t size) [member function]
+ cls.add_method('AddPaddingAtEnd',
+ 'void',
+ [param('uint32_t', 'size')])
+ ## packet.h (module 'network'): void ns3::Packet::AddTrailer(ns3::Trailer const & trailer) [member function]
+ cls.add_method('AddTrailer',
+ 'void',
+ [param('ns3::Trailer const &', 'trailer')])
+ ## packet.h (module 'network'): ns3::PacketMetadata::ItemIterator ns3::Packet::BeginItem() const [member function]
+ cls.add_method('BeginItem',
+ 'ns3::PacketMetadata::ItemIterator',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Packet::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::Packet >',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::CopyData(uint8_t * buffer, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::CopyData(std::ostream * os, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'void',
+ [param('std::ostream *', 'os'), param('uint32_t', 'size')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Packet::CreateFragment(uint32_t start, uint32_t length) const [member function]
+ cls.add_method('CreateFragment',
+ 'ns3::Ptr< ns3::Packet >',
+ [param('uint32_t', 'start'), param('uint32_t', 'length')],
+ is_const=True)
+ ## packet.h (module 'network'): static void ns3::Packet::EnableChecking() [member function]
+ cls.add_method('EnableChecking',
+ 'void',
+ [],
+ is_static=True)
+ ## packet.h (module 'network'): static void ns3::Packet::EnablePrinting() [member function]
+ cls.add_method('EnablePrinting',
+ 'void',
+ [],
+ is_static=True)
+ ## packet.h (module 'network'): bool ns3::Packet::FindFirstMatchingByteTag(ns3::Tag & tag) const [member function]
+ cls.add_method('FindFirstMatchingByteTag',
+ 'bool',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::ByteTagIterator ns3::Packet::GetByteTagIterator() const [member function]
+ cls.add_method('GetByteTagIterator',
+ 'ns3::ByteTagIterator',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::Ptr<ns3::NixVector> ns3::Packet::GetNixVector() const [member function]
+ cls.add_method('GetNixVector',
+ 'ns3::Ptr< ns3::NixVector >',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::PacketTagIterator ns3::Packet::GetPacketTagIterator() const [member function]
+ cls.add_method('GetPacketTagIterator',
+ 'ns3::PacketTagIterator',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::GetSize() const [member function]
+ cls.add_method('GetSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint64_t ns3::Packet::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint8_t const * ns3::Packet::PeekData() const [member function]
+ cls.add_method('PeekData',
+ 'uint8_t const *',
+ [],
+ deprecated=True, is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::PeekHeader(ns3::Header & header) const [member function]
+ cls.add_method('PeekHeader',
+ 'uint32_t',
+ [param('ns3::Header &', 'header')],
+ is_const=True)
+ ## packet.h (module 'network'): bool ns3::Packet::PeekPacketTag(ns3::Tag & tag) const [member function]
+ cls.add_method('PeekPacketTag',
+ 'bool',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::PeekTrailer(ns3::Trailer & trailer) [member function]
+ cls.add_method('PeekTrailer',
+ 'uint32_t',
+ [param('ns3::Trailer &', 'trailer')])
+ ## packet.h (module 'network'): void ns3::Packet::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::PrintByteTags(std::ostream & os) const [member function]
+ cls.add_method('PrintByteTags',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::PrintPacketTags(std::ostream & os) const [member function]
+ cls.add_method('PrintPacketTags',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAllByteTags() [member function]
+ cls.add_method('RemoveAllByteTags',
+ 'void',
+ [])
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAllPacketTags() [member function]
+ cls.add_method('RemoveAllPacketTags',
+ 'void',
+ [])
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAtEnd(uint32_t size) [member function]
+ cls.add_method('RemoveAtEnd',
+ 'void',
+ [param('uint32_t', 'size')])
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAtStart(uint32_t size) [member function]
+ cls.add_method('RemoveAtStart',
+ 'void',
+ [param('uint32_t', 'size')])
+ ## packet.h (module 'network'): uint32_t ns3::Packet::RemoveHeader(ns3::Header & header) [member function]
+ cls.add_method('RemoveHeader',
+ 'uint32_t',
+ [param('ns3::Header &', 'header')])
+ ## packet.h (module 'network'): bool ns3::Packet::RemovePacketTag(ns3::Tag & tag) [member function]
+ cls.add_method('RemovePacketTag',
+ 'bool',
+ [param('ns3::Tag &', 'tag')])
+ ## packet.h (module 'network'): uint32_t ns3::Packet::RemoveTrailer(ns3::Trailer & trailer) [member function]
+ cls.add_method('RemoveTrailer',
+ 'uint32_t',
+ [param('ns3::Trailer &', 'trailer')])
+ ## packet.h (module 'network'): uint32_t ns3::Packet::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr<ns3::NixVector> arg0) [member function]
+ cls.add_method('SetNixVector',
+ 'void',
+ [param('ns3::Ptr< ns3::NixVector >', 'arg0')])
+ return
+
+def register_Ns3PlanetLabFdNetDeviceHelper_methods(root_module, cls):
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::PlanetLabFdNetDeviceHelper::PlanetLabFdNetDeviceHelper(ns3::PlanetLabFdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PlanetLabFdNetDeviceHelper const &', 'arg0')])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::PlanetLabFdNetDeviceHelper::PlanetLabFdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): void ns3::PlanetLabFdNetDeviceHelper::SetTapIpAddress(ns3::Ipv4Address address) [member function]
+ cls.add_method('SetTapIpAddress',
+ 'void',
+ [param('ns3::Ipv4Address', 'address')])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): void ns3::PlanetLabFdNetDeviceHelper::SetTapMask(ns3::Ipv4Mask mask) [member function]
+ cls.add_method('SetTapMask',
+ 'void',
+ [param('ns3::Ipv4Mask', 'mask')])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): int ns3::PlanetLabFdNetDeviceHelper::CreateFileDescriptor() const [member function]
+ cls.add_method('CreateFileDescriptor',
+ 'int',
+ [],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::PlanetLabFdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): void ns3::PlanetLabFdNetDeviceHelper::SetFileDescriptor(ns3::Ptr<ns3::FdNetDevice> device) const [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('ns3::Ptr< ns3::FdNetDevice >', 'device')],
+ is_const=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3TapFdNetDeviceHelper_methods(root_module, cls):
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::TapFdNetDeviceHelper::TapFdNetDeviceHelper(ns3::TapFdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TapFdNetDeviceHelper const &', 'arg0')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::TapFdNetDeviceHelper::TapFdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetModePi(bool pi) [member function]
+ cls.add_method('SetModePi',
+ 'void',
+ [param('bool', 'pi')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv4Address(ns3::Ipv4Address address) [member function]
+ cls.add_method('SetTapIpv4Address',
+ 'void',
+ [param('ns3::Ipv4Address', 'address')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv4Mask(ns3::Ipv4Mask mask) [member function]
+ cls.add_method('SetTapIpv4Mask',
+ 'void',
+ [param('ns3::Ipv4Mask', 'mask')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv6Address(ns3::Ipv6Address address) [member function]
+ cls.add_method('SetTapIpv6Address',
+ 'void',
+ [param('ns3::Ipv6Address', 'address')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv6Prefix(int prefix) [member function]
+ cls.add_method('SetTapIpv6Prefix',
+ 'void',
+ [param('int', 'prefix')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapMacAddress(ns3::Mac48Address mac) [member function]
+ cls.add_method('SetTapMacAddress',
+ 'void',
+ [param('ns3::Mac48Address', 'mac')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): int ns3::TapFdNetDeviceHelper::CreateFileDescriptor() const [member function]
+ cls.add_method('CreateFileDescriptor',
+ 'int',
+ [],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::TapFdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetFileDescriptor(ns3::Ptr<ns3::FdNetDevice> device) const [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('ns3::Ptr< ns3::FdNetDevice >', 'device')],
+ is_const=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3TimeChecker_methods(root_module, cls):
+ ## nstime.h (module 'core'): ns3::TimeChecker::TimeChecker() [constructor]
+ cls.add_constructor([])
+ ## nstime.h (module 'core'): ns3::TimeChecker::TimeChecker(ns3::TimeChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TimeChecker const &', 'arg0')])
+ return
+
+def register_Ns3TimeValue_methods(root_module, cls):
+ ## nstime.h (module 'core'): ns3::TimeValue::TimeValue() [constructor]
+ cls.add_constructor([])
+ ## nstime.h (module 'core'): ns3::TimeValue::TimeValue(ns3::TimeValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TimeValue const &', 'arg0')])
+ ## nstime.h (module 'core'): ns3::TimeValue::TimeValue(ns3::Time const & value) [constructor]
+ cls.add_constructor([param('ns3::Time const &', 'value')])
+ ## nstime.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::TimeValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## nstime.h (module 'core'): bool ns3::TimeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## nstime.h (module 'core'): ns3::Time ns3::TimeValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Time',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): std::string ns3::TimeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## nstime.h (module 'core'): void ns3::TimeValue::Set(ns3::Time const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Time const &', 'value')])
+ return
+
+def register_Ns3TypeIdChecker_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeIdChecker::TypeIdChecker() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeIdChecker::TypeIdChecker(ns3::TypeIdChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeIdChecker const &', 'arg0')])
+ return
+
+def register_Ns3TypeIdValue_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue(ns3::TypeIdValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeIdValue const &', 'arg0')])
+ ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue(ns3::TypeId const & value) [constructor]
+ cls.add_constructor([param('ns3::TypeId const &', 'value')])
+ ## type-id.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::TypeIdValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## type-id.h (module 'core'): bool ns3::TypeIdValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeIdValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeIdValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## type-id.h (module 'core'): void ns3::TypeIdValue::Set(ns3::TypeId const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::TypeId const &', 'value')])
+ return
+
+def register_Ns3AddressChecker_methods(root_module, cls):
+ ## address.h (module 'network'): ns3::AddressChecker::AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## address.h (module 'network'): ns3::AddressChecker::AddressChecker(ns3::AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3AddressValue_methods(root_module, cls):
+ ## address.h (module 'network'): ns3::AddressValue::AddressValue() [constructor]
+ cls.add_constructor([])
+ ## address.h (module 'network'): ns3::AddressValue::AddressValue(ns3::AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AddressValue const &', 'arg0')])
+ ## address.h (module 'network'): ns3::AddressValue::AddressValue(ns3::Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Address const &', 'value')])
+ ## address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## address.h (module 'network'): bool ns3::AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## address.h (module 'network'): ns3::Address ns3::AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Address',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): std::string ns3::AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## address.h (module 'network'): void ns3::AddressValue::Set(ns3::Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Address const &', 'value')])
+ return
+
+def register_Ns3FdNetDevice_methods(root_module, cls):
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice::FdNetDevice() [constructor]
+ cls.add_constructor([])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::AddLinkChangeCallback(ns3::Callback<void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [member function]
+ cls.add_method('AddLinkChangeCallback',
+ 'void',
+ [param('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'callback')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetAddress() const [member function]
+ cls.add_method('GetAddress',
+ 'ns3::Address',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetBroadcast() const [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Address',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Ptr<ns3::Channel> ns3::FdNetDevice::GetChannel() const [member function]
+ cls.add_method('GetChannel',
+ 'ns3::Ptr< ns3::Channel >',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice::EncapsulationMode ns3::FdNetDevice::GetEncapsulationMode() const [member function]
+ cls.add_method('GetEncapsulationMode',
+ 'ns3::FdNetDevice::EncapsulationMode',
+ [],
+ is_const=True)
+ ## fd-net-device.h (module 'fd-net-device'): uint32_t ns3::FdNetDevice::GetIfIndex() const [member function]
+ cls.add_method('GetIfIndex',
+ 'uint32_t',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): uint16_t ns3::FdNetDevice::GetMtu() const [member function]
+ cls.add_method('GetMtu',
+ 'uint16_t',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetMulticast(ns3::Ipv4Address multicastGroup) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv4Address', 'multicastGroup')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetMulticast(ns3::Ipv6Address addr) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv6Address', 'addr')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Ptr<ns3::Node> ns3::FdNetDevice::GetNode() const [member function]
+ cls.add_method('GetNode',
+ 'ns3::Ptr< ns3::Node >',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): static ns3::TypeId ns3::FdNetDevice::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsBridge() const [member function]
+ cls.add_method('IsBridge',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsLinkUp() const [member function]
+ cls.add_method('IsLinkUp',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsPointToPoint() const [member function]
+ cls.add_method('IsPointToPoint',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::NeedsArp() const [member function]
+ cls.add_method('NeedsArp',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::Send(ns3::Ptr<ns3::Packet> packet, ns3::Address const & dest, uint16_t protocolNumber) [member function]
+ cls.add_method('Send',
+ 'bool',
+ [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::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 const &', 'source'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetAddress(ns3::Address address) [member function]
+ cls.add_method('SetAddress',
+ 'void',
+ [param('ns3::Address', 'address')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetEncapsulationMode(ns3::FdNetDevice::EncapsulationMode mode) [member function]
+ cls.add_method('SetEncapsulationMode',
+ 'void',
+ [param('ns3::FdNetDevice::EncapsulationMode', 'mode')])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetFileDescriptor(int fd) [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('int', 'fd')])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetIfIndex(uint32_t const index) [member function]
+ cls.add_method('SetIfIndex',
+ 'void',
+ [param('uint32_t const', 'index')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetIsBroadcast(bool broadcast) [member function]
+ cls.add_method('SetIsBroadcast',
+ 'void',
+ [param('bool', 'broadcast')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetIsMulticast(bool multicast) [member function]
+ cls.add_method('SetIsMulticast',
+ 'void',
+ [param('bool', 'multicast')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::SetMtu(uint16_t const mtu) [member function]
+ cls.add_method('SetMtu',
+ 'bool',
+ [param('uint16_t const', 'mtu')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetNode(ns3::Ptr<ns3::Node> node) [member function]
+ cls.add_method('SetNode',
+ 'void',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetPromiscReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetPromiscReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::Start(ns3::Time tStart) [member function]
+ cls.add_method('Start',
+ 'void',
+ [param('ns3::Time', 'tStart')])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::Stop(ns3::Time tStop) [member function]
+ cls.add_method('Stop',
+ 'void',
+ [param('ns3::Time', 'tStop')])
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::SupportsSendFrom() const [member function]
+ cls.add_method('SupportsSendFrom',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::DoDispose() [member function]
+ cls.add_method('DoDispose',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3FdNetDeviceFdReader_methods(root_module, cls):
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDeviceFdReader::FdNetDeviceFdReader(ns3::FdNetDeviceFdReader const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::FdNetDeviceFdReader const &', 'arg0')])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDeviceFdReader::FdNetDeviceFdReader() [constructor]
+ cls.add_constructor([])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDeviceFdReader::SetBufferSize(uint32_t bufferSize) [member function]
+ cls.add_method('SetBufferSize',
+ 'void',
+ [param('uint32_t', 'bufferSize')])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdReader::Data ns3::FdNetDeviceFdReader::DoRead() [member function]
+ cls.add_method('DoRead',
+ 'ns3::FdReader::Data',
+ [],
+ visibility='private', is_virtual=True)
+ return
+
+def register_functions(root_module):
+ module = root_module
+ register_functions_ns3_FatalImpl(module.get_submodule('FatalImpl'), root_module)
+ return
+
+def register_functions_ns3_FatalImpl(module, root_module):
+ return
+
+def main():
+ out = FileCodeSink(sys.stdout)
+ root_module = module_init()
+ register_types(root_module)
+ register_methods(root_module)
+ register_functions(root_module)
+ root_module.generate(out)
+
+if __name__ == '__main__':
+ main()
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/bindings/modulegen__gcc_LP64.py Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,4574 @@
+from pybindgen import Module, FileCodeSink, param, retval, cppclass, typehandlers
+
+
+import pybindgen.settings
+import warnings
+
+class ErrorHandler(pybindgen.settings.ErrorHandler):
+ def handle_error(self, wrapper, exception, traceback_):
+ warnings.warn("exception %r in wrapper %s" % (exception, wrapper))
+ return True
+pybindgen.settings.error_handler = ErrorHandler()
+
+
+import sys
+
+def module_init():
+ root_module = Module('ns.fd_net_device', cpp_namespace='::ns3')
+ return root_module
+
+def register_types(module):
+ root_module = module.get_root()
+
+ ## address.h (module 'network'): ns3::Address [class]
+ module.add_class('Address', import_from_module='ns.network')
+ ## address.h (module 'network'): ns3::Address::MaxSize_e [enumeration]
+ module.add_enum('MaxSize_e', ['MAX_SIZE'], outer_class=root_module['ns3::Address'], import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelper [class]
+ module.add_class('AsciiTraceHelper', import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelperForDevice [class]
+ module.add_class('AsciiTraceHelperForDevice', allow_subclassing=True, import_from_module='ns.network')
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList [class]
+ module.add_class('AttributeConstructionList', import_from_module='ns.core')
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item [struct]
+ module.add_class('Item', import_from_module='ns.core', outer_class=root_module['ns3::AttributeConstructionList'])
+ ## buffer.h (module 'network'): ns3::Buffer [class]
+ module.add_class('Buffer', import_from_module='ns.network')
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator [class]
+ module.add_class('Iterator', import_from_module='ns.network', outer_class=root_module['ns3::Buffer'])
+ ## packet.h (module 'network'): ns3::ByteTagIterator [class]
+ module.add_class('ByteTagIterator', import_from_module='ns.network')
+ ## packet.h (module 'network'): ns3::ByteTagIterator::Item [class]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagIterator'])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList [class]
+ module.add_class('ByteTagList', import_from_module='ns.network')
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator [class]
+ module.add_class('Iterator', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagList'])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item [struct]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagList::Iterator'])
+ ## callback.h (module 'core'): ns3::CallbackBase [class]
+ module.add_class('CallbackBase', import_from_module='ns.core')
+ ## system-mutex.h (module 'core'): ns3::CriticalSection [class]
+ module.add_class('CriticalSection', import_from_module='ns.core')
+ ## data-rate.h (module 'network'): ns3::DataRate [class]
+ module.add_class('DataRate', import_from_module='ns.network')
+ ## event-id.h (module 'core'): ns3::EventId [class]
+ module.add_class('EventId', import_from_module='ns.core')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address [class]
+ module.add_class('Ipv4Address', import_from_module='ns.network')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address [class]
+ root_module['ns3::Ipv4Address'].implicitly_converts_to(root_module['ns3::Address'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask [class]
+ module.add_class('Ipv4Mask', import_from_module='ns.network')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address [class]
+ module.add_class('Ipv6Address', import_from_module='ns.network')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address [class]
+ root_module['ns3::Ipv6Address'].implicitly_converts_to(root_module['ns3::Address'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix [class]
+ module.add_class('Ipv6Prefix', import_from_module='ns.network')
+ ## mac48-address.h (module 'network'): ns3::Mac48Address [class]
+ module.add_class('Mac48Address', import_from_module='ns.network')
+ ## mac48-address.h (module 'network'): ns3::Mac48Address [class]
+ root_module['ns3::Mac48Address'].implicitly_converts_to(root_module['ns3::Address'])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer [class]
+ module.add_class('NetDeviceContainer', import_from_module='ns.network')
+ ## node-container.h (module 'network'): ns3::NodeContainer [class]
+ module.add_class('NodeContainer', import_from_module='ns.network')
+ ## object-base.h (module 'core'): ns3::ObjectBase [class]
+ module.add_class('ObjectBase', allow_subclassing=True, import_from_module='ns.core')
+ ## object.h (module 'core'): ns3::ObjectDeleter [struct]
+ module.add_class('ObjectDeleter', import_from_module='ns.core')
+ ## object-factory.h (module 'core'): ns3::ObjectFactory [class]
+ module.add_class('ObjectFactory', import_from_module='ns.core')
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata [class]
+ module.add_class('PacketMetadata', import_from_module='ns.network')
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item [struct]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::PacketMetadata'])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item [enumeration]
+ module.add_enum('', ['PAYLOAD', 'HEADER', 'TRAILER'], outer_class=root_module['ns3::PacketMetadata::Item'], import_from_module='ns.network')
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator [class]
+ module.add_class('ItemIterator', import_from_module='ns.network', outer_class=root_module['ns3::PacketMetadata'])
+ ## packet.h (module 'network'): ns3::PacketTagIterator [class]
+ module.add_class('PacketTagIterator', import_from_module='ns.network')
+ ## packet.h (module 'network'): ns3::PacketTagIterator::Item [class]
+ module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::PacketTagIterator'])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList [class]
+ module.add_class('PacketTagList', import_from_module='ns.network')
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData [struct]
+ module.add_class('TagData', import_from_module='ns.network', outer_class=root_module['ns3::PacketTagList'])
+ ## pcap-file.h (module 'network'): ns3::PcapFile [class]
+ module.add_class('PcapFile', import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::PcapHelper [class]
+ module.add_class('PcapHelper', import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::PcapHelper [enumeration]
+ module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO'], outer_class=root_module['ns3::PcapHelper'], import_from_module='ns.network')
+ ## trace-helper.h (module 'network'): ns3::PcapHelperForDevice [class]
+ module.add_class('PcapHelperForDevice', allow_subclassing=True, import_from_module='ns.network')
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter> [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Object', 'ns3::ObjectBase', 'ns3::ObjectDeleter'], parent=root_module['ns3::ObjectBase'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simulator.h (module 'core'): ns3::Simulator [class]
+ module.add_class('Simulator', destructor_visibility='private', import_from_module='ns.core')
+ ## system-condition.h (module 'core'): ns3::SystemCondition [class]
+ module.add_class('SystemCondition', import_from_module='ns.core')
+ ## system-mutex.h (module 'core'): ns3::SystemMutex [class]
+ module.add_class('SystemMutex', import_from_module='ns.core')
+ ## tag.h (module 'network'): ns3::Tag [class]
+ module.add_class('Tag', import_from_module='ns.network', parent=root_module['ns3::ObjectBase'])
+ ## tag-buffer.h (module 'network'): ns3::TagBuffer [class]
+ module.add_class('TagBuffer', import_from_module='ns.network')
+ ## type-id.h (module 'core'): ns3::TypeId [class]
+ module.add_class('TypeId', import_from_module='ns.core')
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeFlag [enumeration]
+ module.add_enum('AttributeFlag', ['ATTR_GET', 'ATTR_SET', 'ATTR_CONSTRUCT', 'ATTR_SGC'], outer_class=root_module['ns3::TypeId'], import_from_module='ns.core')
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation [struct]
+ module.add_class('AttributeInformation', import_from_module='ns.core', outer_class=root_module['ns3::TypeId'])
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation [struct]
+ module.add_class('TraceSourceInformation', import_from_module='ns.core', outer_class=root_module['ns3::TypeId'])
+ ## empty.h (module 'core'): ns3::empty [class]
+ module.add_class('empty', import_from_module='ns.core')
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t [class]
+ module.add_class('int64x64_t', import_from_module='ns.core')
+ ## chunk.h (module 'network'): ns3::Chunk [class]
+ module.add_class('Chunk', import_from_module='ns.network', parent=root_module['ns3::ObjectBase'])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::FdNetDeviceHelper [class]
+ module.add_class('FdNetDeviceHelper', parent=[root_module['ns3::PcapHelperForDevice'], root_module['ns3::AsciiTraceHelperForDevice']])
+ ## header.h (module 'network'): ns3::Header [class]
+ module.add_class('Header', import_from_module='ns.network', parent=root_module['ns3::Chunk'])
+ ## object.h (module 'core'): ns3::Object [class]
+ module.add_class('Object', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >'])
+ ## object.h (module 'core'): ns3::Object::AggregateIterator [class]
+ module.add_class('AggregateIterator', import_from_module='ns.core', outer_class=root_module['ns3::Object'])
+ ## pcap-file-wrapper.h (module 'network'): ns3::PcapFileWrapper [class]
+ module.add_class('PcapFileWrapper', import_from_module='ns.network', parent=root_module['ns3::Object'])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeAccessor', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeAccessor>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeChecker', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeChecker>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeValue', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeValue>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::CallbackImplBase', 'ns3::empty', 'ns3::DefaultDeleter<ns3::CallbackImplBase>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::EventImpl', 'ns3::empty', 'ns3::DefaultDeleter<ns3::EventImpl>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::FdReader', 'ns3::empty', 'ns3::DefaultDeleter<ns3::FdReader>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::NixVector', 'ns3::empty', 'ns3::DefaultDeleter<ns3::NixVector>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::OutputStreamWrapper', 'ns3::empty', 'ns3::DefaultDeleter<ns3::OutputStreamWrapper>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Packet', 'ns3::empty', 'ns3::DefaultDeleter<ns3::Packet>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::SystemThread', 'ns3::empty', 'ns3::DefaultDeleter<ns3::SystemThread>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> > [class]
+ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::TraceSourceAccessor', 'ns3::empty', 'ns3::DefaultDeleter<ns3::TraceSourceAccessor>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount'))
+ ## system-thread.h (module 'core'): ns3::SystemThread [class]
+ module.add_class('SystemThread', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >'])
+ ## nstime.h (module 'core'): ns3::Time [class]
+ module.add_class('Time', import_from_module='ns.core')
+ ## nstime.h (module 'core'): ns3::Time::Unit [enumeration]
+ module.add_enum('Unit', ['S', 'MS', 'US', 'NS', 'PS', 'FS', 'LAST'], outer_class=root_module['ns3::Time'], import_from_module='ns.core')
+ ## nstime.h (module 'core'): ns3::Time [class]
+ root_module['ns3::Time'].implicitly_converts_to(root_module['ns3::int64x64_t'])
+ ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor [class]
+ module.add_class('TraceSourceAccessor', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >'])
+ ## trailer.h (module 'network'): ns3::Trailer [class]
+ module.add_class('Trailer', import_from_module='ns.network', parent=root_module['ns3::Chunk'])
+ ## attribute.h (module 'core'): ns3::AttributeAccessor [class]
+ module.add_class('AttributeAccessor', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >'])
+ ## attribute.h (module 'core'): ns3::AttributeChecker [class]
+ module.add_class('AttributeChecker', allow_subclassing=False, automatic_type_narrowing=True, import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >'])
+ ## attribute.h (module 'core'): ns3::AttributeValue [class]
+ module.add_class('AttributeValue', allow_subclassing=False, automatic_type_narrowing=True, import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >'])
+ ## callback.h (module 'core'): ns3::CallbackChecker [class]
+ module.add_class('CallbackChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## callback.h (module 'core'): ns3::CallbackImplBase [class]
+ module.add_class('CallbackImplBase', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >'])
+ ## callback.h (module 'core'): ns3::CallbackValue [class]
+ module.add_class('CallbackValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## data-rate.h (module 'network'): ns3::DataRateChecker [class]
+ module.add_class('DataRateChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## data-rate.h (module 'network'): ns3::DataRateValue [class]
+ module.add_class('DataRateValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## attribute.h (module 'core'): ns3::EmptyAttributeValue [class]
+ module.add_class('EmptyAttributeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::EmuFdNetDeviceHelper [class]
+ module.add_class('EmuFdNetDeviceHelper', parent=root_module['ns3::FdNetDeviceHelper'])
+ ## event-impl.h (module 'core'): ns3::EventImpl [class]
+ module.add_class('EventImpl', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >'])
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader [class]
+ module.add_class('FdReader', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class]
+ module.add_class('Ipv4AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue [class]
+ module.add_class('Ipv4AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker [class]
+ module.add_class('Ipv4MaskChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue [class]
+ module.add_class('Ipv4MaskValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker [class]
+ module.add_class('Ipv6AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue [class]
+ module.add_class('Ipv6AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker [class]
+ module.add_class('Ipv6PrefixChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue [class]
+ module.add_class('Ipv6PrefixValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker [class]
+ module.add_class('Mac48AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue [class]
+ module.add_class('Mac48AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## net-device.h (module 'network'): ns3::NetDevice [class]
+ module.add_class('NetDevice', import_from_module='ns.network', parent=root_module['ns3::Object'])
+ ## net-device.h (module 'network'): ns3::NetDevice::PacketType [enumeration]
+ module.add_enum('PacketType', ['PACKET_HOST', 'NS3_PACKET_HOST', 'PACKET_BROADCAST', 'NS3_PACKET_BROADCAST', 'PACKET_MULTICAST', 'NS3_PACKET_MULTICAST', 'PACKET_OTHERHOST', 'NS3_PACKET_OTHERHOST'], outer_class=root_module['ns3::NetDevice'], import_from_module='ns.network')
+ ## nix-vector.h (module 'network'): ns3::NixVector [class]
+ module.add_class('NixVector', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >'])
+ ## node.h (module 'network'): ns3::Node [class]
+ module.add_class('Node', import_from_module='ns.network', parent=root_module['ns3::Object'])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker [class]
+ module.add_class('ObjectFactoryChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue [class]
+ module.add_class('ObjectFactoryValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper [class]
+ module.add_class('OutputStreamWrapper', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >'])
+ ## packet.h (module 'network'): ns3::Packet [class]
+ module.add_class('Packet', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >'])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::PlanetLabFdNetDeviceHelper [class]
+ module.add_class('PlanetLabFdNetDeviceHelper', parent=root_module['ns3::EmuFdNetDeviceHelper'])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::TapFdNetDeviceHelper [class]
+ module.add_class('TapFdNetDeviceHelper', parent=root_module['ns3::EmuFdNetDeviceHelper'])
+ ## nstime.h (module 'core'): ns3::TimeChecker [class]
+ module.add_class('TimeChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## nstime.h (module 'core'): ns3::TimeValue [class]
+ module.add_class('TimeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## type-id.h (module 'core'): ns3::TypeIdChecker [class]
+ module.add_class('TypeIdChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker'])
+ ## type-id.h (module 'core'): ns3::TypeIdValue [class]
+ module.add_class('TypeIdValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue'])
+ ## address.h (module 'network'): ns3::AddressChecker [class]
+ module.add_class('AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker'])
+ ## address.h (module 'network'): ns3::AddressValue [class]
+ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue'])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice [class]
+ module.add_class('FdNetDevice', parent=root_module['ns3::NetDevice'])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice::EncapsulationMode [enumeration]
+ module.add_enum('EncapsulationMode', ['DIX', 'LLC', 'DIXPI'], outer_class=root_module['ns3::FdNetDevice'])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDeviceFdReader [class]
+ module.add_class('FdNetDeviceFdReader', parent=root_module['ns3::FdReader'])
+
+ ## Register a nested module for the namespace FatalImpl
+
+ nested_module = module.add_cpp_namespace('FatalImpl')
+ register_types_ns3_FatalImpl(nested_module)
+
+
+def register_types_ns3_FatalImpl(module):
+ root_module = module.get_root()
+
+
+def register_methods(root_module):
+ register_Ns3Address_methods(root_module, root_module['ns3::Address'])
+ register_Ns3AsciiTraceHelper_methods(root_module, root_module['ns3::AsciiTraceHelper'])
+ register_Ns3AsciiTraceHelperForDevice_methods(root_module, root_module['ns3::AsciiTraceHelperForDevice'])
+ register_Ns3AttributeConstructionList_methods(root_module, root_module['ns3::AttributeConstructionList'])
+ register_Ns3AttributeConstructionListItem_methods(root_module, root_module['ns3::AttributeConstructionList::Item'])
+ register_Ns3Buffer_methods(root_module, root_module['ns3::Buffer'])
+ register_Ns3BufferIterator_methods(root_module, root_module['ns3::Buffer::Iterator'])
+ register_Ns3ByteTagIterator_methods(root_module, root_module['ns3::ByteTagIterator'])
+ register_Ns3ByteTagIteratorItem_methods(root_module, root_module['ns3::ByteTagIterator::Item'])
+ register_Ns3ByteTagList_methods(root_module, root_module['ns3::ByteTagList'])
+ register_Ns3ByteTagListIterator_methods(root_module, root_module['ns3::ByteTagList::Iterator'])
+ register_Ns3ByteTagListIteratorItem_methods(root_module, root_module['ns3::ByteTagList::Iterator::Item'])
+ register_Ns3CallbackBase_methods(root_module, root_module['ns3::CallbackBase'])
+ register_Ns3CriticalSection_methods(root_module, root_module['ns3::CriticalSection'])
+ register_Ns3DataRate_methods(root_module, root_module['ns3::DataRate'])
+ register_Ns3EventId_methods(root_module, root_module['ns3::EventId'])
+ register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address'])
+ register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask'])
+ register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address'])
+ register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix'])
+ register_Ns3Mac48Address_methods(root_module, root_module['ns3::Mac48Address'])
+ register_Ns3NetDeviceContainer_methods(root_module, root_module['ns3::NetDeviceContainer'])
+ register_Ns3NodeContainer_methods(root_module, root_module['ns3::NodeContainer'])
+ register_Ns3ObjectBase_methods(root_module, root_module['ns3::ObjectBase'])
+ register_Ns3ObjectDeleter_methods(root_module, root_module['ns3::ObjectDeleter'])
+ register_Ns3ObjectFactory_methods(root_module, root_module['ns3::ObjectFactory'])
+ register_Ns3PacketMetadata_methods(root_module, root_module['ns3::PacketMetadata'])
+ register_Ns3PacketMetadataItem_methods(root_module, root_module['ns3::PacketMetadata::Item'])
+ register_Ns3PacketMetadataItemIterator_methods(root_module, root_module['ns3::PacketMetadata::ItemIterator'])
+ register_Ns3PacketTagIterator_methods(root_module, root_module['ns3::PacketTagIterator'])
+ register_Ns3PacketTagIteratorItem_methods(root_module, root_module['ns3::PacketTagIterator::Item'])
+ register_Ns3PacketTagList_methods(root_module, root_module['ns3::PacketTagList'])
+ register_Ns3PacketTagListTagData_methods(root_module, root_module['ns3::PacketTagList::TagData'])
+ register_Ns3PcapFile_methods(root_module, root_module['ns3::PcapFile'])
+ register_Ns3PcapHelper_methods(root_module, root_module['ns3::PcapHelper'])
+ register_Ns3PcapHelperForDevice_methods(root_module, root_module['ns3::PcapHelperForDevice'])
+ register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >'])
+ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator'])
+ register_Ns3SystemCondition_methods(root_module, root_module['ns3::SystemCondition'])
+ register_Ns3SystemMutex_methods(root_module, root_module['ns3::SystemMutex'])
+ register_Ns3Tag_methods(root_module, root_module['ns3::Tag'])
+ register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer'])
+ register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId'])
+ register_Ns3TypeIdAttributeInformation_methods(root_module, root_module['ns3::TypeId::AttributeInformation'])
+ register_Ns3TypeIdTraceSourceInformation_methods(root_module, root_module['ns3::TypeId::TraceSourceInformation'])
+ register_Ns3Empty_methods(root_module, root_module['ns3::empty'])
+ register_Ns3Int64x64_t_methods(root_module, root_module['ns3::int64x64_t'])
+ register_Ns3Chunk_methods(root_module, root_module['ns3::Chunk'])
+ register_Ns3FdNetDeviceHelper_methods(root_module, root_module['ns3::FdNetDeviceHelper'])
+ register_Ns3Header_methods(root_module, root_module['ns3::Header'])
+ register_Ns3Object_methods(root_module, root_module['ns3::Object'])
+ register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator'])
+ register_Ns3PcapFileWrapper_methods(root_module, root_module['ns3::PcapFileWrapper'])
+ register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >'])
+ register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >'])
+ register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >'])
+ register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >'])
+ register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >'])
+ register_Ns3SimpleRefCount__Ns3FdReader_Ns3Empty_Ns3DefaultDeleter__lt__ns3FdReader__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >'])
+ register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >'])
+ register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >'])
+ register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >'])
+ register_Ns3SimpleRefCount__Ns3SystemThread_Ns3Empty_Ns3DefaultDeleter__lt__ns3SystemThread__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >'])
+ register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >'])
+ register_Ns3SystemThread_methods(root_module, root_module['ns3::SystemThread'])
+ register_Ns3Time_methods(root_module, root_module['ns3::Time'])
+ register_Ns3TraceSourceAccessor_methods(root_module, root_module['ns3::TraceSourceAccessor'])
+ register_Ns3Trailer_methods(root_module, root_module['ns3::Trailer'])
+ register_Ns3AttributeAccessor_methods(root_module, root_module['ns3::AttributeAccessor'])
+ register_Ns3AttributeChecker_methods(root_module, root_module['ns3::AttributeChecker'])
+ register_Ns3AttributeValue_methods(root_module, root_module['ns3::AttributeValue'])
+ register_Ns3CallbackChecker_methods(root_module, root_module['ns3::CallbackChecker'])
+ register_Ns3CallbackImplBase_methods(root_module, root_module['ns3::CallbackImplBase'])
+ register_Ns3CallbackValue_methods(root_module, root_module['ns3::CallbackValue'])
+ register_Ns3DataRateChecker_methods(root_module, root_module['ns3::DataRateChecker'])
+ register_Ns3DataRateValue_methods(root_module, root_module['ns3::DataRateValue'])
+ register_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue'])
+ register_Ns3EmuFdNetDeviceHelper_methods(root_module, root_module['ns3::EmuFdNetDeviceHelper'])
+ register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl'])
+ register_Ns3FdReader_methods(root_module, root_module['ns3::FdReader'])
+ register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker'])
+ register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue'])
+ register_Ns3Ipv4MaskChecker_methods(root_module, root_module['ns3::Ipv4MaskChecker'])
+ register_Ns3Ipv4MaskValue_methods(root_module, root_module['ns3::Ipv4MaskValue'])
+ register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker'])
+ register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue'])
+ register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker'])
+ register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue'])
+ register_Ns3Mac48AddressChecker_methods(root_module, root_module['ns3::Mac48AddressChecker'])
+ register_Ns3Mac48AddressValue_methods(root_module, root_module['ns3::Mac48AddressValue'])
+ register_Ns3NetDevice_methods(root_module, root_module['ns3::NetDevice'])
+ register_Ns3NixVector_methods(root_module, root_module['ns3::NixVector'])
+ register_Ns3Node_methods(root_module, root_module['ns3::Node'])
+ register_Ns3ObjectFactoryChecker_methods(root_module, root_module['ns3::ObjectFactoryChecker'])
+ register_Ns3ObjectFactoryValue_methods(root_module, root_module['ns3::ObjectFactoryValue'])
+ register_Ns3OutputStreamWrapper_methods(root_module, root_module['ns3::OutputStreamWrapper'])
+ register_Ns3Packet_methods(root_module, root_module['ns3::Packet'])
+ register_Ns3PlanetLabFdNetDeviceHelper_methods(root_module, root_module['ns3::PlanetLabFdNetDeviceHelper'])
+ register_Ns3TapFdNetDeviceHelper_methods(root_module, root_module['ns3::TapFdNetDeviceHelper'])
+ register_Ns3TimeChecker_methods(root_module, root_module['ns3::TimeChecker'])
+ register_Ns3TimeValue_methods(root_module, root_module['ns3::TimeValue'])
+ register_Ns3TypeIdChecker_methods(root_module, root_module['ns3::TypeIdChecker'])
+ register_Ns3TypeIdValue_methods(root_module, root_module['ns3::TypeIdValue'])
+ register_Ns3AddressChecker_methods(root_module, root_module['ns3::AddressChecker'])
+ register_Ns3AddressValue_methods(root_module, root_module['ns3::AddressValue'])
+ register_Ns3FdNetDevice_methods(root_module, root_module['ns3::FdNetDevice'])
+ register_Ns3FdNetDeviceFdReader_methods(root_module, root_module['ns3::FdNetDeviceFdReader'])
+ return
+
+def register_Ns3Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## address.h (module 'network'): ns3::Address::Address() [constructor]
+ cls.add_constructor([])
+ ## address.h (module 'network'): ns3::Address::Address(uint8_t type, uint8_t const * buffer, uint8_t len) [constructor]
+ cls.add_constructor([param('uint8_t', 'type'), param('uint8_t const *', 'buffer'), param('uint8_t', 'len')])
+ ## address.h (module 'network'): ns3::Address::Address(ns3::Address const & address) [copy constructor]
+ cls.add_constructor([param('ns3::Address const &', 'address')])
+ ## address.h (module 'network'): bool ns3::Address::CheckCompatible(uint8_t type, uint8_t len) const [member function]
+ cls.add_method('CheckCompatible',
+ 'bool',
+ [param('uint8_t', 'type'), param('uint8_t', 'len')],
+ is_const=True)
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyAllFrom(uint8_t const * buffer, uint8_t len) [member function]
+ cls.add_method('CopyAllFrom',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint8_t', 'len')])
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyAllTo(uint8_t * buffer, uint8_t len) const [member function]
+ cls.add_method('CopyAllTo',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint8_t', 'len')],
+ is_const=True)
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyFrom(uint8_t const * buffer, uint8_t len) [member function]
+ cls.add_method('CopyFrom',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint8_t', 'len')])
+ ## address.h (module 'network'): uint32_t ns3::Address::CopyTo(uint8_t * buffer) const [member function]
+ cls.add_method('CopyTo',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer')],
+ is_const=True)
+ ## address.h (module 'network'): void ns3::Address::Deserialize(ns3::TagBuffer buffer) [member function]
+ cls.add_method('Deserialize',
+ 'void',
+ [param('ns3::TagBuffer', 'buffer')])
+ ## address.h (module 'network'): uint8_t ns3::Address::GetLength() const [member function]
+ cls.add_method('GetLength',
+ 'uint8_t',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): uint32_t ns3::Address::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): bool ns3::Address::IsInvalid() const [member function]
+ cls.add_method('IsInvalid',
+ 'bool',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): bool ns3::Address::IsMatchingType(uint8_t type) const [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('uint8_t', 'type')],
+ is_const=True)
+ ## address.h (module 'network'): static uint8_t ns3::Address::Register() [member function]
+ cls.add_method('Register',
+ 'uint8_t',
+ [],
+ is_static=True)
+ ## address.h (module 'network'): void ns3::Address::Serialize(ns3::TagBuffer buffer) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::TagBuffer', 'buffer')],
+ is_const=True)
+ return
+
+def register_Ns3AsciiTraceHelper_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelper::AsciiTraceHelper(ns3::AsciiTraceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AsciiTraceHelper const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelper::AsciiTraceHelper() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): ns3::Ptr<ns3::OutputStreamWrapper> ns3::AsciiTraceHelper::CreateFileStream(std::string filename, std::_Ios_Openmode filemode=std::ios_base::out) [member function]
+ cls.add_method('CreateFileStream',
+ 'ns3::Ptr< ns3::OutputStreamWrapper >',
+ [param('std::string', 'filename'), param('std::_Ios_Openmode', 'filemode', default_value='std::ios_base::out')])
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDequeueSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDequeueSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDequeueSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDequeueSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDropSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDropSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultDropSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultDropSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultEnqueueSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultEnqueueSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultEnqueueSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultEnqueueSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultReceiveSinkWithContext(ns3::Ptr<ns3::OutputStreamWrapper> file, std::string context, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultReceiveSinkWithContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('std::string', 'context'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): static void ns3::AsciiTraceHelper::DefaultReceiveSinkWithoutContext(ns3::Ptr<ns3::OutputStreamWrapper> file, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('DefaultReceiveSinkWithoutContext',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'file'), param('ns3::Ptr< ns3::Packet const >', 'p')],
+ is_static=True)
+ ## trace-helper.h (module 'network'): std::string ns3::AsciiTraceHelper::GetFilenameFromDevice(std::string prefix, ns3::Ptr<ns3::NetDevice> device, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromDevice',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'device'), param('bool', 'useObjectNames', default_value='true')])
+ ## trace-helper.h (module 'network'): std::string ns3::AsciiTraceHelper::GetFilenameFromInterfacePair(std::string prefix, ns3::Ptr<ns3::Object> object, uint32_t interface, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromInterfacePair',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::Object >', 'object'), param('uint32_t', 'interface'), param('bool', 'useObjectNames', default_value='true')])
+ return
+
+def register_Ns3AsciiTraceHelperForDevice_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelperForDevice::AsciiTraceHelperForDevice(ns3::AsciiTraceHelperForDevice const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AsciiTraceHelperForDevice const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::AsciiTraceHelperForDevice::AsciiTraceHelperForDevice() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool explicitFilename=false) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Ptr<ns3::NetDevice> nd) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Ptr< ns3::NetDevice >', 'nd')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, std::string ndName, bool explicitFilename=false) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('std::string', 'ndName'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, std::string ndName) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('std::string', 'ndName')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, ns3::NetDeviceContainer d) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NetDeviceContainer', 'd')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::NetDeviceContainer d) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::NetDeviceContainer', 'd')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, ns3::NodeContainer n) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NodeContainer', 'n')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::NodeContainer n) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::NodeContainer', 'n')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(std::string prefix, uint32_t nodeid, uint32_t deviceid, bool explicitFilename) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('std::string', 'prefix'), param('uint32_t', 'nodeid'), param('uint32_t', 'deviceid'), param('bool', 'explicitFilename')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAscii(ns3::Ptr<ns3::OutputStreamWrapper> stream, uint32_t nodeid, uint32_t deviceid) [member function]
+ cls.add_method('EnableAscii',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('uint32_t', 'nodeid'), param('uint32_t', 'deviceid')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAsciiAll(std::string prefix) [member function]
+ cls.add_method('EnableAsciiAll',
+ 'void',
+ [param('std::string', 'prefix')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAsciiAll(ns3::Ptr<ns3::OutputStreamWrapper> stream) [member function]
+ cls.add_method('EnableAsciiAll',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')])
+ ## trace-helper.h (module 'network'): void ns3::AsciiTraceHelperForDevice::EnableAsciiInternal(ns3::Ptr<ns3::OutputStreamWrapper> stream, std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool explicitFilename) [member function]
+ cls.add_method('EnableAsciiInternal',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'explicitFilename')],
+ is_pure_virtual=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeConstructionList_methods(root_module, cls):
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::AttributeConstructionList(ns3::AttributeConstructionList const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeConstructionList const &', 'arg0')])
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::AttributeConstructionList() [constructor]
+ cls.add_constructor([])
+ ## attribute-construction-list.h (module 'core'): void ns3::AttributeConstructionList::Add(std::string name, ns3::Ptr<ns3::AttributeChecker const> checker, ns3::Ptr<ns3::AttributeValue> value) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('std::string', 'name'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker'), param('ns3::Ptr< ns3::AttributeValue >', 'value')])
+ ## attribute-construction-list.h (module 'core'): std::_List_const_iterator<ns3::AttributeConstructionList::Item> ns3::AttributeConstructionList::Begin() const [member function]
+ cls.add_method('Begin',
+ 'std::_List_const_iterator< ns3::AttributeConstructionList::Item >',
+ [],
+ is_const=True)
+ ## attribute-construction-list.h (module 'core'): std::_List_const_iterator<ns3::AttributeConstructionList::Item> ns3::AttributeConstructionList::End() const [member function]
+ cls.add_method('End',
+ 'std::_List_const_iterator< ns3::AttributeConstructionList::Item >',
+ [],
+ is_const=True)
+ ## attribute-construction-list.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeConstructionList::Find(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('Find',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True)
+ return
+
+def register_Ns3AttributeConstructionListItem_methods(root_module, cls):
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::Item() [constructor]
+ cls.add_constructor([])
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::Item(ns3::AttributeConstructionList::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeConstructionList::Item const &', 'arg0')])
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::checker [variable]
+ cls.add_instance_attribute('checker', 'ns3::Ptr< ns3::AttributeChecker const >', is_const=False)
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::name [variable]
+ cls.add_instance_attribute('name', 'std::string', is_const=False)
+ ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::value [variable]
+ cls.add_instance_attribute('value', 'ns3::Ptr< ns3::AttributeValue >', is_const=False)
+ return
+
+def register_Ns3Buffer_methods(root_module, cls):
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer() [constructor]
+ cls.add_constructor([])
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer(uint32_t dataSize) [constructor]
+ cls.add_constructor([param('uint32_t', 'dataSize')])
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer(uint32_t dataSize, bool initialize) [constructor]
+ cls.add_constructor([param('uint32_t', 'dataSize'), param('bool', 'initialize')])
+ ## buffer.h (module 'network'): ns3::Buffer::Buffer(ns3::Buffer const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Buffer const &', 'o')])
+ ## buffer.h (module 'network'): bool ns3::Buffer::AddAtEnd(uint32_t end) [member function]
+ cls.add_method('AddAtEnd',
+ 'bool',
+ [param('uint32_t', 'end')])
+ ## buffer.h (module 'network'): void ns3::Buffer::AddAtEnd(ns3::Buffer const & o) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('ns3::Buffer const &', 'o')])
+ ## buffer.h (module 'network'): bool ns3::Buffer::AddAtStart(uint32_t start) [member function]
+ cls.add_method('AddAtStart',
+ 'bool',
+ [param('uint32_t', 'start')])
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator ns3::Buffer::Begin() const [member function]
+ cls.add_method('Begin',
+ 'ns3::Buffer::Iterator',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): void ns3::Buffer::CopyData(std::ostream * os, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'void',
+ [param('std::ostream *', 'os'), param('uint32_t', 'size')],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::CopyData(uint8_t * buffer, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')],
+ is_const=True)
+ ## buffer.h (module 'network'): ns3::Buffer ns3::Buffer::CreateFragment(uint32_t start, uint32_t length) const [member function]
+ cls.add_method('CreateFragment',
+ 'ns3::Buffer',
+ [param('uint32_t', 'start'), param('uint32_t', 'length')],
+ is_const=True)
+ ## buffer.h (module 'network'): ns3::Buffer ns3::Buffer::CreateFullCopy() const [member function]
+ cls.add_method('CreateFullCopy',
+ 'ns3::Buffer',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Deserialize(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator ns3::Buffer::End() const [member function]
+ cls.add_method('End',
+ 'ns3::Buffer::Iterator',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): int32_t ns3::Buffer::GetCurrentEndOffset() const [member function]
+ cls.add_method('GetCurrentEndOffset',
+ 'int32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): int32_t ns3::Buffer::GetCurrentStartOffset() const [member function]
+ cls.add_method('GetCurrentStartOffset',
+ 'int32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::GetSize() const [member function]
+ cls.add_method('GetSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): uint8_t const * ns3::Buffer::PeekData() const [member function]
+ cls.add_method('PeekData',
+ 'uint8_t const *',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): void ns3::Buffer::RemoveAtEnd(uint32_t end) [member function]
+ cls.add_method('RemoveAtEnd',
+ 'void',
+ [param('uint32_t', 'end')])
+ ## buffer.h (module 'network'): void ns3::Buffer::RemoveAtStart(uint32_t start) [member function]
+ cls.add_method('RemoveAtStart',
+ 'void',
+ [param('uint32_t', 'start')])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ return
+
+def register_Ns3BufferIterator_methods(root_module, cls):
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator::Iterator(ns3::Buffer::Iterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Buffer::Iterator const &', 'arg0')])
+ ## buffer.h (module 'network'): ns3::Buffer::Iterator::Iterator() [constructor]
+ cls.add_constructor([])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::CalculateIpChecksum(uint16_t size) [member function]
+ cls.add_method('CalculateIpChecksum',
+ 'uint16_t',
+ [param('uint16_t', 'size')])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::CalculateIpChecksum(uint16_t size, uint32_t initialChecksum) [member function]
+ cls.add_method('CalculateIpChecksum',
+ 'uint16_t',
+ [param('uint16_t', 'size'), param('uint32_t', 'initialChecksum')])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::GetDistanceFrom(ns3::Buffer::Iterator const & o) const [member function]
+ cls.add_method('GetDistanceFrom',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator const &', 'o')],
+ is_const=True)
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::GetSize() const [member function]
+ cls.add_method('GetSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): bool ns3::Buffer::Iterator::IsEnd() const [member function]
+ cls.add_method('IsEnd',
+ 'bool',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): bool ns3::Buffer::Iterator::IsStart() const [member function]
+ cls.add_method('IsStart',
+ 'bool',
+ [],
+ is_const=True)
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Next() [member function]
+ cls.add_method('Next',
+ 'void',
+ [])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Next(uint32_t delta) [member function]
+ cls.add_method('Next',
+ 'void',
+ [param('uint32_t', 'delta')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function]
+ cls.add_method('Prev',
+ 'void',
+ [])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev(uint32_t delta) [member function]
+ cls.add_method('Prev',
+ 'void',
+ [param('uint32_t', 'delta')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(uint8_t * buffer, uint32_t size) [member function]
+ cls.add_method('Read',
+ 'void',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function]
+ cls.add_method('ReadLsbtohU16',
+ 'uint16_t',
+ [])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadLsbtohU32() [member function]
+ cls.add_method('ReadLsbtohU32',
+ 'uint32_t',
+ [])
+ ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadLsbtohU64() [member function]
+ cls.add_method('ReadLsbtohU64',
+ 'uint64_t',
+ [])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadNtohU16() [member function]
+ cls.add_method('ReadNtohU16',
+ 'uint16_t',
+ [])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadNtohU32() [member function]
+ cls.add_method('ReadNtohU32',
+ 'uint32_t',
+ [])
+ ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadNtohU64() [member function]
+ cls.add_method('ReadNtohU64',
+ 'uint64_t',
+ [])
+ ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadU16() [member function]
+ cls.add_method('ReadU16',
+ 'uint16_t',
+ [])
+ ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadU32() [member function]
+ cls.add_method('ReadU32',
+ 'uint32_t',
+ [])
+ ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadU64() [member function]
+ cls.add_method('ReadU64',
+ 'uint64_t',
+ [])
+ ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::ReadU8() [member function]
+ cls.add_method('ReadU8',
+ 'uint8_t',
+ [])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Write(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Write(ns3::Buffer::Iterator start, ns3::Buffer::Iterator end) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Buffer::Iterator', 'start'), param('ns3::Buffer::Iterator', 'end')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU16(uint16_t data) [member function]
+ cls.add_method('WriteHtolsbU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU32(uint32_t data) [member function]
+ cls.add_method('WriteHtolsbU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU64(uint64_t data) [member function]
+ cls.add_method('WriteHtolsbU64',
+ 'void',
+ [param('uint64_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU16(uint16_t data) [member function]
+ cls.add_method('WriteHtonU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU32(uint32_t data) [member function]
+ cls.add_method('WriteHtonU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU64(uint64_t data) [member function]
+ cls.add_method('WriteHtonU64',
+ 'void',
+ [param('uint64_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU16(uint16_t data) [member function]
+ cls.add_method('WriteU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU32(uint32_t data) [member function]
+ cls.add_method('WriteU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU64(uint64_t data) [member function]
+ cls.add_method('WriteU64',
+ 'void',
+ [param('uint64_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU8(uint8_t data) [member function]
+ cls.add_method('WriteU8',
+ 'void',
+ [param('uint8_t', 'data')])
+ ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU8(uint8_t data, uint32_t len) [member function]
+ cls.add_method('WriteU8',
+ 'void',
+ [param('uint8_t', 'data'), param('uint32_t', 'len')])
+ return
+
+def register_Ns3ByteTagIterator_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::ByteTagIterator::ByteTagIterator(ns3::ByteTagIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagIterator const &', 'arg0')])
+ ## packet.h (module 'network'): bool ns3::ByteTagIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::ByteTagIterator::Item ns3::ByteTagIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::ByteTagIterator::Item',
+ [])
+ return
+
+def register_Ns3ByteTagIteratorItem_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::ByteTagIterator::Item::Item(ns3::ByteTagIterator::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagIterator::Item const &', 'arg0')])
+ ## packet.h (module 'network'): uint32_t ns3::ByteTagIterator::Item::GetEnd() const [member function]
+ cls.add_method('GetEnd',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::ByteTagIterator::Item::GetStart() const [member function]
+ cls.add_method('GetStart',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::ByteTagIterator::Item::GetTag(ns3::Tag & tag) const [member function]
+ cls.add_method('GetTag',
+ 'void',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::TypeId ns3::ByteTagIterator::Item::GetTypeId() const [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3ByteTagList_methods(root_module, cls):
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::ByteTagList() [constructor]
+ cls.add_constructor([])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::ByteTagList(ns3::ByteTagList const & o) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagList const &', 'o')])
+ ## byte-tag-list.h (module 'network'): ns3::TagBuffer ns3::ByteTagList::Add(ns3::TypeId tid, uint32_t bufferSize, int32_t start, int32_t end) [member function]
+ cls.add_method('Add',
+ 'ns3::TagBuffer',
+ [param('ns3::TypeId', 'tid'), param('uint32_t', 'bufferSize'), param('int32_t', 'start'), param('int32_t', 'end')])
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::Add(ns3::ByteTagList const & o) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::ByteTagList const &', 'o')])
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::AddAtEnd(int32_t adjustment, int32_t appendOffset) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('int32_t', 'adjustment'), param('int32_t', 'appendOffset')])
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::AddAtStart(int32_t adjustment, int32_t prependOffset) [member function]
+ cls.add_method('AddAtStart',
+ 'void',
+ [param('int32_t', 'adjustment'), param('int32_t', 'prependOffset')])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator ns3::ByteTagList::Begin(int32_t offsetStart, int32_t offsetEnd) const [member function]
+ cls.add_method('Begin',
+ 'ns3::ByteTagList::Iterator',
+ [param('int32_t', 'offsetStart'), param('int32_t', 'offsetEnd')],
+ is_const=True)
+ ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::RemoveAll() [member function]
+ cls.add_method('RemoveAll',
+ 'void',
+ [])
+ return
+
+def register_Ns3ByteTagListIterator_methods(root_module, cls):
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Iterator(ns3::ByteTagList::Iterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagList::Iterator const &', 'arg0')])
+ ## byte-tag-list.h (module 'network'): uint32_t ns3::ByteTagList::Iterator::GetOffsetStart() const [member function]
+ cls.add_method('GetOffsetStart',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## byte-tag-list.h (module 'network'): bool ns3::ByteTagList::Iterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item ns3::ByteTagList::Iterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::ByteTagList::Iterator::Item',
+ [])
+ return
+
+def register_Ns3ByteTagListIteratorItem_methods(root_module, cls):
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::Item(ns3::ByteTagList::Iterator::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ByteTagList::Iterator::Item const &', 'arg0')])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::Item(ns3::TagBuffer buf) [constructor]
+ cls.add_constructor([param('ns3::TagBuffer', 'buf')])
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::buf [variable]
+ cls.add_instance_attribute('buf', 'ns3::TagBuffer', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::end [variable]
+ cls.add_instance_attribute('end', 'int32_t', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::size [variable]
+ cls.add_instance_attribute('size', 'uint32_t', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::start [variable]
+ cls.add_instance_attribute('start', 'int32_t', is_const=False)
+ ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::tid [variable]
+ cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False)
+ return
+
+def register_Ns3CallbackBase_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase(ns3::CallbackBase const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackBase const &', 'arg0')])
+ ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::Ptr<ns3::CallbackImplBase> ns3::CallbackBase::GetImpl() const [member function]
+ cls.add_method('GetImpl',
+ 'ns3::Ptr< ns3::CallbackImplBase >',
+ [],
+ is_const=True)
+ ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase(ns3::Ptr<ns3::CallbackImplBase> impl) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::CallbackImplBase >', 'impl')],
+ visibility='protected')
+ ## callback.h (module 'core'): static std::string ns3::CallbackBase::Demangle(std::string const & mangled) [member function]
+ cls.add_method('Demangle',
+ 'std::string',
+ [param('std::string const &', 'mangled')],
+ is_static=True, visibility='protected')
+ return
+
+def register_Ns3CriticalSection_methods(root_module, cls):
+ ## system-mutex.h (module 'core'): ns3::CriticalSection::CriticalSection(ns3::CriticalSection const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CriticalSection const &', 'arg0')])
+ ## system-mutex.h (module 'core'): ns3::CriticalSection::CriticalSection(ns3::SystemMutex & mutex) [constructor]
+ cls.add_constructor([param('ns3::SystemMutex &', 'mutex')])
+ return
+
+def register_Ns3DataRate_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('!=')
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('<=')
+ cls.add_binary_comparison_operator('==')
+ cls.add_binary_comparison_operator('>')
+ cls.add_binary_comparison_operator('>=')
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate(ns3::DataRate const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::DataRate const &', 'arg0')])
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate() [constructor]
+ cls.add_constructor([])
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate(uint64_t bps) [constructor]
+ cls.add_constructor([param('uint64_t', 'bps')])
+ ## data-rate.h (module 'network'): ns3::DataRate::DataRate(std::string rate) [constructor]
+ cls.add_constructor([param('std::string', 'rate')])
+ ## data-rate.h (module 'network'): double ns3::DataRate::CalculateTxTime(uint32_t bytes) const [member function]
+ cls.add_method('CalculateTxTime',
+ 'double',
+ [param('uint32_t', 'bytes')],
+ is_const=True)
+ ## data-rate.h (module 'network'): uint64_t ns3::DataRate::GetBitRate() const [member function]
+ cls.add_method('GetBitRate',
+ 'uint64_t',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3EventId_methods(root_module, cls):
+ cls.add_binary_comparison_operator('!=')
+ cls.add_binary_comparison_operator('==')
+ ## event-id.h (module 'core'): ns3::EventId::EventId(ns3::EventId const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EventId const &', 'arg0')])
+ ## event-id.h (module 'core'): ns3::EventId::EventId() [constructor]
+ cls.add_constructor([])
+ ## event-id.h (module 'core'): ns3::EventId::EventId(ns3::Ptr<ns3::EventImpl> const & impl, uint64_t ts, uint32_t context, uint32_t uid) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::EventImpl > const &', 'impl'), param('uint64_t', 'ts'), param('uint32_t', 'context'), param('uint32_t', 'uid')])
+ ## event-id.h (module 'core'): void ns3::EventId::Cancel() [member function]
+ cls.add_method('Cancel',
+ 'void',
+ [])
+ ## event-id.h (module 'core'): uint32_t ns3::EventId::GetContext() const [member function]
+ cls.add_method('GetContext',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): uint64_t ns3::EventId::GetTs() const [member function]
+ cls.add_method('GetTs',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): uint32_t ns3::EventId::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): bool ns3::EventId::IsExpired() const [member function]
+ cls.add_method('IsExpired',
+ 'bool',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): bool ns3::EventId::IsRunning() const [member function]
+ cls.add_method('IsRunning',
+ 'bool',
+ [],
+ is_const=True)
+ ## event-id.h (module 'core'): ns3::EventImpl * ns3::EventId::PeekEventImpl() const [member function]
+ cls.add_method('PeekEventImpl',
+ 'ns3::EventImpl *',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3Ipv4Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(ns3::Ipv4Address const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4Address const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(uint32_t address) [constructor]
+ cls.add_constructor([param('uint32_t', 'address')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(char const * address) [constructor]
+ cls.add_constructor([param('char const *', 'address')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4Address::CombineMask(ns3::Ipv4Mask const & mask) const [member function]
+ cls.add_method('CombineMask',
+ 'ns3::Ipv4Address',
+ [param('ns3::Ipv4Mask const &', 'mask')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::ConvertFrom(ns3::Address const & address) [member function]
+ cls.add_method('ConvertFrom',
+ 'ns3::Ipv4Address',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::Deserialize(uint8_t const * buf) [member function]
+ cls.add_method('Deserialize',
+ 'ns3::Ipv4Address',
+ [param('uint8_t const *', 'buf')],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Address::Get() const [member function]
+ cls.add_method('Get',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetAny() [member function]
+ cls.add_method('GetAny',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetBroadcast() [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4Address::GetSubnetDirectedBroadcast(ns3::Ipv4Mask const & mask) const [member function]
+ cls.add_method('GetSubnetDirectedBroadcast',
+ 'ns3::Ipv4Address',
+ [param('ns3::Ipv4Mask const &', 'mask')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv4Address',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsEqual(ns3::Ipv4Address const & other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv4Address const &', 'other')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsLocalMulticast() const [member function]
+ cls.add_method('IsLocalMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static bool ns3::Ipv4Address::IsMatchingType(ns3::Address const & address) [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsSubnetDirectedBroadcast(ns3::Ipv4Mask const & mask) const [member function]
+ cls.add_method('IsSubnetDirectedBroadcast',
+ 'bool',
+ [param('ns3::Ipv4Mask const &', 'mask')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Serialize(uint8_t * buf) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Set(uint32_t address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('uint32_t', 'address')])
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Set(char const * address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('char const *', 'address')])
+ return
+
+def register_Ns3Ipv4Mask_methods(root_module, cls):
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(ns3::Ipv4Mask const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4Mask const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(uint32_t mask) [constructor]
+ cls.add_constructor([param('uint32_t', 'mask')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(char const * mask) [constructor]
+ cls.add_constructor([param('char const *', 'mask')])
+ ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Mask::Get() const [member function]
+ cls.add_method('Get',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Mask::GetInverse() const [member function]
+ cls.add_method('GetInverse',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv4Mask',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetOnes() [member function]
+ cls.add_method('GetOnes',
+ 'ns3::Ipv4Mask',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): uint16_t ns3::Ipv4Mask::GetPrefixLength() const [member function]
+ cls.add_method('GetPrefixLength',
+ 'uint16_t',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv4Mask',
+ [],
+ is_static=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Mask::IsEqual(ns3::Ipv4Mask other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv4Mask', 'other')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4Mask::IsMatch(ns3::Ipv4Address a, ns3::Ipv4Address b) const [member function]
+ cls.add_method('IsMatch',
+ 'bool',
+ [param('ns3::Ipv4Address', 'a'), param('ns3::Ipv4Address', 'b')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Mask::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4Mask::Set(uint32_t mask) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('uint32_t', 'mask')])
+ return
+
+def register_Ns3Ipv6Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(char const * address) [constructor]
+ cls.add_constructor([param('char const *', 'address')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(uint8_t * address) [constructor]
+ cls.add_constructor([param('uint8_t *', 'address')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(ns3::Ipv6Address const & addr) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6Address const &', 'addr')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(ns3::Ipv6Address const * addr) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Address const *', 'addr')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address ns3::Ipv6Address::CombinePrefix(ns3::Ipv6Prefix const & prefix) [member function]
+ cls.add_method('CombinePrefix',
+ 'ns3::Ipv6Address',
+ [param('ns3::Ipv6Prefix const &', 'prefix')])
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::ConvertFrom(ns3::Address const & address) [member function]
+ cls.add_method('ConvertFrom',
+ 'ns3::Ipv6Address',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::Deserialize(uint8_t const * buf) [member function]
+ cls.add_method('Deserialize',
+ 'ns3::Ipv6Address',
+ [param('uint8_t const *', 'buf')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllHostsMulticast() [member function]
+ cls.add_method('GetAllHostsMulticast',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllNodesMulticast() [member function]
+ cls.add_method('GetAllNodesMulticast',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllRoutersMulticast() [member function]
+ cls.add_method('GetAllRoutersMulticast',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAny() [member function]
+ cls.add_method('GetAny',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::GetBytes(uint8_t * buf) const [member function]
+ cls.add_method('GetBytes',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv6Address::GetIpv4MappedAddress() const [member function]
+ cls.add_method('GetIpv4MappedAddress',
+ 'ns3::Ipv4Address',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetOnes() [member function]
+ cls.add_method('GetOnes',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv6Address',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllHostsMulticast() const [member function]
+ cls.add_method('IsAllHostsMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllNodesMulticast() const [member function]
+ cls.add_method('IsAllNodesMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllRoutersMulticast() const [member function]
+ cls.add_method('IsAllRoutersMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAny() const [member function]
+ cls.add_method('IsAny',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsEqual(ns3::Ipv6Address const & other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv6Address const &', 'other')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsIpv4MappedAddress() [member function]
+ cls.add_method('IsIpv4MappedAddress',
+ 'bool',
+ [])
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocal() const [member function]
+ cls.add_method('IsLinkLocal',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocalMulticast() const [member function]
+ cls.add_method('IsLinkLocalMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLocalhost() const [member function]
+ cls.add_method('IsLocalhost',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static bool ns3::Ipv6Address::IsMatchingType(ns3::Address const & address) [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsSolicitedMulticast() const [member function]
+ cls.add_method('IsSolicitedMulticast',
+ 'bool',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredAddress(ns3::Mac48Address addr, ns3::Ipv6Address prefix) [member function]
+ cls.add_method('MakeAutoconfiguredAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Mac48Address', 'addr'), param('ns3::Ipv6Address', 'prefix')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredLinkLocalAddress(ns3::Mac48Address mac) [member function]
+ cls.add_method('MakeAutoconfiguredLinkLocalAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Mac48Address', 'mac')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeIpv4MappedAddress(ns3::Ipv4Address addr) [member function]
+ cls.add_method('MakeIpv4MappedAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Ipv4Address', 'addr')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeSolicitedAddress(ns3::Ipv6Address addr) [member function]
+ cls.add_method('MakeSolicitedAddress',
+ 'ns3::Ipv6Address',
+ [param('ns3::Ipv6Address', 'addr')],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Serialize(uint8_t * buf) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Set(char const * address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('char const *', 'address')])
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Set(uint8_t * address) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('uint8_t *', 'address')])
+ return
+
+def register_Ns3Ipv6Prefix_methods(root_module, cls):
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(uint8_t * prefix) [constructor]
+ cls.add_constructor([param('uint8_t *', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(char const * prefix) [constructor]
+ cls.add_constructor([param('char const *', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(uint8_t prefix) [constructor]
+ cls.add_constructor([param('uint8_t', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(ns3::Ipv6Prefix const & prefix) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6Prefix const &', 'prefix')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(ns3::Ipv6Prefix const * prefix) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Prefix const *', 'prefix')])
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Prefix::GetBytes(uint8_t * buf) const [member function]
+ cls.add_method('GetBytes',
+ 'void',
+ [param('uint8_t *', 'buf')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetLoopback() [member function]
+ cls.add_method('GetLoopback',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetOnes() [member function]
+ cls.add_method('GetOnes',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): uint8_t ns3::Ipv6Prefix::GetPrefixLength() const [member function]
+ cls.add_method('GetPrefixLength',
+ 'uint8_t',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetZero() [member function]
+ cls.add_method('GetZero',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_static=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Prefix::IsEqual(ns3::Ipv6Prefix const & other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ipv6Prefix const &', 'other')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6Prefix::IsMatch(ns3::Ipv6Address a, ns3::Ipv6Address b) const [member function]
+ cls.add_method('IsMatch',
+ 'bool',
+ [param('ns3::Ipv6Address', 'a'), param('ns3::Ipv6Address', 'b')],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6Prefix::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ return
+
+def register_Ns3Mac48Address_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address(ns3::Mac48Address const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Mac48Address const &', 'arg0')])
+ ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address() [constructor]
+ cls.add_constructor([])
+ ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address(char const * str) [constructor]
+ cls.add_constructor([param('char const *', 'str')])
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::Allocate() [member function]
+ cls.add_method('Allocate',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::ConvertFrom(ns3::Address const & address) [member function]
+ cls.add_method('ConvertFrom',
+ 'ns3::Mac48Address',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ ## mac48-address.h (module 'network'): void ns3::Mac48Address::CopyFrom(uint8_t const * buffer) [member function]
+ cls.add_method('CopyFrom',
+ 'void',
+ [param('uint8_t const *', 'buffer')])
+ ## mac48-address.h (module 'network'): void ns3::Mac48Address::CopyTo(uint8_t * buffer) const [member function]
+ cls.add_method('CopyTo',
+ 'void',
+ [param('uint8_t *', 'buffer')],
+ is_const=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetBroadcast() [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast(ns3::Ipv4Address address) [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Mac48Address',
+ [param('ns3::Ipv4Address', 'address')],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast(ns3::Ipv6Address address) [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Mac48Address',
+ [param('ns3::Ipv6Address', 'address')],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast6Prefix() [member function]
+ cls.add_method('GetMulticast6Prefix',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticastPrefix() [member function]
+ cls.add_method('GetMulticastPrefix',
+ 'ns3::Mac48Address',
+ [],
+ is_static=True)
+ ## mac48-address.h (module 'network'): bool ns3::Mac48Address::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_const=True)
+ ## mac48-address.h (module 'network'): bool ns3::Mac48Address::IsGroup() const [member function]
+ cls.add_method('IsGroup',
+ 'bool',
+ [],
+ is_const=True)
+ ## mac48-address.h (module 'network'): static bool ns3::Mac48Address::IsMatchingType(ns3::Address const & address) [member function]
+ cls.add_method('IsMatchingType',
+ 'bool',
+ [param('ns3::Address const &', 'address')],
+ is_static=True)
+ return
+
+def register_Ns3NetDeviceContainer_methods(root_module, cls):
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(ns3::NetDeviceContainer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::NetDeviceContainer const &', 'arg0')])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer() [constructor]
+ cls.add_constructor([])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(ns3::Ptr<ns3::NetDevice> dev) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::NetDevice >', 'dev')])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(std::string devName) [constructor]
+ cls.add_constructor([param('std::string', 'devName')])
+ ## net-device-container.h (module 'network'): ns3::NetDeviceContainer::NetDeviceContainer(ns3::NetDeviceContainer const & a, ns3::NetDeviceContainer const & b) [constructor]
+ cls.add_constructor([param('ns3::NetDeviceContainer const &', 'a'), param('ns3::NetDeviceContainer const &', 'b')])
+ ## net-device-container.h (module 'network'): void ns3::NetDeviceContainer::Add(ns3::NetDeviceContainer other) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::NetDeviceContainer', 'other')])
+ ## net-device-container.h (module 'network'): void ns3::NetDeviceContainer::Add(ns3::Ptr<ns3::NetDevice> device) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::Ptr< ns3::NetDevice >', 'device')])
+ ## net-device-container.h (module 'network'): void ns3::NetDeviceContainer::Add(std::string deviceName) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('std::string', 'deviceName')])
+ ## net-device-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::NetDevice>*,std::vector<ns3::Ptr<ns3::NetDevice>, std::allocator<ns3::Ptr<ns3::NetDevice> > > > ns3::NetDeviceContainer::Begin() const [member function]
+ cls.add_method('Begin',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::NetDevice > const, std::vector< ns3::Ptr< ns3::NetDevice > > >',
+ [],
+ is_const=True)
+ ## net-device-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::NetDevice>*,std::vector<ns3::Ptr<ns3::NetDevice>, std::allocator<ns3::Ptr<ns3::NetDevice> > > > ns3::NetDeviceContainer::End() const [member function]
+ cls.add_method('End',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::NetDevice > const, std::vector< ns3::Ptr< ns3::NetDevice > > >',
+ [],
+ is_const=True)
+ ## net-device-container.h (module 'network'): ns3::Ptr<ns3::NetDevice> ns3::NetDeviceContainer::Get(uint32_t i) const [member function]
+ cls.add_method('Get',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## net-device-container.h (module 'network'): uint32_t ns3::NetDeviceContainer::GetN() const [member function]
+ cls.add_method('GetN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3NodeContainer_methods(root_module, cls):
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'arg0')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer() [constructor]
+ cls.add_constructor([])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::Ptr<ns3::Node> node) [constructor]
+ cls.add_constructor([param('ns3::Ptr< ns3::Node >', 'node')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(std::string nodeName) [constructor]
+ cls.add_constructor([param('std::string', 'nodeName')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c, ns3::NodeContainer const & d) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c'), param('ns3::NodeContainer const &', 'd')])
+ ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c, ns3::NodeContainer const & d, ns3::NodeContainer const & e) [constructor]
+ cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c'), param('ns3::NodeContainer const &', 'd'), param('ns3::NodeContainer const &', 'e')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Add(ns3::NodeContainer other) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::NodeContainer', 'other')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Add(ns3::Ptr<ns3::Node> node) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::Ptr< ns3::Node >', 'node')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Add(std::string nodeName) [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('std::string', 'nodeName')])
+ ## node-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::Node>*,std::vector<ns3::Ptr<ns3::Node>, std::allocator<ns3::Ptr<ns3::Node> > > > ns3::NodeContainer::Begin() const [member function]
+ cls.add_method('Begin',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::Node > const, std::vector< ns3::Ptr< ns3::Node > > >',
+ [],
+ is_const=True)
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Create(uint32_t n) [member function]
+ cls.add_method('Create',
+ 'void',
+ [param('uint32_t', 'n')])
+ ## node-container.h (module 'network'): void ns3::NodeContainer::Create(uint32_t n, uint32_t systemId) [member function]
+ cls.add_method('Create',
+ 'void',
+ [param('uint32_t', 'n'), param('uint32_t', 'systemId')])
+ ## node-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::Node>*,std::vector<ns3::Ptr<ns3::Node>, std::allocator<ns3::Ptr<ns3::Node> > > > ns3::NodeContainer::End() const [member function]
+ cls.add_method('End',
+ '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::Node > const, std::vector< ns3::Ptr< ns3::Node > > >',
+ [],
+ is_const=True)
+ ## node-container.h (module 'network'): ns3::Ptr<ns3::Node> ns3::NodeContainer::Get(uint32_t i) const [member function]
+ cls.add_method('Get',
+ 'ns3::Ptr< ns3::Node >',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## node-container.h (module 'network'): static ns3::NodeContainer ns3::NodeContainer::GetGlobal() [member function]
+ cls.add_method('GetGlobal',
+ 'ns3::NodeContainer',
+ [],
+ is_static=True)
+ ## node-container.h (module 'network'): uint32_t ns3::NodeContainer::GetN() const [member function]
+ cls.add_method('GetN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3ObjectBase_methods(root_module, cls):
+ ## object-base.h (module 'core'): ns3::ObjectBase::ObjectBase() [constructor]
+ cls.add_constructor([])
+ ## object-base.h (module 'core'): ns3::ObjectBase::ObjectBase(ns3::ObjectBase const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectBase const &', 'arg0')])
+ ## object-base.h (module 'core'): void ns3::ObjectBase::GetAttribute(std::string name, ns3::AttributeValue & value) const [member function]
+ cls.add_method('GetAttribute',
+ 'void',
+ [param('std::string', 'name'), param('ns3::AttributeValue &', 'value')],
+ is_const=True)
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::GetAttributeFailSafe(std::string name, ns3::AttributeValue & attribute) const [member function]
+ cls.add_method('GetAttributeFailSafe',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::AttributeValue &', 'attribute')],
+ is_const=True)
+ ## object-base.h (module 'core'): ns3::TypeId ns3::ObjectBase::GetInstanceTypeId() const [member function]
+ cls.add_method('GetInstanceTypeId',
+ 'ns3::TypeId',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## object-base.h (module 'core'): static ns3::TypeId ns3::ObjectBase::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## object-base.h (module 'core'): void ns3::ObjectBase::SetAttribute(std::string name, ns3::AttributeValue const & value) [member function]
+ cls.add_method('SetAttribute',
+ 'void',
+ [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::SetAttributeFailSafe(std::string name, ns3::AttributeValue const & value) [member function]
+ cls.add_method('SetAttributeFailSafe',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceConnect(std::string name, std::string context, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceConnect',
+ 'bool',
+ [param('std::string', 'name'), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceConnectWithoutContext(std::string name, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceConnectWithoutContext',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceDisconnect(std::string name, std::string context, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceDisconnect',
+ 'bool',
+ [param('std::string', 'name'), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceDisconnectWithoutContext(std::string name, ns3::CallbackBase const & cb) [member function]
+ cls.add_method('TraceDisconnectWithoutContext',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::CallbackBase const &', 'cb')])
+ ## object-base.h (module 'core'): void ns3::ObjectBase::ConstructSelf(ns3::AttributeConstructionList const & attributes) [member function]
+ cls.add_method('ConstructSelf',
+ 'void',
+ [param('ns3::AttributeConstructionList const &', 'attributes')],
+ visibility='protected')
+ ## object-base.h (module 'core'): void ns3::ObjectBase::NotifyConstructionCompleted() [member function]
+ cls.add_method('NotifyConstructionCompleted',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3ObjectDeleter_methods(root_module, cls):
+ ## object.h (module 'core'): ns3::ObjectDeleter::ObjectDeleter() [constructor]
+ cls.add_constructor([])
+ ## object.h (module 'core'): ns3::ObjectDeleter::ObjectDeleter(ns3::ObjectDeleter const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectDeleter const &', 'arg0')])
+ ## object.h (module 'core'): static void ns3::ObjectDeleter::Delete(ns3::Object * object) [member function]
+ cls.add_method('Delete',
+ 'void',
+ [param('ns3::Object *', 'object')],
+ is_static=True)
+ return
+
+def register_Ns3ObjectFactory_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory(ns3::ObjectFactory const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectFactory const &', 'arg0')])
+ ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory() [constructor]
+ cls.add_constructor([])
+ ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory(std::string typeId) [constructor]
+ cls.add_constructor([param('std::string', 'typeId')])
+ ## object-factory.h (module 'core'): ns3::Ptr<ns3::Object> ns3::ObjectFactory::Create() const [member function]
+ cls.add_method('Create',
+ 'ns3::Ptr< ns3::Object >',
+ [],
+ is_const=True)
+ ## object-factory.h (module 'core'): ns3::TypeId ns3::ObjectFactory::GetTypeId() const [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::Set(std::string name, ns3::AttributeValue const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')])
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(ns3::TypeId tid) [member function]
+ cls.add_method('SetTypeId',
+ 'void',
+ [param('ns3::TypeId', 'tid')])
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(char const * tid) [member function]
+ cls.add_method('SetTypeId',
+ 'void',
+ [param('char const *', 'tid')])
+ ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(std::string tid) [member function]
+ cls.add_method('SetTypeId',
+ 'void',
+ [param('std::string', 'tid')])
+ return
+
+def register_Ns3PacketMetadata_methods(root_module, cls):
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::PacketMetadata(uint64_t uid, uint32_t size) [constructor]
+ cls.add_constructor([param('uint64_t', 'uid'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::PacketMetadata(ns3::PacketMetadata const & o) [copy constructor]
+ cls.add_constructor([param('ns3::PacketMetadata const &', 'o')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddAtEnd(ns3::PacketMetadata const & o) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('ns3::PacketMetadata const &', 'o')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddHeader(ns3::Header const & header, uint32_t size) [member function]
+ cls.add_method('AddHeader',
+ 'void',
+ [param('ns3::Header const &', 'header'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddPaddingAtEnd(uint32_t end) [member function]
+ cls.add_method('AddPaddingAtEnd',
+ 'void',
+ [param('uint32_t', 'end')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddTrailer(ns3::Trailer const & trailer, uint32_t size) [member function]
+ cls.add_method('AddTrailer',
+ 'void',
+ [param('ns3::Trailer const &', 'trailer'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator ns3::PacketMetadata::BeginItem(ns3::Buffer buffer) const [member function]
+ cls.add_method('BeginItem',
+ 'ns3::PacketMetadata::ItemIterator',
+ [param('ns3::Buffer', 'buffer')],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata ns3::PacketMetadata::CreateFragment(uint32_t start, uint32_t end) const [member function]
+ cls.add_method('CreateFragment',
+ 'ns3::PacketMetadata',
+ [param('uint32_t', 'start'), param('uint32_t', 'end')],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::Deserialize(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): static void ns3::PacketMetadata::Enable() [member function]
+ cls.add_method('Enable',
+ 'void',
+ [],
+ is_static=True)
+ ## packet-metadata.h (module 'network'): static void ns3::PacketMetadata::EnableChecking() [member function]
+ cls.add_method('EnableChecking',
+ 'void',
+ [],
+ is_static=True)
+ ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): uint64_t ns3::PacketMetadata::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveAtEnd(uint32_t end) [member function]
+ cls.add_method('RemoveAtEnd',
+ 'void',
+ [param('uint32_t', 'end')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveAtStart(uint32_t start) [member function]
+ cls.add_method('RemoveAtStart',
+ 'void',
+ [param('uint32_t', 'start')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveHeader(ns3::Header const & header, uint32_t size) [member function]
+ cls.add_method('RemoveHeader',
+ 'void',
+ [param('ns3::Header const &', 'header'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveTrailer(ns3::Trailer const & trailer, uint32_t size) [member function]
+ cls.add_method('RemoveTrailer',
+ 'void',
+ [param('ns3::Trailer const &', 'trailer'), param('uint32_t', 'size')])
+ ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ return
+
+def register_Ns3PacketMetadataItem_methods(root_module, cls):
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::Item() [constructor]
+ cls.add_constructor([])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::Item(ns3::PacketMetadata::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketMetadata::Item const &', 'arg0')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::current [variable]
+ cls.add_instance_attribute('current', 'ns3::Buffer::Iterator', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentSize [variable]
+ cls.add_instance_attribute('currentSize', 'uint32_t', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentTrimedFromEnd [variable]
+ cls.add_instance_attribute('currentTrimedFromEnd', 'uint32_t', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentTrimedFromStart [variable]
+ cls.add_instance_attribute('currentTrimedFromStart', 'uint32_t', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::isFragment [variable]
+ cls.add_instance_attribute('isFragment', 'bool', is_const=False)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::tid [variable]
+ cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False)
+ return
+
+def register_Ns3PacketMetadataItemIterator_methods(root_module, cls):
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator::ItemIterator(ns3::PacketMetadata::ItemIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketMetadata::ItemIterator const &', 'arg0')])
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator::ItemIterator(ns3::PacketMetadata const * metadata, ns3::Buffer buffer) [constructor]
+ cls.add_constructor([param('ns3::PacketMetadata const *', 'metadata'), param('ns3::Buffer', 'buffer')])
+ ## packet-metadata.h (module 'network'): bool ns3::PacketMetadata::ItemIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item ns3::PacketMetadata::ItemIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::PacketMetadata::Item',
+ [])
+ return
+
+def register_Ns3PacketTagIterator_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::PacketTagIterator::PacketTagIterator(ns3::PacketTagIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagIterator const &', 'arg0')])
+ ## packet.h (module 'network'): bool ns3::PacketTagIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::PacketTagIterator::Item ns3::PacketTagIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::PacketTagIterator::Item',
+ [])
+ return
+
+def register_Ns3PacketTagIteratorItem_methods(root_module, cls):
+ ## packet.h (module 'network'): ns3::PacketTagIterator::Item::Item(ns3::PacketTagIterator::Item const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagIterator::Item const &', 'arg0')])
+ ## packet.h (module 'network'): void ns3::PacketTagIterator::Item::GetTag(ns3::Tag & tag) const [member function]
+ cls.add_method('GetTag',
+ 'void',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::TypeId ns3::PacketTagIterator::Item::GetTypeId() const [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ return
+
+def register_Ns3PacketTagList_methods(root_module, cls):
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::PacketTagList() [constructor]
+ cls.add_constructor([])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::PacketTagList(ns3::PacketTagList const & o) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagList const &', 'o')])
+ ## packet-tag-list.h (module 'network'): void ns3::PacketTagList::Add(ns3::Tag const & tag) const [member function]
+ cls.add_method('Add',
+ 'void',
+ [param('ns3::Tag const &', 'tag')],
+ is_const=True)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData const * ns3::PacketTagList::Head() const [member function]
+ cls.add_method('Head',
+ 'ns3::PacketTagList::TagData const *',
+ [],
+ is_const=True)
+ ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Peek(ns3::Tag & tag) const [member function]
+ cls.add_method('Peek',
+ 'bool',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Remove(ns3::Tag & tag) [member function]
+ cls.add_method('Remove',
+ 'bool',
+ [param('ns3::Tag &', 'tag')])
+ ## packet-tag-list.h (module 'network'): void ns3::PacketTagList::RemoveAll() [member function]
+ cls.add_method('RemoveAll',
+ 'void',
+ [])
+ return
+
+def register_Ns3PacketTagListTagData_methods(root_module, cls):
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData() [constructor]
+ cls.add_constructor([])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData(ns3::PacketTagList::TagData const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PacketTagList::TagData const &', 'arg0')])
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::count [variable]
+ cls.add_instance_attribute('count', 'uint32_t', is_const=False)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::data [variable]
+ cls.add_instance_attribute('data', 'uint8_t [ 20 ]', is_const=False)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::next [variable]
+ cls.add_instance_attribute('next', 'ns3::PacketTagList::TagData *', is_const=False)
+ ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::tid [variable]
+ cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False)
+ return
+
+def register_Ns3PcapFile_methods(root_module, cls):
+ ## pcap-file.h (module 'network'): ns3::PcapFile::PcapFile() [constructor]
+ cls.add_constructor([])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Clear() [member function]
+ cls.add_method('Clear',
+ 'void',
+ [])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Close() [member function]
+ cls.add_method('Close',
+ 'void',
+ [])
+ ## pcap-file.h (module 'network'): static bool ns3::PcapFile::Diff(std::string const & f1, std::string const & f2, uint32_t & sec, uint32_t & usec, uint32_t snapLen=ns3::PcapFile::SNAPLEN_DEFAULT) [member function]
+ cls.add_method('Diff',
+ 'bool',
+ [param('std::string const &', 'f1'), param('std::string const &', 'f2'), param('uint32_t &', 'sec'), param('uint32_t &', 'usec'), param('uint32_t', 'snapLen', default_value='ns3::PcapFile::SNAPLEN_DEFAULT')],
+ is_static=True)
+ ## pcap-file.h (module 'network'): bool ns3::PcapFile::Eof() const [member function]
+ cls.add_method('Eof',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file.h (module 'network'): bool ns3::PcapFile::Fail() const [member function]
+ cls.add_method('Fail',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetDataLinkType() [member function]
+ cls.add_method('GetDataLinkType',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetMagic() [member function]
+ cls.add_method('GetMagic',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetSigFigs() [member function]
+ cls.add_method('GetSigFigs',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint32_t ns3::PcapFile::GetSnapLen() [member function]
+ cls.add_method('GetSnapLen',
+ 'uint32_t',
+ [])
+ ## pcap-file.h (module 'network'): bool ns3::PcapFile::GetSwapMode() [member function]
+ cls.add_method('GetSwapMode',
+ 'bool',
+ [])
+ ## pcap-file.h (module 'network'): int32_t ns3::PcapFile::GetTimeZoneOffset() [member function]
+ cls.add_method('GetTimeZoneOffset',
+ 'int32_t',
+ [])
+ ## pcap-file.h (module 'network'): uint16_t ns3::PcapFile::GetVersionMajor() [member function]
+ cls.add_method('GetVersionMajor',
+ 'uint16_t',
+ [])
+ ## pcap-file.h (module 'network'): uint16_t ns3::PcapFile::GetVersionMinor() [member function]
+ cls.add_method('GetVersionMinor',
+ 'uint16_t',
+ [])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Init(uint32_t dataLinkType, uint32_t snapLen=ns3::PcapFile::SNAPLEN_DEFAULT, int32_t timeZoneCorrection=ns3::PcapFile::ZONE_DEFAULT, bool swapMode=false) [member function]
+ cls.add_method('Init',
+ 'void',
+ [param('uint32_t', 'dataLinkType'), param('uint32_t', 'snapLen', default_value='ns3::PcapFile::SNAPLEN_DEFAULT'), param('int32_t', 'timeZoneCorrection', default_value='ns3::PcapFile::ZONE_DEFAULT'), param('bool', 'swapMode', default_value='false')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Open(std::string const & filename, std::_Ios_Openmode mode) [member function]
+ cls.add_method('Open',
+ 'void',
+ [param('std::string const &', 'filename'), param('std::_Ios_Openmode', 'mode')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Read(uint8_t * const data, uint32_t maxBytes, uint32_t & tsSec, uint32_t & tsUsec, uint32_t & inclLen, uint32_t & origLen, uint32_t & readLen) [member function]
+ cls.add_method('Read',
+ 'void',
+ [param('uint8_t * const', 'data'), param('uint32_t', 'maxBytes'), param('uint32_t &', 'tsSec'), param('uint32_t &', 'tsUsec'), param('uint32_t &', 'inclLen'), param('uint32_t &', 'origLen'), param('uint32_t &', 'readLen')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Write(uint32_t tsSec, uint32_t tsUsec, uint8_t const * const data, uint32_t totalLen) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint32_t', 'tsSec'), param('uint32_t', 'tsUsec'), param('uint8_t const * const', 'data'), param('uint32_t', 'totalLen')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Write(uint32_t tsSec, uint32_t tsUsec, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint32_t', 'tsSec'), param('uint32_t', 'tsUsec'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file.h (module 'network'): void ns3::PcapFile::Write(uint32_t tsSec, uint32_t tsUsec, ns3::Header & header, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint32_t', 'tsSec'), param('uint32_t', 'tsUsec'), param('ns3::Header &', 'header'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file.h (module 'network'): ns3::PcapFile::SNAPLEN_DEFAULT [variable]
+ cls.add_static_attribute('SNAPLEN_DEFAULT', 'uint32_t const', is_const=True)
+ ## pcap-file.h (module 'network'): ns3::PcapFile::ZONE_DEFAULT [variable]
+ cls.add_static_attribute('ZONE_DEFAULT', 'int32_t const', is_const=True)
+ return
+
+def register_Ns3PcapHelper_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::PcapHelper::PcapHelper(ns3::PcapHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PcapHelper const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::PcapHelper::PcapHelper() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): ns3::Ptr<ns3::PcapFileWrapper> ns3::PcapHelper::CreateFile(std::string filename, std::_Ios_Openmode filemode, uint32_t dataLinkType, uint32_t snapLen=65535, int32_t tzCorrection=0) [member function]
+ cls.add_method('CreateFile',
+ 'ns3::Ptr< ns3::PcapFileWrapper >',
+ [param('std::string', 'filename'), param('std::_Ios_Openmode', 'filemode'), param('uint32_t', 'dataLinkType'), param('uint32_t', 'snapLen', default_value='65535'), param('int32_t', 'tzCorrection', default_value='0')])
+ ## trace-helper.h (module 'network'): std::string ns3::PcapHelper::GetFilenameFromDevice(std::string prefix, ns3::Ptr<ns3::NetDevice> device, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromDevice',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'device'), param('bool', 'useObjectNames', default_value='true')])
+ ## trace-helper.h (module 'network'): std::string ns3::PcapHelper::GetFilenameFromInterfacePair(std::string prefix, ns3::Ptr<ns3::Object> object, uint32_t interface, bool useObjectNames=true) [member function]
+ cls.add_method('GetFilenameFromInterfacePair',
+ 'std::string',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::Object >', 'object'), param('uint32_t', 'interface'), param('bool', 'useObjectNames', default_value='true')])
+ return
+
+def register_Ns3PcapHelperForDevice_methods(root_module, cls):
+ ## trace-helper.h (module 'network'): ns3::PcapHelperForDevice::PcapHelperForDevice(ns3::PcapHelperForDevice const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PcapHelperForDevice const &', 'arg0')])
+ ## trace-helper.h (module 'network'): ns3::PcapHelperForDevice::PcapHelperForDevice() [constructor]
+ cls.add_constructor([])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool promiscuous=false, bool explicitFilename=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'promiscuous', default_value='false'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, std::string ndName, bool promiscuous=false, bool explicitFilename=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('std::string', 'ndName'), param('bool', 'promiscuous', default_value='false'), param('bool', 'explicitFilename', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, ns3::NetDeviceContainer d, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NetDeviceContainer', 'd'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, ns3::NodeContainer n, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::NodeContainer', 'n'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcap(std::string prefix, uint32_t nodeid, uint32_t deviceid, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcap',
+ 'void',
+ [param('std::string', 'prefix'), param('uint32_t', 'nodeid'), param('uint32_t', 'deviceid'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcapAll(std::string prefix, bool promiscuous=false) [member function]
+ cls.add_method('EnablePcapAll',
+ 'void',
+ [param('std::string', 'prefix'), param('bool', 'promiscuous', default_value='false')])
+ ## trace-helper.h (module 'network'): void ns3::PcapHelperForDevice::EnablePcapInternal(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool promiscuous, bool explicitFilename) [member function]
+ cls.add_method('EnablePcapInternal',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'promiscuous'), param('bool', 'explicitFilename')],
+ is_pure_virtual=True, is_virtual=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::SimpleRefCount(ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter> const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3Simulator_methods(root_module, cls):
+ ## simulator.h (module 'core'): ns3::Simulator::Simulator(ns3::Simulator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Simulator const &', 'arg0')])
+ ## simulator.h (module 'core'): static void ns3::Simulator::Cancel(ns3::EventId const & id) [member function]
+ cls.add_method('Cancel',
+ 'void',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Destroy() [member function]
+ cls.add_method('Destroy',
+ 'void',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static uint32_t ns3::Simulator::GetContext() [member function]
+ cls.add_method('GetContext',
+ 'uint32_t',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::GetDelayLeft(ns3::EventId const & id) [member function]
+ cls.add_method('GetDelayLeft',
+ 'ns3::Time',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Ptr<ns3::SimulatorImpl> ns3::Simulator::GetImplementation() [member function]
+ cls.add_method('GetImplementation',
+ 'ns3::Ptr< ns3::SimulatorImpl >',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::GetMaximumSimulationTime() [member function]
+ cls.add_method('GetMaximumSimulationTime',
+ 'ns3::Time',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static uint32_t ns3::Simulator::GetSystemId() [member function]
+ cls.add_method('GetSystemId',
+ 'uint32_t',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static bool ns3::Simulator::IsExpired(ns3::EventId const & id) [member function]
+ cls.add_method('IsExpired',
+ 'bool',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): static bool ns3::Simulator::IsFinished() [member function]
+ cls.add_method('IsFinished',
+ 'bool',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::Now() [member function]
+ cls.add_method('Now',
+ 'ns3::Time',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Remove(ns3::EventId const & id) [member function]
+ cls.add_method('Remove',
+ 'void',
+ [param('ns3::EventId const &', 'id')],
+ is_static=True)
+ ## simulator.h (module 'core'): 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)
+ ## simulator.h (module 'core'): static void ns3::Simulator::SetScheduler(ns3::ObjectFactory schedulerFactory) [member function]
+ cls.add_method('SetScheduler',
+ 'void',
+ [param('ns3::ObjectFactory', 'schedulerFactory')],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Stop() [member function]
+ cls.add_method('Stop',
+ 'void',
+ [],
+ is_static=True)
+ ## simulator.h (module 'core'): static void ns3::Simulator::Stop(ns3::Time const & time) [member function]
+ cls.add_method('Stop',
+ 'void',
+ [param('ns3::Time const &', 'time')],
+ is_static=True)
+ return
+
+def register_Ns3SystemCondition_methods(root_module, cls):
+ ## system-condition.h (module 'core'): ns3::SystemCondition::SystemCondition(ns3::SystemCondition const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::SystemCondition const &', 'arg0')])
+ ## system-condition.h (module 'core'): ns3::SystemCondition::SystemCondition() [constructor]
+ cls.add_constructor([])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::Broadcast() [member function]
+ cls.add_method('Broadcast',
+ 'void',
+ [])
+ ## system-condition.h (module 'core'): bool ns3::SystemCondition::GetCondition() [member function]
+ cls.add_method('GetCondition',
+ 'bool',
+ [])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::SetCondition(bool condition) [member function]
+ cls.add_method('SetCondition',
+ 'void',
+ [param('bool', 'condition')])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::Signal() [member function]
+ cls.add_method('Signal',
+ 'void',
+ [])
+ ## system-condition.h (module 'core'): bool ns3::SystemCondition::TimedWait(uint64_t ns) [member function]
+ cls.add_method('TimedWait',
+ 'bool',
+ [param('uint64_t', 'ns')])
+ ## system-condition.h (module 'core'): void ns3::SystemCondition::Wait() [member function]
+ cls.add_method('Wait',
+ 'void',
+ [])
+ return
+
+def register_Ns3SystemMutex_methods(root_module, cls):
+ ## system-mutex.h (module 'core'): ns3::SystemMutex::SystemMutex(ns3::SystemMutex const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::SystemMutex const &', 'arg0')])
+ ## system-mutex.h (module 'core'): ns3::SystemMutex::SystemMutex() [constructor]
+ cls.add_constructor([])
+ ## system-mutex.h (module 'core'): void ns3::SystemMutex::Lock() [member function]
+ cls.add_method('Lock',
+ 'void',
+ [])
+ ## system-mutex.h (module 'core'): void ns3::SystemMutex::Unlock() [member function]
+ cls.add_method('Unlock',
+ 'void',
+ [])
+ return
+
+def register_Ns3Tag_methods(root_module, cls):
+ ## tag.h (module 'network'): ns3::Tag::Tag() [constructor]
+ cls.add_constructor([])
+ ## tag.h (module 'network'): ns3::Tag::Tag(ns3::Tag const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Tag const &', 'arg0')])
+ ## tag.h (module 'network'): void ns3::Tag::Deserialize(ns3::TagBuffer i) [member function]
+ cls.add_method('Deserialize',
+ 'void',
+ [param('ns3::TagBuffer', 'i')],
+ is_pure_virtual=True, is_virtual=True)
+ ## tag.h (module 'network'): uint32_t ns3::Tag::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## tag.h (module 'network'): static ns3::TypeId ns3::Tag::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## tag.h (module 'network'): void ns3::Tag::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## tag.h (module 'network'): void ns3::Tag::Serialize(ns3::TagBuffer i) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::TagBuffer', 'i')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3TagBuffer_methods(root_module, cls):
+ ## tag-buffer.h (module 'network'): ns3::TagBuffer::TagBuffer(ns3::TagBuffer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TagBuffer const &', 'arg0')])
+ ## tag-buffer.h (module 'network'): ns3::TagBuffer::TagBuffer(uint8_t * start, uint8_t * end) [constructor]
+ cls.add_constructor([param('uint8_t *', 'start'), param('uint8_t *', 'end')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::CopyFrom(ns3::TagBuffer o) [member function]
+ cls.add_method('CopyFrom',
+ 'void',
+ [param('ns3::TagBuffer', 'o')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::Read(uint8_t * buffer, uint32_t size) [member function]
+ cls.add_method('Read',
+ 'void',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')])
+ ## tag-buffer.h (module 'network'): double ns3::TagBuffer::ReadDouble() [member function]
+ cls.add_method('ReadDouble',
+ 'double',
+ [])
+ ## tag-buffer.h (module 'network'): uint16_t ns3::TagBuffer::ReadU16() [member function]
+ cls.add_method('ReadU16',
+ 'uint16_t',
+ [])
+ ## tag-buffer.h (module 'network'): uint32_t ns3::TagBuffer::ReadU32() [member function]
+ cls.add_method('ReadU32',
+ 'uint32_t',
+ [])
+ ## tag-buffer.h (module 'network'): uint64_t ns3::TagBuffer::ReadU64() [member function]
+ cls.add_method('ReadU64',
+ 'uint64_t',
+ [])
+ ## tag-buffer.h (module 'network'): uint8_t ns3::TagBuffer::ReadU8() [member function]
+ cls.add_method('ReadU8',
+ 'uint8_t',
+ [])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::TrimAtEnd(uint32_t trim) [member function]
+ cls.add_method('TrimAtEnd',
+ 'void',
+ [param('uint32_t', 'trim')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::Write(uint8_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteDouble(double v) [member function]
+ cls.add_method('WriteDouble',
+ 'void',
+ [param('double', 'v')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU16(uint16_t data) [member function]
+ cls.add_method('WriteU16',
+ 'void',
+ [param('uint16_t', 'data')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU32(uint32_t data) [member function]
+ cls.add_method('WriteU32',
+ 'void',
+ [param('uint32_t', 'data')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU64(uint64_t v) [member function]
+ cls.add_method('WriteU64',
+ 'void',
+ [param('uint64_t', 'v')])
+ ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU8(uint8_t v) [member function]
+ cls.add_method('WriteU8',
+ 'void',
+ [param('uint8_t', 'v')])
+ return
+
+def register_Ns3TypeId_methods(root_module, cls):
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('==')
+ ## type-id.h (module 'core'): ns3::TypeId::TypeId(char const * name) [constructor]
+ cls.add_constructor([param('char const *', 'name')])
+ ## type-id.h (module 'core'): ns3::TypeId::TypeId() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeId::TypeId(ns3::TypeId const & o) [copy constructor]
+ cls.add_constructor([param('ns3::TypeId const &', 'o')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddAttribute(std::string name, std::string help, ns3::AttributeValue const & initialValue, ns3::Ptr<ns3::AttributeAccessor const> accessor, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('AddAttribute',
+ 'ns3::TypeId',
+ [param('std::string', 'name'), param('std::string', 'help'), param('ns3::AttributeValue const &', 'initialValue'), param('ns3::Ptr< ns3::AttributeAccessor const >', 'accessor'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddAttribute(std::string name, std::string help, uint32_t flags, ns3::AttributeValue const & initialValue, ns3::Ptr<ns3::AttributeAccessor const> accessor, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('AddAttribute',
+ 'ns3::TypeId',
+ [param('std::string', 'name'), param('std::string', 'help'), param('uint32_t', 'flags'), param('ns3::AttributeValue const &', 'initialValue'), param('ns3::Ptr< ns3::AttributeAccessor const >', 'accessor'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddTraceSource(std::string name, std::string help, ns3::Ptr<ns3::TraceSourceAccessor const> accessor) [member function]
+ cls.add_method('AddTraceSource',
+ 'ns3::TypeId',
+ [param('std::string', 'name'), param('std::string', 'help'), param('ns3::Ptr< ns3::TraceSourceAccessor const >', 'accessor')])
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation ns3::TypeId::GetAttribute(uint32_t i) const [member function]
+ cls.add_method('GetAttribute',
+ 'ns3::TypeId::AttributeInformation',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeId::GetAttributeFullName(uint32_t i) const [member function]
+ cls.add_method('GetAttributeFullName',
+ 'std::string',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## type-id.h (module 'core'): uint32_t ns3::TypeId::GetAttributeN() const [member function]
+ cls.add_method('GetAttributeN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): ns3::Callback<ns3::ObjectBase*,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::TypeId::GetConstructor() const [member function]
+ cls.add_method('GetConstructor',
+ 'ns3::Callback< ns3::ObjectBase *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeId::GetGroupName() const [member function]
+ cls.add_method('GetGroupName',
+ 'std::string',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeId::GetName() const [member function]
+ cls.add_method('GetName',
+ 'std::string',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::GetParent() const [member function]
+ cls.add_method('GetParent',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): static ns3::TypeId ns3::TypeId::GetRegistered(uint32_t i) [member function]
+ cls.add_method('GetRegistered',
+ 'ns3::TypeId',
+ [param('uint32_t', 'i')],
+ is_static=True)
+ ## type-id.h (module 'core'): static uint32_t ns3::TypeId::GetRegisteredN() [member function]
+ cls.add_method('GetRegisteredN',
+ 'uint32_t',
+ [],
+ is_static=True)
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation ns3::TypeId::GetTraceSource(uint32_t i) const [member function]
+ cls.add_method('GetTraceSource',
+ 'ns3::TypeId::TraceSourceInformation',
+ [param('uint32_t', 'i')],
+ is_const=True)
+ ## type-id.h (module 'core'): uint32_t ns3::TypeId::GetTraceSourceN() const [member function]
+ cls.add_method('GetTraceSourceN',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): uint16_t ns3::TypeId::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint16_t',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::HasConstructor() const [member function]
+ cls.add_method('HasConstructor',
+ 'bool',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::HasParent() const [member function]
+ cls.add_method('HasParent',
+ 'bool',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::HideFromDocumentation() [member function]
+ cls.add_method('HideFromDocumentation',
+ 'ns3::TypeId',
+ [])
+ ## type-id.h (module 'core'): bool ns3::TypeId::IsChildOf(ns3::TypeId other) const [member function]
+ cls.add_method('IsChildOf',
+ 'bool',
+ [param('ns3::TypeId', 'other')],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::LookupAttributeByName(std::string name, ns3::TypeId::AttributeInformation * info) const [member function]
+ cls.add_method('LookupAttributeByName',
+ 'bool',
+ [param('std::string', 'name'), param('ns3::TypeId::AttributeInformation *', 'info', transfer_ownership=False)],
+ is_const=True)
+ ## type-id.h (module 'core'): static ns3::TypeId ns3::TypeId::LookupByName(std::string name) [member function]
+ cls.add_method('LookupByName',
+ 'ns3::TypeId',
+ [param('std::string', 'name')],
+ is_static=True)
+ ## type-id.h (module 'core'): ns3::Ptr<ns3::TraceSourceAccessor const> ns3::TypeId::LookupTraceSourceByName(std::string name) const [member function]
+ cls.add_method('LookupTraceSourceByName',
+ 'ns3::Ptr< ns3::TraceSourceAccessor const >',
+ [param('std::string', 'name')],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::MustHideFromDocumentation() const [member function]
+ cls.add_method('MustHideFromDocumentation',
+ 'bool',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): bool ns3::TypeId::SetAttributeInitialValue(uint32_t i, ns3::Ptr<ns3::AttributeValue const> initialValue) [member function]
+ cls.add_method('SetAttributeInitialValue',
+ 'bool',
+ [param('uint32_t', 'i'), param('ns3::Ptr< ns3::AttributeValue const >', 'initialValue')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::SetGroupName(std::string groupName) [member function]
+ cls.add_method('SetGroupName',
+ 'ns3::TypeId',
+ [param('std::string', 'groupName')])
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::SetParent(ns3::TypeId tid) [member function]
+ cls.add_method('SetParent',
+ 'ns3::TypeId',
+ [param('ns3::TypeId', 'tid')])
+ ## type-id.h (module 'core'): void ns3::TypeId::SetUid(uint16_t tid) [member function]
+ cls.add_method('SetUid',
+ 'void',
+ [param('uint16_t', 'tid')])
+ return
+
+def register_Ns3TypeIdAttributeInformation_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::AttributeInformation() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::AttributeInformation(ns3::TypeId::AttributeInformation const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeId::AttributeInformation const &', 'arg0')])
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::accessor [variable]
+ cls.add_instance_attribute('accessor', 'ns3::Ptr< ns3::AttributeAccessor const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::checker [variable]
+ cls.add_instance_attribute('checker', 'ns3::Ptr< ns3::AttributeChecker const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::flags [variable]
+ cls.add_instance_attribute('flags', 'uint32_t', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::help [variable]
+ cls.add_instance_attribute('help', 'std::string', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::initialValue [variable]
+ cls.add_instance_attribute('initialValue', 'ns3::Ptr< ns3::AttributeValue const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::name [variable]
+ cls.add_instance_attribute('name', 'std::string', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::originalInitialValue [variable]
+ cls.add_instance_attribute('originalInitialValue', 'ns3::Ptr< ns3::AttributeValue const >', is_const=False)
+ return
+
+def register_Ns3TypeIdTraceSourceInformation_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::TraceSourceInformation() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::TraceSourceInformation(ns3::TypeId::TraceSourceInformation const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeId::TraceSourceInformation const &', 'arg0')])
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::accessor [variable]
+ cls.add_instance_attribute('accessor', 'ns3::Ptr< ns3::TraceSourceAccessor const >', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::help [variable]
+ cls.add_instance_attribute('help', 'std::string', is_const=False)
+ ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::name [variable]
+ cls.add_instance_attribute('name', 'std::string', is_const=False)
+ return
+
+def register_Ns3Empty_methods(root_module, cls):
+ ## empty.h (module 'core'): ns3::empty::empty() [constructor]
+ cls.add_constructor([])
+ ## empty.h (module 'core'): ns3::empty::empty(ns3::empty const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::empty const &', 'arg0')])
+ return
+
+def register_Ns3Int64x64_t_methods(root_module, cls):
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_unary_numeric_operator('-')
+ cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short unsigned int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('unsigned char const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long long int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('long int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('short int const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('signed char const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('double const', 'right'))
+ cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', 'right'))
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('>')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', 'right'))
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('<=')
+ cls.add_binary_comparison_operator('==')
+ cls.add_binary_comparison_operator('>=')
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t() [constructor]
+ cls.add_constructor([])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(double v) [constructor]
+ cls.add_constructor([param('double', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(int v) [constructor]
+ cls.add_constructor([param('int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long int v) [constructor]
+ cls.add_constructor([param('long int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long long int v) [constructor]
+ cls.add_constructor([param('long long int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(unsigned int v) [constructor]
+ cls.add_constructor([param('unsigned int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long unsigned int v) [constructor]
+ cls.add_constructor([param('long unsigned int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long long unsigned int v) [constructor]
+ cls.add_constructor([param('long long unsigned int', 'v')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(int64_t hi, uint64_t lo) [constructor]
+ cls.add_constructor([param('int64_t', 'hi'), param('uint64_t', 'lo')])
+ ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(ns3::int64x64_t const & o) [copy constructor]
+ cls.add_constructor([param('ns3::int64x64_t const &', 'o')])
+ ## int64x64-double.h (module 'core'): double ns3::int64x64_t::GetDouble() const [member function]
+ cls.add_method('GetDouble',
+ 'double',
+ [],
+ is_const=True)
+ ## int64x64-double.h (module 'core'): int64_t ns3::int64x64_t::GetHigh() const [member function]
+ cls.add_method('GetHigh',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## int64x64-double.h (module 'core'): uint64_t ns3::int64x64_t::GetLow() const [member function]
+ cls.add_method('GetLow',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## int64x64-double.h (module 'core'): static ns3::int64x64_t ns3::int64x64_t::Invert(uint64_t v) [member function]
+ cls.add_method('Invert',
+ 'ns3::int64x64_t',
+ [param('uint64_t', 'v')],
+ is_static=True)
+ ## int64x64-double.h (module 'core'): void ns3::int64x64_t::MulByInvert(ns3::int64x64_t const & o) [member function]
+ cls.add_method('MulByInvert',
+ 'void',
+ [param('ns3::int64x64_t const &', 'o')])
+ return
+
+def register_Ns3Chunk_methods(root_module, cls):
+ ## chunk.h (module 'network'): ns3::Chunk::Chunk() [constructor]
+ cls.add_constructor([])
+ ## chunk.h (module 'network'): ns3::Chunk::Chunk(ns3::Chunk const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Chunk const &', 'arg0')])
+ ## chunk.h (module 'network'): uint32_t ns3::Chunk::Deserialize(ns3::Buffer::Iterator start) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_virtual=True)
+ ## chunk.h (module 'network'): static ns3::TypeId ns3::Chunk::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## chunk.h (module 'network'): void ns3::Chunk::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3FdNetDeviceHelper_methods(root_module, cls):
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::FdNetDeviceHelper::FdNetDeviceHelper(ns3::FdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::FdNetDeviceHelper const &', 'arg0')])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::FdNetDeviceHelper::FdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::NetDeviceContainer ns3::FdNetDeviceHelper::Install(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('Install',
+ 'ns3::NetDeviceContainer',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::NetDeviceContainer ns3::FdNetDeviceHelper::Install(std::string name) const [member function]
+ cls.add_method('Install',
+ 'ns3::NetDeviceContainer',
+ [param('std::string', 'name')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::NetDeviceContainer ns3::FdNetDeviceHelper::Install(ns3::NodeContainer const & c) const [member function]
+ cls.add_method('Install',
+ 'ns3::NetDeviceContainer',
+ [param('ns3::NodeContainer const &', 'c')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): void ns3::FdNetDeviceHelper::SetAttribute(std::string n1, ns3::AttributeValue const & v1) [member function]
+ cls.add_method('SetAttribute',
+ 'void',
+ [param('std::string', 'n1'), param('ns3::AttributeValue const &', 'v1')])
+ ## fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::FdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): void ns3::FdNetDeviceHelper::EnableAsciiInternal(ns3::Ptr<ns3::OutputStreamWrapper> stream, std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool explicitFilename) [member function]
+ cls.add_method('EnableAsciiInternal',
+ 'void',
+ [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'explicitFilename')],
+ visibility='private', is_virtual=True)
+ ## fd-net-device-helper.h (module 'fd-net-device'): void ns3::FdNetDeviceHelper::EnablePcapInternal(std::string prefix, ns3::Ptr<ns3::NetDevice> nd, bool promiscuous, bool explicitFilename) [member function]
+ cls.add_method('EnablePcapInternal',
+ 'void',
+ [param('std::string', 'prefix'), param('ns3::Ptr< ns3::NetDevice >', 'nd'), param('bool', 'promiscuous'), param('bool', 'explicitFilename')],
+ visibility='private', is_virtual=True)
+ return
+
+def register_Ns3Header_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## header.h (module 'network'): ns3::Header::Header() [constructor]
+ cls.add_constructor([])
+ ## header.h (module 'network'): ns3::Header::Header(ns3::Header const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Header const &', 'arg0')])
+ ## header.h (module 'network'): uint32_t ns3::Header::Deserialize(ns3::Buffer::Iterator start) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_virtual=True)
+ ## header.h (module 'network'): uint32_t ns3::Header::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## header.h (module 'network'): static ns3::TypeId ns3::Header::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## header.h (module 'network'): void ns3::Header::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## header.h (module 'network'): void ns3::Header::Serialize(ns3::Buffer::Iterator start) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3Object_methods(root_module, cls):
+ ## object.h (module 'core'): ns3::Object::Object() [constructor]
+ cls.add_constructor([])
+ ## object.h (module 'core'): void ns3::Object::AggregateObject(ns3::Ptr<ns3::Object> other) [member function]
+ cls.add_method('AggregateObject',
+ 'void',
+ [param('ns3::Ptr< ns3::Object >', 'other')])
+ ## object.h (module 'core'): void ns3::Object::Dispose() [member function]
+ cls.add_method('Dispose',
+ 'void',
+ [])
+ ## object.h (module 'core'): ns3::Object::AggregateIterator ns3::Object::GetAggregateIterator() const [member function]
+ cls.add_method('GetAggregateIterator',
+ 'ns3::Object::AggregateIterator',
+ [],
+ is_const=True)
+ ## object.h (module 'core'): ns3::TypeId ns3::Object::GetInstanceTypeId() const [member function]
+ cls.add_method('GetInstanceTypeId',
+ 'ns3::TypeId',
+ [],
+ is_const=True, is_virtual=True)
+ ## object.h (module 'core'): static ns3::TypeId ns3::Object::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## object.h (module 'core'): void ns3::Object::Start() [member function]
+ cls.add_method('Start',
+ 'void',
+ [])
+ ## object.h (module 'core'): ns3::Object::Object(ns3::Object const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Object const &', 'o')],
+ visibility='protected')
+ ## object.h (module 'core'): void ns3::Object::DoDispose() [member function]
+ cls.add_method('DoDispose',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ ## object.h (module 'core'): void ns3::Object::DoStart() [member function]
+ cls.add_method('DoStart',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ ## object.h (module 'core'): void ns3::Object::NotifyNewAggregate() [member function]
+ cls.add_method('NotifyNewAggregate',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3ObjectAggregateIterator_methods(root_module, cls):
+ ## object.h (module 'core'): ns3::Object::AggregateIterator::AggregateIterator(ns3::Object::AggregateIterator const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Object::AggregateIterator const &', 'arg0')])
+ ## object.h (module 'core'): ns3::Object::AggregateIterator::AggregateIterator() [constructor]
+ cls.add_constructor([])
+ ## object.h (module 'core'): bool ns3::Object::AggregateIterator::HasNext() const [member function]
+ cls.add_method('HasNext',
+ 'bool',
+ [],
+ is_const=True)
+ ## object.h (module 'core'): ns3::Ptr<ns3::Object const> ns3::Object::AggregateIterator::Next() [member function]
+ cls.add_method('Next',
+ 'ns3::Ptr< ns3::Object const >',
+ [])
+ return
+
+def register_Ns3PcapFileWrapper_methods(root_module, cls):
+ ## pcap-file-wrapper.h (module 'network'): static ns3::TypeId ns3::PcapFileWrapper::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## pcap-file-wrapper.h (module 'network'): ns3::PcapFileWrapper::PcapFileWrapper() [constructor]
+ cls.add_constructor([])
+ ## pcap-file-wrapper.h (module 'network'): bool ns3::PcapFileWrapper::Fail() const [member function]
+ cls.add_method('Fail',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file-wrapper.h (module 'network'): bool ns3::PcapFileWrapper::Eof() const [member function]
+ cls.add_method('Eof',
+ 'bool',
+ [],
+ is_const=True)
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Clear() [member function]
+ cls.add_method('Clear',
+ 'void',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Open(std::string const & filename, std::_Ios_Openmode mode) [member function]
+ cls.add_method('Open',
+ 'void',
+ [param('std::string const &', 'filename'), param('std::_Ios_Openmode', 'mode')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Close() [member function]
+ cls.add_method('Close',
+ 'void',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Init(uint32_t dataLinkType, uint32_t snapLen=std::numeric_limits<unsigned int>::max(), int32_t tzCorrection=ns3::PcapFile::ZONE_DEFAULT) [member function]
+ cls.add_method('Init',
+ 'void',
+ [param('uint32_t', 'dataLinkType'), param('uint32_t', 'snapLen', default_value='std::numeric_limits<unsigned int>::max()'), param('int32_t', 'tzCorrection', default_value='ns3::PcapFile::ZONE_DEFAULT')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Write(ns3::Time t, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Time', 't'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Write(ns3::Time t, ns3::Header & header, ns3::Ptr<const ns3::Packet> p) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Time', 't'), param('ns3::Header &', 'header'), param('ns3::Ptr< ns3::Packet const >', 'p')])
+ ## pcap-file-wrapper.h (module 'network'): void ns3::PcapFileWrapper::Write(ns3::Time t, uint8_t const * buffer, uint32_t length) [member function]
+ cls.add_method('Write',
+ 'void',
+ [param('ns3::Time', 't'), param('uint8_t const *', 'buffer'), param('uint32_t', 'length')])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetMagic() [member function]
+ cls.add_method('GetMagic',
+ 'uint32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint16_t ns3::PcapFileWrapper::GetVersionMajor() [member function]
+ cls.add_method('GetVersionMajor',
+ 'uint16_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint16_t ns3::PcapFileWrapper::GetVersionMinor() [member function]
+ cls.add_method('GetVersionMinor',
+ 'uint16_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): int32_t ns3::PcapFileWrapper::GetTimeZoneOffset() [member function]
+ cls.add_method('GetTimeZoneOffset',
+ 'int32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetSigFigs() [member function]
+ cls.add_method('GetSigFigs',
+ 'uint32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetSnapLen() [member function]
+ cls.add_method('GetSnapLen',
+ 'uint32_t',
+ [])
+ ## pcap-file-wrapper.h (module 'network'): uint32_t ns3::PcapFileWrapper::GetDataLinkType() [member function]
+ cls.add_method('GetDataLinkType',
+ 'uint32_t',
+ [])
+ return
+
+def register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter< ns3::AttributeAccessor > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter< ns3::AttributeChecker > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter< ns3::AttributeValue > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::SimpleRefCount(ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter< ns3::CallbackImplBase > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::SimpleRefCount(ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter< ns3::EventImpl > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3FdReader_Ns3Empty_Ns3DefaultDeleter__lt__ns3FdReader__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >::SimpleRefCount(ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::FdReader, ns3::empty, ns3::DefaultDeleter< ns3::FdReader > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::FdReader, ns3::empty, ns3::DefaultDeleter<ns3::FdReader> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::SimpleRefCount(ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter< ns3::NixVector > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::SimpleRefCount(ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter< ns3::OutputStreamWrapper > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::SimpleRefCount(ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter< ns3::Packet > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3SystemThread_Ns3Empty_Ns3DefaultDeleter__lt__ns3SystemThread__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >::SimpleRefCount(ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::SystemThread, ns3::empty, ns3::DefaultDeleter< ns3::SystemThread > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::SystemThread, ns3::empty, ns3::DefaultDeleter<ns3::SystemThread> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, cls):
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::SimpleRefCount() [constructor]
+ cls.add_constructor([])
+ ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::SimpleRefCount(ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> > const & o) [copy constructor]
+ cls.add_constructor([param('ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter< ns3::TraceSourceAccessor > > const &', 'o')])
+ ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::Cleanup() [member function]
+ cls.add_method('Cleanup',
+ 'void',
+ [],
+ is_static=True)
+ return
+
+def register_Ns3SystemThread_methods(root_module, cls):
+ ## system-thread.h (module 'core'): ns3::SystemThread::SystemThread(ns3::SystemThread const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::SystemThread const &', 'arg0')])
+ ## system-thread.h (module 'core'): ns3::SystemThread::SystemThread(ns3::Callback<void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [constructor]
+ cls.add_constructor([param('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'callback')])
+ ## system-thread.h (module 'core'): static bool ns3::SystemThread::Equals(pthread_t id) [member function]
+ cls.add_method('Equals',
+ 'bool',
+ [param('pthread_t', 'id')],
+ is_static=True)
+ ## system-thread.h (module 'core'): void ns3::SystemThread::Join() [member function]
+ cls.add_method('Join',
+ 'void',
+ [])
+ ## system-thread.h (module 'core'): static pthread_t ns3::SystemThread::Self() [member function]
+ cls.add_method('Self',
+ 'pthread_t',
+ [],
+ is_static=True)
+ ## system-thread.h (module 'core'): void ns3::SystemThread::Start() [member function]
+ cls.add_method('Start',
+ 'void',
+ [])
+ return
+
+def register_Ns3Time_methods(root_module, cls):
+ cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right'))
+ cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right'))
+ cls.add_binary_comparison_operator('<')
+ cls.add_binary_comparison_operator('>')
+ cls.add_binary_comparison_operator('!=')
+ cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', 'right'))
+ cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', 'right'))
+ cls.add_output_stream_operator()
+ cls.add_binary_comparison_operator('<=')
+ cls.add_binary_comparison_operator('==')
+ cls.add_binary_comparison_operator('>=')
+ ## nstime.h (module 'core'): ns3::Time::Time() [constructor]
+ cls.add_constructor([])
+ ## nstime.h (module 'core'): ns3::Time::Time(ns3::Time const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Time const &', 'o')])
+ ## nstime.h (module 'core'): ns3::Time::Time(double v) [constructor]
+ cls.add_constructor([param('double', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(int v) [constructor]
+ cls.add_constructor([param('int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long int v) [constructor]
+ cls.add_constructor([param('long int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long long int v) [constructor]
+ cls.add_constructor([param('long long int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(unsigned int v) [constructor]
+ cls.add_constructor([param('unsigned int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long unsigned int v) [constructor]
+ cls.add_constructor([param('long unsigned int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(long long unsigned int v) [constructor]
+ cls.add_constructor([param('long long unsigned int', 'v')])
+ ## nstime.h (module 'core'): ns3::Time::Time(std::string const & s) [constructor]
+ cls.add_constructor([param('std::string const &', 's')])
+ ## nstime.h (module 'core'): ns3::Time::Time(ns3::int64x64_t const & value) [constructor]
+ cls.add_constructor([param('ns3::int64x64_t const &', 'value')])
+ ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function]
+ cls.add_method('Compare',
+ 'int',
+ [param('ns3::Time const &', 'o')],
+ is_const=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & from, ns3::Time::Unit timeUnit) [member function]
+ cls.add_method('From',
+ 'ns3::Time',
+ [param('ns3::int64x64_t const &', 'from'), param('ns3::Time::Unit', 'timeUnit')],
+ is_static=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & value) [member function]
+ cls.add_method('From',
+ 'ns3::Time',
+ [param('ns3::int64x64_t const &', 'value')],
+ is_static=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::FromDouble(double value, ns3::Time::Unit timeUnit) [member function]
+ cls.add_method('FromDouble',
+ 'ns3::Time',
+ [param('double', 'value'), param('ns3::Time::Unit', 'timeUnit')],
+ is_static=True)
+ ## nstime.h (module 'core'): static ns3::Time ns3::Time::FromInteger(uint64_t value, ns3::Time::Unit timeUnit) [member function]
+ cls.add_method('FromInteger',
+ 'ns3::Time',
+ [param('uint64_t', 'value'), param('ns3::Time::Unit', 'timeUnit')],
+ is_static=True)
+ ## nstime.h (module 'core'): double ns3::Time::GetDouble() const [member function]
+ cls.add_method('GetDouble',
+ 'double',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetFemtoSeconds() const [member function]
+ cls.add_method('GetFemtoSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetInteger() const [member function]
+ cls.add_method('GetInteger',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetMicroSeconds() const [member function]
+ cls.add_method('GetMicroSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetMilliSeconds() const [member function]
+ cls.add_method('GetMilliSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetNanoSeconds() const [member function]
+ cls.add_method('GetNanoSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetPicoSeconds() const [member function]
+ cls.add_method('GetPicoSeconds',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): static ns3::Time::Unit ns3::Time::GetResolution() [member function]
+ cls.add_method('GetResolution',
+ 'ns3::Time::Unit',
+ [],
+ is_static=True)
+ ## nstime.h (module 'core'): double ns3::Time::GetSeconds() const [member function]
+ cls.add_method('GetSeconds',
+ 'double',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::GetTimeStep() const [member function]
+ cls.add_method('GetTimeStep',
+ 'int64_t',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsNegative() const [member function]
+ cls.add_method('IsNegative',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsPositive() const [member function]
+ cls.add_method('IsPositive',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsStrictlyNegative() const [member function]
+ cls.add_method('IsStrictlyNegative',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsStrictlyPositive() const [member function]
+ cls.add_method('IsStrictlyPositive',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): bool ns3::Time::IsZero() const [member function]
+ cls.add_method('IsZero',
+ 'bool',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): static void ns3::Time::SetResolution(ns3::Time::Unit resolution) [member function]
+ cls.add_method('SetResolution',
+ 'void',
+ [param('ns3::Time::Unit', 'resolution')],
+ is_static=True)
+ ## nstime.h (module 'core'): ns3::int64x64_t ns3::Time::To(ns3::Time::Unit timeUnit) const [member function]
+ cls.add_method('To',
+ 'ns3::int64x64_t',
+ [param('ns3::Time::Unit', 'timeUnit')],
+ is_const=True)
+ ## nstime.h (module 'core'): double ns3::Time::ToDouble(ns3::Time::Unit timeUnit) const [member function]
+ cls.add_method('ToDouble',
+ 'double',
+ [param('ns3::Time::Unit', 'timeUnit')],
+ is_const=True)
+ ## nstime.h (module 'core'): int64_t ns3::Time::ToInteger(ns3::Time::Unit timeUnit) const [member function]
+ cls.add_method('ToInteger',
+ 'int64_t',
+ [param('ns3::Time::Unit', 'timeUnit')],
+ is_const=True)
+ return
+
+def register_Ns3TraceSourceAccessor_methods(root_module, cls):
+ ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor::TraceSourceAccessor(ns3::TraceSourceAccessor const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TraceSourceAccessor const &', 'arg0')])
+ ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor::TraceSourceAccessor() [constructor]
+ cls.add_constructor([])
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::Connect(ns3::ObjectBase * obj, std::string context, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('Connect',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::ConnectWithoutContext(ns3::ObjectBase * obj, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('ConnectWithoutContext',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::Disconnect(ns3::ObjectBase * obj, std::string context, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('Disconnect',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::DisconnectWithoutContext(ns3::ObjectBase * obj, ns3::CallbackBase const & cb) const [member function]
+ cls.add_method('DisconnectWithoutContext',
+ 'bool',
+ [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('ns3::CallbackBase const &', 'cb')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3Trailer_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## trailer.h (module 'network'): ns3::Trailer::Trailer() [constructor]
+ cls.add_constructor([])
+ ## trailer.h (module 'network'): ns3::Trailer::Trailer(ns3::Trailer const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Trailer const &', 'arg0')])
+ ## trailer.h (module 'network'): uint32_t ns3::Trailer::Deserialize(ns3::Buffer::Iterator end) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('ns3::Buffer::Iterator', 'end')],
+ is_pure_virtual=True, is_virtual=True)
+ ## trailer.h (module 'network'): uint32_t ns3::Trailer::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trailer.h (module 'network'): static ns3::TypeId ns3::Trailer::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## trailer.h (module 'network'): void ns3::Trailer::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## trailer.h (module 'network'): void ns3::Trailer::Serialize(ns3::Buffer::Iterator start) const [member function]
+ cls.add_method('Serialize',
+ 'void',
+ [param('ns3::Buffer::Iterator', 'start')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeAccessor_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::AttributeAccessor::AttributeAccessor(ns3::AttributeAccessor const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeAccessor const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::AttributeAccessor::AttributeAccessor() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::Get(ns3::ObjectBase const * object, ns3::AttributeValue & attribute) const [member function]
+ cls.add_method('Get',
+ 'bool',
+ [param('ns3::ObjectBase const *', 'object'), param('ns3::AttributeValue &', 'attribute')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::HasGetter() const [member function]
+ cls.add_method('HasGetter',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::HasSetter() const [member function]
+ cls.add_method('HasSetter',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeAccessor::Set(ns3::ObjectBase * object, ns3::AttributeValue const & value) const [member function]
+ cls.add_method('Set',
+ 'bool',
+ [param('ns3::ObjectBase *', 'object', transfer_ownership=False), param('ns3::AttributeValue const &', 'value')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeChecker_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::AttributeChecker::AttributeChecker(ns3::AttributeChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeChecker const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::AttributeChecker::AttributeChecker() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): bool ns3::AttributeChecker::Check(ns3::AttributeValue const & value) const [member function]
+ cls.add_method('Check',
+ 'bool',
+ [param('ns3::AttributeValue const &', 'value')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeChecker::Copy(ns3::AttributeValue const & source, ns3::AttributeValue & destination) const [member function]
+ cls.add_method('Copy',
+ 'bool',
+ [param('ns3::AttributeValue const &', 'source'), param('ns3::AttributeValue &', 'destination')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeChecker::Create() const [member function]
+ cls.add_method('Create',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeChecker::CreateValidValue(ns3::AttributeValue const & value) const [member function]
+ cls.add_method('CreateValidValue',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [param('ns3::AttributeValue const &', 'value')],
+ is_const=True)
+ ## attribute.h (module 'core'): std::string ns3::AttributeChecker::GetUnderlyingTypeInformation() const [member function]
+ cls.add_method('GetUnderlyingTypeInformation',
+ 'std::string',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): std::string ns3::AttributeChecker::GetValueTypeName() const [member function]
+ cls.add_method('GetValueTypeName',
+ 'std::string',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeChecker::HasUnderlyingTypeInformation() const [member function]
+ cls.add_method('HasUnderlyingTypeInformation',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3AttributeValue_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::AttributeValue::AttributeValue(ns3::AttributeValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AttributeValue const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::AttributeValue::AttributeValue() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::AttributeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_pure_virtual=True, is_virtual=True)
+ ## attribute.h (module 'core'): std::string ns3::AttributeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3CallbackChecker_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackChecker::CallbackChecker() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::CallbackChecker::CallbackChecker(ns3::CallbackChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackChecker const &', 'arg0')])
+ return
+
+def register_Ns3CallbackImplBase_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackImplBase::CallbackImplBase() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::CallbackImplBase::CallbackImplBase(ns3::CallbackImplBase const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackImplBase const &', 'arg0')])
+ ## callback.h (module 'core'): bool ns3::CallbackImplBase::IsEqual(ns3::Ptr<ns3::CallbackImplBase const> other) const [member function]
+ cls.add_method('IsEqual',
+ 'bool',
+ [param('ns3::Ptr< ns3::CallbackImplBase const >', 'other')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3CallbackValue_methods(root_module, cls):
+ ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue(ns3::CallbackValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::CallbackValue const &', 'arg0')])
+ ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue() [constructor]
+ cls.add_constructor([])
+ ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue(ns3::CallbackBase const & base) [constructor]
+ cls.add_constructor([param('ns3::CallbackBase const &', 'base')])
+ ## callback.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::CallbackValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## callback.h (module 'core'): bool ns3::CallbackValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## callback.h (module 'core'): std::string ns3::CallbackValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## callback.h (module 'core'): void ns3::CallbackValue::Set(ns3::CallbackBase base) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::CallbackBase', 'base')])
+ return
+
+def register_Ns3DataRateChecker_methods(root_module, cls):
+ ## data-rate.h (module 'network'): ns3::DataRateChecker::DataRateChecker() [constructor]
+ cls.add_constructor([])
+ ## data-rate.h (module 'network'): ns3::DataRateChecker::DataRateChecker(ns3::DataRateChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::DataRateChecker const &', 'arg0')])
+ return
+
+def register_Ns3DataRateValue_methods(root_module, cls):
+ ## data-rate.h (module 'network'): ns3::DataRateValue::DataRateValue() [constructor]
+ cls.add_constructor([])
+ ## data-rate.h (module 'network'): ns3::DataRateValue::DataRateValue(ns3::DataRateValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::DataRateValue const &', 'arg0')])
+ ## data-rate.h (module 'network'): ns3::DataRateValue::DataRateValue(ns3::DataRate const & value) [constructor]
+ cls.add_constructor([param('ns3::DataRate const &', 'value')])
+ ## data-rate.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::DataRateValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## data-rate.h (module 'network'): bool ns3::DataRateValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## data-rate.h (module 'network'): ns3::DataRate ns3::DataRateValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::DataRate',
+ [],
+ is_const=True)
+ ## data-rate.h (module 'network'): std::string ns3::DataRateValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## data-rate.h (module 'network'): void ns3::DataRateValue::Set(ns3::DataRate const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::DataRate const &', 'value')])
+ return
+
+def register_Ns3EmptyAttributeValue_methods(root_module, cls):
+ ## attribute.h (module 'core'): ns3::EmptyAttributeValue::EmptyAttributeValue(ns3::EmptyAttributeValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EmptyAttributeValue const &', 'arg0')])
+ ## attribute.h (module 'core'): ns3::EmptyAttributeValue::EmptyAttributeValue() [constructor]
+ cls.add_constructor([])
+ ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::EmptyAttributeValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, visibility='private', is_virtual=True)
+ ## attribute.h (module 'core'): bool ns3::EmptyAttributeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ visibility='private', is_virtual=True)
+ ## attribute.h (module 'core'): std::string ns3::EmptyAttributeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, visibility='private', is_virtual=True)
+ return
+
+def register_Ns3EmuFdNetDeviceHelper_methods(root_module, cls):
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::EmuFdNetDeviceHelper::EmuFdNetDeviceHelper(ns3::EmuFdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EmuFdNetDeviceHelper const &', 'arg0')])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::EmuFdNetDeviceHelper::EmuFdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): std::string ns3::EmuFdNetDeviceHelper::GetDeviceName() [member function]
+ cls.add_method('GetDeviceName',
+ 'std::string',
+ [])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): void ns3::EmuFdNetDeviceHelper::SetDeviceName(std::string deviceName) [member function]
+ cls.add_method('SetDeviceName',
+ 'void',
+ [param('std::string', 'deviceName')])
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): int ns3::EmuFdNetDeviceHelper::CreateFileDescriptor() const [member function]
+ cls.add_method('CreateFileDescriptor',
+ 'int',
+ [],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::EmuFdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## emu-fd-net-device-helper.h (module 'fd-net-device'): void ns3::EmuFdNetDeviceHelper::SetFileDescriptor(ns3::Ptr<ns3::FdNetDevice> device) const [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('ns3::Ptr< ns3::FdNetDevice >', 'device')],
+ is_const=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3EventImpl_methods(root_module, cls):
+ ## event-impl.h (module 'core'): ns3::EventImpl::EventImpl(ns3::EventImpl const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::EventImpl const &', 'arg0')])
+ ## event-impl.h (module 'core'): ns3::EventImpl::EventImpl() [constructor]
+ cls.add_constructor([])
+ ## event-impl.h (module 'core'): void ns3::EventImpl::Cancel() [member function]
+ cls.add_method('Cancel',
+ 'void',
+ [])
+ ## event-impl.h (module 'core'): void ns3::EventImpl::Invoke() [member function]
+ cls.add_method('Invoke',
+ 'void',
+ [])
+ ## event-impl.h (module 'core'): bool ns3::EventImpl::IsCancelled() [member function]
+ cls.add_method('IsCancelled',
+ 'bool',
+ [])
+ ## event-impl.h (module 'core'): void ns3::EventImpl::Notify() [member function]
+ cls.add_method('Notify',
+ 'void',
+ [],
+ is_pure_virtual=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3FdReader_methods(root_module, cls):
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader::FdReader(ns3::FdReader const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::FdReader const &', 'arg0')])
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader::FdReader() [constructor]
+ cls.add_constructor([])
+ ## unix-fd-reader.h (module 'core'): void ns3::FdReader::Start(int fd, ns3::Callback<void, unsigned char*, long, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> readCallback) [member function]
+ cls.add_method('Start',
+ 'void',
+ [param('int', 'fd'), param('ns3::Callback< void, unsigned char *, long, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'readCallback')])
+ ## unix-fd-reader.h (module 'core'): void ns3::FdReader::Stop() [member function]
+ cls.add_method('Stop',
+ 'void',
+ [])
+ ## unix-fd-reader.h (module 'core'): ns3::FdReader::Data ns3::FdReader::DoRead() [member function]
+ cls.add_method('DoRead',
+ 'ns3::FdReader::Data',
+ [],
+ is_pure_virtual=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3Ipv4AddressChecker_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker::Ipv4AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker::Ipv4AddressChecker(ns3::Ipv4AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv4AddressValue_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue(ns3::Ipv4AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4AddressValue const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue(ns3::Ipv4Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv4Address const &', 'value')])
+ ## ipv4-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv4AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv4Address',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): std::string ns3::Ipv4AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4AddressValue::Set(ns3::Ipv4Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv4Address const &', 'value')])
+ return
+
+def register_Ns3Ipv4MaskChecker_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker::Ipv4MaskChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker::Ipv4MaskChecker(ns3::Ipv4MaskChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4MaskChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv4MaskValue_methods(root_module, cls):
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue() [constructor]
+ cls.add_constructor([])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue(ns3::Ipv4MaskValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv4MaskValue const &', 'arg0')])
+ ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue(ns3::Ipv4Mask const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv4Mask const &', 'value')])
+ ## ipv4-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv4MaskValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): bool ns3::Ipv4MaskValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv4-address.h (module 'network'): ns3::Ipv4Mask ns3::Ipv4MaskValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv4Mask',
+ [],
+ is_const=True)
+ ## ipv4-address.h (module 'network'): std::string ns3::Ipv4MaskValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv4-address.h (module 'network'): void ns3::Ipv4MaskValue::Set(ns3::Ipv4Mask const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv4Mask const &', 'value')])
+ return
+
+def register_Ns3Ipv6AddressChecker_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker(ns3::Ipv6AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv6AddressValue_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue(ns3::Ipv6AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6AddressValue const &', 'arg0')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue(ns3::Ipv6Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Address const &', 'value')])
+ ## ipv6-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv6AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Address ns3::Ipv6AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv6Address',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): std::string ns3::Ipv6AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6AddressValue::Set(ns3::Ipv6Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv6Address const &', 'value')])
+ return
+
+def register_Ns3Ipv6PrefixChecker_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker(ns3::Ipv6PrefixChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6PrefixChecker const &', 'arg0')])
+ return
+
+def register_Ns3Ipv6PrefixValue_methods(root_module, cls):
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue() [constructor]
+ cls.add_constructor([])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue(ns3::Ipv6PrefixValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Ipv6PrefixValue const &', 'arg0')])
+ ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue(ns3::Ipv6Prefix const & value) [constructor]
+ cls.add_constructor([param('ns3::Ipv6Prefix const &', 'value')])
+ ## ipv6-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv6PrefixValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): bool ns3::Ipv6PrefixValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix ns3::Ipv6PrefixValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Ipv6Prefix',
+ [],
+ is_const=True)
+ ## ipv6-address.h (module 'network'): std::string ns3::Ipv6PrefixValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## ipv6-address.h (module 'network'): void ns3::Ipv6PrefixValue::Set(ns3::Ipv6Prefix const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Ipv6Prefix const &', 'value')])
+ return
+
+def register_Ns3Mac48AddressChecker_methods(root_module, cls):
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker::Mac48AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker::Mac48AddressChecker(ns3::Mac48AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Mac48AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3Mac48AddressValue_methods(root_module, cls):
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue() [constructor]
+ cls.add_constructor([])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue(ns3::Mac48AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Mac48AddressValue const &', 'arg0')])
+ ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue(ns3::Mac48Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Mac48Address const &', 'value')])
+ ## mac48-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Mac48AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## mac48-address.h (module 'network'): bool ns3::Mac48AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## mac48-address.h (module 'network'): ns3::Mac48Address ns3::Mac48AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Mac48Address',
+ [],
+ is_const=True)
+ ## mac48-address.h (module 'network'): std::string ns3::Mac48AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## mac48-address.h (module 'network'): void ns3::Mac48AddressValue::Set(ns3::Mac48Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Mac48Address const &', 'value')])
+ return
+
+def register_Ns3NetDevice_methods(root_module, cls):
+ ## net-device.h (module 'network'): ns3::NetDevice::NetDevice() [constructor]
+ cls.add_constructor([])
+ ## net-device.h (module 'network'): ns3::NetDevice::NetDevice(ns3::NetDevice const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::NetDevice const &', 'arg0')])
+ ## net-device.h (module 'network'): void ns3::NetDevice::AddLinkChangeCallback(ns3::Callback<void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [member function]
+ cls.add_method('AddLinkChangeCallback',
+ 'void',
+ [param('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'callback')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetAddress() const [member function]
+ cls.add_method('GetAddress',
+ 'ns3::Address',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetBroadcast() const [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Address',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Ptr<ns3::Channel> ns3::NetDevice::GetChannel() const [member function]
+ cls.add_method('GetChannel',
+ 'ns3::Ptr< ns3::Channel >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): uint32_t ns3::NetDevice::GetIfIndex() const [member function]
+ cls.add_method('GetIfIndex',
+ 'uint32_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): uint16_t ns3::NetDevice::GetMtu() const [member function]
+ cls.add_method('GetMtu',
+ 'uint16_t',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetMulticast(ns3::Ipv4Address multicastGroup) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv4Address', 'multicastGroup')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetMulticast(ns3::Ipv6Address addr) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv6Address', 'addr')],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): ns3::Ptr<ns3::Node> ns3::NetDevice::GetNode() const [member function]
+ cls.add_method('GetNode',
+ 'ns3::Ptr< ns3::Node >',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): static ns3::TypeId ns3::NetDevice::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsBridge() const [member function]
+ cls.add_method('IsBridge',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsLinkUp() const [member function]
+ cls.add_method('IsLinkUp',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::IsPointToPoint() const [member function]
+ cls.add_method('IsPointToPoint',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::NeedsArp() const [member function]
+ cls.add_method('NeedsArp',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::Send(ns3::Ptr<ns3::Packet> packet, ns3::Address const & dest, uint16_t protocolNumber) [member function]
+ cls.add_method('Send',
+ 'bool',
+ [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::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 const &', 'source'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetAddress(ns3::Address address) [member function]
+ cls.add_method('SetAddress',
+ 'void',
+ [param('ns3::Address', 'address')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetIfIndex(uint32_t const index) [member function]
+ cls.add_method('SetIfIndex',
+ 'void',
+ [param('uint32_t const', 'index')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::SetMtu(uint16_t const mtu) [member function]
+ cls.add_method('SetMtu',
+ 'bool',
+ [param('uint16_t const', 'mtu')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetNode(ns3::Ptr<ns3::Node> node) [member function]
+ cls.add_method('SetNode',
+ 'void',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetPromiscReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetPromiscReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): void ns3::NetDevice::SetReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_pure_virtual=True, is_virtual=True)
+ ## net-device.h (module 'network'): bool ns3::NetDevice::SupportsSendFrom() const [member function]
+ cls.add_method('SupportsSendFrom',
+ 'bool',
+ [],
+ is_pure_virtual=True, is_const=True, is_virtual=True)
+ return
+
+def register_Ns3NixVector_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## nix-vector.h (module 'network'): ns3::NixVector::NixVector() [constructor]
+ cls.add_constructor([])
+ ## nix-vector.h (module 'network'): ns3::NixVector::NixVector(ns3::NixVector const & o) [copy constructor]
+ cls.add_constructor([param('ns3::NixVector const &', 'o')])
+ ## nix-vector.h (module 'network'): void ns3::NixVector::AddNeighborIndex(uint32_t newBits, uint32_t numberOfBits) [member function]
+ cls.add_method('AddNeighborIndex',
+ 'void',
+ [param('uint32_t', 'newBits'), param('uint32_t', 'numberOfBits')])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::BitCount(uint32_t numberOfNeighbors) const [member function]
+ cls.add_method('BitCount',
+ 'uint32_t',
+ [param('uint32_t', 'numberOfNeighbors')],
+ is_const=True)
+ ## nix-vector.h (module 'network'): ns3::Ptr<ns3::NixVector> ns3::NixVector::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::NixVector >',
+ [],
+ is_const=True)
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::Deserialize(uint32_t const * buffer, uint32_t size) [member function]
+ cls.add_method('Deserialize',
+ 'uint32_t',
+ [param('uint32_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::ExtractNeighborIndex(uint32_t numberOfBits) [member function]
+ cls.add_method('ExtractNeighborIndex',
+ 'uint32_t',
+ [param('uint32_t', 'numberOfBits')])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::GetRemainingBits() [member function]
+ cls.add_method('GetRemainingBits',
+ 'uint32_t',
+ [])
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::Serialize(uint32_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint32_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ return
+
+def register_Ns3Node_methods(root_module, cls):
+ ## node.h (module 'network'): ns3::Node::Node(ns3::Node const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::Node const &', 'arg0')])
+ ## node.h (module 'network'): ns3::Node::Node() [constructor]
+ cls.add_constructor([])
+ ## node.h (module 'network'): ns3::Node::Node(uint32_t systemId) [constructor]
+ cls.add_constructor([param('uint32_t', 'systemId')])
+ ## node.h (module 'network'): uint32_t ns3::Node::AddApplication(ns3::Ptr<ns3::Application> application) [member function]
+ cls.add_method('AddApplication',
+ 'uint32_t',
+ [param('ns3::Ptr< ns3::Application >', 'application')])
+ ## node.h (module 'network'): uint32_t ns3::Node::AddDevice(ns3::Ptr<ns3::NetDevice> device) [member function]
+ cls.add_method('AddDevice',
+ 'uint32_t',
+ [param('ns3::Ptr< ns3::NetDevice >', 'device')])
+ ## node.h (module 'network'): static bool ns3::Node::ChecksumEnabled() [member function]
+ cls.add_method('ChecksumEnabled',
+ 'bool',
+ [],
+ is_static=True)
+ ## node.h (module 'network'): ns3::Ptr<ns3::Application> ns3::Node::GetApplication(uint32_t index) const [member function]
+ cls.add_method('GetApplication',
+ 'ns3::Ptr< ns3::Application >',
+ [param('uint32_t', 'index')],
+ is_const=True)
+ ## node.h (module 'network'): ns3::Ptr<ns3::NetDevice> ns3::Node::GetDevice(uint32_t index) const [member function]
+ cls.add_method('GetDevice',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('uint32_t', 'index')],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetId() const [member function]
+ cls.add_method('GetId',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetNApplications() const [member function]
+ cls.add_method('GetNApplications',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetNDevices() const [member function]
+ cls.add_method('GetNDevices',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): uint32_t ns3::Node::GetSystemId() const [member function]
+ cls.add_method('GetSystemId',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## node.h (module 'network'): static ns3::TypeId ns3::Node::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## node.h (module 'network'): void ns3::Node::RegisterDeviceAdditionListener(ns3::Callback<void,ns3::Ptr<ns3::NetDevice>,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> listener) [member function]
+ cls.add_method('RegisterDeviceAdditionListener',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'listener')])
+ ## node.h (module 'network'): void ns3::Node::RegisterProtocolHandler(ns3::Callback<void, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler, uint16_t protocolType, ns3::Ptr<ns3::NetDevice> device, bool promiscuous=false) [member function]
+ cls.add_method('RegisterProtocolHandler',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'handler'), param('uint16_t', 'protocolType'), param('ns3::Ptr< ns3::NetDevice >', 'device'), param('bool', 'promiscuous', default_value='false')])
+ ## node.h (module 'network'): void ns3::Node::UnregisterDeviceAdditionListener(ns3::Callback<void,ns3::Ptr<ns3::NetDevice>,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> listener) [member function]
+ cls.add_method('UnregisterDeviceAdditionListener',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'listener')])
+ ## node.h (module 'network'): void ns3::Node::UnregisterProtocolHandler(ns3::Callback<void, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler) [member function]
+ cls.add_method('UnregisterProtocolHandler',
+ 'void',
+ [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'handler')])
+ ## node.h (module 'network'): void ns3::Node::DoDispose() [member function]
+ cls.add_method('DoDispose',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ ## node.h (module 'network'): void ns3::Node::DoStart() [member function]
+ cls.add_method('DoStart',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3ObjectFactoryChecker_methods(root_module, cls):
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker::ObjectFactoryChecker() [constructor]
+ cls.add_constructor([])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker::ObjectFactoryChecker(ns3::ObjectFactoryChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectFactoryChecker const &', 'arg0')])
+ return
+
+def register_Ns3ObjectFactoryValue_methods(root_module, cls):
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue() [constructor]
+ cls.add_constructor([])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue(ns3::ObjectFactoryValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::ObjectFactoryValue const &', 'arg0')])
+ ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue(ns3::ObjectFactory const & value) [constructor]
+ cls.add_constructor([param('ns3::ObjectFactory const &', 'value')])
+ ## object-factory.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::ObjectFactoryValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## object-factory.h (module 'core'): bool ns3::ObjectFactoryValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## object-factory.h (module 'core'): ns3::ObjectFactory ns3::ObjectFactoryValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::ObjectFactory',
+ [],
+ is_const=True)
+ ## object-factory.h (module 'core'): std::string ns3::ObjectFactoryValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## object-factory.h (module 'core'): void ns3::ObjectFactoryValue::Set(ns3::ObjectFactory const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::ObjectFactory const &', 'value')])
+ return
+
+def register_Ns3OutputStreamWrapper_methods(root_module, cls):
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(ns3::OutputStreamWrapper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::OutputStreamWrapper const &', 'arg0')])
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(std::string filename, std::_Ios_Openmode filemode) [constructor]
+ cls.add_constructor([param('std::string', 'filename'), param('std::_Ios_Openmode', 'filemode')])
+ ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(std::ostream * os) [constructor]
+ cls.add_constructor([param('std::ostream *', 'os')])
+ ## output-stream-wrapper.h (module 'network'): std::ostream * ns3::OutputStreamWrapper::GetStream() [member function]
+ cls.add_method('GetStream',
+ 'std::ostream *',
+ [])
+ return
+
+def register_Ns3Packet_methods(root_module, cls):
+ cls.add_output_stream_operator()
+ ## packet.h (module 'network'): ns3::Packet::Packet() [constructor]
+ cls.add_constructor([])
+ ## packet.h (module 'network'): ns3::Packet::Packet(ns3::Packet const & o) [copy constructor]
+ cls.add_constructor([param('ns3::Packet const &', 'o')])
+ ## packet.h (module 'network'): ns3::Packet::Packet(uint32_t size) [constructor]
+ cls.add_constructor([param('uint32_t', 'size')])
+ ## packet.h (module 'network'): ns3::Packet::Packet(uint8_t const * buffer, uint32_t size, bool magic) [constructor]
+ cls.add_constructor([param('uint8_t const *', 'buffer'), param('uint32_t', 'size'), param('bool', 'magic')])
+ ## packet.h (module 'network'): ns3::Packet::Packet(uint8_t const * buffer, uint32_t size) [constructor]
+ cls.add_constructor([param('uint8_t const *', 'buffer'), param('uint32_t', 'size')])
+ ## packet.h (module 'network'): void ns3::Packet::AddAtEnd(ns3::Ptr<const ns3::Packet> packet) [member function]
+ cls.add_method('AddAtEnd',
+ 'void',
+ [param('ns3::Ptr< ns3::Packet const >', 'packet')])
+ ## packet.h (module 'network'): void ns3::Packet::AddByteTag(ns3::Tag const & tag) const [member function]
+ cls.add_method('AddByteTag',
+ 'void',
+ [param('ns3::Tag const &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::AddHeader(ns3::Header const & header) [member function]
+ cls.add_method('AddHeader',
+ 'void',
+ [param('ns3::Header const &', 'header')])
+ ## packet.h (module 'network'): void ns3::Packet::AddPacketTag(ns3::Tag const & tag) const [member function]
+ cls.add_method('AddPacketTag',
+ 'void',
+ [param('ns3::Tag const &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::AddPaddingAtEnd(uint32_t size) [member function]
+ cls.add_method('AddPaddingAtEnd',
+ 'void',
+ [param('uint32_t', 'size')])
+ ## packet.h (module 'network'): void ns3::Packet::AddTrailer(ns3::Trailer const & trailer) [member function]
+ cls.add_method('AddTrailer',
+ 'void',
+ [param('ns3::Trailer const &', 'trailer')])
+ ## packet.h (module 'network'): ns3::PacketMetadata::ItemIterator ns3::Packet::BeginItem() const [member function]
+ cls.add_method('BeginItem',
+ 'ns3::PacketMetadata::ItemIterator',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Packet::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::Packet >',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::CopyData(uint8_t * buffer, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'size')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::CopyData(std::ostream * os, uint32_t size) const [member function]
+ cls.add_method('CopyData',
+ 'void',
+ [param('std::ostream *', 'os'), param('uint32_t', 'size')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Packet::CreateFragment(uint32_t start, uint32_t length) const [member function]
+ cls.add_method('CreateFragment',
+ 'ns3::Ptr< ns3::Packet >',
+ [param('uint32_t', 'start'), param('uint32_t', 'length')],
+ is_const=True)
+ ## packet.h (module 'network'): static void ns3::Packet::EnableChecking() [member function]
+ cls.add_method('EnableChecking',
+ 'void',
+ [],
+ is_static=True)
+ ## packet.h (module 'network'): static void ns3::Packet::EnablePrinting() [member function]
+ cls.add_method('EnablePrinting',
+ 'void',
+ [],
+ is_static=True)
+ ## packet.h (module 'network'): bool ns3::Packet::FindFirstMatchingByteTag(ns3::Tag & tag) const [member function]
+ cls.add_method('FindFirstMatchingByteTag',
+ 'bool',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::ByteTagIterator ns3::Packet::GetByteTagIterator() const [member function]
+ cls.add_method('GetByteTagIterator',
+ 'ns3::ByteTagIterator',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::Ptr<ns3::NixVector> ns3::Packet::GetNixVector() const [member function]
+ cls.add_method('GetNixVector',
+ 'ns3::Ptr< ns3::NixVector >',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): ns3::PacketTagIterator ns3::Packet::GetPacketTagIterator() const [member function]
+ cls.add_method('GetPacketTagIterator',
+ 'ns3::PacketTagIterator',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::GetSerializedSize() const [member function]
+ cls.add_method('GetSerializedSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::GetSize() const [member function]
+ cls.add_method('GetSize',
+ 'uint32_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint64_t ns3::Packet::GetUid() const [member function]
+ cls.add_method('GetUid',
+ 'uint64_t',
+ [],
+ is_const=True)
+ ## packet.h (module 'network'): uint8_t const * ns3::Packet::PeekData() const [member function]
+ cls.add_method('PeekData',
+ 'uint8_t const *',
+ [],
+ deprecated=True, is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::PeekHeader(ns3::Header & header) const [member function]
+ cls.add_method('PeekHeader',
+ 'uint32_t',
+ [param('ns3::Header &', 'header')],
+ is_const=True)
+ ## packet.h (module 'network'): bool ns3::Packet::PeekPacketTag(ns3::Tag & tag) const [member function]
+ cls.add_method('PeekPacketTag',
+ 'bool',
+ [param('ns3::Tag &', 'tag')],
+ is_const=True)
+ ## packet.h (module 'network'): uint32_t ns3::Packet::PeekTrailer(ns3::Trailer & trailer) [member function]
+ cls.add_method('PeekTrailer',
+ 'uint32_t',
+ [param('ns3::Trailer &', 'trailer')])
+ ## packet.h (module 'network'): void ns3::Packet::Print(std::ostream & os) const [member function]
+ cls.add_method('Print',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::PrintByteTags(std::ostream & os) const [member function]
+ cls.add_method('PrintByteTags',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::PrintPacketTags(std::ostream & os) const [member function]
+ cls.add_method('PrintPacketTags',
+ 'void',
+ [param('std::ostream &', 'os')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAllByteTags() [member function]
+ cls.add_method('RemoveAllByteTags',
+ 'void',
+ [])
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAllPacketTags() [member function]
+ cls.add_method('RemoveAllPacketTags',
+ 'void',
+ [])
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAtEnd(uint32_t size) [member function]
+ cls.add_method('RemoveAtEnd',
+ 'void',
+ [param('uint32_t', 'size')])
+ ## packet.h (module 'network'): void ns3::Packet::RemoveAtStart(uint32_t size) [member function]
+ cls.add_method('RemoveAtStart',
+ 'void',
+ [param('uint32_t', 'size')])
+ ## packet.h (module 'network'): uint32_t ns3::Packet::RemoveHeader(ns3::Header & header) [member function]
+ cls.add_method('RemoveHeader',
+ 'uint32_t',
+ [param('ns3::Header &', 'header')])
+ ## packet.h (module 'network'): bool ns3::Packet::RemovePacketTag(ns3::Tag & tag) [member function]
+ cls.add_method('RemovePacketTag',
+ 'bool',
+ [param('ns3::Tag &', 'tag')])
+ ## packet.h (module 'network'): uint32_t ns3::Packet::RemoveTrailer(ns3::Trailer & trailer) [member function]
+ cls.add_method('RemoveTrailer',
+ 'uint32_t',
+ [param('ns3::Trailer &', 'trailer')])
+ ## packet.h (module 'network'): uint32_t ns3::Packet::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function]
+ cls.add_method('Serialize',
+ 'uint32_t',
+ [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')],
+ is_const=True)
+ ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr<ns3::NixVector> arg0) [member function]
+ cls.add_method('SetNixVector',
+ 'void',
+ [param('ns3::Ptr< ns3::NixVector >', 'arg0')])
+ return
+
+def register_Ns3PlanetLabFdNetDeviceHelper_methods(root_module, cls):
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::PlanetLabFdNetDeviceHelper::PlanetLabFdNetDeviceHelper(ns3::PlanetLabFdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::PlanetLabFdNetDeviceHelper const &', 'arg0')])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::PlanetLabFdNetDeviceHelper::PlanetLabFdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): void ns3::PlanetLabFdNetDeviceHelper::SetTapIpAddress(ns3::Ipv4Address address) [member function]
+ cls.add_method('SetTapIpAddress',
+ 'void',
+ [param('ns3::Ipv4Address', 'address')])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): void ns3::PlanetLabFdNetDeviceHelper::SetTapMask(ns3::Ipv4Mask mask) [member function]
+ cls.add_method('SetTapMask',
+ 'void',
+ [param('ns3::Ipv4Mask', 'mask')])
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): int ns3::PlanetLabFdNetDeviceHelper::CreateFileDescriptor() const [member function]
+ cls.add_method('CreateFileDescriptor',
+ 'int',
+ [],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::PlanetLabFdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## planetlab-fd-net-device-helper.h (module 'fd-net-device'): void ns3::PlanetLabFdNetDeviceHelper::SetFileDescriptor(ns3::Ptr<ns3::FdNetDevice> device) const [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('ns3::Ptr< ns3::FdNetDevice >', 'device')],
+ is_const=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3TapFdNetDeviceHelper_methods(root_module, cls):
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::TapFdNetDeviceHelper::TapFdNetDeviceHelper(ns3::TapFdNetDeviceHelper const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TapFdNetDeviceHelper const &', 'arg0')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::TapFdNetDeviceHelper::TapFdNetDeviceHelper() [constructor]
+ cls.add_constructor([])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetModePi(bool pi) [member function]
+ cls.add_method('SetModePi',
+ 'void',
+ [param('bool', 'pi')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv4Address(ns3::Ipv4Address address) [member function]
+ cls.add_method('SetTapIpv4Address',
+ 'void',
+ [param('ns3::Ipv4Address', 'address')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv4Mask(ns3::Ipv4Mask mask) [member function]
+ cls.add_method('SetTapIpv4Mask',
+ 'void',
+ [param('ns3::Ipv4Mask', 'mask')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv6Address(ns3::Ipv6Address address) [member function]
+ cls.add_method('SetTapIpv6Address',
+ 'void',
+ [param('ns3::Ipv6Address', 'address')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapIpv6Prefix(int prefix) [member function]
+ cls.add_method('SetTapIpv6Prefix',
+ 'void',
+ [param('int', 'prefix')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetTapMacAddress(ns3::Mac48Address mac) [member function]
+ cls.add_method('SetTapMacAddress',
+ 'void',
+ [param('ns3::Mac48Address', 'mac')])
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): int ns3::TapFdNetDeviceHelper::CreateFileDescriptor() const [member function]
+ cls.add_method('CreateFileDescriptor',
+ 'int',
+ [],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): ns3::Ptr<ns3::NetDevice> ns3::TapFdNetDeviceHelper::InstallPriv(ns3::Ptr<ns3::Node> node) const [member function]
+ cls.add_method('InstallPriv',
+ 'ns3::Ptr< ns3::NetDevice >',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_const=True, visibility='protected', is_virtual=True)
+ ## tap-fd-net-device-helper.h (module 'fd-net-device'): void ns3::TapFdNetDeviceHelper::SetFileDescriptor(ns3::Ptr<ns3::FdNetDevice> device) const [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('ns3::Ptr< ns3::FdNetDevice >', 'device')],
+ is_const=True, visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3TimeChecker_methods(root_module, cls):
+ ## nstime.h (module 'core'): ns3::TimeChecker::TimeChecker() [constructor]
+ cls.add_constructor([])
+ ## nstime.h (module 'core'): ns3::TimeChecker::TimeChecker(ns3::TimeChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TimeChecker const &', 'arg0')])
+ return
+
+def register_Ns3TimeValue_methods(root_module, cls):
+ ## nstime.h (module 'core'): ns3::TimeValue::TimeValue() [constructor]
+ cls.add_constructor([])
+ ## nstime.h (module 'core'): ns3::TimeValue::TimeValue(ns3::TimeValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TimeValue const &', 'arg0')])
+ ## nstime.h (module 'core'): ns3::TimeValue::TimeValue(ns3::Time const & value) [constructor]
+ cls.add_constructor([param('ns3::Time const &', 'value')])
+ ## nstime.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::TimeValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## nstime.h (module 'core'): bool ns3::TimeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## nstime.h (module 'core'): ns3::Time ns3::TimeValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Time',
+ [],
+ is_const=True)
+ ## nstime.h (module 'core'): std::string ns3::TimeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## nstime.h (module 'core'): void ns3::TimeValue::Set(ns3::Time const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Time const &', 'value')])
+ return
+
+def register_Ns3TypeIdChecker_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeIdChecker::TypeIdChecker() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeIdChecker::TypeIdChecker(ns3::TypeIdChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeIdChecker const &', 'arg0')])
+ return
+
+def register_Ns3TypeIdValue_methods(root_module, cls):
+ ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue() [constructor]
+ cls.add_constructor([])
+ ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue(ns3::TypeIdValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::TypeIdValue const &', 'arg0')])
+ ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue(ns3::TypeId const & value) [constructor]
+ cls.add_constructor([param('ns3::TypeId const &', 'value')])
+ ## type-id.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::TypeIdValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## type-id.h (module 'core'): bool ns3::TypeIdValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## type-id.h (module 'core'): ns3::TypeId ns3::TypeIdValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::TypeId',
+ [],
+ is_const=True)
+ ## type-id.h (module 'core'): std::string ns3::TypeIdValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## type-id.h (module 'core'): void ns3::TypeIdValue::Set(ns3::TypeId const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::TypeId const &', 'value')])
+ return
+
+def register_Ns3AddressChecker_methods(root_module, cls):
+ ## address.h (module 'network'): ns3::AddressChecker::AddressChecker() [constructor]
+ cls.add_constructor([])
+ ## address.h (module 'network'): ns3::AddressChecker::AddressChecker(ns3::AddressChecker const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AddressChecker const &', 'arg0')])
+ return
+
+def register_Ns3AddressValue_methods(root_module, cls):
+ ## address.h (module 'network'): ns3::AddressValue::AddressValue() [constructor]
+ cls.add_constructor([])
+ ## address.h (module 'network'): ns3::AddressValue::AddressValue(ns3::AddressValue const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::AddressValue const &', 'arg0')])
+ ## address.h (module 'network'): ns3::AddressValue::AddressValue(ns3::Address const & value) [constructor]
+ cls.add_constructor([param('ns3::Address const &', 'value')])
+ ## address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::AddressValue::Copy() const [member function]
+ cls.add_method('Copy',
+ 'ns3::Ptr< ns3::AttributeValue >',
+ [],
+ is_const=True, is_virtual=True)
+ ## address.h (module 'network'): bool ns3::AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function]
+ cls.add_method('DeserializeFromString',
+ 'bool',
+ [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_virtual=True)
+ ## address.h (module 'network'): ns3::Address ns3::AddressValue::Get() const [member function]
+ cls.add_method('Get',
+ 'ns3::Address',
+ [],
+ is_const=True)
+ ## address.h (module 'network'): std::string ns3::AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function]
+ cls.add_method('SerializeToString',
+ 'std::string',
+ [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')],
+ is_const=True, is_virtual=True)
+ ## address.h (module 'network'): void ns3::AddressValue::Set(ns3::Address const & value) [member function]
+ cls.add_method('Set',
+ 'void',
+ [param('ns3::Address const &', 'value')])
+ return
+
+def register_Ns3FdNetDevice_methods(root_module, cls):
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice::FdNetDevice() [constructor]
+ cls.add_constructor([])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::AddLinkChangeCallback(ns3::Callback<void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [member function]
+ cls.add_method('AddLinkChangeCallback',
+ 'void',
+ [param('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'callback')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetAddress() const [member function]
+ cls.add_method('GetAddress',
+ 'ns3::Address',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetBroadcast() const [member function]
+ cls.add_method('GetBroadcast',
+ 'ns3::Address',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Ptr<ns3::Channel> ns3::FdNetDevice::GetChannel() const [member function]
+ cls.add_method('GetChannel',
+ 'ns3::Ptr< ns3::Channel >',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDevice::EncapsulationMode ns3::FdNetDevice::GetEncapsulationMode() const [member function]
+ cls.add_method('GetEncapsulationMode',
+ 'ns3::FdNetDevice::EncapsulationMode',
+ [],
+ is_const=True)
+ ## fd-net-device.h (module 'fd-net-device'): uint32_t ns3::FdNetDevice::GetIfIndex() const [member function]
+ cls.add_method('GetIfIndex',
+ 'uint32_t',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): uint16_t ns3::FdNetDevice::GetMtu() const [member function]
+ cls.add_method('GetMtu',
+ 'uint16_t',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetMulticast(ns3::Ipv4Address multicastGroup) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv4Address', 'multicastGroup')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Address ns3::FdNetDevice::GetMulticast(ns3::Ipv6Address addr) const [member function]
+ cls.add_method('GetMulticast',
+ 'ns3::Address',
+ [param('ns3::Ipv6Address', 'addr')],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): ns3::Ptr<ns3::Node> ns3::FdNetDevice::GetNode() const [member function]
+ cls.add_method('GetNode',
+ 'ns3::Ptr< ns3::Node >',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): static ns3::TypeId ns3::FdNetDevice::GetTypeId() [member function]
+ cls.add_method('GetTypeId',
+ 'ns3::TypeId',
+ [],
+ is_static=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsBridge() const [member function]
+ cls.add_method('IsBridge',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsBroadcast() const [member function]
+ cls.add_method('IsBroadcast',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsLinkUp() const [member function]
+ cls.add_method('IsLinkUp',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsMulticast() const [member function]
+ cls.add_method('IsMulticast',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::IsPointToPoint() const [member function]
+ cls.add_method('IsPointToPoint',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::NeedsArp() const [member function]
+ cls.add_method('NeedsArp',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::Send(ns3::Ptr<ns3::Packet> packet, ns3::Address const & dest, uint16_t protocolNumber) [member function]
+ cls.add_method('Send',
+ 'bool',
+ [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::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 const &', 'source'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetAddress(ns3::Address address) [member function]
+ cls.add_method('SetAddress',
+ 'void',
+ [param('ns3::Address', 'address')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetEncapsulationMode(ns3::FdNetDevice::EncapsulationMode mode) [member function]
+ cls.add_method('SetEncapsulationMode',
+ 'void',
+ [param('ns3::FdNetDevice::EncapsulationMode', 'mode')])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetFileDescriptor(int fd) [member function]
+ cls.add_method('SetFileDescriptor',
+ 'void',
+ [param('int', 'fd')])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetIfIndex(uint32_t const index) [member function]
+ cls.add_method('SetIfIndex',
+ 'void',
+ [param('uint32_t const', 'index')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetIsBroadcast(bool broadcast) [member function]
+ cls.add_method('SetIsBroadcast',
+ 'void',
+ [param('bool', 'broadcast')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetIsMulticast(bool multicast) [member function]
+ cls.add_method('SetIsMulticast',
+ 'void',
+ [param('bool', 'multicast')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::SetMtu(uint16_t const mtu) [member function]
+ cls.add_method('SetMtu',
+ 'bool',
+ [param('uint16_t const', 'mtu')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetNode(ns3::Ptr<ns3::Node> node) [member function]
+ cls.add_method('SetNode',
+ 'void',
+ [param('ns3::Ptr< ns3::Node >', 'node')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetPromiscReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetPromiscReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::SetReceiveCallback(ns3::Callback<bool, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> cb) [member function]
+ cls.add_method('SetReceiveCallback',
+ 'void',
+ [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')],
+ is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::Start(ns3::Time tStart) [member function]
+ cls.add_method('Start',
+ 'void',
+ [param('ns3::Time', 'tStart')])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::Stop(ns3::Time tStop) [member function]
+ cls.add_method('Stop',
+ 'void',
+ [param('ns3::Time', 'tStop')])
+ ## fd-net-device.h (module 'fd-net-device'): bool ns3::FdNetDevice::SupportsSendFrom() const [member function]
+ cls.add_method('SupportsSendFrom',
+ 'bool',
+ [],
+ is_const=True, is_virtual=True)
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDevice::DoDispose() [member function]
+ cls.add_method('DoDispose',
+ 'void',
+ [],
+ visibility='protected', is_virtual=True)
+ return
+
+def register_Ns3FdNetDeviceFdReader_methods(root_module, cls):
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDeviceFdReader::FdNetDeviceFdReader(ns3::FdNetDeviceFdReader const & arg0) [copy constructor]
+ cls.add_constructor([param('ns3::FdNetDeviceFdReader const &', 'arg0')])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdNetDeviceFdReader::FdNetDeviceFdReader() [constructor]
+ cls.add_constructor([])
+ ## fd-net-device.h (module 'fd-net-device'): void ns3::FdNetDeviceFdReader::SetBufferSize(uint32_t bufferSize) [member function]
+ cls.add_method('SetBufferSize',
+ 'void',
+ [param('uint32_t', 'bufferSize')])
+ ## fd-net-device.h (module 'fd-net-device'): ns3::FdReader::Data ns3::FdNetDeviceFdReader::DoRead() [member function]
+ cls.add_method('DoRead',
+ 'ns3::FdReader::Data',
+ [],
+ visibility='private', is_virtual=True)
+ return
+
+def register_functions(root_module):
+ module = root_module
+ register_functions_ns3_FatalImpl(module.get_submodule('FatalImpl'), root_module)
+ return
+
+def register_functions_ns3_FatalImpl(module, root_module):
+ return
+
+def main():
+ out = FileCodeSink(sys.stdout)
+ root_module = module_init()
+ register_types(root_module)
+ register_methods(root_module)
+ register_functions(root_module)
+ root_module.generate(out)
+
+if __name__ == '__main__':
+ main()
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/bindings/modulegen_customizations.py Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,19 @@
+import os
+
+def post_register_types(root_module):
+ enabled_features = os.environ['NS3_ENABLED_FEATURES'].split(',')
+
+ if 'EmuFdNetDevice' not in enabled_features:
+ root_module.classes.remove(root_module['ns3::EmuFdNetDeviceHelper'])
+
+ if 'TapFdNetDevice' not in enabled_features:
+ root_module.classes.remove(root_module['ns3::TapFdNetDeviceHelper'])
+
+ if 'PlanetLabFdNetDevice' not in enabled_features:
+ root_module.classes.remove(root_module['ns3::PlanetLabFdNetDeviceHelper'])
+
+ if 'FdNetDevice' not in enabled_features:
+ for clsname in ['FdNetDevice', 'FdNetDeviceHelper', 'FdNetDeviceFdReader']:
+ root_module.classes.remove(root_module['ns3::%s' % clsname])
+ root_module.enums.remove(root_module['ns3::FdNetDeviceHelper::EncapsulationMode'])
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/doc/fd-net-device.rst Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,463 @@
+File Descriptor NetDevice
+-------------------------
+.. include:: replace.txt
+
+.. heading hierarchy:
+ ------------- Chapter
+ ************* Section (#.#)
+ ============= Subsection (#.#.#)
+ ############# Paragraph (no number)
+
+The ``src/fd-net-device`` module provides the ``FdNetDevice`` class,
+which is able to read and write traffic using a file descriptor
+provided by the user. This file descriptor can be associated to a TAP
+device, to a raw socket, to a user space process generating/consuming
+traffic, etc.
+The user has full freedom to define how external traffic is generated
+and |ns3| traffic is consumed.
+
+Different mechanisms to associate a simulation to external traffic can
+be provided through helper classes. Three specific helpers are provided:
+
+* EmuFdNetDeviceHelper (to associate the |ns3| device with a physical device
+ in the host machine)
+* TapFdNetDeviceHelper (to associate the ns-3 device with the file descriptor
+ from a tap device in the host machine)
+* PlanteLabFdNetDeviceHelper (to automate the creation of tap devices in
+ PlanetLab nodes, enabling |ns3| simulations that can send and receive
+ traffic though the Internet using PlanetLab resource.
+
+Model Description
+*****************
+
+The source code for this module lives in the directory ``src/fd-net-device``.
+
+The FdNetDevice is a special type of |ns3| NetDevice that reads traffic
+to and from a file descriptor. That is, unlike pure simulation NetDevice
+objects that write frames to and from a simulated channel, this FdNetDevice
+directs frames out of the simulation to a file descriptor. The file
+descriptor may be associated to a Linux TUN/TAP device, to a socket, or
+to a user-space process.
+
+It is up to the user of this device to provide a file descriptor. The
+type of file descriptor being provided determines what is being
+modelled. For instance, if the file descriptor provides a raw socket
+to a WiFi card on the host machine, the device being modelled is a
+WiFi device.
+
+From the conceptual "top" of the device looking down, it looks to the
+simulated node like a device supporting a 48-bit IEEE MAC address that
+can be bridged, supports broadcast, and uses IPv4 ARP or IPv6 Neighbor
+Discovery, although these attributes can be tuned on a per-use-case basis.
+
+Design
+======
+
+The FdNetDevice implementation makes use of a reader object,
+extended from the ``FdReader`` class in the |ns3| ``src/core`` module,
+which manages a separate thread from the main |ns3| execution thread, in order
+to read traffic from the file descriptor.
+
+Upon invocation of the ``StartDevice`` method, the reader object is initialized
+and starts the reading thread.
+Before device start, a file descriptor must be previously associated to the
+FdNetDevice with the ``SetFileDescriptor`` invocation.
+
+The creation and configuration of the file descriptor can be left to a
+number of helpers, described in more detail below. When this is done, the
+invocation of ``SetFileDescriptor`` is responsibility of
+the helper and must not be directly invoked by the user.
+
+Upon reading an incoming frame from the file descriptor, the reader
+will pass the frame to the ``ReceiveCallback`` method, whose
+task it is to schedule the reception of the frame by the device as a
+|ns3| simulation event. Since the new frame is passed from the reader
+thread to the main |ns3| simulation thread, thread-safety issues
+are avoided by using the ``ScheduleWithContext`` call instead of the
+regular ``Schedule`` call.
+
+In order to avoid overwhelming the scheduler when the incoming data rate
+is too high, a counter is kept with the number of frames that are currently
+scheduled to be received by the device. If this counter reaches the value
+given by the ``RxQueueSize`` attribute in the device, then the new frame will
+be dropped silently.
+
+The actual reception of the new frame by the device occurs when the
+scheduled ``FordwarUp`` method is invoked by the simulator.
+This method acts as if a new frame had arrived from a channel attached
+to the device. The device then decapsulates the frame, removing any layer 2
+headers, and forwards it to upper network stack layers of the node.
+The ``ForwardUp`` method will remove the frame headers,
+according to the frame encapsulation type defined by the ``EncapsulationMode``
+attribute, and invoke the receive callback passing an IP packet.
+
+An extra header, the PI header, can be present when the file descriptor is
+associated to a TAP device that was created without setting the IFF_NO_PI flag.
+This extra header is removed if ``EncapsulationMode`` is set to DIXPI value.
+
+In the opposite direction, packets generated inside the simulation that are
+sent out through the device, will be passed to the ``Send`` method, which
+will in turn invoke the ``SendFrom`` method. The latter method will add the
+necessary layer 2 headers, and simply write the newly created frame to the
+file descriptor.
+
+
+Scope and Limitations
+=====================
+
+Users of this device are cautioned that there is no flow control
+across the file descriptor boundary, when using in emulation mode.
+That is, in a Linux system, if the speed of writing network packets
+exceeds the ability of the underlying physical device to buffer the
+packets, backpressure up to the writing application will be applied
+to avoid local packet loss. No such flow control is provided across
+the file descriptor interface, so users must be aware of this limitation.
+
+As explained before, the RxQueueSize attribute limits the number of packets
+that can be pending to be received by the device.
+Frames read from the file descriptor while the number of pending packets is
+in its maximum will be silently dropped.
+
+The mtu of the device defaults to the Ethernet II MTU value. However, helpers
+are supposed to set the mtu to the right value to reflect the characteristics
+of the network interface associated to the file descriptor.
+If no helper is used, then the responsibility of setting the correct mtu value
+for the device falls back to the user.
+The size of the read buffer on the file descriptor reader is set to the
+mtu value in the ``StartDevice`` method.
+
+The FdNetDevice class currently supports three encapsulation modes,
+DIX for Ethernet II frames, LLC for 802.2 LLC/SNAP frames,
+and DIXPI for Ethernet II frames with an additional TAP PI header.
+This means that traffic traversing the file descriptor is expected to be
+Ethernet II compatible.
+Attaching an FdNetDevice to a wireless interface is possible as long as the
+driver provides Ethernet II frames to the socket API.
+Note that to associate a FdNetDevice to a wireless card in ad-hoc mode,
+the MAC address of the device must be set to the real card MAC address, else
+any incoming traffic a fake MAC address will be discarded by the driver.
+
+As mentioned before, three helpers are provided with the fd-net-device module.
+Each individual helper (file descriptor type) may have platform
+limitations. For instance, threading, real-time simulation mode, and the
+ability to create TUN/TAP devices are prerequisites to using the
+provided helpers. Support for these modes can be found in the output
+of the ``waf configure`` step, e.g.:
+
+::
+
+ Threading Primitives : enabled
+ Real Time Simulator : enabled
+ Emulated Net Device : enabled
+ Tap Bridge : enabled
+
+
+It is important to mention that while testing the ``FdNetDevice`` we have found
+an upper bound limit for TCP throughput when using 1Gb Ethernet links of 60Mbps.
+This limit is most likely due to the processing power of the computers involved
+in the tests.
+
+
+Usage
+*****
+
+The usage pattern for this type of device is similar to other net devices
+with helpers that install to node pointers or node containers.
+When using the base ``FdNetDeviceHelper`` the user is responsible for
+creating and setting the file descriptor by himself.
+
+::
+
+ FdNetDeviceHelper fd;
+ NetDeviceContainer devices = fd.Install (nodes);
+
+ // file descriptor generation
+ ...
+
+ device->SetFileDescriptor (fd);
+
+
+Most commonly a FdNetDevice will be used to interact with the host system.
+In these cases it is almost certain that the user will want to run in real-time
+emulation mode, and to enable checksum computations.
+The typical program statements are as follows:
+
+::
+
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+The easiest way to set up an experiment that interacts with a Linux host
+system is to user the ``Emu`` and ``Tap`` helpers.
+Perhaps the most unusual part of these helper implementations
+relates to the requirement for executing some of the code with super-user
+permissions. Rather than force the user to execute the entire simulation as
+root, we provide a small "creator" program that runs as root and does any
+required high-permission sockets work. The easiest way to set the right
+privileges for the "creator" programs, is by enabling the ``--enable-sudo``
+flag when performing ``waf configure``.
+
+We do a similar thing for both the ``Emu`` and the ``Tap`` devices. The
+high-level view is that the ``CreateFileDescriptor`` method creates a local interprocess
+(Unix) socket, forks, and executes the small creation program. The small
+program, which runs as suid root, creates a raw socket and sends back the raw
+socket file descriptor over the Unix socket that is passed to it as a parameter.
+The raw socket is passed as a control message (sometimes called ancillary data)
+of type SCM_RIGHTS.
+
+
+Helpers
+=======
+
+EmuFdNetDeviceHelper
+####################
+
+The EmuFdNetDeviceHelper creates a raw socket to an underlying physical
+device, and provides the socket descriptor to the FdNetDevice. This
+allows the |ns3| simulation to read frames from and write frames to
+a network device on the host.
+
+The emulation helper permits to transparently integrate a simulated
+|ns3| node into a network composed of real nodes.
+
+::
+
+ +----------------------+ +-----------------------+
+ | machine 1 | | machine 2 |
+ +----------------------+ +-----------------------+
+ | ns-3 simulation | | |
+ +----------------------+ | Linux |
+ | node 0 | | Network Stack |
+ | +----------------+ | | +----------------+ |
+ | | ns-3 TCP | | | | TCP | |
+ | +----------------+ | | +----------------+ |
+ | | ns-3 IP | | | | | |
+ | | 10.1.1.1 | | | | IP | |
+ | +----------------+ | | +----------------+ |
+ | | fd-net-device | | | | | |
+ | +----------------+ | | + ETHERNET + |
+ | | raw socket | | | | | |
+ | +----------------+ | | +----------------+ |
+ | | eth0 | | | | eth0 | |
+ +-------+------+-------+ +--------+------+-------+
+
+ 10.1.1.11 10.1.1.12
+
+ | |
+ +----------------------------+
+
+
+This helper replaces the functionality of the ``EmuNetDevice`` found in
+|ns3| prior to ns-3.17, by bringing this type of device into the common
+framework of the FdNetDevice. The ``EmuNetDevice`` will be deprecated
+in favor of this new helper.
+
+The device is configured to perform
+MAC spoofing to separate simulation network traffic from other
+network traffic that may be flowing to and from the host.
+
+One can use this helper in a testbed situation where the host on
+which the simulation is running has a specific interface of interest which
+drives the testbed hardware. You would also need to set this specific interface
+into promiscuous mode and provide an appropriate device name to the |ns3|
+simulation.
+
+The helper only works if the underlying interface is up and in
+promiscuous mode. Packets will be sent out over the device, but we use MAC
+spoofing. The MAC addresses will be generated (by default) using the
+Organizationally Unique Identifier (OUI) 00:00:00 as a base. This vendor code
+is not assigned to any organization and so should not conflict with any real
+hardware.
+
+It is always up to the user to determine that using these MAC addresses is okay
+on your network and won't conflict with anything else (including another
+simulation using such devices) on your network. If you are using the emulated
+FdNetDevice configuration in separate simulations,
+ you must consider global MAC address
+assignment issues and ensure that MAC addresses are unique across all
+simulations. The emulated net device respects the MAC address provided in the
+``Address`` attribute so you can do this manually. For larger simulations, you
+may want to set the OUI in the MAC address allocation function.
+
+Before invoking the ``Install`` method, the correct device name must be configured
+on the helper using the ``SetDeviceName`` method. The device name is required to
+identify which physical device should be used to open the raw socket.
+
+::
+
+ EmuFdNetDeviceHelper emu;
+ emu.SetDeviceName (deviceName);
+ NetDeviceContainer devices = emu.Install (node);
+ Ptr<NetDevice> device = devices.Get (0);
+ device->SetAttribute ("Address", Mac48AddressValue (Mac48Address::Allocate ()));
+
+
+TapFdNetDeviceHelper
+####################
+
+A Tap device is a special type of Linux device for which one end of the
+device appears to the kernel as a virtual net_device, and the other
+end is provided as a file descriptor to user-space. This file descriptor
+can be passed to the FdNetDevice. Packets forwarded to the TAP device
+by the kernel will show up in the FdNetDevice in |ns3|.
+
+Users should note that this usage of TAP devices is different than that
+provided by the TapBridge NetDevice found in ``src/tap-bridge``.
+The model in this helper is as follows:
+
+::
+
+ +-----------------+
+ | ns-3 simulation |
+ | |
+ | ------- |
+ | | node | |
+ | ------- |
+ | | fd- | |
+ | | net- | |
+ | | device| |
+ | ------- |
+ | | |
+ | | |
+ ----|-------------
+ | --- --- |
+ | | | | | |
+ | |TAP| |ETH| |
+ | | | | | |
+ | --- --- |
+ | | |
+ | host | |
+ --------------|----
+ |
+ |
+ ---- (Internet) -------
+
+
+In the above, the configuration requires that the host be able to forward
+traffic generated by the simulation to the Internet.
+
+The model in TapBridge (in another module) is as follows:
+
+::
+
+ +--------+
+ | Linux |
+ | host | +----------+
+ | ------ | | ghost |
+ | apps | | node |
+ | ------ | | -------- |
+ | stack | | IP | +----------+
+ | ------ | | stack | | node |
+ | TAP | |==========| | -------- |
+ | device | <----- IPC ------> | tap | | IP |
+ +--------+ | bridge | | stack |
+ | -------- | | -------- |
+ | ns-3 | | ns-3 |
+ | net | | net |
+ | device | | device |
+ +----------+ +----------+
+ || ||
+ +---------------------------+
+ | ns-3 channel |
+ +---------------------------+
+
+
+In the above, packets instead traverse |ns3| NetDevices and Channels.
+
+The usage pattern for this example is that the user sets the
+MAC address and either (or both) the IPv4 and IPv6 addresses and masks
+on the device, and the PI header if needed. For example:
+
+::
+
+ TapFdNetDeviceHelper helper;
+ helper.SetDeviceName (deviceName);
+ helper.SetModePi (modePi);
+ helper.SetTapIpv4Address (tapIp);
+ helper.SetTapIpv4Mask (tapMask);
+ ...
+ helper.Install (node);
+
+
+PlanetLabFdNetDeviceHelper
+##########################
+
+TODO: Write section
+
+Attributes
+==========
+
+The ``FdNetDevice`` provides a number of attributes:
+
+* ``Address``: The MAC address of the device
+* ``Start``: The simulation start time to spin up the device thread
+* ``Stop``: The simulation start time to stop the device thread
+* ``EncapsulationMode``: Link-layer encapsulation format
+* ``RxQueueSize``: The buffer size of the read queue on the file descriptor
+ thread (default of 1000 packets)
+
+``Start`` and ``Stop`` do not normally need to be specified unless the
+user wants to limit the time during which this device is active.
+``Address`` needs to be set to some kind of unique MAC address if the
+simulation will be interacting with other real devices somehow using
+real MAC addresses. Typical code:
+
+::
+
+ device->SetAttribute ("Address", Mac48AddressValue (Mac48Address::Allocate ()));
+
+Output
+======
+
+Ascii and PCAP tracing is provided similar to the other |ns3| NetDevice
+types, through the helpers, such as (e.g.):
+
+::
+ EmuFdNetDeviceHelper emu;
+ NetDeviceContainer devices = emu.Install (node);
+ ...
+ emu.EnablePcap ("emu-ping", device, true);
+
+
+The standard set of Mac-level NetDevice trace sources is provided.
+
+* ``MaxTx``: Trace source triggered when |ns3| provides the device with a
+ new frame to send
+* ``MaxTxDrop``: Trace source if write to file descriptor fails
+* ``MaxPromiscRx``: Whenever any valid Mac frame is received
+* ``MaxRx``: Whenever a valid Mac frame is received for this device
+* ``Sniffer``: Non-promiscuous packet sniffer
+* ``PromiscSniffer``: Promiscuous packet sniffer (for tcpdump-like traces)
+
+Examples
+========
+
+Several examples are provided:
+
+* ``dummy-network.cc``: This simple example creates two nodes and
+ interconnects them with a Unix pipe by passing the file descriptors
+ from the socketpair into the FdNetDevice objects of the respective nodes.
+* ``fd2fd-onoff.cc``: Describe
+* ``fd-emu-onoff.cc``: Describe
+* ``fd-emu-ping.cc``: Describe
+* ``fd-emu-udp-echo.cc``: Describe
+* ``fd-planetlab-ping.cc``: Describe
+* ``fd-tap-ping.cc``: Describe
+* ``fd-tap6-ping.cc``: Describe
+
+TODO: What examples using this new code are available? Describe them here.
+
+Troubleshooting
+===============
+
+TODO: Write section
+
+Validation
+**********
+
+TODO: Validation of this device is not easy to automate since most
+What do the examples in examples_to_run.py test for?
+
+Describe how the model has been tested/validated. What tests run in the
+test suite? How much API and code is covered by the tests?
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/dummy-network.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,77 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+// Network topology
+//
+#include <sys/socket.h>
+#include <errno.h>
+
+#include "ns3/core-module.h"
+#include "ns3/network-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/fd-net-device-module.h"
+#include "ns3/applications-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("DummyNetworkExample");
+
+int
+main (int argc, char *argv[])
+{
+ NodeContainer nodes;
+ nodes.Create (2);
+
+ InternetStackHelper stack;
+ stack.Install (nodes);
+
+ FdNetDeviceHelper fd;
+ NetDeviceContainer devices = fd.Install (nodes);
+
+ int sv[2];
+ if (socketpair (AF_UNIX, SOCK_DGRAM, 0, sv) < 0)
+ {
+ NS_FATAL_ERROR ("Error creating pipe=" << strerror (errno));
+ }
+
+ Ptr<NetDevice> d1 = devices.Get (0);
+ Ptr<FdNetDevice> device1 = d1->GetObject<FdNetDevice> ();
+ device1->SetFileDescriptor (sv[0]);
+
+ Ptr<NetDevice> d2 = devices.Get (1);
+ Ptr<FdNetDevice> device2 = d2->GetObject<FdNetDevice> ();
+ device2->SetFileDescriptor (sv[1]);
+
+ Ipv4AddressHelper addresses;
+ addresses.SetBase ("10.0.0.0", "255.255.255.0");
+ Ipv4InterfaceContainer interfaces = addresses.Assign (devices);
+
+ Ptr<V4Ping> app = CreateObject<V4Ping> ();
+ app->SetAttribute ("Remote", Ipv4AddressValue (interfaces.GetAddress (0)));
+ app->SetAttribute ("Verbose", BooleanValue (true));
+ nodes.Get (1)->AddApplication (app);
+ app->SetStartTime (Seconds (0.0));
+ app->SetStopTime (Seconds (4.0));
+
+ fd.EnablePcapAll ("dummy-network", false);
+
+ Simulator::Stop (Seconds (5.));
+ Simulator::Run ();
+ Simulator::Destroy ();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/fd-emu-onoff.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,196 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ *
+ */
+
+// +----------------------+ +-----------------------+
+// | client machine | | server machine |
+// +----------------------+ +-----------------------+
+// | node 0 | | node 1 |
+// | +----------------+ | | +----------------+ |
+// | | ns-3 TCP | | | | ns-3 TCP | |
+// | +----------------+ | | +----------------+ |
+// | | 10.1.1.1 | | | | 10.1.1.2 | |
+// | +----------------+ | | +----------------+ |
+// | | fd-net-device | | | | fd-net-device | |
+// | +----------------+ | | +----------------+ |
+// | | raw socket | | | | raw socket | |
+// | +----------------+ | | +----------------+ |
+// | | eth0 | | | | eth0 | |
+// +-------+------+-------+ +--------+------+-------+
+//
+// 10.1.1.11 10.1.1.12
+//
+// | |
+// +----------------------------+
+//
+// This example is aimed at meassuring the thoughput of the FdNetDevice
+// when using the EmuFdNetDeviceHelper. This is achieved by saturating
+// the channel with TCP traffic. Then the thoughput can be obtained from
+// the generated .pcap files.
+//
+// To run this example you will need two computers (client & server).
+// Steps to run the experiment:
+//
+// 1 - Connect the 2 computers with an Ethernet cable
+// 2 - Set the IP addresses on both Ethernet devices
+//
+// client machine: $ sudo ip addr add dev eth0 10.1.1.11/24
+// server machine: $ sudo ip addr add dev eth0 10.1.1.12/24
+//
+// 3 - Set both Ethernet devices to promiscuous mode
+//
+// both machines: $ sudo ip link set eth0 promisc on
+//
+// 4 - Give root suid to the raw socket creator binary
+//
+// both machines: $ sudo chown root.root build/src/fd-net-device/ns3-dev-raw-sock-creator
+// both machines: $ sudo chmod 4755 build/src/fd-net-device/ns3-dev-raw-sock-creator
+//
+// 5 - Run the server side:
+//
+// server machine: $ ./waf --run="fd-emu-onoff --serverMode=1"
+//
+// 6 - Run the client side:
+//
+// client machine: $ ./waf --run="fd-emu-onoff"
+//
+
+#include <iostream>
+#include <fstream>
+#include <vector>
+#include <string>
+
+#include "ns3/core-module.h"
+#include "ns3/network-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/applications-module.h"
+#include "ns3/config-store-module.h"
+#include "ns3/fd-net-device-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("EmuFdNetDeviceSaturationExample");
+
+int
+main (int argc, char *argv[])
+{
+ uint16_t sinkPort = 8000;
+ uint32_t packetSize = 10000; // bytes
+ std::string dataRate("1000Mb/s");
+ bool serverMode = false;
+
+ std::string deviceName ("eth0");
+ std::string client ("10.1.1.1");
+ std::string server ("10.1.1.2");
+ std::string netmask ("255.255.255.0");
+ std::string macClient ("00:00:00:00:00:01");
+ std::string macServer ("00:00:00:00:00:02");
+
+ CommandLine cmd;
+ cmd.AddValue ("deviceName", "Device name", deviceName);
+ cmd.AddValue ("client", "Local IP address (dotted decimal only please)", client);
+ cmd.AddValue ("server", "Remote IP address (dotted decimal only please)", server);
+ cmd.AddValue ("localmask", "Local mask address (dotted decimal only please)", netmask);
+ cmd.AddValue ("serverMode", "1:true, 0:false, default client", serverMode);
+ cmd.AddValue ("mac-client", "Mac Address for Server Client : 00:00:00:00:00:01", macClient);
+ cmd.AddValue ("mac-server", "Mac Address for Server Default : 00:00:00:00:00:02", macServer);
+ cmd.AddValue ("data-rate", "Data rate defaults to 1000Mb/s", dataRate);
+ cmd.Parse (argc, argv);
+
+ Ipv4Address remoteIp;
+ Ipv4Address localIp;
+ Mac48AddressValue localMac;
+
+ if (serverMode)
+ {
+ remoteIp = Ipv4Address (client.c_str ());
+ localIp = Ipv4Address (server.c_str ());
+ localMac = Mac48AddressValue (macServer.c_str ());
+ }
+ else
+ {
+ remoteIp = Ipv4Address (server.c_str ());
+ localIp = Ipv4Address (client.c_str ());
+ localMac = Mac48AddressValue (macClient.c_str ());
+ }
+
+ Ipv4Mask localMask (netmask.c_str ());
+
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ NS_LOG_INFO ("Create Node");
+ Ptr<Node> node = CreateObject<Node> ();
+
+ NS_LOG_INFO ("Create Device");
+ EmuFdNetDeviceHelper emu;
+ emu.SetDeviceName (deviceName);
+ NetDeviceContainer devices = emu.Install (node);
+ Ptr<NetDevice> device = devices.Get (0);
+ device->SetAttribute ("Address", localMac);
+
+ NS_LOG_INFO ("Add Internet Stack");
+ InternetStackHelper internetStackHelper;
+ internetStackHelper.SetIpv4StackInstall(true);
+ internetStackHelper.Install (node);
+
+ NS_LOG_INFO ("Create IPv4 Interface");
+ Ptr<Ipv4> ipv4 = node->GetObject<Ipv4> ();
+ uint32_t interface = ipv4->AddInterface (device);
+ Ipv4InterfaceAddress address = Ipv4InterfaceAddress (localIp, localMask);
+ ipv4->AddAddress (interface, address);
+ ipv4->SetMetric (interface, 1);
+ ipv4->SetUp (interface);
+
+ if(serverMode)
+ {
+ Address sinkLocalAddress (InetSocketAddress (localIp, sinkPort));
+ PacketSinkHelper sinkHelper ("ns3::TcpSocketFactory", sinkLocalAddress);
+ ApplicationContainer sinkApp = sinkHelper.Install (node);
+ sinkApp.Start (Seconds (1.0));
+ sinkApp.Stop (Seconds (60.0));
+
+ emu.EnablePcap ("fd-server", device);
+ }
+ else
+ {
+ AddressValue remoteAddress (InetSocketAddress (remoteIp, sinkPort));
+ OnOffHelper onoff ("ns3::TcpSocketFactory", Address ());
+ onoff.SetAttribute ("Remote", remoteAddress);
+ onoff.SetAttribute ("OnTime", StringValue ("ns3::ConstantRandomVariable[Constant=1]"));
+ onoff.SetAttribute ("OffTime", StringValue ("ns3::ConstantRandomVariable[Constant=0]"));
+ onoff.SetAttribute ("DataRate", DataRateValue (dataRate));
+ onoff.SetAttribute ("PacketSize", UintegerValue (packetSize));
+
+ ApplicationContainer clientApps = onoff.Install (node);
+ clientApps.Start (Seconds (4.0));
+ clientApps.Stop (Seconds (58.0));
+
+ emu.EnablePcap ("fd-client", device);
+ }
+
+ Simulator::Stop (Seconds (61.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+
+ return 0;
+}
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/fd-emu-ping.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,222 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+// Allow ns-3 to ping a real host somewhere, using emulation mode
+//
+// ------------
+// | node n0 |
+// | |
+// | --- |
+// | | | |
+// | |emu| |
+// | | | |
+// | --- |
+// | | |
+// ----|-------
+// |
+// (device on host system, set to promiscuous mode)
+// |
+// --------- (Internet) -------
+//
+// To use this example:
+// 1) You need to decide on a physical device on your real system, and either
+// overwrite the hard-configured device name below (eth0) or pass this
+// device name in as a command-line argument
+// 2) The host device must be set to promiscuous mode
+// (e.g. "sudo ifconfig eth0 promisc")
+// 3) Be aware that ns-3 will generate a fake mac address, and that in
+// some enterprise networks, this may be considered bad form to be
+// sending packets out of your device with "unauthorized" mac addresses
+// 4) You will need to assign an IP address to the ns-3 simulation node that
+// is consistent with the subnet that is active on the host device's link.
+// That is, you will have to assign an IP address to the ns-3 node as if
+// it were on your real subnet. Search for "Ipv4Address localIp" and
+// replace the string "1.2.3.4" with a valid IP address.
+// 5) You will need to configure a default route in the ns-3 node to tell it
+// how to get off of your subnet. One thing you could do is a
+// 'netstat -rn' command and find the IP address of the default gateway
+// on your host. Search for "Ipv4Address gateway" and replace the string
+// "1.2.3.4" string with the gateway IP address.
+
+#include "ns3/abort.h"
+#include "ns3/core-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/network-module.h"
+#include "ns3/fd-net-device-module.h"
+#include "ns3/applications-module.h"
+#include "ns3/ipv4-static-routing-helper.h"
+#include "ns3/ipv4-list-routing-helper.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("PingEmulationExample");
+
+static void
+PingRtt (std::string context, Time rtt)
+{
+ NS_LOG_UNCOND ("Received Response with RTT = " << rtt);
+}
+
+int
+main (int argc, char *argv[])
+{
+ NS_LOG_INFO ("Ping Emulation Example");
+
+ std::string deviceName ("wlan0");
+ std::string remote ("173.194.34.51"); // example.com
+
+ //
+ // Allow the user to override any of the defaults at run-time, via
+ // command-line arguments
+ //
+ CommandLine cmd;
+ cmd.AddValue ("deviceName", "Device name", deviceName);
+ cmd.AddValue ("remote", "Remote IP address (dotted decimal only please)", remote);
+ cmd.Parse (argc, argv);
+
+ Ipv4Address remoteIp (remote.c_str ());
+ Ipv4Address localIp ("1.2.3.4");
+ NS_ABORT_MSG_IF (localIp == "1.2.3.4", "You must change the local IP address before running this example");
+
+ Ipv4Mask localMask ("255.255.255.0");
+
+ //
+ // Since we are using a real piece of hardware we need to use the realtime
+ // simulator.
+ //
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+
+ //
+ // Since we are going to be talking to real-world machines, we need to enable
+ // calculation of checksums in our protocols.
+ //
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ //
+ // In such a simple topology, the use of the helper API can be a hindrance
+ // so we drop down into the low level API and do it manually.
+ //
+ // First we need a single node.
+ //
+ NS_LOG_INFO ("Create Node");
+ Ptr<Node> node = CreateObject<Node> ();
+
+ //
+ // Create an emu device, allocate a MAC address and point the device to the
+ // Linux device name. The device needs a transmit queueing discipline so
+ // create a droptail queue and give it to the device. Finally, "install"
+ // the device into the node.
+ //
+ // Do understand that the ns-3 allocated MAC address will be sent out over
+ // your network since the emu net device will spoof it. By default, this
+ // address will have an Organizationally Unique Identifier (OUI) of zero.
+ // The Internet Assigned Number Authority IANA
+ //
+ // http://www.iana.org/assignments/ethernet-numbers
+ //
+ // reports that this OUI is unassigned, and so should not conflict with
+ // real hardware on your net. It may raise all kinds of red flags in a
+ // real environment to have packets from a device with an obviously bogus
+ // OUI flying around. Be aware.
+ //
+ NS_LOG_INFO ("Create Device");
+ EmuFdNetDeviceHelper emu;
+ emu.SetDeviceName (deviceName);
+ NetDeviceContainer devices = emu.Install (node);
+ Ptr<NetDevice> device = devices.Get (0);
+ device->SetAttribute ("Address", Mac48AddressValue (Mac48Address::Allocate ()));
+
+ //Ptr<Queue> queue = CreateObject<DropTailQueue> ();
+ //device->SetQueue (queue);
+ //node->AddDevice (device);
+
+ //
+ // Add a default internet stack to the node. This gets us the ns-3 versions
+ // of ARP, IPv4, ICMP, UDP and TCP.
+ //
+ NS_LOG_INFO ("Add Internet Stack");
+ InternetStackHelper internetStackHelper;
+ internetStackHelper.Install (node);
+
+ NS_LOG_INFO ("Create IPv4 Interface");
+ Ptr<Ipv4> ipv4 = node->GetObject<Ipv4> ();
+ uint32_t interface = ipv4->AddInterface (device);
+ Ipv4InterfaceAddress address = Ipv4InterfaceAddress (localIp, localMask);
+ ipv4->AddAddress (interface, address);
+ ipv4->SetMetric (interface, 1);
+ ipv4->SetUp (interface);
+
+ //
+ // When the ping appliation sends its ICMP packet, it will happily send it
+ // down the ns-3 protocol stack. We set the IP address of the destination
+ // to the address corresponding to example.com above. This address is off
+ // our local network so we have got to provide some kind of default route
+ // to ns-3 to be able to get that ICMP packet forwarded off of our network.
+ //
+ // You have got to provide an IP address of a real host that you can send
+ // real packets to and have them forwarded off of your local network. One
+ // thing you could do is a 'netstat -rn' command and find the IP address of
+ // the default gateway on your host and add it below, replacing the
+ // "1.2.3.4" string.
+ //
+ Ipv4Address gateway ("1.2.3.4");
+ NS_ABORT_MSG_IF (gateway == "1.2.3.4", "You must change the gateway IP address before running this example");
+
+ Ipv4StaticRoutingHelper ipv4RoutingHelper;
+ Ptr<Ipv4StaticRouting> staticRouting = ipv4RoutingHelper.GetStaticRouting (ipv4);
+ staticRouting->SetDefaultRoute (gateway, interface);
+
+ //
+ // Create the ping application. This application knows how to send
+ // ICMP echo requests. Setting up the packet sink manually is a bit
+ // of a hassle and since there is no law that says we cannot mix the
+ // helper API with the low level API, let's just use the helper.
+ //
+ NS_LOG_INFO ("Create V4Ping Appliation");
+ Ptr<V4Ping> app = CreateObject<V4Ping> ();
+ app->SetAttribute ("Remote", Ipv4AddressValue (remoteIp));
+ app->SetAttribute ("Verbose", BooleanValue (true) );
+ node->AddApplication (app);
+ app->SetStartTime (Seconds (1.0));
+ app->SetStopTime (Seconds (21.0));
+
+ //
+ // Give the application a name. This makes life much easier when constructing
+ // config paths.
+ //
+ Names::Add ("app", app);
+
+ //
+ // Hook a trace to print something when the response comes back.
+ //
+ Config::Connect ("/Names/app/Rtt", MakeCallback (&PingRtt));
+
+ //
+ // Enable a promiscuous pcap trace to see what is coming and going on our device.
+ //
+ emu.EnablePcap ("emu-ping", device, true);
+
+ //
+ // Now, do the actual emulation.
+ //
+ NS_LOG_INFO ("Run Emulation.");
+ Simulator::Stop (Seconds (22.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+ NS_LOG_INFO ("Done.");
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/fd-emu-udp-echo.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,166 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+// Network topology
+//
+// Normally, the use case for emulated net devices is in collections of
+// small simulations that connect to the outside world through specific
+// interfaces. For example, one could construct a number of virtual
+// machines and connect them via a host-only network. To use the emulated
+// net device, you would need to set all of the host-only interfaces in
+// promiscuous mode and provide an appropriate device name (search for "eth1"
+// below). One could also use the emulated net device in a testbed situation
+// where the host on which the simulation is running has a specific interface
+// of interested. You would also need to set this specific interface into
+// promiscuous mode and provide an appropriate device name.
+//
+// This philosophy carries over to this simple example.
+//
+// We don't assume any special configuration and all of the ns-3 emulated net
+// devices will actually talk to the same underlying OS device. We rely on
+// the fact that the OS will deliver copies of our packets to the other ns-3
+// net devices since we operate in promiscuous mode.
+//
+// Packets will be sent out over the device, but we use MAC spoofing. The
+// MAC addresses will be generated using the Organizationally Unique Identifier
+// (OUI) 00:00:00 as a base. This vendor code is not assigned to any
+// organization and so should not conflict with any real hardware. We'll use
+// the first n of these addresses, where n is the number of nodes, in this
+// simualtion. It is up to you to determine that using these MAC addresses is
+// okay on your network and won't conflict with anything else (including another
+// simulation using emu devices) on your network. Once you have made this
+// determination, you need to put the interface you chose into promiscuous mode.
+// We don't do it for you since you need to think about it first.
+//
+// This simulation uses the real-time simulator and so will consume ten seconds
+// of real time.
+//
+// By default, we create the following topology
+//
+// n0 n1
+// | |
+// -------
+// "eth1"
+//
+// - UDP flows from n0 to n1 and back
+// - DropTail queues
+// - Tracing of queues and packet receptions to file "udp-echo.tr"
+// - pcap tracing on all devices
+//
+
+#include <fstream>
+#include "ns3/core-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/applications-module.h"
+#include "ns3/fd-net-device-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("EmulatedUdpEchoExample");
+
+int
+main (int argc, char *argv[])
+{
+ std::string deviceName ("eth1");
+ std::string encapMode ("Dix");
+ uint32_t nNodes = 4;
+
+ //
+ // Allow the user to override any of the defaults at run-time, via command-line
+ // arguments
+ //
+ CommandLine cmd;
+ cmd.AddValue ("deviceName", "device name", deviceName);
+ cmd.AddValue ("encapsulationMode", "encapsulation mode of emu device (\"Dix\" [default] or \"Llc\")", encapMode);
+ cmd.AddValue ("nNodes", "number of nodes to create (>= 2)", nNodes);
+
+ cmd.Parse (argc, argv);
+
+ GlobalValue::Bind ("SimulatorImplementationType",
+ StringValue ("ns3::RealtimeSimulatorImpl"));
+
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+ //
+ // need at least two nodes
+ //
+ nNodes = nNodes < 2 ? 2 : nNodes;
+
+ //
+ // Explicitly create the nodes required by the topology (shown above).
+ //
+ NS_LOG_INFO ("Create nodes.");
+ NodeContainer n;
+ n.Create (nNodes);
+
+ InternetStackHelper internet;
+ internet.Install (n);
+
+ //
+ // Explicitly create the channels required by the topology (shown above).
+ //
+ NS_LOG_INFO ("Create channels.");
+ EmuFdNetDeviceHelper emu;
+ emu.SetDeviceName (deviceName);
+ emu.SetAttribute ("EncapsulationMode", StringValue (encapMode));
+
+ NetDeviceContainer d = emu.Install (n);
+
+ //
+ // We've got the "hardware" in place. Now we need to add IP addresses.
+ //
+ Ipv4AddressHelper ipv4;
+ NS_LOG_INFO ("Assign IP Addresses.");
+ ipv4.SetBase ("10.1.1.0", "255.255.255.0");
+ Ipv4InterfaceContainer i = ipv4.Assign (d);
+
+ //
+ // Create a UdpEchoServer application on node one.
+ //
+ NS_LOG_INFO ("Create Applications.");
+ UdpEchoServerHelper server (9);
+ ApplicationContainer apps = server.Install (n.Get (1));
+ apps.Start (Seconds (1.0));
+ apps.Stop (Seconds (10.0));
+
+ //
+ // Create a UdpEchoClient application to send UDP datagrams from node zero to node one.
+ //
+ uint32_t packetSize = 1024;
+ uint32_t maxPacketCount = 20;
+ Time interPacketInterval = Seconds (0.1);
+ UdpEchoClientHelper client (i.GetAddress (1), 9);
+ client.SetAttribute ("MaxPackets", UintegerValue (maxPacketCount));
+ client.SetAttribute ("Interval", TimeValue (interPacketInterval));
+ client.SetAttribute ("PacketSize", UintegerValue (packetSize));
+ apps = client.Install (n.Get (0));
+ apps.Start (Seconds (2.0));
+ apps.Stop (Seconds (10.0));
+
+ std::ofstream ascii;
+ ascii.open ("emu-udp-echo.tr");
+ emu.EnablePcapAll ("emu-udp-echo", true);
+
+ //
+ // Now, do the actual simulation.
+ //
+ NS_LOG_INFO ("Run Simulation.");
+ Simulator::Stop (Seconds (12.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+ NS_LOG_INFO ("Done.");
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/fd-planetlab-ping.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,213 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+// Allow ns-3 to ping a real host somewhere, using emulation mode and ping
+// the simulated node from the host.
+//
+// ------------------
+// | ns-3 simulation |
+// | |
+// | ------- |
+// | | node | |
+// | ------- |
+// | | fd- | |
+// | | net- | |
+// | | device| |
+// | ------- |
+// | | |
+// | | |
+// ----|-------------
+// | --- --- |
+// | | | | | |
+// | |TAP| |ETH| |
+// | | | | | |
+// | --- --- |
+// | | |
+// |PlanteLab | |
+// |host | |
+// --------------|----
+// |
+// |
+// ---- (Internet) -------
+//
+// To use this example:
+// 1) The ns-3 will create the TAP device for you in the host machine.
+// For this you need to provide the network address to allocate IP addresses
+// for the TAP/TU device and the ns-3 FdNetDevice.
+// 2) Once the experiment is running you can ping the FdNetDevice IP address from
+// the host machine.
+// 3) For more information on the required configuration to create TAP devices
+// on PlanetLab refer to:
+// http://minerva.netgroup.uniroma2.it/fairvpn/wiki/TapDevice
+//
+
+#include "ns3/abort.h"
+#include "ns3/core-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/network-module.h"
+#include "ns3/fd-net-device-module.h"
+#include "ns3/applications-module.h"
+#include "ns3/ipv4-static-routing-helper.h"
+#include "ns3/ipv4-list-routing-helper.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("PlanetLabTAPPingExample");
+
+static void
+PingRtt (std::string context, Time rtt)
+{
+ NS_LOG_UNCOND ("Received Response with RTT = " << rtt);
+}
+
+int
+main (int argc, char *argv[])
+{
+ NS_LOG_INFO ("Ping Emulation Example with TAP on PlanetLab host");
+
+ std::string remote ("173.194.34.51"); // example.com
+ //
+ // Make suer network and mask correspond to those assigned to your PlanetLab
+ // slice, through the tag vsys_vnet x.x.x.x/yy .
+ // In this case The network should be x.x.x.x and the mask should correspond to
+ // the prefix yy.
+ //
+ std::string network ("1.2.3.4");
+ std::string mask ("255.255.255.0");
+
+ //
+ // Allow the user to override any of the defaults at run-time, via
+ // command-line arguments
+ //
+ CommandLine cmd;
+ cmd.AddValue ("remote", "Remote IP address (dotted decimal only please)", remote);
+ cmd.AddValue ("tapNetwork", "Network address to assign the TAP device IP address (dotted decimal only please). Note that the network address must be that from the vsys_vnet tag which must exist in your PlanetLab slice.", network);
+ cmd.AddValue ("tapMask", "Network mask for configure the TAP device (dotted decimal only please)", mask);
+ cmd.Parse (argc, argv);
+
+ NS_ABORT_MSG_IF (network == "1.2.3.4", "You must change the local IP address before running this example");
+
+ Ipv4Address remoteIp (remote.c_str ());
+ Ipv4Address tapNetwork (network.c_str ());
+ Ipv4Mask tapMask (mask.c_str ());
+
+ //
+ // Since we are using a real piece of hardware we need to use the realtime
+ // simulator.
+ //
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+
+ //
+ // Since we are going to be talking to real-world machines, we need to enable
+ // calculation of checksums in our protocols.
+ //
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ //
+ // In such a simple topology, the use of the helper API can be a hindrance
+ // so we drop down into the low level API and do it manually.
+ //
+ // First we need a single node.
+ //
+ NS_LOG_INFO ("Create Node");
+ Ptr<Node> node = CreateObject<Node> ();
+
+ // Create an fd device, set a MAC address and point the device to the
+ // Linux device name. The device needs a transmit queueing discipline so
+ // create a droptail queue and give it to the device. Finally, "install"
+ // the device into the node.
+ //
+ Ipv4AddressHelper addresses;
+ addresses.SetBase (tapNetwork, tapMask);
+ Ipv4Address tapIp = addresses.NewAddress ();
+
+ NS_LOG_INFO ("Create Device");
+ PlanetLabFdNetDeviceHelper helper;
+ helper.SetTapIpAddress (tapIp);
+ helper.SetTapMask (tapMask);
+
+ NetDeviceContainer devices = helper.Install (node);
+ Ptr<NetDevice> device = devices.Get (0);
+
+ //
+ // Add a default internet stack to the node (ARP, IPv4, ICMP, UDP and TCP).
+ //
+ NS_LOG_INFO ("Add Internet Stack");
+ InternetStackHelper internetStackHelper;
+ internetStackHelper.Install (node);
+
+ //
+ // Add an address to the ns-3 device in the same network than one
+ // assigned to the TAP.
+ //
+ NS_LOG_INFO ("Create IPv4 Interface");
+ Ptr<Ipv4> ipv4 = node->GetObject<Ipv4> ();
+ uint32_t interface = ipv4->AddInterface (device);
+ Ipv4Address devIp = addresses.NewAddress ();
+ Ipv4InterfaceAddress address = Ipv4InterfaceAddress (devIp, tapMask);
+ ipv4->AddAddress (interface, address);
+ ipv4->SetMetric (interface, 1);
+ ipv4->SetUp (interface);
+
+ //
+ // Add a route to the ns-3 device so it can reach the outside world though the
+ // TAP.
+ //
+ Ipv4StaticRoutingHelper ipv4RoutingHelper;
+ Ptr<Ipv4StaticRouting> staticRouting = ipv4RoutingHelper.GetStaticRouting (ipv4);
+ staticRouting->SetDefaultRoute (tapIp, interface);
+
+ //
+ // Create the ping application. This application knows how to send
+ // ICMP echo requests. Setting up the packet sink manually is a bit
+ // of a hassle and since there is no law that says we cannot mix the
+ // helper API with the low level API, let's just use the helper.
+ //
+ NS_LOG_INFO ("Create V4Ping Appliation");
+ Ptr<V4Ping> app = CreateObject<V4Ping> ();
+ app->SetAttribute ("Remote", Ipv4AddressValue (remoteIp));
+ app->SetAttribute ("Verbose", BooleanValue (true) );
+ node->AddApplication (app);
+ app->SetStartTime (Seconds (1.0));
+ app->SetStopTime (Seconds (21.0));
+
+ //
+ // Give the application a name. This makes life much easier when constructing
+ // config paths.
+ //
+ Names::Add ("app", app);
+
+ //
+ // Hook a trace to print something when the response comes back.
+ //
+ Config::Connect ("/Names/app/Rtt", MakeCallback (&PingRtt));
+
+ //
+ // Enable a promiscuous pcap trace to see what is coming and going on our device.
+ //
+ helper.EnablePcap ("fd-planete-ping", device, true);
+
+ //
+ // Now, do the actual emulation.
+ //
+ NS_LOG_INFO ("Run Emulation.");
+ Simulator::Stop (Seconds (22.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+ NS_LOG_INFO ("Done.");
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/fd-tap-ping.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,226 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+// Allow ns-3 to ping a real host somewhere, using emulation mode and ping
+// the simulated node from the host.
+//
+// ------------------
+// | ns-3 simulation |
+// | |
+// | ------- |
+// | | node | |
+// | ------- |
+// | | fd- | |
+// | | net- | |
+// | | device| |
+// | ------- |
+// | | |
+// | | |
+// ----|-------------
+// | --- --- |
+// | | | | | |
+// | |TAP| |ETH| |
+// | | | | | |
+// | --- --- |
+// | | |
+// | host | |
+// --------------|----
+// |
+// |
+// ---- (Internet) -------
+//
+// To use this example:
+// 1) ns-3 will create the TAP device for you in the host machine.
+// For this you need to provide the network address to allocate IP addresses
+// for the TAP device and the ns-3 FdNetDevice.
+//
+// 2) Take into consideration that this experiment requires the host to be able
+// to forward the traffic generated by the simulation to the Internet.
+// So for Linux systems, make sure to configure:
+// # echo 1 > /proc/sys/net/ipv4/ip_forward
+//
+// Also enable natting so the traffic sent on the Internet are able to
+// reach back the TAP.
+// - TAP-network-address is the same as 'tapNetwork'
+// - net-device-ip is be the IP address of the network device connected to the internet
+// # iptables -t nat -A POSTROUTING -s <TAP-network-addres>/24 -j SNAT --to-source <net-device-ip>
+//
+// 3) Before running the example make sure that the tap creator binary has root suid
+//
+// # chown root.root build/src/fd-net-device/ns3-dev-tap-device-creator
+// # sudo chmod 4755 build/src/fd-net-device/ns3-dev-tap-device-creator
+//
+
+
+#include "ns3/abort.h"
+#include "ns3/core-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/network-module.h"
+#include "ns3/fd-net-device-module.h"
+#include "ns3/applications-module.h"
+#include "ns3/ipv4-static-routing-helper.h"
+#include "ns3/ipv4-list-routing-helper.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("TAPPingExample");
+
+static void
+PingRtt (std::string context, Time rtt)
+{
+ NS_LOG_UNCOND ("Received Response with RTT = " << rtt);
+}
+
+int
+main (int argc, char *argv[])
+{
+ NS_LOG_INFO ("Ping Emulation Example with TAP");
+
+ std::string deviceName ("tap0");
+ std::string remote ("192.0.43.10"); // example.com
+ std::string network ("1.2.3.4");
+ std::string mask ("255.255.255.0");
+ std::string pi ("no");
+
+ //
+ // Allow the user to override any of the defaults at run-time, via
+ // command-line arguments
+ //
+ CommandLine cmd;
+ cmd.AddValue ("deviceName", "Device name", deviceName);
+ cmd.AddValue ("remote", "Remote IP address (dotted decimal only please)", remote);
+ cmd.AddValue ("tapNetwork", "Network address to assign the TAP device IP address (dotted decimal only please)", network);
+ cmd.AddValue ("tapMask", "Network mask for configure the TAP device (dotted decimal only please)", mask);
+ cmd.AddValue ("modePi", "If 'yes' a PI header will be added to the traffic traversing the device(flag IFF_NOPI will be unset).", pi);
+ cmd.Parse (argc, argv);
+
+ NS_ABORT_MSG_IF (network == "1.2.3.4", "You must change the local IP address before running this example");
+
+ Ipv4Address remoteIp (remote.c_str ());
+ Ipv4Address tapNetwork (network.c_str ());
+ Ipv4Mask tapMask (mask.c_str ());
+
+ bool modePi = ( pi == "yes" ? true : false);
+
+ //
+ // Since we are using a real piece of hardware we need to use the realtime
+ // simulator.
+ //
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+
+ //
+ // Since we are going to be talking to real-world machines, we need to enable
+ // calculation of checksums in our protocols.
+ //
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ //
+ // In such a simple topology, the use of the helper API can be a hindrance
+ // so we drop down into the low level API and do it manually.
+ //
+ // First we need a single node.
+ //
+ NS_LOG_INFO ("Create Node");
+ Ptr<Node> node = CreateObject<Node> ();
+
+ // Create an fd device, set a MAC address and point the device to the
+ // Linux device name. The device needs a transmit queueing discipline so
+ // create a droptail queue and give it to the device. Finally, "install"
+ // the device into the node.
+ //
+ Ipv4AddressHelper addresses;
+ addresses.SetBase (tapNetwork, tapMask);
+ Ipv4Address tapIp = addresses.NewAddress ();
+
+ NS_LOG_INFO ("Create Device");
+ TapFdNetDeviceHelper helper;
+ helper.SetDeviceName (deviceName);
+ helper.SetModePi (modePi);
+ helper.SetTapIpv4Address (tapIp);
+ helper.SetTapIpv4Mask (tapMask);
+
+ NetDeviceContainer devices = helper.Install (node);
+ Ptr<NetDevice> device = devices.Get (0);
+
+ //
+ // Add a default internet stack to the node (ARP, IPv4, ICMP, UDP and TCP).
+ //
+ NS_LOG_INFO ("Add Internet Stack");
+ InternetStackHelper internetStackHelper;
+ internetStackHelper.Install (node);
+
+ //
+ // Add an address to the ns-3 device in the same network than one
+ // assigned to the TAP.
+ //
+ NS_LOG_INFO ("Create IPv4 Interface");
+ Ptr<Ipv4> ipv4 = node->GetObject<Ipv4> ();
+ uint32_t interface = ipv4->AddInterface (device);
+ Ipv4Address devIp = addresses.NewAddress ();
+ Ipv4InterfaceAddress address = Ipv4InterfaceAddress (devIp, tapMask);
+ ipv4->AddAddress (interface, address);
+ ipv4->SetMetric (interface, 1);
+ ipv4->SetUp (interface);
+
+ //
+ // Add a route to the ns-3 device so it can reach the outside world though the
+ // TAP.
+ //
+ Ipv4StaticRoutingHelper ipv4RoutingHelper;
+ Ptr<Ipv4StaticRouting> staticRouting = ipv4RoutingHelper.GetStaticRouting (ipv4);
+ staticRouting->SetDefaultRoute (tapIp, interface);
+
+ //
+ // Create the ping application. This application knows how to send
+ // ICMP echo requests. Setting up the packet sink manually is a bit
+ // of a hassle and since there is no law that says we cannot mix the
+ // helper API with the low level API, let's just use the helper.
+ //
+ NS_LOG_INFO ("Create V4Ping Appliation");
+ Ptr<V4Ping> app = CreateObject<V4Ping> ();
+ app->SetAttribute ("Remote", Ipv4AddressValue (remoteIp));
+ app->SetAttribute ("Verbose", BooleanValue (true) );
+ node->AddApplication (app);
+ app->SetStartTime (Seconds (1.0));
+ app->SetStopTime (Seconds (21.0));
+
+ //
+ // Give the application a name. This makes life much easier when constructing
+ // config paths.
+ //
+ Names::Add ("app", app);
+
+ //
+ // Hook a trace to print something when the response comes back.
+ //
+ Config::Connect ("/Names/app/Rtt", MakeCallback (&PingRtt));
+
+ //
+ // Enable a promiscuous pcap trace to see what is coming and going on our device.
+ //
+ helper.EnablePcap ("fd-tap-ping", device, true);
+
+ //
+ // Now, do the actual emulation.
+ //
+ NS_LOG_INFO ("Run Emulation.");
+ Simulator::Stop (Seconds (25.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+ NS_LOG_INFO ("Done.");
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/fd-tap-ping6.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,164 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+// Allow ns-3 to ping a TAP device in the host machine.
+//
+// -------------------------------------------------
+// | ns-3 simulation |
+// | |
+// | ------- -------- |
+// | | node | | node | |
+// | | (r) | | (n) | |
+// | | | | | |
+// | ------- -------- -------- |
+// | | fd- | csma- | | csma- | |
+// | | net- | net- | | net- | |
+// | | device| device | | device | |
+// | ------- -------- -------- |
+// | | |____csma channel_____| |
+// | | |
+// ----|------------------------------------------
+// | --- |
+// | | | |
+// | |TAP| |
+// | | | |
+// | --- |
+// | |
+// | host |
+// ------------------
+//
+//
+
+#include <sstream>
+#include <string>
+
+#include "ns3/core-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/csma-module.h"
+#include "ns3/applications-module.h"
+#include "ns3/fd-net-device-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("TAPPing6Example");
+
+int
+main (int argc, char *argv[])
+{
+ NS_LOG_INFO ("Ping6 Emulation Example with TAP");
+
+ //
+ // Since we are using a real piece of hardware we need to use the realtime
+ // simulator.
+ //
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+
+ //
+ // Since we are going to be talking to real-world machines, we need to enable
+ // calculation of checksums in our protocols.
+ //
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ //
+ // Create the two nodes.
+ //
+ Ptr<Node> n = CreateObject<Node> ();
+ Ptr<Node> r = CreateObject<Node> ();
+ NodeContainer net (n, r);
+
+ //
+ // Install IPv6 stack.
+ //
+ InternetStackHelper internetv6;
+ internetv6.Install (net);
+
+ //
+ // Create CSMA channel.
+ //
+ CsmaHelper csma;
+ csma.SetChannelAttribute ("DataRate", DataRateValue (5000000));
+ csma.SetChannelAttribute ("Delay", TimeValue (MilliSeconds (2)));
+ NetDeviceContainer devs = csma.Install (net);
+
+ //
+ // Assign IPv6 addresses.
+ //
+ Ipv6AddressHelper ipv6;
+
+ ipv6.SetBase (Ipv6Address ("2001:0DB8:1::"), Ipv6Prefix (64));
+ Ipv6InterfaceContainer i1 = ipv6.Assign (devs);
+ i1.SetRouter (1, true);
+
+ ipv6.SetBase (Ipv6Address ("2001:0DB8:2::"), Ipv6Prefix (64));
+ Ipv6Address tapAddr = ipv6.NewAddress ();
+ std::stringstream ss;
+ std::string tapIp;
+ tapAddr.Print (ss);
+ ss >> tapIp;
+
+ //
+ // Create FdNetDevice.
+ //
+ TapFdNetDeviceHelper helper;
+ helper.SetDeviceName ("tap0");
+ helper.SetTapIpv6Address (tapIp.c_str ());
+ helper.SetTapIpv6Prefix (64);
+
+ NetDeviceContainer fdevs = helper.Install (r);
+ Ptr<NetDevice> device = fdevs.Get (0);
+ Ptr<FdNetDevice> fdevice = device->GetObject<FdNetDevice> ();
+ fdevice-> SetIsMulticast (true);
+ Ipv6InterfaceContainer i2 = ipv6.Assign (fdevs);
+ i2.SetRouter (0, true);
+
+ //
+ // Create the Ping6 application.
+ //
+ uint32_t packetSize = 1024;
+ uint32_t maxPacketCount = 1;
+ Time interPacketInterval = Seconds (1.0);
+
+ Ping6Helper ping6;
+
+ ping6.SetRemote (tapIp.c_str ());
+
+ ping6.SetAttribute ("MaxPackets", UintegerValue (maxPacketCount));
+ ping6.SetAttribute ("Interval", TimeValue (interPacketInterval));
+ ping6.SetAttribute ("PacketSize", UintegerValue (packetSize));
+ ApplicationContainer apps = ping6.Install (n);
+ apps.Start (Seconds (2.0));
+ apps.Stop (Seconds (20.0));
+
+ AsciiTraceHelper ascii;
+ csma.EnableAsciiAll (ascii.CreateFileStream ("csma-ping6.tr"));
+ csma.EnablePcapAll ("csma-ping6", true);
+
+ //
+ // Enable a promiscuous pcap trace to see what is coming and going on in the fd-net-device.
+ //
+ helper.EnablePcap ("fd-ping6", fdevice, true);
+
+ //
+ // Run the experiment.
+ //
+ NS_LOG_INFO ("Run Emulation.");
+ Simulator::Stop (Seconds (200.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+ NS_LOG_INFO ("Done.");
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/fd2fd-onoff.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,125 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ *
+ */
+
+//
+// node 0 node 1
+// +----------------+ +----------------+
+// | ns-3 TCP | | ns-3 TCP |
+// +----------------+ +----------------+
+// | 10.1.1.1 | | 10.1.1.2 |
+// +----------------+ socketpair +----------------+
+// | fd-net-device |--------------| fd-net-device |
+// +----------------+ +----------------+
+//
+// This example is aimed at meassuring the thoughput of the FdNetDevice
+// in a pure simulation. For this purpose two FdNetDevices, attached to
+// different nodes but in a same simulation, are connected using a socket pair.
+// TCP traffic is sent at a saturating data rate. Then the thoughput can
+// be obtained from the generated .pcap files.
+//
+// Steps to run the experiment:
+//
+// $ ./waf --run="fd2fd-onoff"
+//
+
+#include <sys/socket.h>
+#include <errno.h>
+
+#include "ns3/core-module.h"
+#include "ns3/network-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/fd-net-device-module.h"
+#include "ns3/applications-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("FdNetDeviceSaturationExample");
+
+int
+main (int argc, char *argv[])
+{
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ uint16_t sinkPort = 8000;
+ uint32_t packetSize = 10000; // bytes
+ std::string dataRate("10Mb/s");
+
+ NS_LOG_INFO ("Create Node");
+ NodeContainer nodes;
+ nodes.Create (2);
+
+ NS_LOG_INFO ("Create Device");
+ FdNetDeviceHelper fd;
+ NetDeviceContainer devices = fd.Install (nodes);
+
+ int sv[2];
+ if (socketpair (AF_UNIX, SOCK_DGRAM, 0, sv) < 0)
+ {
+ NS_FATAL_ERROR ("Error creating pipe=" << strerror (errno));
+ }
+
+ Ptr<NetDevice> d1 = devices.Get (0);
+ Ptr<FdNetDevice> clientDevice = d1->GetObject<FdNetDevice> ();
+ clientDevice->SetFileDescriptor (sv[0]);
+
+ Ptr<NetDevice> d2 = devices.Get (1);
+ Ptr<FdNetDevice> serverDevice = d2->GetObject<FdNetDevice> ();
+ serverDevice->SetFileDescriptor (sv[1]);
+
+ NS_LOG_INFO ("Add Internet Stack");
+ InternetStackHelper internetStackHelper;
+ internetStackHelper.SetIpv4StackInstall(true);
+ internetStackHelper.Install (nodes);
+
+ NS_LOG_INFO ("Create IPv4 Interface");
+ Ipv4AddressHelper addresses;
+ addresses.SetBase ("10.0.0.0", "255.255.255.0");
+ Ipv4InterfaceContainer interfaces = addresses.Assign (devices);
+
+ Ptr<Node> clientNode = nodes.Get (0);
+ Ipv4Address serverIp = interfaces.GetAddress (1);
+ Ptr<Node> serverNode = nodes.Get (1);
+
+ // server
+ Address sinkLocalAddress (InetSocketAddress (serverIp, sinkPort));
+ PacketSinkHelper sinkHelper ("ns3::TcpSocketFactory", sinkLocalAddress);
+ ApplicationContainer sinkApp = sinkHelper.Install (serverNode);
+ sinkApp.Start (Seconds (0.0));
+ sinkApp.Stop (Seconds (30.0));
+ fd.EnablePcap ("fd2fd-onoff-server", serverDevice);
+
+ // client
+ AddressValue serverAddress (InetSocketAddress (serverIp, sinkPort));
+ OnOffHelper onoff ("ns3::TcpSocketFactory", Address ());
+ onoff.SetAttribute ("Remote", serverAddress);
+ onoff.SetAttribute ("OnTime", StringValue ("ns3::ConstantRandomVariable[Constant=1]"));
+ onoff.SetAttribute ("OffTime", StringValue ("ns3::ConstantRandomVariable[Constant=0]"));
+ onoff.SetAttribute ("DataRate", DataRateValue (dataRate));
+ onoff.SetAttribute ("PacketSize", UintegerValue (packetSize));
+ ApplicationContainer clientApps = onoff.Install (clientNode);
+ clientApps.Start (Seconds (2.0));
+ clientApps.Stop (Seconds (29.0));
+ fd.EnablePcap ("fd2fd-onoff-client", clientDevice);
+
+ Simulator::Stop (Seconds (30.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/realtime-dummy-network.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,81 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+// Network topology
+//
+#include <sys/socket.h>
+#include <errno.h>
+
+#include "ns3/core-module.h"
+#include "ns3/network-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/fd-net-device-module.h"
+#include "ns3/applications-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("RealtimeDummyNetworkExample");
+
+int
+main (int argc, char *argv[])
+{
+
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ NodeContainer nodes;
+ nodes.Create (2);
+
+ InternetStackHelper stack;
+ stack.Install (nodes);
+
+ FdNetDeviceHelper fd;
+ NetDeviceContainer devices = fd.Install (nodes);
+
+ int sv[2];
+ if (socketpair (AF_UNIX, SOCK_DGRAM, 0, sv) < 0)
+ {
+ NS_FATAL_ERROR ("Error creating pipe=" << strerror (errno));
+ }
+
+ Ptr<NetDevice> d1 = devices.Get (0);
+ Ptr<FdNetDevice> device1 = d1->GetObject<FdNetDevice> ();
+ device1->SetFileDescriptor (sv[0]);
+
+ Ptr<NetDevice> d2 = devices.Get (1);
+ Ptr<FdNetDevice> device2 = d2->GetObject<FdNetDevice> ();
+ device2->SetFileDescriptor (sv[1]);
+
+ Ipv4AddressHelper addresses;
+ addresses.SetBase ("10.0.0.0", "255.255.255.0");
+ Ipv4InterfaceContainer interfaces = addresses.Assign (devices);
+
+ Ptr<V4Ping> app = CreateObject<V4Ping> ();
+ app->SetAttribute ("Remote", Ipv4AddressValue (interfaces.GetAddress (0)));
+ app->SetAttribute ("Verbose", BooleanValue (true));
+ nodes.Get (1)->AddApplication (app);
+ app->SetStartTime (Seconds (0.0));
+ app->SetStopTime (Seconds (4.0));
+
+ fd.EnablePcapAll ("realtime-dummy-network", false);
+
+ Simulator::Stop (Seconds (5.));
+ Simulator::Run ();
+ Simulator::Destroy ();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/realtime-fd2fd-onoff.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,127 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 University of Washington, 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ *
+ */
+
+//
+// node 0 node 1
+// +----------------+ +----------------+
+// | ns-3 TCP | | ns-3 TCP |
+// +----------------+ +----------------+
+// | 10.1.1.1 | | 10.1.1.2 |
+// +----------------+ socketpair +----------------+
+// | fd-net-device |--------------| fd-net-device |
+// +----------------+ +----------------+
+//
+// This example is aimed at meassuring the thoughput of the FdNetDevice
+// in a pure simulation. For this purpose two FdNetDevices, attached to
+// different nodes but in a same simulation, are connected using a socket pair.
+// TCP traffic is sent at a saturating data rate. Then the thoughput can
+// be obtained from the generated .pcap files.
+//
+// Steps to run the experiment:
+//
+// $ ./waf --run="fd2fd-onoff"
+//
+
+#include <sys/socket.h>
+#include <errno.h>
+
+#include "ns3/core-module.h"
+#include "ns3/network-module.h"
+#include "ns3/internet-module.h"
+#include "ns3/fd-net-device-module.h"
+#include "ns3/applications-module.h"
+
+using namespace ns3;
+
+NS_LOG_COMPONENT_DEFINE ("RealtimeFdNetDeviceSaturationExample");
+
+int
+main (int argc, char *argv[])
+{
+
+ uint16_t sinkPort = 8000;
+ uint32_t packetSize = 10000; // bytes
+ std::string dataRate("1000Mb/s");
+
+ GlobalValue::Bind ("SimulatorImplementationType", StringValue ("ns3::RealtimeSimulatorImpl"));
+ GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true));
+
+ NS_LOG_INFO ("Create Node");
+ NodeContainer nodes;
+ nodes.Create (2);
+
+ NS_LOG_INFO ("Create Device");
+ FdNetDeviceHelper fd;
+ NetDeviceContainer devices = fd.Install (nodes);
+
+ int sv[2];
+ if (socketpair (AF_UNIX, SOCK_DGRAM, 0, sv) < 0)
+ {
+ NS_FATAL_ERROR ("Error creating pipe=" << strerror (errno));
+ }
+
+ Ptr<NetDevice> d1 = devices.Get (0);
+ Ptr<FdNetDevice> clientDevice = d1->GetObject<FdNetDevice> ();
+ clientDevice->SetFileDescriptor (sv[0]);
+
+ Ptr<NetDevice> d2 = devices.Get (1);
+ Ptr<FdNetDevice> serverDevice = d2->GetObject<FdNetDevice> ();
+ serverDevice->SetFileDescriptor (sv[1]);
+
+ NS_LOG_INFO ("Add Internet Stack");
+ InternetStackHelper internetStackHelper;
+ internetStackHelper.SetIpv4StackInstall(true);
+ internetStackHelper.Install (nodes);
+
+ NS_LOG_INFO ("Create IPv4 Interface");
+ Ipv4AddressHelper addresses;
+ addresses.SetBase ("10.0.0.0", "255.255.255.0");
+ Ipv4InterfaceContainer interfaces = addresses.Assign (devices);
+
+ Ptr<Node> clientNode = nodes.Get (0);
+ Ipv4Address serverIp = interfaces.GetAddress (1);
+ Ptr<Node> serverNode = nodes.Get (1);
+
+ // server
+ Address sinkLocalAddress (InetSocketAddress (serverIp, sinkPort));
+ PacketSinkHelper sinkHelper ("ns3::TcpSocketFactory", sinkLocalAddress);
+ ApplicationContainer sinkApp = sinkHelper.Install (serverNode);
+ sinkApp.Start (Seconds (0.0));
+ sinkApp.Stop (Seconds (40.0));
+ fd.EnablePcap ("rt-fd2fd-onoff-server", serverDevice);
+
+ // client
+ AddressValue serverAddress (InetSocketAddress (serverIp, sinkPort));
+ OnOffHelper onoff ("ns3::TcpSocketFactory", Address ());
+ onoff.SetAttribute ("Remote", serverAddress);
+ onoff.SetAttribute ("OnTime", StringValue ("ns3::ConstantRandomVariable[Constant=1]"));
+ onoff.SetAttribute ("OffTime", StringValue ("ns3::ConstantRandomVariable[Constant=0]"));
+ onoff.SetAttribute ("DataRate", DataRateValue (dataRate));
+ onoff.SetAttribute ("PacketSize", UintegerValue (packetSize));
+ ApplicationContainer clientApps = onoff.Install (clientNode);
+ clientApps.Start (Seconds (1.0));
+ clientApps.Stop (Seconds (39.0));
+ fd.EnablePcap ("rt-fd2fd-onoff-client", clientDevice);
+
+ Simulator::Stop (Seconds (40.0));
+ Simulator::Run ();
+ Simulator::Destroy ();
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/waf Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,1 @@
+exec "`dirname "$0"`"/../../waf "$@"
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/examples/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,36 @@
+## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
+
+def build(bld):
+ env = bld.env
+ if not env['ENABLE_FDNETDEV']:
+ return
+
+ obj = bld.create_ns3_program('dummy-network', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'dummy-network.cc'
+ obj = bld.create_ns3_program('fd2fd-onoff', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'fd2fd-onoff.cc'
+
+ if bld.env["ENABLE_REAL_TIME"]:
+ obj = bld.create_ns3_program('realtime-dummy-network', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'realtime-dummy-network.cc'
+ obj = bld.create_ns3_program('realtime-fd2fd-onoff', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'realtime-fd2fd-onoff.cc'
+
+ if bld.env['ENABLE_TAP']:
+ obj = bld.create_ns3_program('fd-emu-ping', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'fd-emu-ping.cc'
+ obj = bld.create_ns3_program('fd-emu-udp-echo', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'fd-emu-udp-echo.cc'
+ obj = bld.create_ns3_program('fd-emu-onoff', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'fd-emu-onoff.cc'
+
+ if bld.env['ENABLE_TAP']:
+ obj = bld.create_ns3_program('fd-tap-ping', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'fd-tap-ping.cc'
+ obj = bld.create_ns3_program('fd-tap-ping6', ['fd-net-device', 'internet', 'applications', 'csma'])
+ obj.source = 'fd-tap-ping6.cc'
+
+ if bld.env['ENABLE_PLANETLAB']:
+ obj = bld.create_ns3_program('fd-planetlab-ping', ['fd-net-device', 'internet', 'applications'])
+ obj.source = 'fd-planetlab-ping.cc'
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/creator-utils.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,175 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include <unistd.h>
+#include <string>
+#include <iostream>
+#include <iomanip>
+#include <sstream>
+#include <stdlib.h>
+#include <errno.h>
+
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <sys/ioctl.h>
+#include <net/ethernet.h>
+#include <net/if.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
+#include "creator-utils.h"
+#include "encode-decode.h"
+
+namespace ns3 {
+
+int gVerbose = 0;
+
+/**
+ * \brief Send the file descriptor back to the code that invoked the creation.
+ *
+ * \param path The socket address information from the Unix socket we use
+ * to send the created socket back to.
+ * \param fd The file descriptor we're going to send.
+ * \param magic_number A verification number to verify the caller is talking to the
+ * right process.
+ */
+void
+SendSocket (const char *path, int fd, const int magic_number)
+{
+ //
+ // Open a Unix (local interprocess) socket to call back to the emu net
+ // device.
+ //
+ LOG ("Create Unix socket");
+ int sock = socket (PF_UNIX, SOCK_DGRAM, 0);
+ ABORT_IF (sock == -1, "Unable to open socket", 1);
+
+ //
+ // We have this string called path, which is really a hex representation
+ // of the endpoint that the net device created. It used a forward encoding
+ // method (BufferToString) to take the sockaddr_un it made and passed
+ // the resulting string to us. So we need to take the inverse method
+ // (StringToBuffer) and build the same sockaddr_un over here.
+ //
+ socklen_t clientAddrLen;
+ struct sockaddr_un clientAddr;
+
+ LOG ("Decode address " << path);
+ bool rc = ns3::StringToBuffer (path, (uint8_t *)&clientAddr, &clientAddrLen);
+ ABORT_IF (rc == false, "Unable to decode path", 0);
+
+ LOG ("Connect");
+ int status = connect (sock, (struct sockaddr*)&clientAddr, clientAddrLen);
+ ABORT_IF (status == -1, "Unable to connect to emu device", 1);
+
+ LOG ("Connected");
+
+ //
+ // This is arcane enough that a few words are worthwhile to explain what's
+ // going on here.
+ //
+ // The interesting information (the socket FD) is going to go back to the
+ // fd net device as an integer of ancillary data. Ancillary data is bits
+ // that are not a part a socket payload (out-of-band data). We're also
+ // going to send one integer back. It's just initialized to a magic number
+ // we use to make sure that the fd device is talking to the emu socket
+ // creator and not some other creator process.
+ //
+ // The struct iovec below is part of a scatter-gather list. It describes a
+ // buffer. In this case, it describes a buffer (an integer) containing the
+ // data that we're going to send back to the emu net device (that magic
+ // number).
+ //
+ struct iovec iov;
+ uint32_t magic = magic_number;
+ iov.iov_base = &magic;
+ iov.iov_len = sizeof(magic);
+
+ //
+ // The CMSG macros you'll see below are used to create and access control
+ // messages (which is another name for ancillary data). The ancillary
+ // data is made up of pairs of struct cmsghdr structures and associated
+ // data arrays.
+ //
+ // First, we're going to allocate a buffer on the stack to contain our
+ // data array (that contains the socket). Sometimes you'll see this called
+ // an "ancillary element" but the msghdr uses the control message termimology
+ // so we call it "control."
+ //
+ size_t msg_size = sizeof(int);
+ char control[CMSG_SPACE (msg_size)];
+
+ //
+ // There is a msghdr that is used to minimize the number of parameters
+ // passed to sendmsg (which we will use to send our ancillary data). This
+ // structure uses terminology corresponding to control messages, so you'll
+ // see msg_control, which is the pointer to the ancillary data and controllen
+ // which is the size of the ancillary data array.
+ //
+ // So, initialize the message header that describes our ancillary/control data
+ // and point it to the control message/ancillary data we just allocated space
+ // for.
+ //
+ struct msghdr msg;
+ msg.msg_name = 0;
+ msg.msg_namelen = 0;
+ msg.msg_iov = &iov;
+ msg.msg_iovlen = 1;
+ msg.msg_control = control;
+ msg.msg_controllen = sizeof (control);
+ msg.msg_flags = 0;
+
+ //
+ // A cmsghdr contains a length field that is the length of the header and
+ // the data. It has a cmsg_level field corresponding to the originating
+ // protocol. This takes values which are legal levels for getsockopt and
+ // setsockopt (here SOL_SOCKET). We're going to use the SCM_RIGHTS type of
+ // cmsg, that indicates that the ancillary data array contains access rights
+ // that we are sending back to the emu net device.
+ //
+ // We have to put together the first (and only) cmsghdr that will describe
+ // the whole package we're sending.
+ //
+ struct cmsghdr *cmsg;
+ cmsg = CMSG_FIRSTHDR (&msg);
+ cmsg->cmsg_level = SOL_SOCKET;
+ cmsg->cmsg_type = SCM_RIGHTS;
+ cmsg->cmsg_len = CMSG_LEN (msg_size);
+ //
+ // We also have to update the controllen in case other stuff is actually
+ // in there we may not be aware of (due to macros).
+ //
+ msg.msg_controllen = cmsg->cmsg_len;
+
+ //
+ // Finally, we get a pointer to the start of the ancillary data array and
+ // put our file descriptor in.
+ //
+ int *fdptr = (int*)(CMSG_DATA (cmsg));
+ *fdptr = fd; //
+
+ //
+ // Actually send the file descriptor back to the emulated net device.
+ //
+ ssize_t len = sendmsg (sock, &msg, 0);
+ ABORT_IF (len == -1, "Could not send socket back to emu net device", 1);
+
+ LOG ("sendmsg complete");
+}
+
+} // namespace ns3
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/creator-utils.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,70 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef CREATOR_UTILS_H
+#define CREATOR_UTILS_H
+
+#include <unistd.h>
+#include <string>
+#include <iostream>
+#include <iomanip>
+#include <sstream>
+#include <stdlib.h>
+#include <errno.h>
+
+#include <sys/socket.h>
+
+namespace ns3 {
+
+extern int gVerbose;
+
+#define LOG(msg) \
+ if (gVerbose) \
+ { \
+ std::cout << __FUNCTION__ << "(): " << msg << std::endl; \
+ }
+
+#define ABORT(msg, printErrno) \
+ std::cout << __FILE__ << ": fatal error at line " << __LINE__ << ": " << __FUNCTION__ << "(): " << msg << std::endl; \
+ if (printErrno) \
+ { \
+ std::cout << " errno = " << errno << " (" << strerror (errno) << ")" << std::endl; \
+ } \
+ exit (-1);
+
+#define ABORT_IF(cond, msg, printErrno) \
+ if (cond) \
+ { \
+ ABORT (msg, printErrno); \
+ }
+
+/**
+ * \brief Send the file descriptor back to the code that invoked the creation.
+ *
+ * \param path The socket address information from the Unix socket we use
+ * to send the created socket back to.
+ * \param fd The file descriptor we're going to send.
+ * \param magic_number A verification number to verify the caller is talking to the
+ * right process.
+ */
+void SendSocket (const char *path, int fd, const int magic_number);
+
+} // namespace ns3
+
+#endif /* CREATOR_UTILS_DEVICE_H */
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/emu-fd-net-device-helper.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,410 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA, 2012 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include "emu-fd-net-device-helper.h"
+#include "encode-decode.h"
+
+#include "ns3/abort.h"
+#include "ns3/config.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/log.h"
+#include "ns3/names.h"
+#include "ns3/object-factory.h"
+#include "ns3/packet.h"
+#include "ns3/simulator.h"
+#include "ns3/trace-helper.h"
+
+#include <arpa/inet.h>
+#include <errno.h>
+#include <iostream>
+#include <iomanip>
+#include <limits>
+#include <linux/if_tun.h>
+#include <memory>
+#include <net/ethernet.h>
+#include <net/if.h>
+#include <netinet/in.h>
+#include <netpacket/packet.h>
+
+#include <stdlib.h>
+#include <string.h>
+#include <sys/wait.h>
+#include <sys/stat.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <sys/ioctl.h>
+#include <time.h>
+#include <unistd.h>
+
+#include <string>
+
+NS_LOG_COMPONENT_DEFINE ("EmuFdNetDeviceHelper");
+
+namespace ns3 {
+
+#define EMU_MAGIC 65867
+
+EmuFdNetDeviceHelper::EmuFdNetDeviceHelper ()
+{
+ m_deviceName = "undefined";
+}
+
+void
+EmuFdNetDeviceHelper::SetDeviceName (std::string deviceName)
+{
+ m_deviceName = deviceName;
+}
+
+std::string
+EmuFdNetDeviceHelper::GetDeviceName (void)
+{
+ return m_deviceName;
+}
+
+Ptr<NetDevice>
+EmuFdNetDeviceHelper::InstallPriv (Ptr<Node> node) const
+{
+ Ptr<NetDevice> d = FdNetDeviceHelper::InstallPriv (node);
+ Ptr<FdNetDevice> device = d->GetObject<FdNetDevice> ();
+ SetFileDescriptor (device);
+ return device;
+}
+
+void
+EmuFdNetDeviceHelper::SetFileDescriptor (Ptr<FdNetDevice> device) const
+{
+ NS_LOG_LOGIC ("Creating EMU socket");
+
+ if (m_deviceName == "undefined")
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::SetFileDescriptor (): m_deviceName is not set");
+ }
+
+ //
+ // Call out to a separate process running as suid root in order to get a raw
+ // socket. We do this to avoid having the entire simulation running as root.
+ //
+ int fd = CreateFileDescriptor ();
+ device->SetFileDescriptor (fd);
+
+ //
+ // Figure out which interface index corresponds to the device name in the corresponding attribute.
+ //
+ struct ifreq ifr;
+ bzero (&ifr, sizeof(ifr));
+ strncpy ((char *)ifr.ifr_name, m_deviceName.c_str (), IFNAMSIZ);
+
+ NS_LOG_LOGIC ("Getting interface index");
+ int32_t rc = ioctl (fd, SIOCGIFINDEX, &ifr);
+ if (rc == -1)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::SetFileDescriptor (): Can't get interface index");
+ }
+
+ //
+ // Bind the socket to the interface we just found.
+ //
+ struct sockaddr_ll ll;
+ bzero (&ll, sizeof(ll));
+
+ ll.sll_family = AF_PACKET;
+ ll.sll_ifindex = ifr.ifr_ifindex;
+ ll.sll_protocol = htons (ETH_P_ALL);
+
+ NS_LOG_LOGIC ("Binding socket to interface");
+
+ rc = bind (fd, (struct sockaddr *)&ll, sizeof (ll));
+ if (rc == -1)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::SetFileDescriptor (): Can't bind to specified interface");
+ }
+
+ rc = ioctl (fd, SIOCGIFFLAGS, &ifr);
+ if (rc == -1)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::SetFileDescriptor (): Can't get interface flags");
+ }
+
+ //
+ // This device only works if the underlying interface is up in promiscuous
+ // mode. We could have turned it on in the socket creator, but the situation
+ // is that we expect these devices to be used in conjunction with virtual
+ // machines with connected host-only (simulated) networks, or in a testbed.
+ // There is a lot of setup and configuration happening outside of this one
+ // issue, and we expect that configuration to include choosing a valid
+ // interface (e.g, "ath1"), ensuring that the device supports promiscuous
+ // mode, and placing it in promiscuous mode. We just make sure of the
+ // end result.
+ //
+ if ((ifr.ifr_flags & IFF_PROMISC) == 0)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::SetFileDescriptor (): " << m_deviceName.c_str () << " is not in promiscuous mode");
+ }
+
+ if ((ifr.ifr_flags & IFF_BROADCAST) != IFF_BROADCAST)
+ {
+ // We default m_isBroadcast to true but turn it off here if not
+ // supported, because in the common case, overlying IP code will
+ // assert during configuration time if this is false, before this
+ // method has a chance to set it during runtime
+ device->SetIsBroadcast (false);
+ }
+
+ if ((ifr.ifr_flags & IFF_MULTICAST) == IFF_MULTICAST)
+ {
+ // This one is OK to enable at runtime
+ device->SetIsMulticast (true);
+ }
+
+ // Set the MTU of the device to the mtu of the associated network interface
+ struct ifreq ifr2;
+
+ bzero (&ifr2, sizeof (ifr2));
+ strcpy (ifr2.ifr_name, m_deviceName.c_str ());
+
+ int32_t mtufd = socket (PF_INET, SOCK_DGRAM, IPPROTO_IP);
+
+ rc = ioctl (mtufd, SIOCGIFMTU, &ifr2);
+ if (rc == -1)
+ {
+ NS_FATAL_ERROR ("FdNetDevice::SetFileDescriptor (): Can't ioctl SIOCGIFMTU");
+ }
+
+ close (mtufd);
+ device->SetMtu (ifr.ifr_mtu);
+}
+
+int
+EmuFdNetDeviceHelper::CreateFileDescriptor (void) const
+{
+ NS_LOG_FUNCTION (this);
+
+ //
+ // We want to create a raw socket for our net device. Unfortunately for us
+ // you have to have root privileges to do that. Instead of running the
+ // entire simulation as root, we decided to make a small program who's whole
+ // reason for being is to run as suid root and create a raw socket. We're
+ // going to fork and exec that program soon, but we need to have a socket
+ // to talk to it with. So we create a local interprocess (Unix) socket
+ // for that purpose.
+ //
+ int sock = socket (PF_UNIX, SOCK_DGRAM, 0);
+ if (sock == -1)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): Unix socket creation error, errno = " << strerror (errno));
+ }
+
+ //
+ // Bind to that socket and let the kernel allocate an endpoint
+ //
+ struct sockaddr_un un;
+ memset (&un, 0, sizeof (un));
+ un.sun_family = AF_UNIX;
+ int status = bind (sock, (struct sockaddr*)&un, sizeof (sa_family_t));
+ if (status == -1)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): Could not bind(): errno = " << strerror (errno));
+ }
+
+ NS_LOG_INFO ("Created Unix socket");
+ NS_LOG_INFO ("sun_family = " << un.sun_family);
+ NS_LOG_INFO ("sun_path = " << un.sun_path);
+
+ //
+ // We have a socket here, but we want to get it there -- to the program we're
+ // going to exec. What we'll do is to do a getsockname and then encode the
+ // resulting address information as a string, and then send the string to the
+ // program as an argument. So we need to get the sock name.
+ //
+ socklen_t len = sizeof (un);
+ status = getsockname (sock, (struct sockaddr*)&un, &len);
+ if (status == -1)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): Could not getsockname(): errno = " << strerror (errno));
+ }
+
+ //
+ // Now encode that socket name (family and path) as a string of hex digits
+ //
+ std::string path = BufferToString ((uint8_t *)&un, len);
+ NS_LOG_INFO ("Encoded Unix socket as \"" << path << "\"");
+ //
+ // Fork and exec the process to create our socket. If we're us (the parent)
+ // we wait for the child (the socket creator) to complete and read the
+ // socket it created using the ancillary data mechanism.
+ //
+ // Tom Goff reports the possiblility of a deadlock when trying to acquire the
+ // python GIL here. He says that this might be due to trying to access Python
+ // objects after fork() without calling PyOS_AfterFork() to properly reset
+ // Python state (including the GIL). There is no code to cause the problem
+ // here in emu, but this was visible in similar code in tap-bridge.
+ //
+ pid_t pid = ::fork ();
+ if (pid == 0)
+ {
+ NS_LOG_DEBUG ("Child process");
+
+ //
+ // build a command line argument from the encoded endpoint string that
+ // the socket creation process will use to figure out how to respond to
+ // the (now) parent process.
+ //
+ std::ostringstream oss;
+ oss << "-p" << path;
+ NS_LOG_INFO ("Parameters set to \"" << oss.str () << "\"");
+
+ //
+ // Execute the socket creation process image.
+ //
+ status = ::execlp (RAW_SOCK_CREATOR,
+ RAW_SOCK_CREATOR, // argv[0] (filename)
+ oss.str ().c_str (), // argv[1] (-p<path?
+ (char *)NULL);
+
+ //
+ // If the execlp successfully completes, it never returns. If it returns it failed or the OS is
+ // broken. In either case, we bail.
+ //
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): Back from execlp(), errno = " << ::strerror (errno));
+ }
+ else
+ {
+ NS_LOG_DEBUG ("Parent process");
+ //
+ // We're the process running the emu net device. We need to wait for the
+ // socket creator process to finish its job.
+ //
+ int st;
+ pid_t waited = waitpid (pid, &st, 0);
+ if (waited == -1)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): waitpid() fails, errno = " << strerror (errno));
+ }
+ NS_ASSERT_MSG (pid == waited, "EmuFdNetDeviceHelper::CreateFileDescriptor(): pid mismatch");
+
+ //
+ // Check to see if the socket creator exited normally and then take a
+ // look at the exit code. If it bailed, so should we. If it didn't
+ // even exit normally, we bail too.
+ //
+ if (WIFEXITED (st))
+ {
+ int exitStatus = WEXITSTATUS (st);
+ if (exitStatus != 0)
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): socket creator exited normally with status " << exitStatus);
+ }
+ }
+ else
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): socket creator exited abnormally");
+ }
+
+ //
+ // At this point, the socket creator has run successfully and should
+ // have created our raw socket and sent it back to the socket address
+ // we provided. Our socket should be waiting on the Unix socket. We've
+ // got to do a bunch of grunto work to get at it, though.
+ //
+ // The struct iovec below is part of a scatter-gather list. It describes a
+ // buffer. In this case, it describes a buffer (an integer) that will
+ // get the data that comes back from the socket creator process. It will
+ // be a magic number that we use as a consistency/sanity check.
+ //
+ struct iovec iov;
+ uint32_t magic;
+ iov.iov_base = &magic;
+ iov.iov_len = sizeof(magic);
+
+ //
+ // The CMSG macros you'll see below are used to create and access control
+ // messages (which is another name for ancillary data). The ancillary
+ // data is made up of pairs of struct cmsghdr structures and associated
+ // data arrays.
+ //
+ // First, we're going to allocate a buffer on the stack to receive our
+ // data array (that contains the socket). Sometimes you'll see this called
+ // an "ancillary element" but the msghdr uses the control message termimology
+ // so we call it "control."
+ //
+ size_t msg_size = sizeof(int);
+ char control[CMSG_SPACE (msg_size)];
+
+ //
+ // There is a msghdr that is used to minimize the number of parameters
+ // passed to recvmsg (which we will use to receive our ancillary data).
+ // This structure uses terminology corresponding to control messages, so
+ // you'll see msg_control, which is the pointer to the ancillary data and
+ // controllen which is the size of the ancillary data array.
+ //
+ // So, initialize the message header that describes the ancillary/control
+ // data we expect to receive and point it to buffer.
+ //
+ struct msghdr msg;
+ msg.msg_name = 0;
+ msg.msg_namelen = 0;
+ msg.msg_iov = &iov;
+ msg.msg_iovlen = 1;
+ msg.msg_control = control;
+ msg.msg_controllen = sizeof (control);
+ msg.msg_flags = 0;
+
+ //
+ // Now we can actually receive the interesting bits from the socket
+ // creator process.
+ //
+ ssize_t bytesRead = recvmsg (sock, &msg, 0);
+ if (bytesRead != sizeof(int))
+ {
+ NS_FATAL_ERROR ("EmuFdNetDeviceHelper::CreateFileDescriptor(): Wrong byte count from socket creator");
+ }
+
+ //
+ // There may be a number of message headers/ancillary data arrays coming in.
+ // Let's look for the one with a type SCM_RIGHTS which indicates it' the
+ // one we're interested in.
+ //
+ struct cmsghdr *cmsg;
+ for (cmsg = CMSG_FIRSTHDR (&msg); cmsg != NULL; cmsg = CMSG_NXTHDR (&msg, cmsg))
+ {
+ if (cmsg->cmsg_level == SOL_SOCKET
+ && cmsg->cmsg_type == SCM_RIGHTS)
+ {
+ //
+ // This is the type of message we want. Check to see if the magic
+ // number is correct and then pull out the socket we care about if
+ // it matches
+ //
+ if (magic == EMU_MAGIC)
+ {
+ NS_LOG_INFO ("Got SCM_RIGHTS with correct magic " << magic);
+ int *rawSocket = (int*)CMSG_DATA (cmsg);
+ NS_LOG_INFO ("Got the socket from the socket creator = " << *rawSocket);
+ return *rawSocket;
+ }
+ else
+ {
+ NS_LOG_INFO ("Got SCM_RIGHTS, but with bad magic " << magic);
+ }
+ }
+ }
+ NS_FATAL_ERROR ("Did not get the raw socket from the socket creator");
+ }
+}
+
+} // namespace ns3
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/emu-fd-net-device-helper.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,91 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA, 2012 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+#ifndef EMU_FD_NET_DEVICE_HELPER_H
+#define EMU_FD_NET_DEVICE_HELPER_H
+
+#include <string>
+
+#include "ns3/attribute.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/fd-net-device-helper.h"
+#include "ns3/object-factory.h"
+#include "ns3/net-device-container.h"
+#include "ns3/node-container.h"
+
+namespace ns3 {
+
+/**
+ * \brief build a set of FdNetDevice objects attached to a physical network
+ * interface
+ *
+ */
+class EmuFdNetDeviceHelper : public FdNetDeviceHelper
+{
+public:
+ /**
+ * Construct a EmuFdNetDeviceHelper.
+ */
+ EmuFdNetDeviceHelper ();
+ virtual ~EmuFdNetDeviceHelper ()
+ {
+ }
+
+ /**
+ * Get the device name of this device.
+ *
+ * \returns The device name of this device.
+ */
+ std::string GetDeviceName (void);
+
+ /**
+ * Set the device name of this device.
+ *
+ * \param deviceName The device name of this device.
+ */
+ void SetDeviceName (std::string deviceName);
+
+protected:
+ /*
+ * \internal
+ */
+ Ptr<NetDevice> InstallPriv (Ptr<Node> node) const;
+
+ /**
+ * Sets a file descriptor on the FileDescriptorNetDevice.
+ */
+ virtual void SetFileDescriptor (Ptr<FdNetDevice> device) const;
+
+ /**
+ * Call out to a separate process running as suid root in order to get a raw
+ * socket. We do this to avoid having the entire simulation running as root.
+ */
+ virtual int CreateFileDescriptor (void) const;
+
+ /**
+ * \internal
+ *
+ * The unix/linux name of the underlying device (e.g., eth0)
+ */
+ std::string m_deviceName;
+};
+
+} // namespace ns3
+
+#endif /* EMU_FD_NET_DEVICE_HELPER_H */
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/encode-decode.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,111 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2009 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include <string>
+#include <iostream>
+#include <iomanip>
+#include <sstream>
+#include <stdint.h>
+
+namespace ns3 {
+
+/**
+ * \brief Convert a byte buffer to a string containing a hex representation
+ * of the buffer. Make the string pretty by adding a colon (':') between
+ * the hex.
+ *
+ * \param buffer The input buffer to be converted.
+ * \param len The length of the input buffer.
+ * \returns A string containing a hex representation of the data in buffer.
+ */
+std::string
+BufferToString (uint8_t *buffer, uint32_t len)
+{
+ std::ostringstream oss;
+ //
+ // Tell the stream to make hex characters, zero-filled
+ //
+ oss.setf (std::ios::hex, std::ios::basefield);
+ oss.fill ('0');
+
+ //
+ // Loop through the buffer, separating the two-digit-wide hex bytes
+ // with a colon.
+ //
+ for (uint8_t i = 0; i < len; i++)
+ {
+ oss << ":" << std::setw (2) << (uint32_t)buffer[i];
+ }
+ return oss.str ();
+}
+
+/**
+ * \brief Convert string encoded by the inverse function (TapBufferToString)
+ * back into a byte buffer.
+ *
+ * \param s The input string.
+ * \param buffer The buffer to initialize with the converted bits.
+ * \param len The length of the data that is valid in the buffer.
+ * \returns True indicates a successful conversion.
+ */
+bool
+StringToBuffer (std::string s, uint8_t *buffer, uint32_t *len)
+{
+ //
+ // If the string was made by our inverse function, the string length must
+ // be a multiple of three characters in length. Use this fact to do a
+ // quick reasonableness test.
+ //
+ if ((s.length () % 3) != 0)
+ {
+ return false;
+ }
+
+ std::istringstream iss;
+ iss.str (s);
+
+ uint8_t n = 0;
+
+ while (iss.good ())
+ {
+ //
+ // The first character in the "triplet" we're working on is always the
+ // the ':' separator. Read that into a char and make sure we're skipping
+ // what we think we're skipping.
+ //
+ char c;
+ iss.read (&c, 1);
+ if (c != ':')
+ {
+ return false;
+ }
+
+ //
+ // And then read in the real bits and convert them.
+ //
+ uint32_t tmp;
+ iss >> std::hex >> tmp;
+ buffer[n] = tmp;
+ n++;
+ }
+
+ *len = n;
+ return true;
+}
+
+} // namespace ns3
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/encode-decode.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,33 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2008 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef ENCODE_DECODE_H
+#define ENCODE_DECODE_H
+
+#include <string>
+
+namespace ns3 {
+
+std::string BufferToString (uint8_t *buffer, uint32_t len);
+bool StringToBuffer (std::string s, uint8_t *buffer, uint32_t *len);
+
+
+} // namespace ns3
+
+#endif /* ENCODE_DECODE_H */
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/fd-net-device-helper.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,204 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ *
+ */
+
+#include "fd-net-device-helper.h"
+
+#include "ns3/abort.h"
+#include "ns3/config.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/log.h"
+#include "ns3/names.h"
+#include "ns3/object-factory.h"
+#include "ns3/packet.h"
+#include "ns3/simulator.h"
+#include "ns3/trace-helper.h"
+
+#include <string>
+
+NS_LOG_COMPONENT_DEFINE ("FdNetDeviceHelper");
+
+namespace ns3 {
+
+FdNetDeviceHelper::FdNetDeviceHelper ()
+{
+ m_deviceFactory.SetTypeId ("ns3::FdNetDevice");
+}
+
+void
+FdNetDeviceHelper::SetAttribute (std::string n1, const AttributeValue &v1)
+{
+ NS_LOG_FUNCTION (this);
+ m_deviceFactory.Set (n1, v1);
+}
+
+void
+FdNetDeviceHelper::EnablePcapInternal (std::string prefix, Ptr<NetDevice> nd, bool promiscuous, bool explicitFilename)
+{
+ //
+ // All of the Pcap enable functions vector through here including the ones
+ // that are wandering through all of devices on perhaps all of the nodes in
+ // the system. We can only deal with devices of type FdNetDevice.
+ //
+ Ptr<FdNetDevice> device = nd->GetObject<FdNetDevice> ();
+ if (device == 0)
+ {
+ NS_LOG_INFO ("FdNetDeviceHelper::EnablePcapInternal(): Device " << device << " not of type ns3::FdNetDevice");
+ return;
+ }
+
+ PcapHelper pcapHelper;
+
+ std::string filename;
+ if (explicitFilename)
+ {
+ filename = prefix;
+ }
+ else
+ {
+ filename = pcapHelper.GetFilenameFromDevice (prefix, device);
+ }
+
+ Ptr<PcapFileWrapper> file = pcapHelper.CreateFile (filename, std::ios::out, PcapHelper::DLT_EN10MB);
+ if (promiscuous)
+ {
+ pcapHelper.HookDefaultSink<FdNetDevice> (device, "PromiscSniffer", file);
+ }
+ else
+ {
+ pcapHelper.HookDefaultSink<FdNetDevice> (device, "Sniffer", file);
+ }
+}
+
+void
+FdNetDeviceHelper::EnableAsciiInternal (
+ Ptr<OutputStreamWrapper> stream,
+ std::string prefix,
+ Ptr<NetDevice> nd,
+ bool explicitFilename)
+{
+ //
+ // All of the ascii enable functions vector through here including the ones
+ // that are wandering through all of devices on perhaps all of the nodes in
+ // the system. We can only deal with devices of type FdNetDevice.
+ //
+ Ptr<FdNetDevice> device = nd->GetObject<FdNetDevice> ();
+ if (device == 0)
+ {
+ NS_LOG_INFO ("FdNetDeviceHelper::EnableAsciiInternal(): Device " << device << " not of type ns3::FdNetDevice");
+ return;
+ }
+
+ //
+ // Our default trace sinks are going to use packet printing, so we have to
+ // make sure that is turned on.
+ //
+ Packet::EnablePrinting ();
+
+ //
+ // If we are not provided an OutputStreamWrapper, we are expected to create
+ // one using the usual trace filename conventions and do a Hook*WithoutContext
+ // since there will be one file per context and therefore the context would
+ // be redundant.
+ //
+ if (stream == 0)
+ {
+ //
+ // Set up an output stream object to deal with private ofstream copy
+ // constructor and lifetime issues. Let the helper decide the actual
+ // name of the file given the prefix.
+ //
+ AsciiTraceHelper asciiTraceHelper;
+
+ std::string filename;
+ if (explicitFilename)
+ {
+ filename = prefix;
+ }
+ else
+ {
+ filename = asciiTraceHelper.GetFilenameFromDevice (prefix, device);
+ }
+
+ Ptr<OutputStreamWrapper> theStream = asciiTraceHelper.CreateFileStream (filename);
+
+ //
+ // The MacRx trace source provides our "r" event.
+ //
+ asciiTraceHelper.HookDefaultReceiveSinkWithoutContext<FdNetDevice> (device, "MacRx", theStream);
+
+ return;
+ }
+
+ //
+ // If we are provided an OutputStreamWrapper, we are expected to use it, and
+ // to providd a context. We are free to come up with our own context if we
+ // want, and use the AsciiTraceHelper Hook*WithContext functions, but for
+ // compatibility and simplicity, we just use Config::Connect and let it deal
+ // with the context.
+ //
+ // Note that we are going to use the default trace sinks provided by the
+ // ascii trace helper. There is actually no AsciiTraceHelper in sight here,
+ // but the default trace sinks are actually publicly available static
+ // functions that are always there waiting for just such a case.
+ //
+ uint32_t deviceid = nd->GetIfIndex ();
+ std::ostringstream oss;
+
+ oss << "/NodeList/" << nd->GetNode ()->GetId () << "/DeviceList/" << deviceid << "/$ns3::FdNetDevice/MacRx";
+ Config::Connect (oss.str (), MakeBoundCallback (&AsciiTraceHelper::DefaultReceiveSinkWithContext, stream));
+}
+
+NetDeviceContainer
+FdNetDeviceHelper::Install (Ptr<Node> node) const
+{
+ return NetDeviceContainer (InstallPriv (node));
+}
+
+NetDeviceContainer
+FdNetDeviceHelper::Install (std::string nodeName) const
+{
+ Ptr<Node> node = Names::Find<Node> (nodeName);
+ return NetDeviceContainer (InstallPriv (node));
+}
+
+NetDeviceContainer
+FdNetDeviceHelper::Install (const NodeContainer &c) const
+{
+ NetDeviceContainer devs;
+
+ for (NodeContainer::Iterator i = c.Begin (); i != c.End (); i++)
+ {
+ devs.Add (InstallPriv (*i));
+ }
+
+ return devs;
+}
+
+Ptr<NetDevice>
+FdNetDeviceHelper::InstallPriv (Ptr<Node> node) const
+{
+ Ptr<FdNetDevice> device = m_deviceFactory.Create<FdNetDevice> ();
+ device->SetAddress (Mac48Address::Allocate ());
+ node->AddDevice (device);
+ return device;
+}
+
+} // namespace ns3
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/fd-net-device-helper.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,134 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ *
+ */
+
+#ifndef FD_NET_DEVICE_HELPER_H
+#define FD_NET_DEVICE_HELPER_H
+
+#include <string>
+
+#include "ns3/attribute.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/object-factory.h"
+#include "ns3/net-device-container.h"
+#include "ns3/node-container.h"
+#include "ns3/trace-helper.h"
+
+namespace ns3 {
+
+/**
+ * \brief build a set of FdNetDevice objects
+ * Normally we eschew multiple inheritance, however, the classes
+ * PcapUserHelperForDevice and AsciiTraceUserHelperForDevice are
+ * treated as "mixins". A mixin is a self-contained class that
+ * encapsulates a general attribute or a set of functionality that
+ * may be of interest to many other classes.
+ */
+class FdNetDeviceHelper : public PcapHelperForDevice,
+ public AsciiTraceHelperForDevice
+{
+public:
+ /**
+ * Construct a FdNetDeviceHelper.
+ */
+ FdNetDeviceHelper ();
+ virtual ~FdNetDeviceHelper ()
+ {
+ }
+
+ /**
+ * \param n1 the name of the attribute to set
+ * \param v1 the value of the attribute to set
+ *
+ * Set these attributes on each ns3::FdNetDevice created
+ * by FdNetDeviceHelper::Install
+ */
+ void SetAttribute (std::string n1, const AttributeValue &v1);
+
+ /**
+ * This method creates a FdNetDevice and associates it to a node
+ *
+ * \param node The node to install the device in
+ * \returns A container holding the added net device.
+ */
+ virtual NetDeviceContainer Install (Ptr<Node> node) const;
+
+ /**
+ * This method creates a FdNetDevice and associates it to a node
+ *
+ * \param name The name of the node to install the device in
+ * \returns A container holding the added net device.
+ */
+ virtual NetDeviceContainer Install (std::string name) const;
+
+ /**
+ * This method creates a FdNetDevice and associates it to a node.
+ * For each Ptr<node> in the provided container: it creates an ns3::FdNetDevice
+ * (with the attributes configured by FdNetDeviceHelper::SetDeviceAttribute);
+ * adds the device to the node; and attaches the channel to the device.
+ *
+ * \param c The NodeContainer holding the nodes to be changed.
+ * \returns A container holding the added net devices.
+ */
+ virtual NetDeviceContainer Install (const NodeContainer &c) const;
+
+protected:
+ /*
+ * \internal
+ */
+ virtual Ptr<NetDevice> InstallPriv (Ptr<Node> node) const;
+
+private:
+ /**
+ * \brief Enable pcap output on the indicated net device.
+ * \internal
+ *
+ * NetDevice-specific implementation mechanism for hooking the trace and
+ * writing to the trace file.
+ *
+ * \param prefix Filename prefix to use for pcap files.
+ * \param nd Net device for which you want to enable tracing.
+ * \param promiscuous If true capture all possible packets available at the device.
+ * \param explicitFilename Treat the prefix as an explicit filename if true
+ */
+ virtual void EnablePcapInternal (std::string prefix, Ptr<NetDevice> nd, bool promiscuous, bool explicitFilename);
+
+ /**
+ * \brief Enable ascii trace output on the indicated net device.
+ * \internal
+ *
+ * NetDevice-specific implementation mechanism for hooking the trace and
+ * writing to the trace file.
+ *
+ * \param stream The output stream object to use when logging ascii traces.
+ * \param prefix Filename prefix to use for ascii trace files.
+ * \param nd Net device for which you want to enable tracing.
+ */
+ virtual void EnableAsciiInternal (Ptr<OutputStreamWrapper> stream,
+ std::string prefix,
+ Ptr<NetDevice> nd,
+ bool explicitFilename);
+
+ ObjectFactory m_deviceFactory;
+};
+
+} // namespace ns3
+
+#endif /* FD_NET_DEVICE_HELPER_H */
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/planetlab-fd-net-device-helper.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,335 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ * Claudio Freire <klaussfreire@sourceforge.net>
+ *
+ */
+
+#include "planetlab-fd-net-device-helper.h"
+#include "encode-decode.h"
+
+#include "ns3/abort.h"
+#include "ns3/config.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/log.h"
+#include "ns3/names.h"
+#include "ns3/object-factory.h"
+#include "ns3/packet.h"
+#include "ns3/simulator.h"
+#include "ns3/trace-helper.h"
+#include "ns3/internet-module.h"
+
+#include <arpa/inet.h>
+#include <errno.h>
+#include <iostream>
+#include <iomanip>
+#include <limits>
+#include <linux/if_tun.h>
+#include <memory>
+#include <net/ethernet.h>
+#include <net/if.h>
+#include <netinet/in.h>
+#include <netpacket/packet.h>
+
+#include <stdlib.h>
+#include <string.h>
+#include <sys/wait.h>
+#include <sys/stat.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <sys/ioctl.h>
+#include <time.h>
+#include <unistd.h>
+
+#include <string>
+
+NS_LOG_COMPONENT_DEFINE ("PlanetLabFdNetDeviceHelper");
+
+namespace ns3 {
+
+#define PLANETLAB_MAGIC 75867
+
+PlanetLabFdNetDeviceHelper::PlanetLabFdNetDeviceHelper ()
+{
+ m_tapIp = Ipv4Address ("255.255.255.255");
+ m_tapMask = Ipv4Mask ("255.255.255.255");
+}
+
+void
+PlanetLabFdNetDeviceHelper::SetTapIpAddress (Ipv4Address address)
+{
+ m_tapIp = address;
+}
+
+void
+PlanetLabFdNetDeviceHelper::SetTapMask (Ipv4Mask mask)
+{
+ m_tapMask = mask;
+}
+
+Ptr<NetDevice>
+PlanetLabFdNetDeviceHelper::InstallPriv (Ptr<Node> node) const
+{
+ Ptr<NetDevice> d = FdNetDeviceHelper::InstallPriv (node);
+ Ptr<FdNetDevice> device = d->GetObject<FdNetDevice> ();
+
+ //
+ // The PlanetLab mechanism to create a TAP device doesn't allow
+ // for the moment to set the IFF_NOPI flag. In consequence, a PI
+ // header will be present in the traffic.
+ // We need to explicitly set the encapsulation mode to DIXPI,
+ // so the FdNetDevice is able to treat correctly the traffic
+ // traversing TAP device.
+ //
+ Ptr<FdNetDevice> fdnd = device->GetObject<FdNetDevice> ();
+ fdnd->SetEncapsulationMode (FdNetDevice::DIXPI);
+
+ SetFileDescriptor (device);
+ return device;
+}
+
+void
+PlanetLabFdNetDeviceHelper::SetFileDescriptor (Ptr<FdNetDevice> device) const
+{
+ NS_LOG_LOGIC ("Creating TAP device");
+
+ //
+ // Call out to a separate process running as suid root in order to create a
+ // TAP device. We do this to avoid having the entire simulation running as root.
+ //
+ int fd = CreateFileDescriptor ();
+ device->SetFileDescriptor (fd);
+}
+
+int
+PlanetLabFdNetDeviceHelper::CreateFileDescriptor (void) const
+{
+ NS_LOG_FUNCTION (this);
+
+ //
+ // We're going to fork and exec that program soon, but first we need to have
+ // a socket to talk to it with. So we create a local interprocess (Unix)
+ // socket for that purpose.
+ //
+ int sock = socket (PF_UNIX, SOCK_DGRAM, 0);
+ NS_ABORT_MSG_IF (sock == -1, "PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): Unix socket creation error, errno = " << strerror (errno));
+
+ //
+ // Bind to that socket and let the kernel allocate an endpoint
+ //
+ struct sockaddr_un un;
+ memset (&un, 0, sizeof (un));
+ un.sun_family = AF_UNIX;
+ int status = bind (sock, (struct sockaddr*)&un, sizeof (sa_family_t));
+ NS_ABORT_MSG_IF (status == -1, "PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): Could not bind(): errno = " << strerror (errno));
+ NS_LOG_INFO ("Created Unix socket");
+ NS_LOG_INFO ("sun_family = " << un.sun_family);
+ NS_LOG_INFO ("sun_path = " << un.sun_path);
+
+ //
+ // We have a socket here, but we want to get it there -- to the program we're
+ // going to exec. What we'll do is to do a getsockname and then encode the
+ // resulting address information as a string, and then send the string to the
+ // program as an argument. So we need to get the sock name.
+ //
+ socklen_t len = sizeof (un);
+ status = getsockname (sock, (struct sockaddr*)&un, &len);
+ NS_ABORT_MSG_IF (status == -1, "PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): Could not getsockname(): errno = " << strerror (errno));
+
+ //
+ // Now encode that socket name (family and path) as a string of hex digits
+ //
+ std::string path = BufferToString ((uint8_t *)&un, len);
+ NS_LOG_INFO ("Encoded Unix socket as \"" << path << "\"");
+
+ //
+ // Fork and exec the process to create our socket. If we're us (the parent)
+ // we wait for the child (the creator) to complete and read the socket it
+ // created and passed back using the ancillary data mechanism.
+ //
+ pid_t pid = ::fork ();
+ if (pid == 0)
+ {
+ NS_LOG_DEBUG ("Child process");
+
+ //
+ // build a command line argument from the encoded endpoint string that
+ // the socket creation process will use to figure out how to respond to
+ // the (now) parent process. We're going to have to give this program
+ // quite a bit of information.
+ //
+ // -i<IP-address> The IP address to assign to the new tap device;
+ // -n<network-prefix> The network prefix to assign to the new tap device;
+ // -t Set teh IFF_TAP flag
+ // -p<path> the path to the unix socket described above.
+ //
+ // Example tap-creator -i1.2.3.1 -n24 -t -pblah
+ //
+
+ std::ostringstream ossIp;
+ ossIp << "-i" << m_tapIp;
+
+ std::ostringstream ossPrefix;
+ ossPrefix << "-n" << m_tapMask.GetPrefixLength ();
+
+ std::ostringstream ossMode;
+ ossMode << "-t";
+
+ std::ostringstream ossPath;
+ ossPath << "-p" << path;
+
+ //
+ // Execute the socket creation process image.
+ //
+ status = ::execlp (PLANETLAB_TAP_CREATOR,
+ PLANETLAB_TAP_CREATOR, // argv[0] (filename)
+ ossIp.str ().c_str (), // argv[1] (-i<IP address>)
+ ossPrefix.str ().c_str (), // argv[2] (-n<prefix>)
+ ossMode.str ().c_str (), // argv[3] (-t <tap>)
+ ossPath.str ().c_str (), // argv[4] (-p<path>)
+ (char *)NULL);
+
+ //
+ // If the execlp successfully completes, it never returns. If it returns it failed or the OS is
+ // broken. In either case, we bail.
+ //
+ NS_FATAL_ERROR ("PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): Back from execlp(), errno = " << ::strerror (errno));
+ }
+ else
+ {
+ NS_LOG_DEBUG ("Parent process");
+ //
+ // We're the process running the emu net device. We need to wait for the
+ // socket creator process to finish its job.
+ //
+ int st;
+ pid_t waited = waitpid (pid, &st, 0);
+ NS_ABORT_MSG_IF (waited == -1, "PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): waitpid() fails, errno = " << strerror (errno));
+ NS_ASSERT_MSG (pid == waited, "PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): pid mismatch");
+
+ //
+ // Check to see if the socket creator exited normally and then take a
+ // look at the exit code. If it bailed, so should we. If it didn't
+ // even exit normally, we bail too.
+ //
+ if (WIFEXITED (st))
+ {
+ int exitStatus = WEXITSTATUS (st);
+ NS_ABORT_MSG_IF (exitStatus != 0,
+ "PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): socket creator exited normally with status " << exitStatus);
+ }
+ else
+ {
+ NS_FATAL_ERROR ("PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): socket creator exited abnormally");
+ }
+
+ //
+ // At this point, the socket creator has run successfully and should
+ // have created our tap device, initialized it with the information we
+ // passed and sent it back to the socket address we provided. A socket
+ // (fd) we can use to talk to this tap device should be waiting on the
+ // Unix socket we set up to receive information back from the creator
+ // program. We've got to do a bunch of grunt work to get at it, though.
+ //
+ // The struct iovec below is part of a scatter-gather list. It describes a
+ // buffer. In this case, it describes a buffer (an integer) that will
+ // get the data that comes back from the socket creator process. It will
+ // be a magic number that we use as a consistency/sanity check.
+ //
+ struct iovec iov;
+ uint32_t magic;
+ iov.iov_base = &magic;
+ iov.iov_len = sizeof(magic);
+
+ //
+ // The CMSG macros you'll see below are used to create and access control
+ // messages (which is another name for ancillary data). The ancillary
+ // data is made up of pairs of struct cmsghdr structures and associated
+ // data arrays.
+ //
+ // First, we're going to allocate a buffer on the stack to receive our
+ // data array (that contains the socket). Sometimes you'll see this called
+ // an "ancillary element" but the msghdr uses the control message termimology
+ // so we call it "control."
+ //
+ size_t msg_size = sizeof(int);
+ char control[CMSG_SPACE (msg_size)];
+
+ //
+ // There is a msghdr that is used to minimize the number of parameters
+ // passed to recvmsg (which we will use to receive our ancillary data).
+ // This structure uses terminology corresponding to control messages, so
+ // you'll see msg_control, which is the pointer to the ancillary data and
+ // controllen which is the size of the ancillary data array.
+ //
+ // So, initialize the message header that describes the ancillary/control
+ // data we expect to receive and point it to buffer.
+ //
+ struct msghdr msg;
+ msg.msg_name = 0;
+ msg.msg_namelen = 0;
+ msg.msg_iov = &iov;
+ msg.msg_iovlen = 1;
+ msg.msg_control = control;
+ msg.msg_controllen = sizeof (control);
+ msg.msg_flags = 0;
+
+ //
+ // Now we can actually receive the interesting bits from the tap
+ // creator process. Lots of pain to get four bytes.
+ //
+ ssize_t bytesRead = recvmsg (sock, &msg, 0);
+ NS_ABORT_MSG_IF (bytesRead != sizeof(int), "PlanetLabFdNetDeviceHelper::CreateFileDescriptor(): Wrong byte count from socket creator");
+
+ //
+ // There may be a number of message headers/ancillary data arrays coming in.
+ // Let's look for the one with a type SCM_RIGHTS which indicates it's the
+ // one we're interested in.
+ //
+ struct cmsghdr *cmsg;
+ for (cmsg = CMSG_FIRSTHDR (&msg); cmsg != NULL; cmsg = CMSG_NXTHDR (&msg, cmsg))
+ {
+ if (cmsg->cmsg_level == SOL_SOCKET
+ && cmsg->cmsg_type == SCM_RIGHTS)
+ {
+ //
+ // This is the type of message we want. Check to see if the magic
+ // number is correct and then pull out the socket we care about if
+ // it matches
+ //
+ if (magic == PLANETLAB_MAGIC)
+ {
+ NS_LOG_INFO ("Got SCM_RIGHTS with correct magic " << magic);
+ int *rawSocket = (int*)CMSG_DATA (cmsg);
+ NS_LOG_INFO ("Got the socket from the socket creator = " << *rawSocket);
+ return *rawSocket;
+ }
+ else
+ {
+ NS_LOG_INFO ("Got SCM_RIGHTS, but with bad magic " << magic);
+ }
+ }
+ }
+ NS_FATAL_ERROR ("Did not get the raw socket from the socket creator");
+ }
+
+}
+
+} // namespace ns3
+
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/planetlab-fd-net-device-helper.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,103 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ * Claudio Freire <klaussfreire@sourceforge.net>
+ */
+
+#ifndef PLANETLAB_FD_NET_DEVICE_HELPER_H
+#define PLANETLAB_FD_NET_DEVICE_HELPER_H
+
+#include <string>
+
+#include "ns3/attribute.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/object-factory.h"
+#include "ns3/mac48-address.h"
+#include "ns3/net-device-container.h"
+#include "ns3/node-container.h"
+
+#include "emu-fd-net-device-helper.h"
+
+namespace ns3 {
+
+/**
+ * \brief build a set of FdNetDevice objects attached to a virtual TAP network
+ * interface
+ *
+ */
+class PlanetLabFdNetDeviceHelper : public EmuFdNetDeviceHelper
+{
+public:
+ /**
+ * Construct a PlanetLabFdNetDeviceHelper.
+ */
+ PlanetLabFdNetDeviceHelper ();
+ virtual ~PlanetLabFdNetDeviceHelper ()
+ {
+ }
+
+ /**
+ * Set the device IPv4 address.
+ *
+ * \param address The IPv4 address for the TAP device.
+ */
+ void SetTapIpAddress (Ipv4Address address);
+
+ /**
+ * Set the network mask for the TAP device.
+ *
+ * \param mask The network mask for the TAP device.
+ */
+ void SetTapMask (Ipv4Mask mask);
+
+protected:
+ /*
+ * \internal
+ */
+ Ptr<NetDevice> InstallPriv (Ptr<Node> node) const;
+
+ /**
+ * Sets a file descriptor on the FileDescriptorNetDevice.
+ */
+ virtual void SetFileDescriptor (Ptr<FdNetDevice> device) const;
+
+ /**
+ * Call out to a separate process running as suid root in order to create a
+ * TAP device and obtain the file descriptor associated to it.
+ */
+ virtual int CreateFileDescriptor (void) const;
+
+ /**
+ * \internal
+ *
+ * The IP address for the TAP device.
+ */
+ Ipv4Address m_tapIp;
+
+ /**
+ * \internal
+ *
+ * The network mask for the TAP device.
+ */
+ Ipv4Mask m_tapMask;
+
+};
+
+} // namespace ns3
+
+#endif /* PLANETLAB_FD_NET_DEVICE_HELPER_H */
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/planetlab-tap-creator.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,235 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ * Claudio Freire <klaussfreire@sourceforge.net>
+ *
+ */
+
+#include <unistd.h>
+#include <stdint.h>
+#include <stdlib.h>
+#include <stdio.h>
+#include <string>
+#include <string.h> // for strerror
+#include <iostream>
+#include <iomanip>
+#include <sstream>
+#include <errno.h>
+#include <fcntl.h>
+#include <sys/ioctl.h>
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <net/if.h>
+#include <linux/if_tun.h>
+#include <net/route.h>
+#include <netinet/in.h>
+
+#include "creator-utils.h"
+
+#define PLANETLAB_MAGIC 75867
+
+#define VSYS_TUNTAP "/vsys/fd_tuntap.control"
+#define VSYS_VIFUP_IN "/vsys/vif_up.in"
+#define VSYS_VIFUP_OUT "/vsys/vif_up.out"
+
+using namespace ns3;
+
+/**
+ *
+ * Reads vif FD from "fd", writes interface name to vif_name, and returns vif FD.
+ * vif_name should be IFNAMSIZ chars long.
+ *
+ */
+int
+ReceiveVifFd (int fd, char *vif_name)
+{
+ struct msghdr msg;
+ struct iovec iov;
+ int rv;
+ size_t ccmsg[CMSG_SPACE (sizeof(int)) / sizeof(size_t)];
+ struct cmsghdr *cmsg;
+
+ /* Use IOV to read interface name */
+ iov.iov_base = vif_name;
+ iov.iov_len = IFNAMSIZ;
+
+ msg.msg_name = 0;
+ msg.msg_namelen = 0;
+ msg.msg_iov = &iov;
+ msg.msg_iovlen = 1;
+ /* old BSD implementations should use msg_accrights instead of
+ * msg_control; the interface is different. */
+ msg.msg_control = ccmsg;
+ msg.msg_controllen = sizeof(ccmsg);
+
+ while (((rv = recvmsg (fd, &msg, 0)) == -1) && errno == EINTR)
+ {
+ }
+ ABORT_IF (rv == -1, "Could not receive fd from Vsys", 0);
+ ABORT_IF (!rv, "Could not receive fd from Vsys (EOF)", 0);
+
+ cmsg = CMSG_FIRSTHDR (&msg);
+ ABORT_IF (!cmsg->cmsg_type == SCM_RIGHTS, "got control message of unknown type" << cmsg->cmsg_type, 0);
+
+ int* retfd = (int*)CMSG_DATA (cmsg);
+ return *retfd;
+}
+
+/**
+ *
+ * Creates a TUN/TAP device on a PlanetLab virtual machine (sliver).
+ * PlanetLab provides the Vsys API to enable privileged operating system calls
+ * in an environment with restricted privileges.
+ * To create a TUN/TAP device the it is necessary to connect to the
+ * /vsys/fd_tuntap.control socket, and send the device initialization parameters.
+ *
+ */
+int
+TunAlloc (int iftype, char *if_name)
+{
+ int control_fd;
+ struct sockaddr_un addr;
+ int remotefd;
+ int ret;
+
+ control_fd = socket (AF_UNIX, SOCK_STREAM, 0);
+ ABORT_IF (control_fd == -1, "Could not create UNIX socket", 0);
+
+ memset (&addr, 0, sizeof(struct sockaddr_un));
+
+ /* Clear structure */
+ addr.sun_family = AF_UNIX;
+ strncpy (addr.sun_path, VSYS_TUNTAP, sizeof(addr.sun_path) - 1);
+
+ ret = connect (control_fd, (struct sockaddr *) &addr,
+ sizeof(struct sockaddr_un));
+ ABORT_IF (ret == -1, "Could not connect to Vsys control socket", 0);
+
+ /* passing type param */
+ ret = send (control_fd, &iftype, sizeof(iftype), 0);
+ ABORT_IF (ret != sizeof(iftype), "Could not send paramater to Vsys control socket", 0);
+
+ return ReceiveVifFd (control_fd, if_name);
+
+}
+
+/**
+ *
+ * Sets the TAP/TUN interface up.
+ * When a TAP/TUN device is created on PlanetLab it must be set up
+ * writing some configuration information to the vsys fifo at /vsys/vif_up.in
+ *
+ */
+void
+SetTunUp (const char *ip, const char *prefix, const char *if_name)
+{
+ FILE *in;
+ FILE *out;
+ int nbytes;
+
+ in = fopen (VSYS_VIFUP_IN, "a");
+
+ if (in == NULL)
+ {
+ ABORT_IF (in == NULL, "Failed to open " << VSYS_VIFUP_IN, 0);
+ }
+
+ out = fopen (VSYS_VIFUP_DOWN, "r");
+
+ if (out == NULL)
+ {
+ ABORT_IF (out == NULL, "Failed to open " << VSYS_VIFUP_OUT, 0);
+ }
+
+ // send input to process
+ fprintf (in, "%s\n%s\n%s\nsnat=1\n", if_name, ip, prefix);
+
+ // close pipe to indicate end parameter passing and flush the fifo
+ fclose (in);
+
+ nbytes = fread(if_name, 4096, 1, out);
+
+ // the error buffer will not be empty if we read an error
+ ABORT_IF (strcmp(if_name, "") != 0, if_name, 0);
+
+ fclose (out);
+
+ return 0;
+}
+
+int
+main (int argc, char *argv[])
+{
+ int c;
+ char *ip = NULL;
+ char *prefix = NULL;
+ char *path = NULL;
+ int iftype = IFF_TUN;
+ char if_name[4096];
+
+ memset(if_name, 0, 4096);
+ opterr = 0;
+
+ while ((c = getopt (argc, argv, "vi:n:tp:")) != -1)
+ {
+ switch (c)
+ {
+ case 'i':
+ ip = optarg; // ip address of the new device
+ break;
+ case 'n':
+ prefix = optarg; // prefix for the new device
+ break;
+ case 't':
+ iftype = IFF_TAP; // mode for the device (TAP or TUN)
+ break;
+ case 'p':
+ path = optarg; // path back to the tap bridge
+ break;
+ case 'v':
+ gVerbose = true;
+ break;
+ }
+ }
+
+ ABORT_IF (ip == NULL, "IP Address is a required argument", 0);
+ LOG ("Provided IP Address is \"" << ip << "\"");
+
+ ABORT_IF (prefix == NULL, "Prefix is a required argument", 0);
+ LOG ("Provided prefix \"" << prefix << "\"");
+
+ ABORT_IF (path == NULL, "path is a required argument", 0);
+ LOG ("Provided path is \"" << path << "\"");
+
+ LOG ("Creating Tap");
+ // allocate a TAP device in planetLab
+ int fd = TunAlloc (iftype, if_name);
+ ABORT_IF (fd == -1, "main(): Unable to create tap device", 1);
+
+ // set the TAP interface up
+ SetTunUp (ip, prefix, (const char*)if_name);
+
+ //
+ // Send the socket back to the tap net device so it can go about its business
+ //
+ SendSocket (path, fd, PLANETLAB_MAGIC);
+
+ return 0;
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/raw-sock-creator.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,95 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include <unistd.h>
+#include <string>
+#include <iostream>
+#include <iomanip>
+#include <sstream>
+#include <stdlib.h>
+#include <errno.h>
+
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <sys/ioctl.h>
+#include <net/ethernet.h>
+#include <net/if.h>
+#include <netinet/in.h>
+#include <netpacket/packet.h>
+#include <arpa/inet.h>
+
+#include "creator-utils.h"
+
+#define EMU_MAGIC 65867
+
+using namespace ns3;
+
+int
+main (int argc, char *argv[])
+{
+ int c;
+ char *path = NULL;
+
+ opterr = 0;
+
+ while ((c = getopt (argc, argv, "vp:")) != -1)
+ {
+ switch (c)
+ {
+ case 'v':
+ gVerbose = true;
+ break;
+ case 'p':
+ path = optarg;
+ break;
+ }
+ }
+
+ //
+ // This program is spawned by an emu net device running in a simulation. It
+ // wants to create a raw socket as described below. We are going to do the
+ // work here since we're running suid root. Once we create the raw socket,
+ // we have to send it back to the emu net device. We do that over a Unix
+ // (local interprocess) socket. The emu net device created a socket to
+ // listen for our response on, and it is expected to have encoded the address
+ // information as a string and to have passed that string as an argument to
+ // us. We see it here as the "path" string. We can't do anything useful
+ // unless we have that string.
+ //
+ ABORT_IF (path == NULL, "path is a required argument", 0);
+ LOG ("Provided path is \"" << path << "\"");
+ //
+ // The whole reason for all of the hoops we went through to call out to this
+ // program will pay off here. We created this program to run as suid root
+ // in order to keep the main simulation program from having to be run with
+ // root privileges. We need root privileges to be able to open a raw socket
+ // though. So all of these hoops are to allow us to execute the following
+ // single line of code:
+ //
+ LOG ("Creating raw socket");
+ int sock = socket (PF_PACKET, SOCK_RAW, htons (ETH_P_ALL));
+ ABORT_IF (sock == -1, "CreateSocket(): Unable to open raw socket", 1);
+
+ //
+ // Send the socket back to the emu net device so it can go about its business
+ //
+ SendSocket (path, sock, EMU_MAGIC);
+
+ return 0;
+}
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/tap-device-creator.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,426 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2009 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include <arpa/inet.h>
+#include <unistd.h>
+#include <stdint.h>
+#include <iostream>
+#include <iomanip>
+#include <sstream>
+#include <stdlib.h>
+#include <errno.h>
+#include <fcntl.h>
+#include <sys/ioctl.h>
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <net/if.h>
+#include <linux/if_tun.h>
+#include <net/route.h>
+#include <netinet/in.h>
+
+#include "creator-utils.h"
+
+#define TAP_MAGIC 95549
+
+//
+// Lots of the following helper code taken from corresponding functions in src/node.
+//
+#define ASCII_DOT (0x2e)
+#define ASCII_ZERO (0x30)
+#define ASCII_a (0x41)
+#define ASCII_z (0x5a)
+#define ASCII_A (0x61)
+#define ASCII_Z (0x7a)
+#define ASCII_COLON (0x3a)
+#define ASCII_ZERO (0x30)
+
+using namespace ns3;
+
+struct in6_ifreq {
+ struct in6_addr ifr6_addr;
+ uint32_t ifr6_prefixlen;
+ int32_t ifr6_ifindex;
+};
+
+char
+AsciiToLowCase (char c)
+{
+ if (c >= ASCII_a && c <= ASCII_z)
+ {
+ return c;
+ }
+ else if (c >= ASCII_A && c <= ASCII_Z)
+ {
+ return c + (ASCII_a - ASCII_A);
+ }
+ else
+ {
+ return c;
+ }
+}
+
+void
+AsciiToMac48 (const char *str, uint8_t addr[6])
+{
+ int i = 0;
+ while (*str != 0 && i < 6)
+ {
+ uint8_t byte = 0;
+ while (*str != ASCII_COLON && *str != 0)
+ {
+ byte <<= 4;
+ char low = AsciiToLowCase (*str);
+ if (low >= ASCII_a)
+ {
+ byte |= low - ASCII_a + 10;
+ }
+ else
+ {
+ byte |= low - ASCII_ZERO;
+ }
+ str++;
+ }
+ addr[i] = byte;
+ i++;
+ if (*str == 0)
+ {
+ break;
+ }
+ str++;
+ }
+}
+
+void
+SetIpv4 (const char *deviceName, const char *ip, const char *netmask)
+{
+ struct ifreq ifr;
+ struct sockaddr_in *sin;
+
+ int sock = socket(AF_INET, SOCK_DGRAM, 0);
+
+ //
+ // Set the IP address of the new interface/device.
+ //
+ memset(&ifr, 0, sizeof(struct ifreq));
+ strncpy(ifr.ifr_name, deviceName, IFNAMSIZ);
+
+ sin = (struct sockaddr_in*) &ifr.ifr_addr;
+ inet_pton(AF_INET, ip, &sin->sin_addr);
+ ifr.ifr_addr.sa_family = AF_INET;
+
+ ABORT_IF (ioctl (sock, SIOCSIFADDR, &ifr) == -1,
+ "Could not set IP address", true);
+
+ LOG ("Set device IP address to " << ip);
+
+ //
+ // Set the net mask of the new interface/device
+ //
+ memset(&ifr, 0, sizeof(struct ifreq));
+ strncpy(ifr.ifr_name, deviceName, IFNAMSIZ);
+
+ sin = (struct sockaddr_in*) &ifr.ifr_netmask;
+ inet_pton(AF_INET, netmask, &sin->sin_addr);
+ ifr.ifr_addr.sa_family = AF_INET;
+
+ ABORT_IF (ioctl (sock, SIOCSIFNETMASK, &ifr) == -1,
+ "Could not set net mask", true);
+
+ LOG ("Set device Net Mask to " << netmask);
+ close(sock);
+}
+
+void
+SetIpv6 (const char* deviceName, const char *ip, int netprefix)
+{
+ struct ifreq ifr;
+ struct sockaddr_in6 sin;
+ struct in6_ifreq ifr6;
+
+ int sock = socket(AF_INET6, SOCK_DGRAM, 0);
+ memset(&ifr, 0, sizeof(struct ifreq));
+ strncpy(ifr.ifr_name, deviceName, IFNAMSIZ);
+
+ ABORT_IF (ioctl (sock, SIOGIFINDEX, &ifr) == -1,
+ "Could not get interface index", true);
+
+ LOG ("Set device IP v6 address to " << ip);
+
+ memset(&sin, 0, sizeof(struct sockaddr_in6));
+ sin.sin6_family = AF_INET6;
+ inet_pton(AF_INET6, ip, (void *) &sin.sin6_addr);
+
+ memset(&ifr6, 0, sizeof(in6_ifreq));
+ memcpy((char *) &ifr6.ifr6_addr, (char *) &sin.sin6_addr, sizeof(struct in6_addr));
+
+ ifr6.ifr6_ifindex = ifr.ifr_ifindex;
+ ifr6.ifr6_prefixlen = netprefix;
+
+ //
+ // Set the IP address of the new interface/device.
+ //
+ ABORT_IF (ioctl (sock, SIOCSIFADDR, &ifr6) == -1,
+ "Could not set IP v6 address", true);
+
+ LOG ("Set device IP v6 address to " << ip);
+ close (sock);
+
+}
+
+void
+SetMacAddress (int fd, const char* mac)
+{
+ struct ifreq ifr;
+ memset(&ifr, 0, sizeof(struct ifreq));
+
+ ifr.ifr_hwaddr.sa_family = 1; // this is ARPHRD_ETHER from if_arp.h
+ AsciiToMac48 (mac, (uint8_t*)ifr.ifr_hwaddr.sa_data);
+ ABORT_IF (ioctl (fd, SIOCSIFHWADDR, &ifr) == -1, "Could not set MAC address", true);
+ LOG ("Set device MAC address to " << mac);
+}
+
+void
+SetUp (char *deviceName)
+{
+ struct ifreq ifr;
+
+ int sock = socket(AF_INET, SOCK_DGRAM, 0);
+
+ memset(&ifr, 0, sizeof(struct ifreq));
+ strncpy(ifr.ifr_name, deviceName, IFNAMSIZ);
+
+ ABORT_IF (ioctl (sock, SIOCGIFFLAGS, &ifr) == -1,
+ "Could not get flags for interface", true);
+ ifr.ifr_flags |= IFF_UP | IFF_RUNNING;
+
+ ABORT_IF (ioctl (sock, SIOCSIFFLAGS, &ifr) == -1,
+ "Could not bring interface up", true);
+
+ LOG ("Device is up");
+ close (sock);
+}
+
+int
+CreateTap (char *deviceName, const char *mac, const int ifftap, const int iffpi,
+ const char *ip4, const char *netmask, const char *ip6, const int netprefix)
+{
+
+ //
+ // Creation and management of Tap devices is done via the tun device
+ //
+ int fd = open ("/dev/net/tun", O_RDWR);
+ ABORT_IF (fd == -1, "Could not open /dev/net/tun", true);
+
+ //
+ // Set flags for device type and PI header.
+ //
+ struct ifreq ifr;
+
+ memset(&ifr, 0, sizeof(struct ifreq));
+
+ ifr.ifr_flags = (ifftap ? IFF_TAP : IFF_TUN);
+ if (!iffpi)
+ {
+ ifr.ifr_flags |= IFF_NO_PI;
+ }
+
+ //
+ // If device name is not specified, the kernel chooses one.
+ //
+ if (*deviceName)
+ {
+ strncpy(ifr.ifr_name, deviceName, IFNAMSIZ);
+ }
+
+
+ ABORT_IF (ioctl (fd, TUNSETIFF, (void *) &ifr) == -1,
+ "Could not allocate tap device", true);
+
+ LOG ("Allocated TAP device " << deviceName);
+
+ //
+ // Set the hardware (MAC) address of the new device
+ //
+ if (ifftap)
+ {
+ SetMacAddress(fd, mac);
+ }
+
+ //
+ // Set the IP address and netmask of the new interface/device.
+ //
+ if (ip4)
+ {
+ SetIpv4(deviceName, ip4, netmask);
+ }
+
+ if (ip6)
+ {
+ SetIpv6(deviceName, ip6, netprefix);
+ }
+
+ //
+ // Bring the interface up.
+ //
+ SetUp(deviceName);
+
+ return fd;
+}
+
+
+int
+main (int argc, char *argv[])
+{
+ int c;
+ char *dev = NULL;
+ char *ip4 = NULL;
+ char *ip6 = NULL;
+ char *mac = NULL;
+ char *netmask = NULL;
+ char *path = NULL;
+ int tap = false;
+ int pi = false;
+ int prefix = -1;
+
+ while ((c = getopt (argc, argv, "vd:i:m:n:I:P:thp:")) != -1)
+ {
+ switch (c)
+ {
+ case 'd':
+ dev = optarg; // name of the new tap device
+ break;
+ case 'i':
+ ip4 = optarg; // ip v4 address of the new device
+ break;
+ case 'I':
+ ip6 = optarg; // ip v6 address of the new device
+ break;
+ case 'm':
+ mac = optarg; // mac address of the new device
+ break;
+ case 'n':
+ netmask = optarg; // ip v4 net mask for the new device
+ break;
+ case 'P':
+ prefix = atoi(optarg); // ip v6 prefix for the new device
+ break;
+ case 't':
+ tap = true; // mode for the device (TAP or TUN)
+ break;
+ case 'h':
+ pi = true; // set the IFF_NO_PI flag
+ break;
+ case 'p':
+ path = optarg; // path back to the tap bridge
+ break;
+ case 'v':
+ gVerbose = true;
+ break;
+ }
+ }
+
+ //
+ // We have got to be able to coordinate the name of the tap device we are
+ // going to create and or open with the device that an external Linux host
+ // will use. If this name is provided we use it. If not we let the system
+ // create the device for us. This name is given in dev
+ //
+ LOG ("Provided Device Name is \"" << dev << "\"");
+
+ //
+ // We have got to be able to assign an IP address to the tap device we are
+ // allocating. This address is allocated in the simulation and assigned to
+ // the tap bridge. This address is given in ip.
+ //
+ ABORT_IF (ip4 == NULL && ip6 == NULL, "IP Address is a required argument", 0);
+ if (ip4)
+ {
+ ABORT_IF (netmask == NULL, "Net mask is a required argument", 0);
+ LOG ("Provided IP v4 Address is \"" << ip4 << "\"");
+ LOG ("Provided IP v4 Net Mask is \"" << netmask << "\"");
+ }
+ if (ip6)
+ {
+ ABORT_IF (prefix == -1, "Prefix is a required argument", 0);
+ LOG ("Provided IP v6 Address is \"" << ip6 << "\"");
+ LOG ("Provided IP v6 Prefix is \"" << prefix << "\"");
+ }
+
+ //
+ // We have got to be able to assign a Mac address to the tap device we are
+ // allocating. This address is allocated in the simulation and assigned to
+ // the bridged device. This allows packets addressed to the bridged device
+ // to appear in the Linux host as if they were received there.
+ //
+ ABORT_IF (mac == NULL, "MAC Address is a required argument", 0);
+ LOG ("Provided MAC Address is \"" << mac << "\"");
+
+ //
+ // We have got to know whether or not to create the TAP.
+ //
+ if (tap)
+ {
+ LOG ("Provided device Mode is TAP");
+ }
+ else
+ {
+ LOG ("Provided device Mode is TUN");
+ }
+
+ //
+ // IFF_NO_PI flag.
+ //
+ if (pi)
+ {
+ LOG ("IFF_NO_PI flag set. Packet Information will be present in the traffic");
+ }
+
+ //
+ // This program is spawned by a tap bridge running in a simulation. It
+ // wants to create a socket as described below. We are going to do the
+ // work here since we're running suid root. Once we create the socket,
+ // we have to send it back to the tap bridge. We do that over a Unix
+ // (local interprocess) socket. The tap bridge created a socket to
+ // listen for our response on, and it is expected to have encoded the address
+ // information as a string and to have passed that string as an argument to
+ // us. We see it here as the "path" string. We can't do anything useful
+ // unless we have that string.
+ //
+ ABORT_IF (path == NULL, "path is a required argument", 0);
+ LOG ("Provided path is \"" << path << "\"");
+
+ //
+ // The whole reason for all of the hoops we went through to call out to this
+ // program will pay off here. We created this program to run as suid root
+ // in order to keep the main simulation program from having to be run with
+ // root privileges. We need root privileges to be able to futz with the
+ // Tap device underlying all of this. So all of these hoops are to allow
+ // us to execute the following code:
+ //
+ LOG ("Creating Tap");
+ int sock = CreateTap (dev, mac, tap, pi, ip4, netmask, ip6, prefix);
+ ABORT_IF (sock == -1, "main(): Unable to create tap socket", 1);
+
+ //
+ // Send the socket back to the tap net device so it can go about its business
+ //
+ SendSocket (path, sock, TAP_MAGIC);
+
+ return 0;
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/tap-fd-net-device-helper.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,407 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA, 2012 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include "tap-fd-net-device-helper.h"
+#include "encode-decode.h"
+
+#include "ns3/abort.h"
+#include "ns3/config.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/log.h"
+#include "ns3/names.h"
+#include "ns3/object-factory.h"
+#include "ns3/packet.h"
+#include "ns3/simulator.h"
+#include "ns3/trace-helper.h"
+#include "ns3/internet-module.h"
+
+#include <arpa/inet.h>
+#include <errno.h>
+#include <iostream>
+#include <iomanip>
+#include <limits>
+#include <linux/if_tun.h>
+#include <memory>
+#include <net/ethernet.h>
+#include <net/if.h>
+#include <netinet/in.h>
+#include <netpacket/packet.h>
+
+#include <stdlib.h>
+#include <string.h>
+#include <sys/wait.h>
+#include <sys/stat.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <sys/ioctl.h>
+#include <time.h>
+#include <unistd.h>
+
+#include <string>
+
+NS_LOG_COMPONENT_DEFINE ("TapFdNetDeviceHelper");
+
+namespace ns3 {
+
+#define TAP_MAGIC 95549
+
+TapFdNetDeviceHelper::TapFdNetDeviceHelper ()
+{
+ m_deviceName = "";
+ m_modePi = false;
+ m_tapIp4 = "";
+ m_tapMask4 = "";
+ m_tapIp6 = "";
+ m_tapPrefix6 = 64;
+ m_tapMac = Mac48Address::Allocate ();
+}
+
+void
+TapFdNetDeviceHelper::SetModePi (bool modePi)
+{
+ m_modePi = modePi;
+}
+
+void
+TapFdNetDeviceHelper::SetTapIpv4Address (Ipv4Address address)
+{
+ m_tapIp4 = address;
+}
+
+void
+TapFdNetDeviceHelper::SetTapIpv4Mask (Ipv4Mask mask)
+{
+ m_tapMask4 = mask;
+}
+
+void
+TapFdNetDeviceHelper::SetTapIpv6Address (Ipv6Address address)
+{
+ m_tapIp6 = address;
+}
+
+void
+TapFdNetDeviceHelper::SetTapIpv6Prefix (int prefix)
+{
+ m_tapPrefix6 = prefix;
+}
+
+void
+TapFdNetDeviceHelper::SetTapMacAddress (Mac48Address mac)
+{
+ m_tapMac = mac;
+}
+
+Ptr<NetDevice>
+TapFdNetDeviceHelper::InstallPriv (Ptr<Node> node) const
+{
+ Ptr<NetDevice> d = FdNetDeviceHelper::InstallPriv (node);
+ Ptr<FdNetDevice> device = d->GetObject<FdNetDevice> ();
+ Ptr<FdNetDevice> fdnd = device->GetObject<FdNetDevice> ();
+
+ //
+ // We need to explicitly set the encapsulation mode for the traffic
+ // traversing the TAP device, so the FdNetDevice is able to know
+ // how to treat the traffic in a way that in compatible with the
+ // TAP device.
+ //
+ if (m_modePi)
+ {
+ fdnd->SetEncapsulationMode (FdNetDevice::DIXPI);
+ }
+
+ SetFileDescriptor (device);
+ return device;
+}
+
+void
+TapFdNetDeviceHelper::SetFileDescriptor (Ptr<FdNetDevice> device) const
+{
+ NS_LOG_LOGIC ("Creating TAP device");
+
+ //
+ // Call out to a separate process running as suid root in order to create a
+ // TAP device. We do this to avoid having the entire simulation running as root.
+ //
+ int fd = CreateFileDescriptor ();
+ device->SetFileDescriptor (fd);
+}
+
+int
+TapFdNetDeviceHelper::CreateFileDescriptor (void) const
+{
+ NS_LOG_FUNCTION (this);
+
+ //
+ // We're going to fork and exec that program soon, but first we need to have
+ // a socket to talk to it with. So we create a local interprocess (Unix)
+ // socket for that purpose.
+ //
+ int sock = socket (PF_UNIX, SOCK_DGRAM, 0);
+ NS_ABORT_MSG_IF (sock == -1, "TapFdNetDeviceHelper::CreateFileDescriptor(): Unix socket creation error, errno = " << strerror (errno));
+
+ //
+ // Bind to that socket and let the kernel allocate an endpoint
+ //
+ struct sockaddr_un un;
+ memset (&un, 0, sizeof (un));
+ un.sun_family = AF_UNIX;
+ int status = bind (sock, (struct sockaddr*)&un, sizeof (sa_family_t));
+ NS_ABORT_MSG_IF (status == -1, "TapFdNetDeviceHelper::CreateFileDescriptor(): Could not bind(): errno = " << strerror (errno));
+ NS_LOG_INFO ("Created Unix socket");
+ NS_LOG_INFO ("sun_family = " << un.sun_family);
+ NS_LOG_INFO ("sun_path = " << un.sun_path);
+
+ //
+ // We have a socket here, but we want to get it there -- to the program we're
+ // going to exec. What we'll do is to do a getsockname and then encode the
+ // resulting address information as a string, and then send the string to the
+ // program as an argument. So we need to get the sock name.
+ //
+ socklen_t len = sizeof (un);
+ status = getsockname (sock, (struct sockaddr*)&un, &len);
+ NS_ABORT_MSG_IF (status == -1, "TapFdNetDeviceHelper::CreateFileDescriptor(): Could not getsockname(): errno = " << strerror (errno));
+
+ //
+ // Now encode that socket name (family and path) as a string of hex digits
+ //
+ std::string path = BufferToString ((uint8_t *)&un, len);
+ NS_LOG_INFO ("Encoded Unix socket as \"" << path << "\"");
+
+ //
+ // Fork and exec the process to create our socket. If we're us (the parent)
+ // we wait for the child (the creator) to complete and read the socket it
+ // created and passed back using the ancillary data mechanism.
+ //
+ pid_t pid = ::fork ();
+ if (pid == 0)
+ {
+ NS_LOG_DEBUG ("Child process");
+
+ //
+ // build a command line argument from the encoded endpoint string that
+ // the socket creation process will use to figure out how to respond to
+ // the (now) parent process. We're going to have to give this program
+ // quite a bit of information.
+ //
+ // -d<device-name> The name of the tap device we want to create;
+ // -m<MAC-address> The MAC-48 address to assign to the new tap device;
+ // -i<IPv4-address> The IP v4 address to assign to the new tap device;
+ // -I<IPv6-address> The IP v6 address to assign to the new tap device;
+ // -n<network-IPv4-mask> The network IPv4 mask to assign to the new tap device;
+ // -N<network-IPv6-mask> The network IPv6 mask to assign to the new tap device;
+ // -t Set teh IFF_TAP flag
+ // -h Set the IFF_NO_PI flag
+ // -p<path> the path to the unix socket described above.
+ //
+ // Example tap-creator -dnewdev -i1.2.3.1 -m08:00:2e:00:01:23 -n255.255.255.0 -t -h -pblah
+ //
+
+ //
+ // The device-name is something we may want the system to make up in
+ // every case. We also rely on it being configured via an Attribute
+ // through the helper. By default, it is set to the empty string
+ // which tells the system to make up a device name such as "tap123".
+ //
+ std::ostringstream ossDeviceName;
+ if (m_deviceName != "")
+ {
+ ossDeviceName << "-d" << m_deviceName;
+ }
+
+ std::ostringstream ossMac;
+ ossMac << "-m" << m_tapMac;
+
+ std::ostringstream ossIp4;
+ if (m_tapIp4 != "")
+ {
+ ossIp4 << "-i" << m_tapIp4;
+ }
+
+ std::ostringstream ossIp6;
+ if (m_tapIp6 != "")
+ {
+ ossIp6 << "-I" << m_tapIp6;
+ }
+
+ std::ostringstream ossNetmask4;
+ if (m_tapMask4 != "" )
+ {
+ ossNetmask4 << "-n" << m_tapMask4;
+ }
+
+ std::ostringstream ossPrefix6;
+ ossPrefix6 << "-P" << m_tapPrefix6;
+
+ std::ostringstream ossMode;
+ ossMode << "-t";
+
+ std::ostringstream ossPI;
+ if (m_modePi)
+ {
+ ossPI << "-h";
+ }
+
+ std::ostringstream ossPath;
+ ossPath << "-p" << path;
+
+ //
+ // Execute the socket creation process image.
+ //
+ status = ::execlp (TAP_DEV_CREATOR,
+ TAP_DEV_CREATOR, // argv[0] (filename)
+ ossDeviceName.str ().c_str (), // argv[1] (-d<device name>)
+ ossMac.str ().c_str (), // argv[2] (-m<MAC address>
+ ossIp4.str ().c_str (), // argv[3] (-i<IP v4 address>)
+ ossIp6.str ().c_str (), // argv[4] (-I<IP v6 address>)
+ ossNetmask4.str ().c_str (), // argv[5] (-n<IP v4 net mask>)
+ ossPrefix6.str ().c_str (), // argv[6] (-P<IP v6 prefix>)
+ ossMode.str ().c_str (), // argv[7] (-t <tap>)
+ ossPI.str ().c_str (), // argv[8] (-h <pi>)
+ ossPath.str ().c_str (), // argv[9] (-p<path>)
+ (char *)NULL);
+
+ //
+ // If the execlp successfully completes, it never returns. If it returns it failed or the OS is
+ // broken. In either case, we bail.
+ //
+ NS_FATAL_ERROR ("TapFdNetDeviceHelper::CreateFileDescriptor(): Back from execlp(), errno = " << ::strerror (errno));
+ }
+ else
+ {
+ NS_LOG_DEBUG ("Parent process");
+ //
+ // We're the process running the emu net device. We need to wait for the
+ // socket creator process to finish its job.
+ //
+ int st;
+ pid_t waited = waitpid (pid, &st, 0);
+ NS_ABORT_MSG_IF (waited == -1, "TapFdNetDeviceHelper::CreateFileDescriptor(): waitpid() fails, errno = " << strerror (errno));
+ NS_ASSERT_MSG (pid == waited, "TapFdNetDeviceHelper::CreateFileDescriptor(): pid mismatch");
+
+ //
+ // Check to see if the socket creator exited normally and then take a
+ // look at the exit code. If it bailed, so should we. If it didn't
+ // even exit normally, we bail too.
+ //
+ if (WIFEXITED (st))
+ {
+ int exitStatus = WEXITSTATUS (st);
+ NS_ABORT_MSG_IF (exitStatus != 0,
+ "TapFdNetDeviceHelper::CreateFileDescriptor(): socket creator exited normally with status " << exitStatus);
+ }
+ else
+ {
+ NS_FATAL_ERROR ("TapFdNetDeviceHelper::CreateFileDescriptor(): socket creator exited abnormally");
+ }
+
+ //
+ // At this point, the socket creator has run successfully and should
+ // have created our tap device, initialized it with the information we
+ // passed and sent it back to the socket address we provided. A socket
+ // (fd) we can use to talk to this tap device should be waiting on the
+ // Unix socket we set up to receive information back from the creator
+ // program. We've got to do a bunch of grunt work to get at it, though.
+ //
+ // The struct iovec below is part of a scatter-gather list. It describes a
+ // buffer. In this case, it describes a buffer (an integer) that will
+ // get the data that comes back from the socket creator process. It will
+ // be a magic number that we use as a consistency/sanity check.
+ //
+ struct iovec iov;
+ uint32_t magic;
+ iov.iov_base = &magic;
+ iov.iov_len = sizeof(magic);
+
+ //
+ // The CMSG macros you'll see below are used to create and access control
+ // messages (which is another name for ancillary data). The ancillary
+ // data is made up of pairs of struct cmsghdr structures and associated
+ // data arrays.
+ //
+ // First, we're going to allocate a buffer on the stack to receive our
+ // data array (that contains the socket). Sometimes you'll see this called
+ // an "ancillary element" but the msghdr uses the control message termimology
+ // so we call it "control."
+ //
+ size_t msg_size = sizeof(int);
+ char control[CMSG_SPACE (msg_size)];
+
+ //
+ // There is a msghdr that is used to minimize the number of parameters
+ // passed to recvmsg (which we will use to receive our ancillary data).
+ // This structure uses terminology corresponding to control messages, so
+ // you'll see msg_control, which is the pointer to the ancillary data and
+ // controllen which is the size of the ancillary data array.
+ //
+ // So, initialize the message header that describes the ancillary/control
+ // data we expect to receive and point it to buffer.
+ //
+ struct msghdr msg;
+ msg.msg_name = 0;
+ msg.msg_namelen = 0;
+ msg.msg_iov = &iov;
+ msg.msg_iovlen = 1;
+ msg.msg_control = control;
+ msg.msg_controllen = sizeof (control);
+ msg.msg_flags = 0;
+
+ //
+ // Now we can actually receive the interesting bits from the tap
+ // creator process. Lots of pain to get four bytes.
+ //
+ ssize_t bytesRead = recvmsg (sock, &msg, 0);
+ NS_ABORT_MSG_IF (bytesRead != sizeof(int), "TapFdNetDeviceHelper::CreateFileDescriptor(): Wrong byte count from socket creator");
+
+ //
+ // There may be a number of message headers/ancillary data arrays coming in.
+ // Let's look for the one with a type SCM_RIGHTS which indicates it's the
+ // one we're interested in.
+ //
+ struct cmsghdr *cmsg;
+ for (cmsg = CMSG_FIRSTHDR (&msg); cmsg != NULL; cmsg = CMSG_NXTHDR (&msg, cmsg))
+ {
+ if (cmsg->cmsg_level == SOL_SOCKET
+ && cmsg->cmsg_type == SCM_RIGHTS)
+ {
+ //
+ // This is the type of message we want. Check to see if the magic
+ // number is correct and then pull out the socket we care about if
+ // it matches
+ //
+ if (magic == TAP_MAGIC)
+ {
+ NS_LOG_INFO ("Got SCM_RIGHTS with correct magic " << magic);
+ int *rawSocket = (int*)CMSG_DATA (cmsg);
+ NS_LOG_INFO ("Got the socket from the socket creator = " << *rawSocket);
+ return *rawSocket;
+ }
+ else
+ {
+ NS_LOG_INFO ("Got SCM_RIGHTS, but with bad magic " << magic);
+ }
+ }
+ }
+ NS_FATAL_ERROR ("Did not get the raw socket from the socket creator");
+ }
+
+}
+
+} // namespace ns3
+
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/helper/tap-fd-net-device-helper.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,159 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA, 2012 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+#ifndef TAP_FD_NET_DEVICE_HELPER_H
+#define TAP_FD_NET_DEVICE_HELPER_H
+
+#include <string>
+
+#include "ns3/attribute.h"
+#include "ns3/fd-net-device.h"
+#include "ns3/object-factory.h"
+#include "ns3/mac48-address.h"
+#include "ns3/net-device-container.h"
+#include "ns3/node-container.h"
+
+#include "emu-fd-net-device-helper.h"
+
+namespace ns3 {
+
+/**
+ * \brief build a set of FdNetDevice objects attached to a virtua TAP network
+ * interface
+ *
+ */
+class TapFdNetDeviceHelper : public EmuFdNetDeviceHelper
+{
+public:
+ /**
+ * Construct a TapFdNetDeviceHelper.
+ */
+ TapFdNetDeviceHelper ();
+ virtual ~TapFdNetDeviceHelper ()
+ {
+ }
+
+ /**
+ * Set flag IFF_NO_PI on the device.
+ *
+ * \param pi Set the IFF_NO_PI flag if pi is false.
+ */
+ void SetModePi (bool pi);
+
+ /**
+ * Set the device IPv4 address.
+ *
+ * \param address The IPv4 address for the TAP device.
+ */
+ void SetTapIpv4Address (Ipv4Address address);
+
+ /**
+ * Set the IPv4 network mask for the TAP device.
+ *
+ * \param mask The IPv4 network mask for the TAP device.
+ */
+ void SetTapIpv4Mask (Ipv4Mask mask);
+
+ /**
+ * Set the device IPv6 address.
+ *
+ * \param address The IPv6 address for the TAP device.
+ */
+ void SetTapIpv6Address (Ipv6Address address);
+
+ /**
+ * Set the IPv6 network mask for the TAP device.
+ *
+ * \param prefix The IPv6 network prefix for the TAP device.
+ */
+ void SetTapIpv6Prefix (int prefix);
+
+ /**
+ * Set the MAC address for the TAP device.
+ *
+ * \param mac The MAC address the TAP device.
+ */
+ void SetTapMacAddress (Mac48Address mac);
+
+protected:
+ /*
+ * \internal
+ */
+ Ptr<NetDevice> InstallPriv (Ptr<Node> node) const;
+
+ /**
+ * Sets a file descriptor on the FileDescriptorNetDevice.
+ */
+ virtual void SetFileDescriptor (Ptr<FdNetDevice> device) const;
+
+ /**
+ * Call out to a separate process running as suid root in order to create a
+ * TAP device and obtain the file descriptor associated to it.
+ */
+ virtual int CreateFileDescriptor (void) const;
+
+ /**
+ * \internal
+ *
+ * The TAP device flag IFF_NO_PI.
+ */
+ bool m_modePi;
+
+ /**
+ * \internal
+ *
+ * The IPv4 address for the TAP device.
+ */
+ Ipv4Address m_tapIp4;
+
+ /**
+ * \internal
+ *
+ * The IPv6 address for the TAP device.
+ */
+ Ipv6Address m_tapIp6;
+
+
+ /**
+ * \internal
+ *
+ * The network mask IPv4 for the TAP device.
+ */
+ Ipv4Mask m_tapMask4;
+
+ /**
+ * \internal
+ *
+ * The network prefix IPv6 for the TAP device.
+ */
+ int m_tapPrefix6;
+
+
+ /**
+ * \internal
+ *
+ * The TAP device MAC address.
+ */
+ Mac48Address m_tapMac;
+
+};
+
+} // namespace ns3
+
+#endif /* TAP_FD_NET_DEVICE_HELPER_H */
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/model/fd-net-device.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,718 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA, 2012 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ * Claudio Freire <klaussfreire@sourceforge.net>
+ */
+
+#include "fd-net-device.h"
+
+#include "ns3/abort.h"
+#include "ns3/boolean.h"
+#include "ns3/channel.h"
+#include "ns3/enum.h"
+#include "ns3/ethernet-header.h"
+#include "ns3/ethernet-trailer.h"
+#include "ns3/log.h"
+#include "ns3/llc-snap-header.h"
+#include "ns3/mac48-address.h"
+#include "ns3/pointer.h"
+#include "ns3/simulator.h"
+#include "ns3/string.h"
+#include "ns3/trace-source-accessor.h"
+#include "ns3/uinteger.h"
+
+#include <unistd.h>
+#include <arpa/inet.h>
+#include <net/ethernet.h>
+
+NS_LOG_COMPONENT_DEFINE ("FdNetDevice");
+
+namespace ns3 {
+
+FdNetDeviceFdReader::FdNetDeviceFdReader ()
+ : m_bufferSize (65536) // Defaults to maximum TCP window size
+{
+}
+
+void
+FdNetDeviceFdReader::SetBufferSize (uint32_t bufferSize)
+{
+ m_bufferSize = bufferSize;
+}
+
+FdReader::Data FdNetDeviceFdReader::DoRead (void)
+{
+ NS_LOG_FUNCTION (this);
+
+ uint8_t *buf = (uint8_t *)malloc (m_bufferSize);
+ NS_ABORT_MSG_IF (buf == 0, "malloc() failed");
+
+ NS_LOG_LOGIC ("Calling read on fd " << m_fd);
+ ssize_t len = read (m_fd, buf, m_bufferSize);
+ if (len <= 0)
+ {
+ free (buf);
+ buf = 0;
+ len = 0;
+ }
+
+ return FdReader::Data (buf, len);
+}
+
+NS_OBJECT_ENSURE_REGISTERED (FdNetDevice);
+
+TypeId
+FdNetDevice::GetTypeId (void)
+{
+ static TypeId tid = TypeId ("ns3::FdNetDevice")
+ .SetParent<NetDevice> ()
+ .AddConstructor<FdNetDevice> ()
+ .AddAttribute ("Address",
+ "The MAC address of this device.",
+ Mac48AddressValue (Mac48Address ("ff:ff:ff:ff:ff:ff")),
+ MakeMac48AddressAccessor (&FdNetDevice::m_address),
+ MakeMac48AddressChecker ())
+ .AddAttribute ("Start",
+ "The simulation time at which to spin up the device thread.",
+ TimeValue (Seconds (0.)),
+ MakeTimeAccessor (&FdNetDevice::m_tStart),
+ MakeTimeChecker ())
+ .AddAttribute ("Stop",
+ "The simulation time at which to tear down the device thread.",
+ TimeValue (Seconds (0.)),
+ MakeTimeAccessor (&FdNetDevice::m_tStop),
+ MakeTimeChecker ())
+ .AddAttribute ("EncapsulationMode",
+ "The link-layer encapsulation type to use.",
+ EnumValue (DIX),
+ MakeEnumAccessor (&FdNetDevice::m_encapMode),
+ MakeEnumChecker (DIX, "Dix",
+ LLC, "Llc",
+ DIXPI, "DixPi"))
+ .AddAttribute ("RxQueueSize", "Maximum size of the read queue. "
+ "This value limits number of packets that have been read "
+ "from the network into a memory buffer but have not yet "
+ "been processed by the simulator.",
+ UintegerValue (1000),
+ MakeUintegerAccessor (&FdNetDevice::m_maxPendingReads),
+ MakeUintegerChecker<uint32_t> ())
+ //
+ // Trace sources at the "top" of the net device, where packets transition
+ // to/from higher layers. These points do not really correspond to the
+ // MAC layer of the underlying operating system, but exist to provide
+ // a consitent tracing environment. These trace hooks should really be
+ // interpreted as the points at which a packet leaves the ns-3 environment
+ // destined for the underlying operating system or vice-versa.
+ //
+ .AddTraceSource ("MacTx",
+ "Trace source indicating a packet has arrived for transmission by this device",
+ MakeTraceSourceAccessor (&FdNetDevice::m_macTxTrace))
+ .AddTraceSource ("MacTxDrop",
+ "Trace source indicating a packet has been dropped by the device before transmission",
+ MakeTraceSourceAccessor (&FdNetDevice::m_macTxDropTrace))
+ .AddTraceSource ("MacPromiscRx",
+ "A packet has been received by this device, has been passed up from the physical layer "
+ "and is being forwarded up the local protocol stack. This is a promiscuous trace,",
+ MakeTraceSourceAccessor (&FdNetDevice::m_macPromiscRxTrace))
+ .AddTraceSource ("MacRx",
+ "A packet has been received by this device, has been passed up from the physical layer "
+ "and is being forwarded up the local protocol stack. This is a non-promiscuous trace,",
+ MakeTraceSourceAccessor (&FdNetDevice::m_macRxTrace))
+
+ //
+ // Trace sources designed to simulate a packet sniffer facility (tcpdump).
+ //
+ .AddTraceSource ("Sniffer",
+ "Trace source simulating a non-promiscuous packet sniffer attached to the device",
+ MakeTraceSourceAccessor (&FdNetDevice::m_snifferTrace))
+ .AddTraceSource ("PromiscSniffer",
+ "Trace source simulating a promiscuous packet sniffer attached to the device",
+ MakeTraceSourceAccessor (&FdNetDevice::m_promiscSnifferTrace))
+ ;
+ return tid;
+}
+
+FdNetDevice::FdNetDevice ()
+ : m_node (0),
+ m_ifIndex (0),
+ m_mtu (1500), // Defaults to Ethernet v2 MTU
+ m_fd (-1),
+ m_fdReader (0),
+ m_isBroadcast (true),
+ m_isMulticast (false),
+ m_pendingReadCount (0),
+ m_startEvent (),
+ m_stopEvent ()
+{
+ NS_LOG_FUNCTION (this);
+ Start (m_tStart);
+}
+
+FdNetDevice::FdNetDevice (FdNetDevice const &)
+{
+}
+
+FdNetDevice::~FdNetDevice ()
+{
+ NS_LOG_FUNCTION (this);
+}
+
+void
+FdNetDevice::DoDispose (void)
+{
+ NS_LOG_FUNCTION (this);
+ StopDevice ();
+ NetDevice::DoDispose ();
+}
+
+void
+FdNetDevice::SetEncapsulationMode (enum EncapsulationMode mode)
+{
+ NS_LOG_FUNCTION (mode);
+ m_encapMode = mode;
+ NS_LOG_LOGIC ("m_encapMode = " << m_encapMode);
+}
+
+FdNetDevice::EncapsulationMode
+FdNetDevice::GetEncapsulationMode (void) const
+{
+ NS_LOG_FUNCTION (this);
+ return m_encapMode;
+}
+
+void
+FdNetDevice::Start (Time tStart)
+{
+ NS_LOG_FUNCTION (tStart);
+ Simulator::Cancel (m_startEvent);
+ m_startEvent = Simulator::Schedule (tStart, &FdNetDevice::StartDevice, this);
+}
+
+void
+FdNetDevice::Stop (Time tStop)
+{
+ NS_LOG_FUNCTION (tStop);
+ Simulator::Cancel (m_stopEvent);
+ m_startEvent = Simulator::Schedule (tStop, &FdNetDevice::StopDevice, this);
+}
+
+void
+FdNetDevice::StartDevice (void)
+{
+ NS_LOG_FUNCTION (this);
+
+ if (m_fd == -1)
+ {
+ NS_LOG_DEBUG ("FdNetDevice::Start(): Failure, invalid file descriptor.");
+ return;
+ }
+ //
+ // A similar story exists for the node ID. We can't just naively do a
+ // GetNode ()->GetId () since GetNode is going to give us a Ptr<Node> which
+ // is reference counted. We need to stash away the node ID for use in the
+ // read thread.
+ //
+ m_nodeId = GetNode ()->GetId ();
+
+ m_fdReader = Create<FdNetDeviceFdReader> ();
+ m_fdReader->SetBufferSize(m_mtu);
+ m_fdReader->Start (m_fd, MakeCallback (&FdNetDevice::ReceiveCallback, this));
+
+ NotifyLinkUp ();
+}
+
+void
+FdNetDevice::StopDevice (void)
+{
+ NS_LOG_FUNCTION (this);
+
+ if (m_fdReader != 0)
+ {
+ m_fdReader->Stop ();
+ m_fdReader = 0;
+ }
+
+ if (m_fd != -1)
+ {
+ close (m_fd);
+ m_fd = -1;
+ }
+}
+
+void
+FdNetDevice::ReceiveCallback (uint8_t *buf, ssize_t len)
+{
+ NS_LOG_FUNCTION (this << buf << len);
+ bool skip = false;
+
+ {
+ CriticalSection cs (m_pendingReadMutex);
+ if (m_pendingReadCount >= m_maxPendingReads)
+ {
+ //XXX: Packet dropped!
+ skip = true;
+ }
+ else
+ {
+ ++m_pendingReadCount;
+ }
+ }
+
+ if (skip)
+ {
+ struct timespec time = { 0, 100000000L }; // 100 ms
+ nanosleep (&time, NULL);
+ }
+ else
+ {
+ Simulator::ScheduleWithContext (m_nodeId, Time (0), MakeEvent (&FdNetDevice::ForwardUp, this, buf, len));
+ }
+}
+
+// XXX: Consider having a instance member m_packetBuffer and using memmove
+// instead of memcpy to add the PI header.
+// It might be faster in this case to use memmove and avoid the extra mallocs.
+static void
+AddPIHeader (uint8_t *&buf, ssize_t &len)
+{
+ // Synthesize PI header for our friend the kernel
+ uint8_t *buf2 = (uint8_t*)malloc (len + 4);
+ memcpy (buf2 + 4, buf, len);
+ len += 4;
+
+ // PI = 16 bits flags (0) + 16 bits proto
+ // NOTE: be careful to interpret buffer data explicitly as
+ // little-endian to be insensible to native byte ordering.
+ uint16_t flags = 0;
+ uint16_t proto = 0x0008; // default to IPv4
+ if (len > 14)
+ {
+ if (buf[12] == 0x81 && buf[13] == 0x00 && len > 18)
+ {
+ // tagged ethernet packet
+ proto = buf[16] | (buf[17] << 8);
+ }
+ else
+ {
+ // untagged ethernet packet
+ proto = buf[12] | (buf[13] << 8);
+ }
+ }
+ buf2[0] = (uint8_t)flags;
+ buf2[1] = (uint8_t)(flags >> 8);
+ buf2[2] = (uint8_t)proto;
+ buf2[3] = (uint8_t)(proto >> 8);
+
+ // swap buffer
+ free (buf);
+ buf = buf2;
+}
+
+static void
+RemovePIHeader (uint8_t *&buf, ssize_t &len)
+{
+ // strip PI header if present, shrink buffer
+ if (len >= 4)
+ {
+ len -= 4;
+ memmove (buf, buf + 4, len);
+ buf = (uint8_t*)realloc (buf, len);
+ }
+}
+
+void
+FdNetDevice::ForwardUp (uint8_t *buf, ssize_t len)
+{
+ NS_LOG_FUNCTION (this << buf << len);
+
+ if (m_pendingReadCount > 0)
+ {
+ {
+ CriticalSection cs (m_pendingReadMutex);
+ --m_pendingReadCount;
+ }
+ }
+
+ // We need to remove the PI header and ignore it
+ if (m_encapMode == DIXPI)
+ {
+ RemovePIHeader (buf, len);
+ }
+
+ //
+ // Create a packet out of the buffer we received and free that buffer.
+ //
+ Ptr<Packet> packet = Create<Packet> (reinterpret_cast<const uint8_t *> (buf), len);
+ free (buf);
+ buf = 0;
+
+ //
+ // Trace sinks will expect complete packets, not packets without some of the
+ // headers
+ //
+ Ptr<Packet> originalPacket = packet->Copy ();
+
+ Mac48Address destination;
+ Mac48Address source;
+ uint16_t protocol;
+ bool isBroadcast = false;
+ bool isMulticast = false;
+
+ EthernetHeader header (false);
+
+ //
+ // This device could be running in an environment where completely unexpected
+ // kinds of packets are flying around, so we need to harden things a bit and
+ // filter out packets we think are completely bogus, so we always check to see
+ // that the packet is long enough to contain the header we want to remove.
+ //
+ if (packet->GetSize () < header.GetSerializedSize ())
+ {
+ m_phyRxDropTrace (originalPacket);
+ return;
+ }
+
+ packet->RemoveHeader (header);
+ destination = header.GetDestination ();
+ source = header.GetSource ();
+ isBroadcast = header.GetDestination ().IsBroadcast ();
+ isMulticast = header.GetDestination ().IsGroup ();
+ protocol = header.GetLengthType ();
+
+ //
+ // If the length/type is less than 1500, it corresponds to a length
+ // interpretation packet. In this case, it is an 802.3 packet and
+ // will also have an 802.2 LLC header. If greater than 1500, we
+ // find the protocol number (Ethernet type) directly.
+ //
+ if (m_encapMode == LLC and header.GetLengthType () <= 1500)
+ {
+ LlcSnapHeader llc;
+ //
+ // Check to see that the packet is long enough to possibly contain the
+ // header we want to remove before just naively calling.
+ //
+ if (packet->GetSize () < llc.GetSerializedSize ())
+ {
+ m_phyRxDropTrace (originalPacket);
+ return;
+ }
+
+ packet->RemoveHeader (llc);
+ protocol = llc.GetType ();
+ }
+
+ NS_LOG_LOGIC ("Pkt source is " << source);
+ NS_LOG_LOGIC ("Pkt destination is " << destination);
+
+ PacketType packetType;
+
+ if (isBroadcast)
+ {
+ packetType = NS3_PACKET_BROADCAST;
+ }
+ else if (isMulticast)
+ {
+ packetType = NS3_PACKET_MULTICAST;
+ }
+ else if (destination == m_address)
+ {
+ packetType = NS3_PACKET_HOST;
+ }
+ else
+ {
+ packetType = NS3_PACKET_OTHERHOST;
+ }
+
+ //
+ // For all kinds of packetType we receive, we hit the promiscuous sniffer
+ // hook and pass a copy up to the promiscuous callback. Pass a copy to
+ // make sure that nobody messes with our packet.
+ //
+ m_promiscSnifferTrace (originalPacket);
+
+ if (!m_promiscRxCallback.IsNull ())
+ {
+ m_macPromiscRxTrace (originalPacket);
+ m_promiscRxCallback (this, packet, protocol, source, destination,
+ packetType);
+ }
+
+ //
+ // If this packet is not destined for some other host, it must be for us
+ // as either a broadcast, multicast or unicast. We need to hit the mac
+ // packet received trace hook and forward the packet up the stack.
+ //
+ if (packetType != NS3_PACKET_OTHERHOST)
+ {
+ m_snifferTrace (originalPacket);
+ m_macRxTrace (originalPacket);
+ m_rxCallback (this, packet, protocol, source);
+ }
+}
+
+bool
+FdNetDevice::Send (Ptr<Packet> packet, const Address& destination, uint16_t protocolNumber)
+{
+ NS_LOG_FUNCTION (this << packet << destination << protocolNumber);
+ return SendFrom (packet, m_address, destination, protocolNumber);
+}
+
+bool
+FdNetDevice::SendFrom (Ptr<Packet> packet, const Address& src, const Address& dest, uint16_t protocolNumber)
+{
+ NS_LOG_FUNCTION (this << packet << src << dest << protocolNumber);
+ NS_LOG_LOGIC ("packet " << packet);
+ NS_LOG_LOGIC ("UID is " << packet->GetUid ());
+
+ if (IsLinkUp () == false)
+ {
+ m_macTxDropTrace (packet);
+ return false;
+ }
+
+ Mac48Address destination = Mac48Address::ConvertFrom (dest);
+ Mac48Address source = Mac48Address::ConvertFrom (src);
+
+ NS_LOG_LOGIC ("Transmit packet with UID " << packet->GetUid ());
+ NS_LOG_LOGIC ("Transmit packet from " << source);
+ NS_LOG_LOGIC ("Transmit packet to " << destination);
+
+ EthernetHeader header (false);
+ header.SetSource (source);
+ header.SetDestination (destination);
+
+ if (m_encapMode == LLC)
+ {
+ LlcSnapHeader llc;
+ llc.SetType (protocolNumber);
+ packet->AddHeader (llc);
+
+ header.SetLengthType (packet->GetSize ());
+ }
+ else
+ {
+ header.SetLengthType (protocolNumber);
+ }
+
+ packet->AddHeader (header);
+
+ //
+ // there's not much meaning associated with the different layers in this
+ // device, so don't be surprised when they're all stacked together in
+ // essentially one place. We do this for trace consistency across devices.
+ //
+ m_macTxTrace (packet);
+
+ m_promiscSnifferTrace (packet);
+ m_snifferTrace (packet);
+
+ NS_LOG_LOGIC ("calling write");
+
+ NS_ASSERT_MSG (packet->GetSize () <= m_mtu, "FdNetDevice::SendFrom(): Packet too big " << packet->GetSize ());
+
+ ssize_t len = (ssize_t) packet->GetSize ();
+ uint8_t *buffer = (uint8_t*)malloc (len);
+ packet->CopyData (buffer, len);
+
+ // We need to add the PI header
+ if (m_encapMode == DIXPI)
+ {
+ AddPIHeader (buffer, len);
+ }
+
+ ssize_t written = write (m_fd, buffer, len);
+ free (buffer);
+
+ if (written == -1 || written != len)
+ {
+ m_macTxDropTrace (packet);
+ return false;
+ }
+
+ return true;
+}
+
+void
+FdNetDevice::SetFileDescriptor (int fd)
+{
+ if (m_fd == -1 and fd > 0)
+ {
+ m_fd = fd;
+ }
+}
+
+void
+FdNetDevice::SetAddress (Address address)
+{
+ m_address = Mac48Address::ConvertFrom (address);
+}
+
+Address
+FdNetDevice::GetAddress (void) const
+{
+ return m_address;
+}
+
+void
+FdNetDevice::NotifyLinkUp (void)
+{
+ m_linkUp = true;
+ m_linkChangeCallbacks ();
+}
+
+void
+FdNetDevice::SetIfIndex (const uint32_t index)
+{
+ m_ifIndex = index;
+}
+
+uint32_t
+FdNetDevice::GetIfIndex (void) const
+{
+ return m_ifIndex;
+}
+
+Ptr<Channel>
+FdNetDevice::GetChannel (void) const
+{
+ return NULL;
+}
+
+bool
+FdNetDevice::SetMtu (const uint16_t mtu)
+{
+ // The MTU depends on the technology associated to
+ // the file descriptor. The user is responsible of
+ // setting the correct value of the MTU.
+ // If the file descriptor is created using a helper,
+ // then is the responsibility of the helper to set
+ // the correct MTU value.
+ m_mtu = mtu;
+ return true;
+}
+
+uint16_t
+FdNetDevice::GetMtu (void) const
+{
+ return m_mtu;
+}
+
+bool
+FdNetDevice::IsLinkUp (void) const
+{
+ return m_linkUp;
+}
+
+void
+FdNetDevice::AddLinkChangeCallback (Callback<void> callback)
+{
+ m_linkChangeCallbacks.ConnectWithoutContext (callback);
+}
+
+bool
+FdNetDevice::IsBroadcast (void) const
+{
+ return m_isBroadcast;
+}
+
+void
+FdNetDevice::SetIsBroadcast (bool broadcast)
+{
+ m_isBroadcast = broadcast;
+}
+
+Address
+FdNetDevice::GetBroadcast (void) const
+{
+ return Mac48Address ("ff:ff:ff:ff:ff:ff");
+}
+
+bool
+FdNetDevice::IsMulticast (void) const
+{
+ return m_isMulticast;
+}
+
+void
+FdNetDevice::SetIsMulticast (bool multicast)
+{
+ m_isMulticast = multicast;
+}
+
+Address
+FdNetDevice::GetMulticast (Ipv4Address multicastGroup) const
+{
+ return Mac48Address::GetMulticast (multicastGroup);
+}
+
+Address
+FdNetDevice::GetMulticast (Ipv6Address addr) const
+{
+ return Mac48Address::GetMulticast (addr);
+}
+
+bool
+FdNetDevice::IsBridge (void) const
+{
+ return false;
+}
+
+bool
+FdNetDevice::IsPointToPoint (void) const
+{
+ return false;
+}
+
+Ptr<Node>
+FdNetDevice::GetNode (void) const
+{
+ return m_node;
+}
+
+void
+FdNetDevice::SetNode (Ptr<Node> node)
+{
+ m_node = node;
+}
+
+bool
+FdNetDevice::NeedsArp (void) const
+{
+ return true;
+}
+
+void
+FdNetDevice::SetReceiveCallback (NetDevice::ReceiveCallback cb)
+{
+ m_rxCallback = cb;
+}
+
+void
+FdNetDevice::SetPromiscReceiveCallback (PromiscReceiveCallback cb)
+{
+ m_promiscRxCallback = cb;
+}
+
+bool
+FdNetDevice::SupportsSendFrom (void) const
+{
+ return true;
+}
+
+} // namespace ns3
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/model/fd-net-device.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,462 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 INRIA, 2012 University of Washington
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Alina Quereilhac <alina.quereilhac@inria.fr>
+ * Claudio Freire <klaussfreire@sourceforge.net>
+ */
+
+#ifndef FD_NET_DEVICE_H
+#define FD_NET_DEVICE_H
+
+#include "ns3/address.h"
+#include "ns3/callback.h"
+#include "ns3/data-rate.h"
+#include "ns3/event-id.h"
+#include "ns3/mac48-address.h"
+#include "ns3/net-device.h"
+#include "ns3/node.h"
+#include "ns3/packet.h"
+#include "ns3/ptr.h"
+#include "ns3/system-condition.h"
+#include "ns3/traced-callback.h"
+#include "ns3/unix-fd-reader.h"
+#include "ns3/system-mutex.h"
+
+#include <string.h>
+
+namespace ns3 {
+
+class FdNetDeviceFdReader : public FdReader
+{
+public:
+ /**
+ * Constructor for the FdNetDevice.
+ */
+ FdNetDeviceFdReader ();
+
+ /**
+ * Set size of the read buffer.
+ *
+ */
+ void SetBufferSize (uint32_t bufferSize);
+
+private:
+ FdReader::Data DoRead (void);
+
+ uint32_t m_bufferSize;
+};
+
+class Node;
+
+/**
+ * \defgroup fd-net-device FdNetDevice
+ * This section documents the API of the ns-3 fd-net-device module.
+ * For a generic functional description, please refer to the ns-3 manual.
+ */
+
+/**
+ * \ingroup fd-net-device
+ *
+ * \brief a NetDevice to read/write network traffic from/into a file descriptor.
+ *
+ * A FdNetDevice object will read and write frames/packets from/to a file descriptor.
+ * This file descriptor might be associated to a Linux TAP/TUN device, to a socket
+ * or to a user space process, allowing the simulation to exchange traffic with the
+ * "outside-world"
+ *
+ */
+class FdNetDevice : public NetDevice
+{
+public:
+ static TypeId GetTypeId (void);
+
+ /**
+ * Enumeration of the types of frames supported in the class.
+ */
+ enum EncapsulationMode
+ {
+ DIX, /**< DIX II / Ethernet II packet */
+ LLC, /**< 802.2 LLC/SNAP Packet*/
+ DIXPI, /**< When using TAP devices, if flag
+ IFF_NO_PI is not set on the device,
+ IP packets will have an extra header:
+ Flags [2 bytes]
+ Proto [2 bytes]
+ Raw protocol(IP, IPv6, etc) frame. */
+ };
+
+ /**
+ * Constructor for the FdNetDevice.
+ */
+ FdNetDevice ();
+
+ /**
+ * Destructor for the FdNetDevice.
+ */
+ virtual ~FdNetDevice ();
+
+ /**
+ * Set the link layer encapsulation mode of this device.
+ *
+ * \param mode The link layer encapsulation mode of this device.
+ *
+ */
+ void SetEncapsulationMode (FdNetDevice::EncapsulationMode mode);
+
+ /**
+ * Get the link layer encapsulation mode of this device.
+ *
+ * \returns The link layer encapsulation mode of this device.
+ */
+ FdNetDevice::EncapsulationMode GetEncapsulationMode (void) const;
+
+ /**
+ * Set the associated file descriptor.
+ *
+ */
+ void SetFileDescriptor (int fd);
+
+ /**
+ * Set a start time for the device.
+ *
+ * @param tStart the start time
+ */
+ void Start (Time tStart);
+
+ /**
+ * Set a stop time for the device.
+ *
+ * @param tStop the stop time
+ */
+ void Stop (Time tStop);
+
+ // inherited from NetDevice base class.
+ virtual void SetIfIndex (const uint32_t index);
+ virtual uint32_t GetIfIndex (void) const;
+ virtual Ptr<Channel> GetChannel (void) const;
+ virtual void SetAddress (Address address);
+ virtual Address GetAddress (void) const;
+ virtual bool SetMtu (const uint16_t mtu);
+ virtual uint16_t GetMtu (void) const;
+ virtual bool IsLinkUp (void) const;
+ virtual void AddLinkChangeCallback (Callback<void> callback);
+ virtual bool IsBroadcast (void) const;
+ virtual Address GetBroadcast (void) const;
+ virtual bool IsMulticast (void) const;
+ virtual Address GetMulticast (Ipv4Address multicastGroup) const;
+ virtual bool IsPointToPoint (void) const;
+ virtual bool IsBridge (void) const;
+ virtual bool Send (Ptr<Packet> packet, const Address& dest, uint16_t protocolNumber);
+ virtual bool SendFrom (Ptr<Packet> packet, const Address& source, const Address& dest, uint16_t protocolNumber);
+ virtual Ptr<Node> GetNode (void) const;
+ virtual void SetNode (Ptr<Node> node);
+ virtual bool NeedsArp (void) const;
+ virtual void SetReceiveCallback (NetDevice::ReceiveCallback cb);
+ virtual void SetPromiscReceiveCallback (NetDevice::PromiscReceiveCallback cb);
+ virtual bool SupportsSendFrom () const;
+ virtual Address GetMulticast (Ipv6Address addr) const;
+
+ virtual void SetIsBroadcast (bool broadcast);
+ virtual void SetIsMulticast (bool multicast);
+
+protected:
+ virtual void DoDispose (void);
+
+private:
+ // private copy constructor as sugested in:
+ // http://www.nsnam.org/wiki/index.php/NS-3_Python_Bindings#.22invalid_use_of_incomplete_type.22
+ FdNetDevice (FdNetDevice const &);
+
+ /**
+ * \internal
+ *
+ * Spin up the device
+ */
+ void StartDevice (void);
+
+ /**
+ * \internal
+ *
+ * Tear down the device
+ */
+ void StopDevice (void);
+
+ /**
+ * \internal
+ *
+ * Callback to invoke when a new frame is received
+ */
+ void ReceiveCallback (uint8_t *buf, ssize_t len);
+
+ /**
+ * \internal
+ *
+ * Forward the frame to the appropriate callback for processing
+ */
+ void ForwardUp (uint8_t *buf, ssize_t len);
+
+ /**
+ * Start Sending a Packet Down the Wire.
+ * @param p packet to send
+ * @returns true if success, false on failure
+ */
+ bool TransmitStart (Ptr<Packet> p);
+
+ void NotifyLinkUp (void);
+
+ /**
+ * \internal
+ *
+ * The ns-3 node associated to the net device.
+ */
+ Ptr<Node> m_node;
+
+ /*
+ * \internal
+ *
+ * a copy of the node id so the read thread doesn't have to GetNode() in
+ * in order to find the node ID. Thread unsafe reference counting in
+ * multithreaded apps is not a good thing.
+ */
+ uint32_t m_nodeId;
+
+ /**
+ * \internal
+ *
+ * The ns-3 interface index (in the sense of net device index) that has been assigned to this network device.
+ */
+ uint32_t m_ifIndex;
+
+ /**
+ * \internal
+ *
+ * The MTU associated to the file descriptor technology
+ */
+ uint16_t m_mtu;
+
+ /**
+ * \internal
+ *
+ * The file descriptor used for receive/send network traffic.
+ */
+ int m_fd;
+
+ /**
+ * \internal
+ *
+ * Reader for the file descriptor.
+ */
+ Ptr<FdNetDeviceFdReader> m_fdReader;
+
+ /**
+ * \internal
+ *
+ * The net device mac address.
+ */
+ Mac48Address m_address;
+
+ /**
+ * \internal
+ *
+ * The typ of encapsulation of the received/transmited frames.
+ */
+ EncapsulationMode m_encapMode;
+
+ /**
+ * \internal
+ *
+ * Flag indicating whether or not the link is up. In this case,
+ * whether or not the device is connected to a channel.
+ */
+ bool m_linkUp;
+
+ /**
+ * \internal
+ *
+ * Callbacks to fire if the link changes state (up or down).
+ */
+ TracedCallback<> m_linkChangeCallbacks;
+
+ /**
+ * \internal
+ *
+ * Flag indicating whether or not the underlying net device supports
+ * broadcast.
+ */
+ bool m_isBroadcast;
+
+ /**
+ * \internal
+ *
+ * Flag indicating whether or not the underlying net device supports
+ * multicast.
+ */
+ bool m_isMulticast;
+
+ /**
+ * \internal
+ *
+ * Number of packets that were received and scheduled for read but not yeat read.
+ */
+ uint32_t m_pendingReadCount;
+
+ /**
+ * \internal
+ *
+ * Maximum number of packets that can be received and scheduled for read but not yeat read.
+ */
+ uint32_t m_maxPendingReads;
+
+
+ /**
+ * \internal
+ *
+ * Mutex to increase pending read counter.
+ */
+ SystemMutex m_pendingReadMutex;
+
+ /**
+ * \internal
+ *
+ * Time to start spinning up the device
+ */
+ Time m_tStart;
+
+ /**
+ * \internal
+ *
+ * Time to start tearing down the device
+ */
+ Time m_tStop;
+
+ EventId m_startEvent;
+ EventId m_stopEvent;
+
+ /**
+ * The callback used to notify higher layers that a packet has been received.
+ */
+ NetDevice::ReceiveCallback m_rxCallback;
+
+ /**
+ * The callback used to notify higher layers that a packet has been received in promiscuous mode.
+ */
+ NetDevice::PromiscReceiveCallback m_promiscRxCallback;
+
+ /**
+ * The trace source fired when packets come into the "top" of the device
+ * at the L3/L2 transition, before being queued for transmission.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_macTxTrace;
+
+ /**
+ * The trace source fired when packets coming into the "top" of the device
+ * at the L3/L2 transition are dropped before being queued for transmission.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_macTxDropTrace;
+
+ /**
+ * The trace source fired for packets successfully received by the device
+ * immediately before being forwarded up to higher layers (at the L2/L3
+ * transition). This is a promiscuous trace.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_macPromiscRxTrace;
+
+ /**
+ * The trace source fired for packets successfully received by the device
+ * immediately before being forwarded up to higher layers (at the L2/L3
+ * transition). This is a non-promiscuous trace.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_macRxTrace;
+
+ /**
+ * The trace source fired for packets successfully received by the device
+ * but which are dropped before being forwarded up to higher layers (at the
+ * L2/L3 transition).
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_macRxDropTrace;
+
+ /**
+ * The trace source fired when the phy layer drops a packet as it tries
+ * to transmit it.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_phyTxDropTrace;
+
+ /**
+ * The trace source fired when the phy layer drops a packet it has received.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_phyRxDropTrace;
+
+ /**
+ * A trace source that emulates a non-promiscuous protocol sniffer connected
+ * to the device. Unlike your average everyday sniffer, this trace source
+ * will not fire on PACKET_OTHERHOST events.
+ *
+ * On the transmit size, this trace hook will fire after a packet is dequeued
+ * from the device queue for transmission. In Linux, for example, this would
+ * correspond to the point just before a device hard_start_xmit where
+ * dev_queue_xmit_nit is called to dispatch the packet to the PF_PACKET
+ * ETH_P_ALL handlers.
+ *
+ * On the receive side, this trace hook will fire when a packet is received,
+ * just before the receive callback is executed. In Linux, for example,
+ * this would correspond to the point at which the packet is dispatched to
+ * packet sniffers in netif_receive_skb.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_snifferTrace;
+
+ /**
+ * A trace source that emulates a promiscuous mode protocol sniffer connected
+ * to the device. This trace source fire on packets destined for any host
+ * just like your average everyday packet sniffer.
+ *
+ * On the transmit size, this trace hook will fire after a packet is dequeued
+ * from the device queue for transmission. In Linux, for example, this would
+ * correspond to the point just before a device hard_start_xmit where
+ * dev_queue_xmit_nit is called to dispatch the packet to the PF_PACKET
+ * ETH_P_ALL handlers.
+ *
+ * On the receive side, this trace hook will fire when a packet is received,
+ * just before the receive callback is executed. In Linux, for example,
+ * this would correspond to the point at which the packet is dispatched to
+ * packet sniffers in netif_receive_skb.
+ *
+ * \see class CallBackTraceSource
+ */
+ TracedCallback<Ptr<const Packet> > m_promiscSnifferTrace;
+
+};
+
+} // namespace ns3
+
+#endif /* FD_NET_DEVICE_H */
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/test/examples-to-run.py Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,26 @@
+#! /usr/bin/env python
+## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
+
+# A list of C++ examples to run in order to ensure that they remain
+# buildable and runnable over time. Each tuple in the list contains
+#
+# (example_name, do_run, do_valgrind_run).
+#
+# See test.py for more information.
+cpp_examples = [
+ ("dummy-network", "True", "True"),
+ ("fd-emu-ping", "False", "True"),
+ ("fd-emu-onoff", "False", "True"),
+ ("fd-emu-udp-echo", "False", "True"),
+ ("realtime-dummy-network", "False", "True"),
+ ("fd2fd-onoff", "False", "True"),
+ ("fd-tap-ping", "False", "True"),
+ ("realtime-fd2fd-onoff", "False", "True"),
+]
+
+# A list of Python examples to run in order to ensure that they remain
+# runnable over time. Each tuple in the list contains
+#
+# (example_name, do_run).
+#
+# See test.py for more information.
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/waf Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,1 @@
+exec "`dirname "$0"`"/../../../waf "$@"
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/fd-net-device/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,171 @@
+## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
+
+import os.path
+
+def configure(conf):
+ conf.env['ENABLE_FDNETDEV'] = False
+
+ if conf.env['ENABLE_THREADING']:
+ # Check for system dependencies
+ have_sysioctl = conf.check_nonfatal(header_name='sys/ioctl.h',
+ define_name = 'HAVE_SYS_IOCTL_H')
+ have_netif = conf.check_nonfatal(header_name='net/if.h',
+ define_name = 'HAVE_IF_NETS_H')
+
+ # Enable the FdNetDevice module.
+ # Our only requirement is threading support.
+ conf.env['ENABLE_FDNETDEV'] = True
+ conf.report_optional_feature("FdNetDevice",
+ "File descriptor NetDevice",
+ True,
+ "FdNetDevice module enabled")
+ else:
+ conf.report_optional_feature("FdNetDevice",
+ "File descriptor NetDevice",
+ False,
+ "needs threading support which is not available")
+
+ if conf.env['ENABLE_FDNETDEV']:
+ blddir = os.path.abspath(os.path.join(conf.bldnode.abspath(), conf.variant))
+ dir = os.path.abspath(os.path.join(blddir, "src/fd-net-device"))
+ conf.env.append_value('NS3_EXECUTABLE_PATH', dir)
+ else:
+ # Add this module to the list of modules that won't be built
+ # if they are enabled.
+ conf.env['MODULES_NOT_BUILT'].append('fd-net-device')
+
+ # Next, check for whether specialized FdNetDevice features are enabled
+ # such as tap device support, raw socket support, and planetlab
+
+ if conf.env['ENABLE_FDNETDEV']:
+ conf.env['ENABLE_TAP'] = conf.check_nonfatal(
+ header_name='linux/if_tun.h',
+ define_name='HAVE_IF_TUN_H') and have_sysioctl and have_netif
+
+ if conf.env['ENABLE_TAP']:
+ conf.report_optional_feature("TapFdNetDevice",
+ "Tap FdNetDevice",
+ True,
+ "Tap support enabled")
+ else:
+ conf.report_optional_feature("TapFdNetDevice",
+ "Tap FdNetDevice",
+ False,
+ "needs linux/if_tun.h")
+
+ # Enable use of raw socket (EMU) helper.
+ conf.env['ENABLE_EMU'] = conf.check_nonfatal(
+ header_name='netpacket/packet.h',
+ define_name='HAVE_PACKET_H') and have_sysioctl and have_netif
+
+ if conf.env['ENABLE_EMU']:
+ conf.report_optional_feature("EmuFdNetDevice",
+ "Emulation FdNetDevice",
+ True,
+ "Emulation support enabled")
+ else:
+ conf.report_optional_feature("EmuFdNetDevice",
+ "Emulation FdNetDevice",
+ False,
+ "needs netpacket/packet.h")
+
+ # Enable use of PlanetLab TAP helper
+ # TODO: How to validate
+ (sysname, nodename, release, version, machine) = os.uname()
+ if release.find('onelab') != -1:
+ conf.env['ENABLE_PLANETLAB'] = True
+
+ if conf.env['ENABLE_PLANETLAB']:
+ conf.report_optional_feature("PlanetLabFdNetDevice",
+ "PlanetLab FdNetDevice",
+ True,
+ "Planetlab support enabled")
+ else:
+ conf.report_optional_feature("PlanetLabFdNetDevice",
+ "PlanetLab FdNetDevice",
+ False,
+ "PlanetLab operating system not detected")
+
+def build(bld):
+ # Don't do anything for this module if emu's not enabled.
+ if not bld.env['ENABLE_FDNETDEV']:
+ return
+
+ module = bld.create_ns3_module('fd-net-device', ['network'])
+ module.source = [
+ 'model/fd-net-device.cc',
+ 'helper/fd-net-device-helper.cc',
+ 'helper/encode-decode.cc',
+ 'helper/creator-utils.cc',
+ ]
+
+ headers = bld(features='ns3header')
+ headers.module = 'fd-net-device'
+ headers.source = [
+ 'model/fd-net-device.h',
+ 'helper/fd-net-device-helper.h',
+ ]
+
+ if bld.env['ENABLE_TAP']:
+ if not bld.env['PLATFORM'].startswith('freebsd'):
+ module.source.extend([
+ 'helper/tap-fd-net-device-helper.cc',
+ ])
+
+ headers.source.extend([
+ 'helper/tap-fd-net-device-helper.h',
+ ])
+
+ creator = bld.create_suid_program('tap-device-creator')
+ creator.source = [
+ 'helper/tap-device-creator.cc',
+ 'helper/encode-decode.cc',
+ 'helper/creator-utils.cc',
+ ]
+
+ module.env.append_value("DEFINES",
+ "TAP_DEV_CREATOR=\"%s\"" % (creator.target,))
+
+ if bld.env['ENABLE_EMU']:
+ module.source.extend([
+ 'helper/emu-fd-net-device-helper.cc',
+ ])
+
+ headers.source.extend([
+ 'helper/emu-fd-net-device-helper.h',
+ ])
+
+ creator = bld.create_suid_program('raw-sock-creator')
+ creator.source = [
+ 'helper/raw-sock-creator.cc',
+ 'helper/encode-decode.cc',
+ 'helper/creator-utils.cc',
+ ]
+
+ module.env.append_value("DEFINES",
+ "RAW_SOCK_CREATOR=\"%s\"" % (creator.target,))
+
+ if bld.env['ENABLE_PLANETLAB']:
+ module.source.extend([
+ 'helper/planetlab-fd-net-device-helper.cc',
+ ])
+
+ headers.source.extend([
+ 'helper/planetlab-fd-net-device-helper.h',
+ ])
+
+ creator = bld.create_suid_program('planetlab-tap-creator')
+ creator.source = [
+ 'helper/planetlab-tap-creator.cc',
+ 'helper/encode-decode.cc',
+ 'helper/creator-utils.cc',
+ ]
+
+ module.env.append_value("DEFINES",
+ "PLANETLAB_TAP_CREATOR=\"%s\"" % (creator.target,))
+
+ if bld.env['ENABLE_EXAMPLES']:
+ bld.recurse('examples')
+
+ bld.ns3_python_bindings()
+
--- a/src/flow-monitor/test/histogram-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/flow-monitor/test/histogram-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -75,7 +75,7 @@
HistogramTestSuite ()
: TestSuite ("histogram", UNIT)
{
- AddTestCase (new HistogramTestCase ());
+ AddTestCase (new HistogramTestCase (), TestCase::QUICK);
}
} g_HistogramTestSuite;
--- a/src/flow-monitor/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/flow-monitor/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -17,7 +17,7 @@
'test/histogram-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'flow-monitor'
headers.source = ["model/%s" % s for s in [
'flow-monitor.h',
@@ -30,6 +30,6 @@
headers.source.append("helper/flow-monitor-helper.h")
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/internet/doc/tcp.rst Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/doc/tcp.rst Fri Apr 05 17:59:11 2013 +0200
@@ -150,8 +150,7 @@
Current limitations
+++++++++++++++++++
-* Only IPv4 is supported
-* Neither the Nagle algorithm nor SACK are supported
+* SACK is not supported
Network Simulation Cradle
*************************
@@ -270,6 +269,13 @@
These additional configuration variables are not available to native |ns3| TCP.
+Also note that default values for TCP attributes in |ns3| TCP may differ from the nsc TCP implementation. Specifically in |ns3|:::
+
+ 1) TCP default MSS is 536
+ 2) TCP Delayed Ack count is 2
+
+Therefore when making comparisons between results obtained using nsc and |ns3| TCP, care must be taken to ensure these values are set appropriately. See /examples/tcp/tcp-nsc-comparision.cc for an example.
+
NSC API
+++++++
--- a/src/internet/model/icmpv6-header.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/model/icmpv6-header.cc Fri Apr 05 17:59:11 2013 +0200
@@ -1646,7 +1646,13 @@
{
SetType (source ? Icmpv6Header::ICMPV6_OPT_LINK_LAYER_SOURCE : Icmpv6Header::ICMPV6_OPT_LINK_LAYER_TARGET);
SetAddress (addr);
- SetLength (GetSerializedSize () / 8);
+
+ uint8_t len = (2 + m_addr.GetLength ()) / 8;
+ if ( (2 + m_addr.GetLength ()) % 8 )
+ {
+ len ++;
+ }
+ SetLength (len);
}
Icmpv6OptionLinkLayerAddress::~Icmpv6OptionLinkLayerAddress ()
@@ -1670,8 +1676,7 @@
uint32_t Icmpv6OptionLinkLayerAddress::GetSerializedSize () const
{
- /* TODO add padding */
- uint8_t nb = 2 + m_addr.GetLength ();
+ uint8_t nb = GetLength() * 8;
return nb;
}
@@ -1686,7 +1691,11 @@
m_addr.CopyTo (mac);
i.Write (mac, m_addr.GetLength ());
- /* XXX if size of the option is not a multiple of 8, add padding */
+ uint8_t len = GetLength ()*8 - (2 + m_addr.GetLength ());
+ for (uint8_t nb = 0; nb<len; nb++)
+ {
+ i.WriteU8 (0);
+ }
}
uint32_t Icmpv6OptionLinkLayerAddress::Deserialize (Buffer::Iterator start)
--- a/src/internet/model/ipv6-l3-protocol.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/model/ipv6-l3-protocol.cc Fri Apr 05 17:59:11 2013 +0200
@@ -993,15 +993,17 @@
uint8_t nextHeaderPosition = 0;
bool isDropped = false;
- /* process hop-by-hop extension first if exists */
+ // check for a malformed hop-by-hop extension
+ // this is a common case when forging IPv6 raw packets
if (nextHeader == Ipv6Header::IPV6_EXT_HOP_BY_HOP)
{
- uint8_t buf[2];
- p->CopyData (buf, sizeof(buf));
- nextHeader = buf[0];
- nextHeaderPosition = buf[1];
- NS_ASSERT_MSG (nextHeader != Ipv6Header::IPV6_EXT_HOP_BY_HOP, "Double Ipv6Header::IPV6_EXT_HOP_BY_HOP in packet, aborting");
- NS_ASSERT_MSG (nextHeaderPosition != 0, "Zero-size IPv6 Option Header, aborting");
+ uint8_t buf;
+ p->CopyData (&buf, 1);
+ if (buf == Ipv6Header::IPV6_EXT_HOP_BY_HOP)
+ {
+ NS_LOG_WARN("Double Ipv6Header::IPV6_EXT_HOP_BY_HOP in packet, dropping packet");
+ return;
+ }
}
/* process all the extensions found and the layer 4 protocol */
--- a/src/internet/model/ipv6-raw-socket-impl.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/model/ipv6-raw-socket-impl.cc Fri Apr 05 17:59:11 2013 +0200
@@ -245,6 +245,8 @@
}
ipv6->Send (p, route->GetSource (), dst, m_protocol, route);
+ // Return only payload size (as Linux does).
+ return p->GetSize () - hdr.GetSerializedSize ();
}
else
{
@@ -273,7 +275,7 @@
/* get packet */
struct Data data = m_data.front ();
m_data.pop_front ();
-
+ fromAddress = Inet6SocketAddress (data.fromIp, data.fromProtocol);
if (data.packet->GetSize () > maxSize)
{
Ptr<Packet> first = data.packet->CreateFragment (0, maxSize);
@@ -285,7 +287,6 @@
return first;
}
- fromAddress = Inet6SocketAddress (data.fromIp, data.fromProtocol);
return data.packet;
}
--- a/src/internet/model/tcp-socket-base.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/model/tcp-socket-base.cc Fri Apr 05 17:59:11 2013 +0200
@@ -450,9 +450,11 @@
// Bug number 426 claims we should send reset in this case.
if (m_rxBuffer.Size () != 0)
{
+ NS_LOG_INFO ("Socket " << this << " << unread rx data during close. Sending reset");
SendRST ();
return 0;
}
+
if (m_txBuffer.SizeFromSequence (m_nextTxSequence) > 0)
{ // App close with pending data must wait until all data transmitted
if (m_closeOnEmpty == false)
@@ -470,7 +472,32 @@
TcpSocketBase::ShutdownSend (void)
{
NS_LOG_FUNCTION (this);
+
+ //this prevents data from being added to the buffer
m_shutdownSend = true;
+ m_closeOnEmpty = true;
+ //if buffer is already empty, send a fin now
+ //otherwise fin will go when buffer empties.
+ if (m_txBuffer.Size () == 0)
+ {
+ if (m_state == ESTABLISHED || m_state == CLOSE_WAIT)
+ {
+ NS_LOG_INFO("Emtpy tx buffer, send fin");
+ SendEmptyPacket (TcpHeader::FIN);
+
+ if (m_state == ESTABLISHED)
+ { // On active close: I am the first one to send FIN
+ NS_LOG_INFO ("ESTABLISHED -> FIN_WAIT_1");
+ m_state = FIN_WAIT_1;
+ }
+ else
+ { // On passive close: Peer sent me FIN already
+ NS_LOG_INFO ("CLOSE_WAIT -> LAST_ACK");
+ m_state = LAST_ACK;
+ }
+ }
+ }
+
return 0;
}
@@ -498,6 +525,11 @@
m_errno = ERROR_MSGSIZE;
return -1;
}
+ if (m_shutdownSend)
+ {
+ m_errno = ERROR_SHUTDOWN;
+ return -1;
+ }
// Submit the data to lower layers
NS_LOG_LOGIC ("txBufSize=" << m_txBuffer.Size () << " state " << TcpStateName[m_state]);
if (m_state == ESTABLISHED || m_state == CLOSE_WAIT)
@@ -1922,12 +1954,6 @@
" highestRxAck " << m_txBuffer.HeadSequence () <<
" pd->Size " << m_txBuffer.Size () <<
" pd->SFS " << m_txBuffer.SizeFromSequence (m_nextTxSequence));
- // Quit if send disallowed
- if (m_shutdownSend)
- {
- m_errno = ERROR_SHUTDOWN;
- return false;
- }
// Stop sending if we need to wait for a larger Tx window (prevent silly window syndrome)
if (w < m_segmentSize && m_txBuffer.SizeFromSequence (m_nextTxSequence) > w)
{
--- a/src/internet/test/global-route-manager-impl-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/global-route-manager-impl-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -220,6 +220,6 @@
GlobalRouteManagerImplTestSuite()
: TestSuite ("global-route-manager-impl", UNIT)
{
- AddTestCase (new GlobalRouteManagerImplTestCase ());
+ AddTestCase (new GlobalRouteManagerImplTestCase (), TestCase::QUICK);
}
} g_globalRoutingManagerImplTestSuite;
--- a/src/internet/test/ipv4-address-generator-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-address-generator-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -308,10 +308,10 @@
Ipv4AddressGeneratorTestSuite ()
: TestSuite ("ipv4-address-generator")
{
- AddTestCase (new NetworkNumberAllocatorTestCase ());
- AddTestCase (new AddressAllocatorTestCase ());
- AddTestCase (new NetworkAndAddressTestCase ());
- AddTestCase (new ExampleAddressGeneratorTestCase ());
- AddTestCase (new AddressCollisionTestCase ());
+ AddTestCase (new NetworkNumberAllocatorTestCase (), TestCase::QUICK);
+ AddTestCase (new AddressAllocatorTestCase (), TestCase::QUICK);
+ AddTestCase (new NetworkAndAddressTestCase (), TestCase::QUICK);
+ AddTestCase (new ExampleAddressGeneratorTestCase (), TestCase::QUICK);
+ AddTestCase (new AddressCollisionTestCase (), TestCase::QUICK);
}
} g_ipv4AddressGeneratorTestSuite;
--- a/src/internet/test/ipv4-address-helper-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-address-helper-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -261,9 +261,9 @@
Ipv4AddressHelperTestSuite ()
: TestSuite ("ipv4-address-helper", UNIT)
{
- AddTestCase (new NetworkAllocatorHelperTestCase ());
- AddTestCase (new AddressAllocatorHelperTestCase ());
- AddTestCase (new ResetAllocatorHelperTestCase ());
- AddTestCase (new IpAddressHelperTestCasev4 ());
+ AddTestCase (new NetworkAllocatorHelperTestCase (), TestCase::QUICK);
+ AddTestCase (new AddressAllocatorHelperTestCase (), TestCase::QUICK);
+ AddTestCase (new ResetAllocatorHelperTestCase (), TestCase::QUICK);
+ AddTestCase (new IpAddressHelperTestCasev4 (), TestCase::QUICK);
}
} g_ipv4AddressHelperTestSuite;
--- a/src/internet/test/ipv4-fragmentation-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-fragmentation-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -407,6 +407,6 @@
public:
Ipv4FragmentationTestSuite () : TestSuite ("ipv4-fragmentation", UNIT)
{
- AddTestCase (new Ipv4FragmentationTest);
+ AddTestCase (new Ipv4FragmentationTest, TestCase::QUICK);
}
} g_ipv4fragmentationTestSuite;
--- a/src/internet/test/ipv4-header-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-header-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -261,6 +261,6 @@
public:
Ipv4HeaderTestSuite () : TestSuite ("ipv4-header", UNIT)
{
- AddTestCase (new Ipv4HeaderTest);
+ AddTestCase (new Ipv4HeaderTest, TestCase::QUICK);
}
} g_ipv4HeaderTestSuite;
--- a/src/internet/test/ipv4-list-routing-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-list-routing-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -118,8 +118,8 @@
Ipv4ListRoutingTestSuite()
: TestSuite ("ipv4-list-routing", UNIT)
{
- AddTestCase (new Ipv4ListRoutingPositiveTestCase ());
- AddTestCase (new Ipv4ListRoutingNegativeTestCase ());
+ AddTestCase (new Ipv4ListRoutingPositiveTestCase (), TestCase::QUICK);
+ AddTestCase (new Ipv4ListRoutingNegativeTestCase (), TestCase::QUICK);
}
} g_ipv4ListRoutingTestSuite;
--- a/src/internet/test/ipv4-packet-info-tag-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-packet-info-tag-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -206,5 +206,5 @@
Ipv4PacketInfoTagTestSuite::Ipv4PacketInfoTagTestSuite ()
: TestSuite ("ipv4-packet-info-tag", UNIT)
{
- AddTestCase (new Ipv4PacketInfoTagTest ());
+ AddTestCase (new Ipv4PacketInfoTagTest (), TestCase::QUICK);
}
--- a/src/internet/test/ipv4-raw-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-raw-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -320,6 +320,6 @@
public:
Ipv4RawTestSuite () : TestSuite ("ipv4-raw", UNIT)
{
- AddTestCase (new Ipv4RawSocketImplTest);
+ AddTestCase (new Ipv4RawSocketImplTest, TestCase::QUICK);
}
} g_ipv4rawTestSuite;
--- a/src/internet/test/ipv4-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv4-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -103,7 +103,7 @@
IPv4L3ProtocolTestSuite () :
TestSuite ("ipv4-protocol", UNIT)
{
- AddTestCase (new Ipv4L3ProtocolTestCase ());
+ AddTestCase (new Ipv4L3ProtocolTestCase (), TestCase::QUICK);
}
} g_ipv4protocolTestSuite;
--- a/src/internet/test/ipv6-address-generator-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-address-generator-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -279,10 +279,10 @@
Ipv6AddressGeneratorTestSuite ()
: TestSuite ("ipv6-address-generator")
{
- AddTestCase (new NetworkNumber6AllocatorTestCase ());
- AddTestCase (new AddressAllocator6TestCase ());
- AddTestCase (new NetworkAndAddress6TestCase ());
- AddTestCase (new ExampleAddress6GeneratorTestCase ());
- AddTestCase (new AddressCollision6TestCase ());
+ AddTestCase (new NetworkNumber6AllocatorTestCase (), TestCase::QUICK);
+ AddTestCase (new AddressAllocator6TestCase (), TestCase::QUICK);
+ AddTestCase (new NetworkAndAddress6TestCase (), TestCase::QUICK);
+ AddTestCase (new ExampleAddress6GeneratorTestCase (), TestCase::QUICK);
+ AddTestCase (new AddressCollision6TestCase (), TestCase::QUICK);
}
} g_ipv6AddressGeneratorTestSuite;
--- a/src/internet/test/ipv6-address-helper-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-address-helper-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -148,7 +148,7 @@
Ipv6AddressHelperTestSuite::Ipv6AddressHelperTestSuite ()
: TestSuite ("ipv6-address-helper", UNIT)
{
- AddTestCase (new IpAddressHelperTestCasev6);
+ AddTestCase (new IpAddressHelperTestCasev6, TestCase::QUICK);
}
// Do not forget to allocate an instance of this TestSuite
--- a/src/internet/test/ipv6-dual-stack-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-dual-stack-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -306,6 +306,6 @@
Ipv6DualStackTestSuite ()
: TestSuite ("ipv6-dual-stack", UNIT)
{
- AddTestCase (new DualStackTestCase());
+ AddTestCase (new DualStackTestCase(), TestCase::QUICK);
}
} g_ipv6DualStackTestSuite;
--- a/src/internet/test/ipv6-extension-header-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-extension-header-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -215,10 +215,10 @@
Ipv6ExtensionHeaderTestSuite ()
: TestSuite ("ipv6-extension-header", UNIT)
{
- AddTestCase (new TestEmptyOptionField);
- AddTestCase (new TestOptionWithoutAlignment);
- AddTestCase (new TestOptionWithAlignment);
- AddTestCase (new TestFulfilledAlignment);
+ AddTestCase (new TestEmptyOptionField, TestCase::QUICK);
+ AddTestCase (new TestOptionWithoutAlignment, TestCase::QUICK);
+ AddTestCase (new TestOptionWithAlignment, TestCase::QUICK);
+ AddTestCase (new TestFulfilledAlignment, TestCase::QUICK);
}
};
--- a/src/internet/test/ipv6-fragmentation-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-fragmentation-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -423,6 +423,6 @@
public:
Ipv6FragmentationTestSuite () : TestSuite ("ipv6-fragmentation", UNIT)
{
- AddTestCase (new Ipv6FragmentationTest);
+ AddTestCase (new Ipv6FragmentationTest, TestCase::QUICK);
}
} g_ipv6fragmentationTestSuite;
--- a/src/internet/test/ipv6-list-routing-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-list-routing-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -125,8 +125,8 @@
Ipv6ListRoutingTestSuite()
: TestSuite ("ipv6-list-routing", UNIT)
{
- AddTestCase (new Ipv6ListRoutingPositiveTestCase ());
- AddTestCase (new Ipv6ListRoutingNegativeTestCase ());
+ AddTestCase (new Ipv6ListRoutingPositiveTestCase (), TestCase::QUICK);
+ AddTestCase (new Ipv6ListRoutingNegativeTestCase (), TestCase::QUICK);
}
} g_ipv6ListRoutingTestSuite;
--- a/src/internet/test/ipv6-packet-info-tag-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-packet-info-tag-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -207,5 +207,5 @@
Ipv6PacketInfoTagTestSuite::Ipv6PacketInfoTagTestSuite ()
: TestSuite ("ipv6-packet-info-tag", UNIT)
{
- AddTestCase (new Ipv6PacketInfoTagTest ());
+ AddTestCase (new Ipv6PacketInfoTagTest (), TestCase::QUICK);
}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/internet/test/ipv6-raw-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,275 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2012 Hajime Tazaki
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Hajime Tazaki <tazaki@sfc.wide.ad.jp>
+ */
+/**
+ * This is the test code for ipv6-raw-socket-impl.cc.
+ */
+
+#include "ns3/test.h"
+#include "ns3/socket-factory.h"
+#include "ns3/ipv6-raw-socket-factory.h"
+#include "ns3/simulator.h"
+#include "ns3/simple-channel.h"
+#include "ns3/simple-net-device.h"
+#include "ns3/drop-tail-queue.h"
+#include "ns3/socket.h"
+
+#include "ns3/log.h"
+#include "ns3/node.h"
+#include "ns3/inet6-socket-address.h"
+#include "ns3/boolean.h"
+#include "ns3/uinteger.h"
+
+#include "ns3/ipv6-l3-protocol.h"
+#include "ns3/icmpv6-l4-protocol.h"
+#include "ns3/ipv6-list-routing.h"
+#include "ns3/ipv6-static-routing.h"
+
+#include <string>
+#include <limits>
+#include <netinet/in.h>
+#include <sys/socket.h>
+#include <sys/types.h>
+
+using namespace ns3;
+
+static void
+AddInternetStack (Ptr<Node> node)
+{
+ Ptr<Ipv6L3Protocol> ipv6 = CreateObject<Ipv6L3Protocol> ();
+ Ptr<Icmpv6L4Protocol> icmpv6 = CreateObject<Icmpv6L4Protocol> ();
+ node->AggregateObject (ipv6);
+ node->AggregateObject (icmpv6);
+ ipv6->Insert (icmpv6);
+ icmpv6->SetAttribute ("DAD", BooleanValue (false));
+
+ //Routing for Ipv6
+ Ptr<Ipv6ListRouting> ipv6Routing = CreateObject<Ipv6ListRouting> ();
+ ipv6->SetRoutingProtocol (ipv6Routing);
+ Ptr<Ipv6StaticRouting> ipv6staticRouting = CreateObject<Ipv6StaticRouting> (); ipv6Routing->AddRoutingProtocol (ipv6staticRouting, 0);
+ /* register IPv6 extensions and options */
+ ipv6->RegisterExtensions (); ipv6->RegisterOptions ();
+}
+
+
+class Ipv6RawSocketImplTest : public TestCase
+{
+ Ptr<Packet> m_receivedPacket;
+ Ptr<Packet> m_receivedPacket2;
+ void DoSendData (Ptr<Socket> socket, std::string to);
+ void SendData (Ptr<Socket> socket, std::string to);
+
+public:
+ virtual void DoRun (void);
+ Ipv6RawSocketImplTest ();
+
+ void ReceivePacket (Ptr<Socket> socket, Ptr<Packet> packet, const Address &from);
+ void ReceivePacket2 (Ptr<Socket> socket, Ptr<Packet> packet, const Address &from);
+ void ReceivePkt (Ptr<Socket> socket);
+ void ReceivePkt2 (Ptr<Socket> socket);
+};
+
+
+Ipv6RawSocketImplTest::Ipv6RawSocketImplTest ()
+ : TestCase ("Ipv6 Raw socket implementation")
+{
+}
+
+void Ipv6RawSocketImplTest::ReceivePacket (Ptr<Socket> socket, Ptr<Packet> packet, const Address &from)
+{
+ m_receivedPacket = packet;
+}
+
+void Ipv6RawSocketImplTest::ReceivePacket2 (Ptr<Socket> socket, Ptr<Packet> packet, const Address &from)
+{
+ m_receivedPacket2 = packet;
+}
+
+void Ipv6RawSocketImplTest::ReceivePkt (Ptr<Socket> socket)
+{
+ uint32_t availableData;
+ availableData = socket->GetRxAvailable ();
+ m_receivedPacket = socket->Recv (2, MSG_PEEK);
+ NS_ASSERT (m_receivedPacket->GetSize () == 2);
+ m_receivedPacket = socket->Recv (std::numeric_limits<uint32_t>::max (), 0);
+ NS_ASSERT (availableData == m_receivedPacket->GetSize ());
+}
+
+void Ipv6RawSocketImplTest::ReceivePkt2 (Ptr<Socket> socket)
+{
+ uint32_t availableData;
+ Address addr;
+ availableData = socket->GetRxAvailable ();
+ m_receivedPacket2 = socket->Recv (2, MSG_PEEK);
+ NS_ASSERT (m_receivedPacket2->GetSize () == 2);
+ m_receivedPacket2 = socket->RecvFrom (std::numeric_limits<uint32_t>::max (), 0, addr);
+ NS_ASSERT (availableData == m_receivedPacket2->GetSize ());
+ Inet6SocketAddress v6addr = Inet6SocketAddress::ConvertFrom (addr);
+ NS_TEST_EXPECT_MSG_EQ (v6addr.GetIpv6 (),Ipv6Address ("fe80:0000:0000:0000:0200:00ff:fe00:0003"), "recvfrom");
+}
+
+void
+Ipv6RawSocketImplTest::DoSendData (Ptr<Socket> socket, std::string to)
+{
+ Address realTo = Inet6SocketAddress (Ipv6Address (to.c_str ()), 0);
+ NS_TEST_EXPECT_MSG_EQ (socket->SendTo (Create<Packet> (123), 0, realTo),
+ 123, to);
+}
+
+void
+Ipv6RawSocketImplTest::SendData (Ptr<Socket> socket, std::string to)
+{
+ m_receivedPacket = Create<Packet> ();
+ m_receivedPacket2 = Create<Packet> ();
+ Simulator::ScheduleWithContext (socket->GetNode ()->GetId (), Seconds (0),
+ &Ipv6RawSocketImplTest::DoSendData, this, socket, to);
+ Simulator::Run ();
+}
+
+void
+Ipv6RawSocketImplTest::DoRun (void)
+{
+ // Create topology
+
+ // Receiver Node
+ Ptr<Node> rxNode = CreateObject<Node> ();
+ AddInternetStack (rxNode);
+ Ptr<SimpleNetDevice> rxDev1, rxDev2;
+ { // first interface
+ rxDev1 = CreateObject<SimpleNetDevice> ();
+ rxDev1->SetAddress (Mac48Address::ConvertFrom (Mac48Address::Allocate ()));
+ rxNode->AddDevice (rxDev1);
+ Ptr<Ipv6> ipv6 = rxNode->GetObject<Ipv6> ();
+ uint32_t netdev_idx = ipv6->AddInterface (rxDev1);
+ Ipv6InterfaceAddress ipv6Addr = Ipv6InterfaceAddress (Ipv6Address ("2001:db8:0::1"), Ipv6Prefix (64));
+ ipv6->AddAddress (netdev_idx, ipv6Addr);
+ ipv6->SetUp (netdev_idx);
+ }
+
+ { // second interface
+ rxDev2 = CreateObject<SimpleNetDevice> ();
+ rxDev2->SetAddress (Mac48Address::ConvertFrom (Mac48Address::Allocate ()));
+ rxNode->AddDevice (rxDev2);
+ Ptr<Ipv6> ipv6 = rxNode->GetObject<Ipv6> ();
+ uint32_t netdev_idx = ipv6->AddInterface (rxDev2);
+ Ipv6InterfaceAddress ipv6Addr = Ipv6InterfaceAddress (Ipv6Address ("2001:db8:1::1"), Ipv6Prefix (64));
+ ipv6->AddAddress (netdev_idx, ipv6Addr);
+ ipv6->SetUp (netdev_idx);
+ }
+
+ // Sender Node
+ Ptr<Node> txNode = CreateObject<Node> ();
+ AddInternetStack (txNode);
+ Ptr<SimpleNetDevice> txDev1;
+ {
+ txDev1 = CreateObject<SimpleNetDevice> ();
+ txDev1->SetAddress (Mac48Address::ConvertFrom (Mac48Address::Allocate ()));
+ txNode->AddDevice (txDev1);
+ Ptr<Ipv6> ipv6 = txNode->GetObject<Ipv6> ();
+ uint32_t netdev_idx = ipv6->AddInterface (txDev1);
+ Ipv6InterfaceAddress ipv6Addr = Ipv6InterfaceAddress (Ipv6Address ("2001:db8:0::2"), Ipv6Prefix (64));
+ ipv6->AddAddress (netdev_idx, ipv6Addr);
+ ipv6->SetUp (netdev_idx);
+ }
+ Ptr<SimpleNetDevice> txDev2;
+ {
+ txDev2 = CreateObject<SimpleNetDevice> ();
+ txDev2->SetAddress (Mac48Address::ConvertFrom (Mac48Address::Allocate ()));
+ txNode->AddDevice (txDev2);
+ Ptr<Ipv6> ipv6 = txNode->GetObject<Ipv6> ();
+ uint32_t netdev_idx = ipv6->AddInterface (txDev2);
+ Ipv6InterfaceAddress ipv6Addr = Ipv6InterfaceAddress (Ipv6Address ("2001:db8:1::2"), Ipv6Prefix (64));
+ ipv6->AddAddress (netdev_idx, ipv6Addr);
+ ipv6->SetUp (netdev_idx);
+ }
+
+ // link the two nodes
+ Ptr<SimpleChannel> channel1 = CreateObject<SimpleChannel> ();
+ rxDev1->SetChannel (channel1);
+ txDev1->SetChannel (channel1);
+
+ Ptr<SimpleChannel> channel2 = CreateObject<SimpleChannel> ();
+ rxDev2->SetChannel (channel2);
+ txDev2->SetChannel (channel2);
+
+
+ // Create the Ipv6 Raw sockets
+ Ptr<SocketFactory> rxSocketFactory = rxNode->GetObject<Ipv6RawSocketFactory> ();
+ Ptr<Socket> rxSocket = rxSocketFactory->CreateSocket ();
+ NS_TEST_EXPECT_MSG_EQ (rxSocket->Bind (Inet6SocketAddress (Ipv6Address::GetAny (), 0)), 0, "trivial");
+ rxSocket->SetAttribute ("Protocol", UintegerValue (Ipv6Header::IPV6_ICMPV6));
+ rxSocket->SetRecvCallback (MakeCallback (&Ipv6RawSocketImplTest::ReceivePkt, this));
+
+ Ptr<Socket> rxSocket2 = rxSocketFactory->CreateSocket ();
+ rxSocket2->SetRecvCallback (MakeCallback (&Ipv6RawSocketImplTest::ReceivePkt2, this));
+ rxSocket2->SetAttribute ("Protocol", UintegerValue (Ipv6Header::IPV6_ICMPV6));
+ NS_TEST_EXPECT_MSG_EQ (rxSocket2->Bind (Inet6SocketAddress (Ipv6Address ("2001:db8:1::1"), 0)), 0, "trivial");
+
+ Ptr<SocketFactory> txSocketFactory = txNode->GetObject<Ipv6RawSocketFactory> ();
+ Ptr<Socket> txSocket = txSocketFactory->CreateSocket ();
+ txSocket->SetAttribute ("Protocol", UintegerValue (Ipv6Header::IPV6_ICMPV6));
+
+ // ------ Now the tests ------------
+
+ // Unicast test
+ SendData (txSocket, "2001:db8:0::1");
+ NS_TEST_EXPECT_MSG_EQ (m_receivedPacket->GetSize (), 163, "recv: 2001:db8:0::1");
+ NS_TEST_EXPECT_MSG_EQ (m_receivedPacket2->GetSize (), 0, "second interface should not receive it");
+
+ m_receivedPacket->RemoveAllByteTags ();
+ m_receivedPacket2->RemoveAllByteTags ();
+
+ // Simple Link-local multicast test
+ txSocket->Bind (Inet6SocketAddress (Ipv6Address ("2001:db8:0::2"), 0));
+ SendData (txSocket, "ff02::1");
+ NS_TEST_EXPECT_MSG_EQ (m_receivedPacket->GetSize (), 163, "recv: ff02::1");
+ NS_TEST_EXPECT_MSG_EQ (m_receivedPacket2->GetSize (), 0, "second socket should not receive it (it is bound specifically to the second interface's address");
+
+ m_receivedPacket->RemoveAllByteTags ();
+ m_receivedPacket2->RemoveAllByteTags ();
+
+ // Broadcast test with multiple receiving sockets
+
+ // When receiving broadcast packets, all sockets sockets bound to
+ // the address/port should receive a copy of the same packet -- if
+ // the socket address matches.
+ rxSocket2->Dispose ();
+ rxSocket2 = rxSocketFactory->CreateSocket ();
+ rxSocket2->SetRecvCallback (MakeCallback (&Ipv6RawSocketImplTest::ReceivePkt2, this));
+ rxSocket2->SetAttribute ("Protocol", UintegerValue (Ipv6Header::IPV6_ICMPV6));
+ NS_TEST_EXPECT_MSG_EQ (rxSocket2->Bind (Inet6SocketAddress (Ipv6Address::GetAny (), 0)), 0, "trivial");
+
+ SendData (txSocket, "ff02::1");
+ NS_TEST_EXPECT_MSG_EQ (m_receivedPacket->GetSize (), 163, "recv: ff02::1");
+ NS_TEST_EXPECT_MSG_EQ (m_receivedPacket2->GetSize (), 163, "recv: ff02::1");
+
+ m_receivedPacket = 0;
+ m_receivedPacket2 = 0;
+
+ Simulator::Destroy ();
+}
+//-----------------------------------------------------------------------------
+class Ipv6RawTestSuite : public TestSuite
+{
+public:
+ Ipv6RawTestSuite () : TestSuite ("ipv6-raw", UNIT)
+ {
+ AddTestCase (new Ipv6RawSocketImplTest, TestCase::QUICK);
+ }
+} g_ipv6rawTestSuite;
--- a/src/internet/test/ipv6-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/ipv6-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -144,7 +144,7 @@
IPv6L3ProtocolTestSuite () :
TestSuite ("ipv6-protocol", UNIT)
{
- AddTestCase (new Ipv6L3ProtocolTestCase ());
+ AddTestCase (new Ipv6L3ProtocolTestCase (), TestCase::QUICK);
}
} g_ipv6protocolTestSuite;
--- a/src/internet/test/tcp-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/tcp-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -435,13 +435,13 @@
// 2) source write size, 3) source read size
// 4) server write size, and 5) server read size
// with units of bytes
- AddTestCase (new TcpTestCase (13, 200, 200, 200, 200, false));
- AddTestCase (new TcpTestCase (13, 1, 1, 1, 1, false));
- AddTestCase (new TcpTestCase (100000, 100, 50, 100, 20, false));
+ AddTestCase (new TcpTestCase (13, 200, 200, 200, 200, false), TestCase::QUICK);
+ AddTestCase (new TcpTestCase (13, 1, 1, 1, 1, false), TestCase::QUICK);
+ AddTestCase (new TcpTestCase (100000, 100, 50, 100, 20, false), TestCase::QUICK);
- AddTestCase (new TcpTestCase (13, 200, 200, 200, 200, true));
- AddTestCase (new TcpTestCase (13, 1, 1, 1, 1, true));
- AddTestCase (new TcpTestCase (100000, 100, 50, 100, 20, true));
+ AddTestCase (new TcpTestCase (13, 200, 200, 200, 200, true), TestCase::QUICK);
+ AddTestCase (new TcpTestCase (13, 1, 1, 1, 1, true), TestCase::QUICK);
+ AddTestCase (new TcpTestCase (100000, 100, 50, 100, 20, true), TestCase::QUICK);
}
} g_tcpTestSuite;
--- a/src/internet/test/udp-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/test/udp-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -576,9 +576,9 @@
public:
UdpTestSuite () : TestSuite ("udp", UNIT)
{
- AddTestCase (new UdpSocketImplTest);
- AddTestCase (new UdpSocketLoopbackTest);
- AddTestCase (new Udp6SocketImplTest);
- AddTestCase (new Udp6SocketLoopbackTest);
+ AddTestCase (new UdpSocketImplTest, TestCase::QUICK);
+ AddTestCase (new UdpSocketLoopbackTest, TestCase::QUICK);
+ AddTestCase (new Udp6SocketImplTest, TestCase::QUICK);
+ AddTestCase (new Udp6SocketLoopbackTest, TestCase::QUICK);
}
} g_udpTestSuite;
--- a/src/internet/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/internet/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -2,10 +2,8 @@
import os
import sys
-import Options
-import Logs
-import Utils
-import Task
+from waflib import Options, Logs, Utils, Task
+
# Required NSC version
NSC_RELEASE_NAME = "nsc-0.5.3"
@@ -202,6 +200,7 @@
'test/ipv6-list-routing-test-suite.cc',
'test/ipv6-packet-info-tag-test-suite.cc',
'test/ipv6-test.cc',
+ 'test/ipv6-raw-test.cc',
'test/tcp-test.cc',
'test/udp-test.cc',
'test/ipv6-address-generator-test-suite.cc',
@@ -210,7 +209,7 @@
'test/ipv6-address-helper-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'internet'
headers.source = [
'model/udp-header.h',
@@ -294,7 +293,7 @@
internet_test.use.append('DL')
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/lte/model/lte-spectrum-phy.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/model/lte-spectrum-phy.cc Fri Apr 05 17:59:11 2013 +0200
@@ -465,7 +465,7 @@
bool
LteSpectrumPhy::StartTxDlCtrlFrame (std::list<Ptr<LteControlMessage> > ctrlMsgList)
{
- NS_LOG_FUNCTION (this << time);
+ NS_LOG_FUNCTION (this);
NS_LOG_LOGIC (this << " state: " << m_state);
// m_phyTxStartTrace (pb);
@@ -521,7 +521,7 @@
bool
LteSpectrumPhy::StartTxUlSrsFrame ()
{
- NS_LOG_FUNCTION (this << time);
+ NS_LOG_FUNCTION (this);
NS_LOG_LOGIC (this << " state: " << m_state);
// m_phyTxStartTrace (pb);
--- a/src/lte/test/epc-test-gtpu.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/epc-test-gtpu.cc Fri Apr 05 17:59:11 2013 +0200
@@ -38,7 +38,7 @@
EpsGtpuTestSuite::EpsGtpuTestSuite ()
: TestSuite ("epc-gtpu", SYSTEM)
{
- AddTestCase (new EpsGtpuHeaderTestCase ());
+ AddTestCase (new EpsGtpuHeaderTestCase (), TestCase::QUICK);
}
static EpsGtpuTestSuite epsGtpuTestSuite;
--- a/src/lte/test/epc-test-s1u-downlink.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/epc-test-s1u-downlink.cc Fri Apr 05 17:59:11 2013 +0200
@@ -250,7 +250,7 @@
UeDlTestData f1 (1, 100);
e1.ues.push_back (f1);
v1.push_back (e1);
- AddTestCase (new EpcS1uDlTestCase ("1 eNB, 1UE", v1));
+ AddTestCase (new EpcS1uDlTestCase ("1 eNB, 1UE", v1), TestCase::QUICK);
std::vector<EnbDlTestData> v2;
@@ -260,13 +260,13 @@
UeDlTestData f2_2 (2, 200);
e2.ues.push_back (f2_2);
v2.push_back (e2);
- AddTestCase (new EpcS1uDlTestCase ("1 eNB, 2UEs", v2));
+ AddTestCase (new EpcS1uDlTestCase ("1 eNB, 2UEs", v2), TestCase::QUICK);
std::vector<EnbDlTestData> v3;
v3.push_back (e1);
v3.push_back (e2);
- AddTestCase (new EpcS1uDlTestCase ("2 eNBs", v3));
+ AddTestCase (new EpcS1uDlTestCase ("2 eNBs", v3), TestCase::QUICK);
EnbDlTestData e3;
@@ -280,35 +280,35 @@
v4.push_back (e3);
v4.push_back (e1);
v4.push_back (e2);
- AddTestCase (new EpcS1uDlTestCase ("3 eNBs", v4));
+ AddTestCase (new EpcS1uDlTestCase ("3 eNBs", v4), TestCase::QUICK);
std::vector<EnbDlTestData> v5;
EnbDlTestData e5;
UeDlTestData f5 (10, 3000);
e5.ues.push_back (f5);
v5.push_back (e5);
- AddTestCase (new EpcS1uDlTestCase ("1 eNB, 10 pkts 3000 bytes each", v5));
+ AddTestCase (new EpcS1uDlTestCase ("1 eNB, 10 pkts 3000 bytes each", v5), TestCase::QUICK);
std::vector<EnbDlTestData> v6;
EnbDlTestData e6;
UeDlTestData f6 (50, 3000);
e6.ues.push_back (f6);
v6.push_back (e6);
- AddTestCase (new EpcS1uDlTestCase ("1 eNB, 50 pkts 3000 bytes each", v6));
+ AddTestCase (new EpcS1uDlTestCase ("1 eNB, 50 pkts 3000 bytes each", v6), TestCase::QUICK);
std::vector<EnbDlTestData> v7;
EnbDlTestData e7;
UeDlTestData f7 (10, 15000);
e7.ues.push_back (f7);
v7.push_back (e7);
- AddTestCase (new EpcS1uDlTestCase ("1 eNB, 10 pkts 15000 bytes each", v7));
+ AddTestCase (new EpcS1uDlTestCase ("1 eNB, 10 pkts 15000 bytes each", v7), TestCase::QUICK);
std::vector<EnbDlTestData> v8;
EnbDlTestData e8;
UeDlTestData f8 (100, 15000);
e8.ues.push_back (f8);
v8.push_back (e8);
- AddTestCase (new EpcS1uDlTestCase ("1 eNB, 100 pkts 15000 bytes each", v8));
+ AddTestCase (new EpcS1uDlTestCase ("1 eNB, 100 pkts 15000 bytes each", v8), TestCase::QUICK);
}
--- a/src/lte/test/epc-test-s1u-uplink.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/epc-test-s1u-uplink.cc Fri Apr 05 17:59:11 2013 +0200
@@ -476,7 +476,7 @@
UeUlTestData f1 (1, 100, 1, 1);
e1.ues.push_back (f1);
v1.push_back (e1);
- AddTestCase (new EpcS1uUlTestCase ("1 eNB, 1UE", v1));
+ AddTestCase (new EpcS1uUlTestCase ("1 eNB, 1UE", v1), TestCase::QUICK);
std::vector<EnbUlTestData> v2;
@@ -486,13 +486,13 @@
UeUlTestData f2_2 (2, 200, 2, 1);
e2.ues.push_back (f2_2);
v2.push_back (e2);
- AddTestCase (new EpcS1uUlTestCase ("1 eNB, 2UEs", v2));
+ AddTestCase (new EpcS1uUlTestCase ("1 eNB, 2UEs", v2), TestCase::QUICK);
std::vector<EnbUlTestData> v3;
v3.push_back (e1);
v3.push_back (e2);
- AddTestCase (new EpcS1uUlTestCase ("2 eNBs", v3));
+ AddTestCase (new EpcS1uUlTestCase ("2 eNBs", v3), TestCase::QUICK);
EnbUlTestData e3;
@@ -506,35 +506,35 @@
v4.push_back (e3);
v4.push_back (e1);
v4.push_back (e2);
- AddTestCase (new EpcS1uUlTestCase ("3 eNBs", v4));
+ AddTestCase (new EpcS1uUlTestCase ("3 eNBs", v4), TestCase::QUICK);
std::vector<EnbUlTestData> v5;
EnbUlTestData e5;
UeUlTestData f5 (10, 3000, 1, 1);
e5.ues.push_back (f5);
v5.push_back (e5);
- AddTestCase (new EpcS1uUlTestCase ("1 eNB, 10 pkts 3000 bytes each", v5));
+ AddTestCase (new EpcS1uUlTestCase ("1 eNB, 10 pkts 3000 bytes each", v5), TestCase::QUICK);
std::vector<EnbUlTestData> v6;
EnbUlTestData e6;
UeUlTestData f6 (50, 3000, 1, 1);
e6.ues.push_back (f6);
v6.push_back (e6);
- AddTestCase (new EpcS1uUlTestCase ("1 eNB, 50 pkts 3000 bytes each", v6));
+ AddTestCase (new EpcS1uUlTestCase ("1 eNB, 50 pkts 3000 bytes each", v6), TestCase::QUICK);
std::vector<EnbUlTestData> v7;
EnbUlTestData e7;
UeUlTestData f7 (10, 15000, 1, 1);
e7.ues.push_back (f7);
v7.push_back (e7);
- AddTestCase (new EpcS1uUlTestCase ("1 eNB, 10 pkts 15000 bytes each", v7));
+ AddTestCase (new EpcS1uUlTestCase ("1 eNB, 10 pkts 15000 bytes each", v7), TestCase::QUICK);
std::vector<EnbUlTestData> v8;
EnbUlTestData e8;
UeUlTestData f8 (100, 15000, 1, 1);
e8.ues.push_back (f8);
v8.push_back (e8);
- AddTestCase (new EpcS1uUlTestCase ("1 eNB, 100 pkts 15000 bytes each", v8));
+ AddTestCase (new EpcS1uUlTestCase ("1 eNB, 100 pkts 15000 bytes each", v8), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-downlink-sinr.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-downlink-sinr.cc Fri Apr 05 17:59:11 2013 +0200
@@ -82,8 +82,8 @@
(*theoreticalSinr1)[0] = 3.72589167251055;
(*theoreticalSinr1)[1] = 3.72255684126076;
- AddTestCase (new LteDownlinkDataSinrTestCase (rxPsd1, theoreticalSinr1, "sdBm = [-46 -48]"));
- AddTestCase (new LteDownlinkCtrlSinrTestCase (rxPsd1, theoreticalSinr1, "sdBm = [-46 -48]"));
+ AddTestCase (new LteDownlinkDataSinrTestCase (rxPsd1, theoreticalSinr1, "sdBm = [-46 -48]"), TestCase::QUICK);
+ AddTestCase (new LteDownlinkCtrlSinrTestCase (rxPsd1, theoreticalSinr1, "sdBm = [-46 -48]"), TestCase::QUICK);
/**
* TX signal #2: Power Spectral Density (W/Hz) of the signal of interest = [-63 -61] dBm and BW = [20 22] MHz
@@ -96,8 +96,8 @@
(*theoreticalSinr2)[0] = 0.0743413124381667;
(*theoreticalSinr2)[1] = 0.1865697965291756;
- AddTestCase (new LteDownlinkDataSinrTestCase (rxPsd2, theoreticalSinr2, "sdBm = [-63 -61]"));
- AddTestCase (new LteDownlinkCtrlSinrTestCase (rxPsd2, theoreticalSinr2, "sdBm = [-63 -61]"));
+ AddTestCase (new LteDownlinkDataSinrTestCase (rxPsd2, theoreticalSinr2, "sdBm = [-63 -61]"), TestCase::QUICK);
+ AddTestCase (new LteDownlinkCtrlSinrTestCase (rxPsd2, theoreticalSinr2, "sdBm = [-63 -61]"), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-earfcn.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-earfcn.cc Fri Apr 05 17:59:11 2013 +0200
@@ -126,29 +126,29 @@
{
NS_LOG_FUNCTION (this);
- AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=500", 500, 2160e6));
- AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=1000", 1000, 1970e6));
- AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=1301", 1301, 1815.1e6));
- AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=7000", 7000, 0.0));
- AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=20000", 20000, 0.0));
- AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=50000", 50000, 0.0));
+ AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=500", 500, 2160e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=1000", 1000, 1970e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=1301", 1301, 1815.1e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=7000", 7000, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=20000", 20000, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEarfcnDlTestCase ("DL EARFCN=50000", 50000, 0.0), TestCase::QUICK);
- AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=18100", 18100, 1930e6));
- AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=19000", 19000, 1890e6));
- AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=19400", 19400, 1730e6));
- AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=10", 10, 0.0));
- AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=1000", 1000, 0.0));
- AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=50000", 50000, 0.0));
+ AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=18100", 18100, 1930e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=19000", 19000, 1890e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=19400", 19400, 1730e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=10", 10, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=1000", 1000, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEarfcnUlTestCase ("UL EARFCN=50000", 50000, 0.0), TestCase::QUICK);
- AddTestCase (new LteEarfcnTestCase ("EARFCN=500", 500, 2160e6));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=1000", 1000, 1970e6));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=1301", 1301, 1815.1e6));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=8000", 8000, 0.0));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=50000", 50000, 0.0));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=18100", 18100, 1930e6));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=19000", 19000, 1890e6));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=19400", 19400, 1730e6));
- AddTestCase (new LteEarfcnTestCase ("EARFCN=50000", 50000, 0.0));
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=500", 500, 2160e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=1000", 1000, 1970e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=1301", 1301, 1815.1e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=8000", 8000, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=50000", 50000, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=18100", 18100, 1930e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=19000", 19000, 1890e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=19400", 19400, 1730e6), TestCase::QUICK);
+ AddTestCase (new LteEarfcnTestCase ("EARFCN=50000", 50000, 0.0), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-fading.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-fading.cc Fri Apr 05 17:59:11 2013 +0200
@@ -124,7 +124,7 @@
Ptr<BuildingsMobilityModel> mm2 = ueNodes.Get (0)->GetObject<BuildingsMobilityModel> ();
mm2->SetPosition (Vector (distance, 0.0, hm));
- AddTestCase (new LteFadingTestCase (mm1, mm2, 137.93, "OH Urban Large city"));
+ AddTestCase (new LteFadingTestCase (mm1, mm2, 137.93, "OH Urban Large city"), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-fdbet-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-fdbet-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -77,10 +77,10 @@
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/12 UE/TTI -> 184670 bytes/sec
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,0,2196000,2292000, errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,0,749000,749000, errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,0,373000,373000, errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,0,185000,184670, errorModel));
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,0,2196000,2292000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,0,749000,749000, errorModel), TestCase::QUICK);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,0,373000,373000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,0,185000,184670, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 4800 -> MCS 22 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 20 -> 1383 -> 1383000 bytes/sec
@@ -93,10 +93,10 @@
// 6 users -> 4 PRB at Itbs 13 -> 125 -> 125000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/12 UE/TTI -> 62000 bytes/sec
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,4800,1383000,807000, errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,4800,469000,253000, errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,4800,233500,125000, errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,4800,113000,62000, errorModel));
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,4800,1383000,807000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,4800,469000,253000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,4800,233500,125000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,4800,113000,62000, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 14 -> Itbs 13 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 15 -> 775 -> 775000 bytes/sec
@@ -108,10 +108,10 @@
// 3 users -> 8 PRB at Itbs 11 -> 201 -> 201000 bytes/sec
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 bytes/sec
// 12 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/12 UE/TTI -> 48667 bytes/sec
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,6000,775000,621000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,6000,253000,201000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,6000,125000,97000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,6000,61000,48667,errorModel));
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,6000,775000,621000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,6000,253000,201000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,6000,125000,97000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,6000,61000,48667,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 10000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec
@@ -124,10 +124,10 @@
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/12 UE/TTI -> 32667 bytes/sec
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,10000,421000,421000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,10000,137000,137000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,10000,67000,67000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,10000,32000,32667,errorModel));
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,10000,421000,421000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,10000,137000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,10000,67000,67000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,10000,32000,32667,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 20000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec
@@ -140,10 +140,10 @@
// 6 users -> 4 PRB at Itbs 2 -> 22 -> 22000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 2 -> 18 bytes * 8/12 UE/TTI -> 12000 bytes/sec
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,20000,421000,137000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,20000,137000,41000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,20000,67000,22000,errorModel));
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,20000,32000,12000,errorModel));
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (1,0,20000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (3,0,20000,137000,41000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (6,0,20000,67000,22000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase1 (12,0,20000,32000,12000,errorModel), TestCase::EXTENSIVE);
// Test Case 2: fairness check
@@ -165,7 +165,7 @@
estThrFdBetUl.push_back (125000); // User 2 estimated TTI throughput from FDBET
estThrFdBetUl.push_back (85000); // User 3 estimated TTI throughput from FDBET
estThrFdBetUl.push_back (26000); // User 4 estimated TTI throughput from FDBET
- AddTestCase (new LenaFdBetFfMacSchedulerTestCase2 (dist, estAchievableRateDl, estThrFdBetUl, errorModel));
+ AddTestCase (new LenaFdBetFfMacSchedulerTestCase2 (dist, estAchievableRateDl, estThrFdBetUl, errorModel), TestCase::QUICK);
}
static LenaTestFdBetFfMacSchedulerSuite lenaTestFdBetFfMacSchedulerSuite;
--- a/src/lte/test/lte-test-fdmt-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-fdmt-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -79,10 +79,10 @@
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/12 UE/TTI -> 184670 bytes/sec
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,0,2196000,2292000, errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,0,2196000,749000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,0,2196000,373000, errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,0,2196000,184670, errorModel));
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,0,2196000,2292000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,0,2196000,749000,errorModel), TestCase::QUICK);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,0,2196000,373000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,0,2196000,184670, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 4800 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 15 -> 903 -> 903000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -95,10 +95,10 @@
// 6 users -> 4 PRB at Itbs 13 -> 125 -> 125000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/12 UE/TTI -> 62000 bytes/sec
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,4800,903000,807000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,4800,903000,253000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,4800,903000,125000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,4800,903000,62000,errorModel));
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,4800,903000,807000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,4800,903000,253000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,4800,903000,125000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,4800,903000,62000,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
@@ -112,10 +112,10 @@
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/12 UE/TTI -> 48667 bytes/sec
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,6000,775000,621000, errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,6000,775000,201000, errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,6000,775000,97000, errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,6000,775000,48667, errorModel));
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,6000,775000,621000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,6000,775000,201000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,6000,775000,97000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,6000,775000,48667, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 10000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -128,10 +128,10 @@
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/12 UE/TTI -> 32667 bytes/sec
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,10000,421000,437000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,10000,421000,137000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,10000,421000,67000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,10000,421000,32667,errorModel));
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,10000,421000,437000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,10000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,10000,421000,67000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,10000,421000,32667,errorModel), TestCase::EXTENSIVE);
// DONWLINK - DISTANCE 20000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -144,10 +144,10 @@
// 6 users -> 4 PRB at Itbs 2 -> 32 -> 22000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 2 -> 26 bytes * 8/12 UE/TTI -> 12000 bytes/sec
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,20000,421000,41000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,20000,421000,22000,errorModel));
- AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,20000,421000,12000,errorModel));
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (3,0,20000,421000,41000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (6,0,20000,421000,22000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdMtFfMacSchedulerTestCase (12,0,20000,421000,12000,errorModel), TestCase::EXTENSIVE);
}
static LenaTestFdMtFfMacSchedulerSuite lenaTestFdMtFfMacSchedulerSuite;
--- a/src/lte/test/lte-test-fdtbfq-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-fdtbfq-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -90,10 +90,10 @@
// 3 users -> 8 PRB at Itbs 26 -> 749 -> 749000 > 232000 -> throughput = 232000 bytes/sec
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 > 232000 -> throughput = 232000 bytes/sec
// 12 users -> 2 PRB at Itbs 26 -> 185 -> 185000 < 232000 -> throughput = 185000 bytes/sec
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,0,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,0,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,0,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,0,183000,185000,200,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,0,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,0,232000,232000,200,1), TestCase::QUICK);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,0,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,0,183000,185000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 3000 -> MCS 24 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
// DOWNLINK -> DISTANCE 0 -> MCS 28 -> Itbs 26 (from table 7.1.7.2.1-1 of 36.2 13)
@@ -110,10 +110,10 @@
// 3 users -> 8 PRB at Itbs 18 -> 389 -> 389000 > 232000 -> throughput = 232000 bytes/sec
// 6 users -> 4 PRB at Itbs 18 -> 193 -> 193000 < 232000 -> throughput = 193000 bytes/sec
// 12 users -> 2 PRB at Itbs 18 -> 97 -> 97000 < 232000 -> throughput = 97000 bytes/sec
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,3000,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,3000,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,3000,230500,193000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,3000,115250,97000,200,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,3000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,3000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,3000,230500,193000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,3000,115250,97000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -129,10 +129,10 @@
// 3 users -> 8 PRB at Itbs 11 -> 201 -> 201000 < 232000 -> throughput = 201000 bytes/sec
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 < 232000 -> throughput = 97000 bytes/sec
// 12 users -> 2 PRB at Itbs 11 -> 47 -> 47000 < 232000 -> throughput = 47000 bytes/sec
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,6000,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,6000,232000,201000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,6000,150500,97000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,6000,75250,47000,200,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,6000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,6000,232000,201000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,6000,150500,97000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,6000,75250,47000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 9000 -> MCS 12 -> Itbs 11 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -148,10 +148,10 @@
// 3 users -> 8 PRB at Itbs 8 -> 137 -> 137000 < 232000 -> throughput = 137000 bytes/sec
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 < 232000 -> throughput = 67000 bytes/sec
// 12 users -> 2 PRB at Itbs 8 -> 32 -> 32000 < 232000 -> throughput = 32000 bytes/sec
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,9000,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,9000,199000,137000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,9000,99500,67000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,9000,49750,32000,200,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,9000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,9000,199000,137000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,9000,99500,67000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,9000,49750,32000,200,1), TestCase::EXTENSIVE);
// DONWLINK - DISTANCE 15000 -> MCS 6 -> Itbs 6 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -167,10 +167,10 @@
// 3 users -> 8 PRB at Itbs 6 -> 69 -> 69000 < 232000 -> throughput = 69000 bytes/sec
// 6 users -> 4 PRB at Itbs 6 -> 32 -> 32000 < 232000 -> throughput = 32000 bytes/sec
// 12 users -> 2 PRB at Itbs 6 -> 15 -> 15000 < 232000 -> throughput = 15000 bytes/sec
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,15000,232000,232000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,15000,103000,69000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,15000,51500,32000,200,1));
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,15000,25750,15000,200,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (1,0,15000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (3,0,15000,103000,69000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (6,0,15000,51500,32000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase1 (12,0,15000,25750,15000,200,1), TestCase::EXTENSIVE);
// Test Case 2: homogeneous flow test in FDTBFQ (different distance)
// Traffic1 info
@@ -196,7 +196,7 @@
estThrFdTbfqDl1.push_back (132000); // User 2 estimated TTI throughput from FDTBFQ
estThrFdTbfqDl1.push_back (132000); // User 3 estimated TTI throughput from FDTBFQ
estThrFdTbfqDl1.push_back (132000); // User 4 estimated TTI throughput from FDTBFQ
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase2 (dist1,estThrFdTbfqDl1,packetSize1,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase2 (dist1,estThrFdTbfqDl1,packetSize1,1), TestCase::EXTENSIVE);
// Traffic2 info
// UDP traffic: payload size = 200 bytes, interval = 1 ms
@@ -221,7 +221,7 @@
estThrFdTbfqDl2.push_back (138944); // User 2 estimated TTI throughput from FDTBFQ
estThrFdTbfqDl2.push_back (138944); // User 3 estimated TTI throughput from FDTBFQ
estThrFdTbfqDl2.push_back (138944); // User 4 estimated TTI throughput from FDTBFQ
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase2 (dist2,estThrFdTbfqDl2,packetSize2,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase2 (dist2,estThrFdTbfqDl2,packetSize2,1), TestCase::EXTENSIVE);
// Test Case 3: heterogeneous flow test in FDTBFQ
// UDP traffic: payload size = [100,200,300] bytes, interval = 1 ms
@@ -240,7 +240,7 @@
estThrFdTbfqDl3.push_back (132000); // User 0 estimated TTI throughput from FDTBFQ
estThrFdTbfqDl3.push_back (232000); // User 1 estimated TTI throughput from FDTBFQ
estThrFdTbfqDl3.push_back (332000); // User 2 estimated TTI throughput from FDTBFQ
- AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase2 (dist3,estThrFdTbfqDl3,packetSize3,1));
+ AddTestCase (new LenaFdTbfqFfMacSchedulerTestCase2 (dist3,estThrFdTbfqDl3,packetSize3,1), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-interference.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-interference.cc Fri Apr 05 17:59:11 2013 +0200
@@ -68,19 +68,19 @@
LteInterferenceTestSuite::LteInterferenceTestSuite ()
: TestSuite ("lte-interference", SYSTEM)
{
- AddTestCase (new LteInterferenceTestCase ("d1=3000, d2=6000", 3000.000000, 6000.000000, 3.844681, 1.714583, 0.761558, 0.389662, 6, 4));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=10", 50.000000, 10.000000, 0.040000, 0.040000, 0.010399, 0.010399, 0, 0));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=20", 50.000000, 20.000000, 0.160000, 0.159998, 0.041154, 0.041153, 0, 0));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=50", 50.000000, 50.000000, 0.999997, 0.999907, 0.239828, 0.239808, 2, 2));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=100", 50.000000, 100.000000, 3.999955, 3.998520, 0.785259, 0.785042, 6, 6));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=200", 50.000000, 200.000000, 15.999282, 15.976339, 1.961072, 1.959533, 14, 14));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=500", 50.000000, 500.000000, 99.971953, 99.082845, 4.254003, 4.241793, 22, 22));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=1000", 50.000000, 1000.000000, 399.551632, 385.718468, 6.194952, 6.144825, 28, 28));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=10000", 50.000000, 10000.000000, 35964.181431, 8505.970614, 12.667381, 10.588084, 28, 28));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=100000", 50.000000, 100000.000000, 327284.773828, 10774.181090, 15.853097, 10.928917, 28, 28));
- AddTestCase (new LteInterferenceTestCase ("d1=50, d2=1000000", 50.000000, 1000000.000000, 356132.574152, 10802.988445, 15.974963, 10.932767, 28, 28));
- AddTestCase (new LteInterferenceTestCase ("d1=4500, d2=12600", 4500.000000, 12600.000000, 6.654462, 1.139831, 1.139781, 0.270399, 8, 2));
- AddTestCase (new LteInterferenceTestCase ("d1=5400, d2=12600", 5400.000000, 12600.000000, 4.621154, 0.791549, 0.876368, 0.193019, 6, 0));
+ AddTestCase (new LteInterferenceTestCase ("d1=3000, d2=6000", 3000.000000, 6000.000000, 3.844681, 1.714583, 0.761558, 0.389662, 6, 4), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=10", 50.000000, 10.000000, 0.040000, 0.040000, 0.010399, 0.010399, 0, 0), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=20", 50.000000, 20.000000, 0.160000, 0.159998, 0.041154, 0.041153, 0, 0), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=50", 50.000000, 50.000000, 0.999997, 0.999907, 0.239828, 0.239808, 2, 2), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=100", 50.000000, 100.000000, 3.999955, 3.998520, 0.785259, 0.785042, 6, 6), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=200", 50.000000, 200.000000, 15.999282, 15.976339, 1.961072, 1.959533, 14, 14), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=500", 50.000000, 500.000000, 99.971953, 99.082845, 4.254003, 4.241793, 22, 22), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=1000", 50.000000, 1000.000000, 399.551632, 385.718468, 6.194952, 6.144825, 28, 28), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=10000", 50.000000, 10000.000000, 35964.181431, 8505.970614, 12.667381, 10.588084, 28, 28), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=100000", 50.000000, 100000.000000, 327284.773828, 10774.181090, 15.853097, 10.928917, 28, 28), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=50, d2=1000000", 50.000000, 1000000.000000, 356132.574152, 10802.988445, 15.974963, 10.932767, 28, 28), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=4500, d2=12600", 4500.000000, 12600.000000, 6.654462, 1.139831, 1.139781, 0.270399, 8, 2), TestCase::QUICK);
+ AddTestCase (new LteInterferenceTestCase ("d1=5400, d2=12600", 5400.000000, 12600.000000, 4.621154, 0.791549, 0.876368, 0.193019, 6, 0), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-link-adaptation.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-link-adaptation.cc Fri Apr 05 17:59:11 2013 +0200
@@ -124,7 +124,7 @@
std::ostringstream name;
name << " snr= " << snrEfficiencyMcs[i].snrDb << " dB, "
<< " mcs= " << snrEfficiencyMcs[i].mcsIndex;
- AddTestCase (new LteLinkAdaptationTestCase (name.str (), snrEfficiencyMcs[i].snrDb, lossDb, snrEfficiencyMcs[i].mcsIndex));
+ AddTestCase (new LteLinkAdaptationTestCase (name.str (), snrEfficiencyMcs[i].snrDb, lossDb, snrEfficiencyMcs[i].mcsIndex), TestCase::QUICK);
}
}
--- a/src/lte/test/lte-test-mimo.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-mimo.cc Fri Apr 05 17:59:11 2013 +0200
@@ -74,11 +74,10 @@
estThrDl.push_back (119100); // interval 1 : estimated throughput for TxMode 1
estThrDl.push_back (183600); // interval 2 : estimated throughput for TxMode 2
estThrDl.push_back (193400); // interval 3 : estimated throughput for TxMode 3
- AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::RrFfMacScheduler", true));
- AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::PfFfMacScheduler", true));
- AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::RrFfMacScheduler", false));
- AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::PfFfMacScheduler", false));
-
+ AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::RrFfMacScheduler", true), TestCase::QUICK);
+ AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::PfFfMacScheduler", true), TestCase::QUICK);
+ AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::RrFfMacScheduler", false), TestCase::QUICK);
+ AddTestCase (new LenaMimoTestCase(300, estThrDl, "ns3::PfFfMacScheduler", false), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-pathloss-model.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-pathloss-model.cc Fri Apr 05 17:59:11 2013 +0200
@@ -169,7 +169,7 @@
std::ostringstream name;
name << " snr= " << sinrDb << " dB, "
<< " mcs= " << snrEfficiencyMcs[i].mcsIndex;
- AddTestCase (new LtePathlossModelSystemTestCase (name.str (), sinrDb, dist[i], mcs));
+ AddTestCase (new LtePathlossModelSystemTestCase (name.str (), sinrDb, dist[i], mcs), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-pf-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-pf-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -77,11 +77,11 @@
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/12 UE/TTI -> 184670 bytes/sec
// 15 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/15 UE/TTI -> 147730 bytes/sec
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,0,2196000,2292000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,0,732000,749000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,0,366000,373000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,0,183000,184670,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,0,146400,147730,errorModel));
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,0,2196000,2292000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,0,732000,749000,errorModel), TestCase::QUICK);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,0,366000,373000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,0,183000,184670,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,0,146400,147730,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 4800 -> MCS 16 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
@@ -97,11 +97,11 @@
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/12 UE/TTI -> 62000 bytes/sec
// 15 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/15 UE/TTI -> 49600 bytes/sec
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,4800,903000,807000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,4800,301000,253000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,4800,150500,125000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,4800,75250,62000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,4800,60200,49600,errorModel));
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,4800,903000,807000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,4800,301000,253000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,4800,150500,125000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,4800,75250,62000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,4800,60200,49600,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 14 -> Itbs 13 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 15 -> 775 -> 775000 bytes/sec
@@ -116,11 +116,11 @@
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/12 UE/TTI -> 48667 bytes/sec
// 15 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/15 UE/TTI -> 38993 bytes/sec
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,6000,775000,621000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,6000,258000,201000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,6000,129200,97000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,6000,64590,48667,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,6000,51700,38993,errorModel));
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,6000,775000,621000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,6000,258000,201000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,6000,129200,97000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,6000,64590,48667,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,6000,51700,38993,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 10000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec
@@ -135,11 +135,11 @@
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/12 UE/TTI -> 32667 bytes/sec
// 15 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/15 UE/TTI -> 26133 bytes/sec
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,10000,421000,437000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,10000,140333,137000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,10000,70167,67000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,10000,35083,32667,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,10000,28067,26133,errorModel));
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,10000,421000,437000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,10000,140333,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,10000,70167,67000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,10000,35083,32667,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,10000,28067,26133,errorModel), TestCase::EXTENSIVE);
// DONWLINK - DISTANCE 20000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec
@@ -154,11 +154,11 @@
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 2 -> 26 bytes * 8/12 UE/TTI -> 12000 bytes/sec
// 15 users -> 3 PRB at Itbs 2 -> 26 bytes * 8/15 UE/TTI -> 9600 bytes/sec
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,20000,421000,137000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,20000,140333,41000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,20000,70167,22000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,20000,35083,12000,errorModel));
- AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,20000,28067,9600,errorModel));
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (1,0,20000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (3,0,20000,140333,41000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (6,0,20000,70167,22000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (12,0,20000,35083,12000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPfFfMacSchedulerTestCase1 (15,0,20000,28067,9600,errorModel), TestCase::EXTENSIVE);
// Test Case 2: fairness check
@@ -181,7 +181,7 @@
estThrPfUl.push_back (125000); // User 2 estimated TTI throughput from PF
estThrPfUl.push_back (85000); // User 3 estimated TTI throughput from PF
estThrPfUl.push_back (26000); // User 4 estimated TTI throughput from PF
- AddTestCase (new LenaPfFfMacSchedulerTestCase2 (dist, estThrPfDl, estThrPfUl,errorModel));
+ AddTestCase (new LenaPfFfMacSchedulerTestCase2 (dist, estThrPfDl, estThrPfUl,errorModel), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-phy-error-model.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-phy-error-model.cc Fri Apr 05 17:59:11 2013 +0200
@@ -63,28 +63,28 @@
// Tests on DL Control Channels (PCFICH+PDDCH)
// 1 interfering eNB SINR -2.0 BER 0.007 TB size 217
- AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (2, 1078, 217, 0.007));
+ AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (2, 1078, 217, 0.007), TestCase::QUICK);
// 2 interfering eNBs SINR -4.0 BER 0.037 TB size 217
- AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (3, 1040, 217, 0.045));
+ AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (3, 1040, 217, 0.045), TestCase::EXTENSIVE);
// 3 interfering eNBs SINR -6.0 BER 0.21 TB size 133
- AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (4, 1250, 133, 0.206));
+ AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (4, 1250, 133, 0.206), TestCase::EXTENSIVE);
// 4 interfering eNBs SINR -7.0 BER 0.34 TB size 133
- AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (5, 1260, 81, 0.343));
+ AddTestCase (new LenaDlCtrlPhyErrorModelTestCase (5, 1260, 81, 0.343), TestCase::EXTENSIVE);
// Tests on DL/UL Data channels (PDSCH, PUSCH)
// MCS 2 TB size of 256 bits BER 0.33 SINR -5.51
- AddTestCase (new LenaDataPhyErrorModelTestCase (4, 1800, 32, 0.33, 50));
+ AddTestCase (new LenaDataPhyErrorModelTestCase (4, 1800, 32, 0.33, 50), TestCase::QUICK);
// MCS 2 TB size of 528 bits BER 0.11 SINR -5.51
- AddTestCase (new LenaDataPhyErrorModelTestCase (2, 1800, 66, 0.11, 34));
+ AddTestCase (new LenaDataPhyErrorModelTestCase (2, 1800, 66, 0.11, 34), TestCase::EXTENSIVE);
// MCS 2 TB size of 1088 bits BER 0.02 SINR -5.51
- AddTestCase (new LenaDataPhyErrorModelTestCase (1, 1800, 136, 0.02, 16));
+ AddTestCase (new LenaDataPhyErrorModelTestCase (1, 1800, 136, 0.02, 16), TestCase::EXTENSIVE);
// MCS 12 TB size of 4800 bits BER 0.3 SINR 4.43
- AddTestCase (new LenaDataPhyErrorModelTestCase (1, 600, 600, 0.3, 48));
+ AddTestCase (new LenaDataPhyErrorModelTestCase (1, 600, 600, 0.3, 48), TestCase::EXTENSIVE);
// MCS 12 TB size of 1632 bits BER 0.55 SINR 4.43
- AddTestCase (new LenaDataPhyErrorModelTestCase (3, 600, 204, 0.55, 52));
+ AddTestCase (new LenaDataPhyErrorModelTestCase (3, 600, 204, 0.55, 52), TestCase::EXTENSIVE);
// MCS 16 TB size of 7272 bits (3648 x 3584) BER 0.14 SINR 8.48
// BER 0.14 = 1 - ((1-0.075)*(1-0.075))
- AddTestCase (new LenaDataPhyErrorModelTestCase (1, 470, 781, 0.14, 29));
+ AddTestCase (new LenaDataPhyErrorModelTestCase (1, 470, 781, 0.14, 29), TestCase::EXTENSIVE);
--- a/src/lte/test/lte-test-pss-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-pss-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -90,10 +90,10 @@
// 3 users -> 8 PRB at Itbs 26 -> 749 -> 749000 > 232000 -> throughput = 232000 bytes/sec
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 > 232000 -> throughput = 232000 bytes/sec
// 12 users -> 2 PRB at Itbs 26 -> 185 -> 185000 < 232000 -> throughput = 185000 bytes/sec
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,0,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,0,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,0,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,0,183000,185000,200,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,0,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,0,232000,232000,200,1), TestCase::QUICK);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,0,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,0,183000,185000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 3000 -> MCS 24 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
// DOWNLINK -> DISTANCE 0 -> MCS 28 -> Itbs 26 (from table 7.1.7.2.1-1 of 36.2 13)
@@ -110,10 +110,10 @@
// 3 users -> 8 PRB at Itbs 18 -> 389 -> 389000 > 232000 -> throughput = 232000 bytes/sec
// 6 users -> 4 PRB at Itbs 18 -> 193 -> 193000 < 232000 -> throughput = 193000 bytes/sec
// 12 users -> 2 PRB at Itbs 18 -> 97 -> 97000 < 232000 -> throughput = 97000 bytes/sec
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,3000,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,3000,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,3000,230500,193000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,3000,115250,97000,200,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,3000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,3000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,3000,230500,193000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,3000,115250,97000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -129,10 +129,10 @@
// 3 users -> 8 PRB at Itbs 11 -> 201 -> 201000 < 232000 -> throughput = 201000 bytes/sec
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 < 232000 -> throughput = 97000 bytes/sec
// 12 users -> 2 PRB at Itbs 11 -> 47 -> 47000 < 232000 -> throughput = 47000 bytes/sec
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,6000,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,6000,232000,201000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,6000,150500,97000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,6000,75250,47000,200,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,6000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,6000,232000,201000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,6000,150500,97000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,6000,75250,47000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 9000 -> MCS 12 -> Itbs 11 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -148,10 +148,10 @@
// 3 users -> 8 PRB at Itbs 8 -> 137 -> 137000 < 232000 -> throughput = 137000 bytes/sec
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 < 232000 -> throughput = 67000 bytes/sec
// 12 users -> 2 PRB at Itbs 8 -> 32 -> 32000 < 232000 -> throughput = 32000 bytes/sec
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,9000,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,9000,199000,137000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,9000,99500,67000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,9000,49750,32000,200,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,9000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,9000,199000,137000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,9000,99500,67000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,9000,49750,32000,200,1), TestCase::EXTENSIVE);
// DONWLINK - DISTANCE 15000 -> MCS 6 -> Itbs 6 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -167,10 +167,10 @@
// 3 users -> 8 PRB at Itbs 6 -> 69 -> 69000 < 232000 -> throughput = 69000 bytes/sec
// 6 users -> 4 PRB at Itbs 6 -> 32 -> 32000 < 232000 -> throughput = 32000 bytes/sec
// 12 users -> 2 PRB at Itbs 6 -> 15 -> 15000 < 232000 -> throughput = 15000 bytes/sec
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,15000,232000,232000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,15000,103000,69000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,15000,51500,32000,200,1));
- AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,15000,25750,15000,200,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (1,0,15000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (3,0,15000,103000,69000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (6,0,15000,51500,32000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaPssFfMacSchedulerTestCase1 (12,0,15000,25750,15000,200,1), TestCase::EXTENSIVE);
// Test Case 2: homogeneous flow test in PSS (different distance)
// Traffic1 info
@@ -196,7 +196,7 @@
estThrPssDl1.push_back (132000);
estThrPssDl1.push_back (132000);
estThrPssDl1.push_back (132000);
- AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist1,estThrPssDl1,packetSize1,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist1,estThrPssDl1,packetSize1,1), TestCase::EXTENSIVE);
// Traffic2 info
// UDP traffic: payload size = 200 bytes, interval = 1 ms
@@ -221,7 +221,7 @@
estThrPssDl2.push_back (138944);
estThrPssDl2.push_back (138944);
estThrPssDl2.push_back (138944);
- AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist2,estThrPssDl2,packetSize2,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist2,estThrPssDl2,packetSize2,1), TestCase::EXTENSIVE);
// Test Case 3: : heterogeneous flow test in PSS (same distance)
// Traffic3 info:
@@ -247,7 +247,7 @@
estThrPssDl3.push_back (332000);
estThrPssDl3.push_back (432000);
estThrPssDl3.push_back (532000);
- AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist3,estThrPssDl3,packetSize3,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist3,estThrPssDl3,packetSize3,1), TestCase::EXTENSIVE);
// Test Case 4: heterogeneous flow test in PSS (different distance)
@@ -268,7 +268,7 @@
estThrPssDl4.push_back (132000); // User 0 estimated TTI throughput from PSS
estThrPssDl4.push_back (232000); // User 1 estimated TTI throughput from PSS
estThrPssDl4.push_back (332000); // User 2 estimated TTI throughput from PSS
- AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist4,estThrPssDl4,packetSize4,1));
+ AddTestCase (new LenaPssFfMacSchedulerTestCase2 (dist4,estThrPssDl4,packetSize4,1), TestCase::QUICK);
}
static LenaTestPssFfMacSchedulerSuite lenaTestPssFfMacSchedulerSuite;
--- a/src/lte/test/lte-test-rlc-am-e2e.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-rlc-am-e2e.cc Fri Apr 05 17:59:11 2013 +0200
@@ -64,7 +64,16 @@
{
std::ostringstream name;
name << " Losses = " << losses[l] * 100 << "%. Seed = " << seeds[s];
- AddTestCase (new LteRlcAmE2eTestCase (name.str (), seeds[s], losses[l]));
+ TestCase::TestDuration testDuration;
+ if (l == 1 && s == 0)
+ {
+ testDuration = TestCase::QUICK;
+ }
+ else
+ {
+ testDuration = TestCase::EXTENSIVE;
+ }
+ AddTestCase (new LteRlcAmE2eTestCase (name.str (), seeds[s], losses[l]), testDuration);
}
}
}
--- a/src/lte/test/lte-test-rlc-am-transmitter.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-rlc-am-transmitter.cc Fri Apr 05 17:59:11 2013 +0200
@@ -42,10 +42,10 @@
// LogLevel logLevel = (LogLevel)(LOG_PREFIX_FUNC | LOG_PREFIX_TIME | LOG_LEVEL_ALL);
// LogComponentEnable ("LteRlcAmTransmitterTest", logLevel);
- AddTestCase (new LteRlcAmTransmitterOneSduTestCase ("One SDU, one PDU"));
- AddTestCase (new LteRlcAmTransmitterSegmentationTestCase ("Segmentation"));
- AddTestCase (new LteRlcAmTransmitterConcatenationTestCase ("Concatenation"));
- AddTestCase (new LteRlcAmTransmitterReportBufferStatusTestCase ("ReportBufferStatus primitive"));
+ AddTestCase (new LteRlcAmTransmitterOneSduTestCase ("One SDU, one PDU"), TestCase::QUICK);
+ AddTestCase (new LteRlcAmTransmitterSegmentationTestCase ("Segmentation"), TestCase::QUICK);
+ AddTestCase (new LteRlcAmTransmitterConcatenationTestCase ("Concatenation"), TestCase::QUICK);
+ AddTestCase (new LteRlcAmTransmitterReportBufferStatusTestCase ("ReportBufferStatus primitive"), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-rlc-um-e2e.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-rlc-um-e2e.cc Fri Apr 05 17:59:11 2013 +0200
@@ -63,7 +63,16 @@
{
std::ostringstream name;
name << " Losses = " << losses[l] << "%. Seed = " << seeds[s];
- AddTestCase (new LteRlcUmE2eTestCase (name.str (), seeds[s], losses[l]));
+ TestCase::TestDuration testDuration;
+ if (l == 1 && s == 0)
+ {
+ testDuration = TestCase::QUICK;
+ }
+ else
+ {
+ testDuration = TestCase::EXTENSIVE;
+ }
+ AddTestCase (new LteRlcUmE2eTestCase (name.str (), seeds[s], losses[l]), testDuration);
}
}
}
--- a/src/lte/test/lte-test-rlc-um-transmitter.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-rlc-um-transmitter.cc Fri Apr 05 17:59:11 2013 +0200
@@ -44,10 +44,10 @@
// NS_LOG_INFO ("Creating LteRlcUmTransmitterTestSuite");
- AddTestCase (new LteRlcUmTransmitterOneSduTestCase ("One SDU, one PDU"));
- AddTestCase (new LteRlcUmTransmitterSegmentationTestCase ("Segmentation"));
- AddTestCase (new LteRlcUmTransmitterConcatenationTestCase ("Concatenation"));
- AddTestCase (new LteRlcUmTransmitterReportBufferStatusTestCase ("ReportBufferStatus primitive"));
+ AddTestCase (new LteRlcUmTransmitterOneSduTestCase ("One SDU, one PDU"), TestCase::QUICK);
+ AddTestCase (new LteRlcUmTransmitterSegmentationTestCase ("Segmentation"), TestCase::QUICK);
+ AddTestCase (new LteRlcUmTransmitterConcatenationTestCase ("Concatenation"), TestCase::QUICK);
+ AddTestCase (new LteRlcUmTransmitterReportBufferStatusTestCase ("ReportBufferStatus primitive"), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-rr-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-rr-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -76,12 +76,12 @@
// 9 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/9 UE/TTI -> 246220 bytes/sec
// 12 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/12 UE/TTI -> 184670 bytes/sec
// 15 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/15 UE/TTI -> 147730 bytes/sec
- AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,0,2196000,2292000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,0,749000,749000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,0,373000,373000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,0,185000,246220,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,0,185000,184670,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,0,148000,147730,errorModel));
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,0,2196000,2292000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,0,749000,749000,errorModel), TestCase::QUICK);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,0,373000,373000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,0,185000,246220,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,0,185000,184670,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,0,148000,147730,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 4800 -> MCS 22 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 20 -> 1383 -> 1383000 bytes/sec
@@ -98,12 +98,12 @@
// 9 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/9 UE/TTI -> 82667 bytes/sec
// 12 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/12 UE/TTI -> 62000 bytes/sec
// 15 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/15 UE/TTI -> 49600 bytes/sec
- AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,4800,1383000,807000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,4800,469000,253000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,4800,233000,125000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,4800,113000,82667,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,4800,113000,62000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,4800,90400,49600,errorModel));
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,4800,1383000,807000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,4800,469000,253000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,4800,233000,125000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,4800,113000,82667,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,4800,113000,62000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,4800,90400,49600,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 14 -> Itbs 13 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 15 -> 775 -> 775000 bytes/sec
@@ -119,12 +119,12 @@
// 9 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/9 UE/TTI -> 64889 bytes/sec
// 12 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/12 UE/TTI -> 48667 bytes/sec
// 15 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/15 UE/TTI -> 38993 bytes/sec
- AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,6000,775000,621000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,6000,253000,201000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,6000,125000,97000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,6000,61000,64889,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,6000,61000,48667,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,6000,48800,38993,errorModel));
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,6000,775000,621000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,6000,253000,201000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,6000,125000,97000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,6000,61000,64889,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,6000,61000,48667,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,6000,48800,38993,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 10000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 437 -> 437000 bytes/sec
@@ -141,12 +141,12 @@
// 9 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/9 UE/TTI -> 43556 bytes/sec
// 12 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/12 UE/TTI -> 32667 bytes/sec
// 15 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/15 UE/TTI -> 26133 bytes/sec
- AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,10000,437000,437000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,10000,137000,137000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,10000,67000,67000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,10000,32000,43556,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,10000,32000,32667,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,10000,25600,26133,errorModel));
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,10000,437000,437000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,10000,137000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,10000,67000,67000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,10000,32000,43556,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,10000,32000,32667,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,10000,25600,26133,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 20000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec
@@ -163,12 +163,12 @@
// 9 users -> 3 PRB at Itbs 2 -> 18 bytes * 8/9 UE/TTI -> 16000 bytes/sec
// 12 users -> 3 PRB at Itbs 2 -> 18 bytes * 8/12 UE/TTI -> 12000 bytes/sec
// 15 users -> 3 PRB at Itbs 2 -> 18 bytes * 8/15 UE/TTI -> 9600 bytes/sec
- AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,20000,137000,41000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,20000,67000,22000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,20000,32000,16000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,20000,32000,12000,errorModel));
- AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,20000,25600,9600,errorModel));
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (3,0,20000,137000,41000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (6,0,20000,67000,22000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (9,0,20000,32000,16000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (12,0,20000,32000,12000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaRrFfMacSchedulerTestCase (15,0,20000,25600,9600,errorModel), TestCase::EXTENSIVE);
}
--- a/src/lte/test/lte-test-spectrum-value-helper.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-spectrum-value-helper.cc Fri Apr 05 17:59:11 2013 +0200
@@ -167,7 +167,7 @@
fc2160nrb6[3] = 2.160090000000e+09;
fc2160nrb6[4] = 2.160270000000e+09;
fc2160nrb6[5] = 2.160450000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb6", 500, 6, fc2160nrb6));
+ AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb6", 500, 6, fc2160nrb6), TestCase::QUICK);
std::vector<double> fc2160nrb15 (15);
fc2160nrb15[0] = 2.158740000000e+09;
@@ -185,7 +185,7 @@
fc2160nrb15[12] = 2.160900000000e+09;
fc2160nrb15[13] = 2.161080000000e+09;
fc2160nrb15[14] = 2.161260000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb15", 500, 15, fc2160nrb15));
+ AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb15", 500, 15, fc2160nrb15), TestCase::QUICK);
std::vector<double> fc2160nrb25 (25);
fc2160nrb25[0] = 2.157840000000e+09;
@@ -213,7 +213,7 @@
fc2160nrb25[22] = 2.161800000000e+09;
fc2160nrb25[23] = 2.161980000000e+09;
fc2160nrb25[24] = 2.162160000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb25", 500, 25, fc2160nrb25));
+ AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb25", 500, 25, fc2160nrb25), TestCase::QUICK);
std::vector<double> fc2160nrb50 (50);
fc2160nrb50[0] = 2.155590000000e+09;
@@ -266,7 +266,7 @@
fc2160nrb50[47] = 2.164050000000e+09;
fc2160nrb50[48] = 2.164230000000e+09;
fc2160nrb50[49] = 2.164410000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb50", 500, 50, fc2160nrb50));
+ AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb50", 500, 50, fc2160nrb50), TestCase::QUICK);
std::vector<double> fc2160nrb75 (75);
fc2160nrb75[0] = 2.153340000000e+09;
@@ -344,7 +344,7 @@
fc2160nrb75[72] = 2.166300000000e+09;
fc2160nrb75[73] = 2.166480000000e+09;
fc2160nrb75[74] = 2.166660000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb75", 500, 75, fc2160nrb75));
+ AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb75", 500, 75, fc2160nrb75), TestCase::QUICK);
std::vector<double> fc2160nrb100 (100);
fc2160nrb100[0] = 2.151090000000e+09;
@@ -447,7 +447,7 @@
fc2160nrb100[97] = 2.168550000000e+09;
fc2160nrb100[98] = 2.168730000000e+09;
fc2160nrb100[99] = 2.168910000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb100", 500, 100, fc2160nrb100));
+ AddTestCase (new LteSpectrumModelTestCase ("fc2160nrb100", 500, 100, fc2160nrb100), TestCase::QUICK);
std::vector<double> fc1730nrb6 (6);
fc1730nrb6[0] = 1.729550000000e+09;
@@ -456,7 +456,7 @@
fc1730nrb6[3] = 1.730090000000e+09;
fc1730nrb6[4] = 1.730270000000e+09;
fc1730nrb6[5] = 1.730450000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb6", 19400, 6, fc1730nrb6));
+ AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb6", 19400, 6, fc1730nrb6), TestCase::QUICK);
std::vector<double> fc1730nrb15 (15);
fc1730nrb15[0] = 1.728740000000e+09;
@@ -474,7 +474,7 @@
fc1730nrb15[12] = 1.730900000000e+09;
fc1730nrb15[13] = 1.731080000000e+09;
fc1730nrb15[14] = 1.731260000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb15", 19400, 15, fc1730nrb15));
+ AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb15", 19400, 15, fc1730nrb15), TestCase::QUICK);
std::vector<double> fc1730nrb25 (25);
fc1730nrb25[0] = 1.727840000000e+09;
@@ -502,7 +502,7 @@
fc1730nrb25[22] = 1.731800000000e+09;
fc1730nrb25[23] = 1.731980000000e+09;
fc1730nrb25[24] = 1.732160000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb25", 19400, 25, fc1730nrb25));
+ AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb25", 19400, 25, fc1730nrb25), TestCase::QUICK);
std::vector<double> fc1730nrb50 (50);
fc1730nrb50[0] = 1.725590000000e+09;
@@ -555,7 +555,7 @@
fc1730nrb50[47] = 1.734050000000e+09;
fc1730nrb50[48] = 1.734230000000e+09;
fc1730nrb50[49] = 1.734410000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb50", 19400, 50, fc1730nrb50));
+ AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb50", 19400, 50, fc1730nrb50), TestCase::QUICK);
std::vector<double> fc1730nrb75 (75);
fc1730nrb75[0] = 1.723340000000e+09;
@@ -633,7 +633,7 @@
fc1730nrb75[72] = 1.736300000000e+09;
fc1730nrb75[73] = 1.736480000000e+09;
fc1730nrb75[74] = 1.736660000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb75", 19400, 75, fc1730nrb75));
+ AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb75", 19400, 75, fc1730nrb75), TestCase::QUICK);
std::vector<double> fc1730nrb100 (100);
fc1730nrb100[0] = 1.721090000000e+09;
@@ -736,7 +736,7 @@
fc1730nrb100[97] = 1.738550000000e+09;
fc1730nrb100[98] = 1.738730000000e+09;
fc1730nrb100[99] = 1.738910000000e+09;
- AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb100", 19400, 100, fc1730nrb100));
+ AddTestCase (new LteSpectrumModelTestCase ("fc1730nrb100", 19400, 100, fc1730nrb100), TestCase::QUICK);
SpectrumValue nfdB0earfcn500nrb6 (LteSpectrumValueHelper::GetSpectrumModel (500, 6));
@@ -746,7 +746,7 @@
nfdB0earfcn500nrb6[3] = 4.002000000000e-21;
nfdB0earfcn500nrb6[4] = 4.002000000000e-21;
nfdB0earfcn500nrb6[5] = 4.002000000000e-21;
- AddTestCase (new LteNoisePsdTestCase ("nfdB0earfcn500nrb6", 500, 6, 0.000000, nfdB0earfcn500nrb6));
+ AddTestCase (new LteNoisePsdTestCase ("nfdB0earfcn500nrb6", 500, 6, 0.000000, nfdB0earfcn500nrb6), TestCase::QUICK);
SpectrumValue nfdB5earfcn500nrb6 (LteSpectrumValueHelper::GetSpectrumModel (500, 6));
nfdB5earfcn500nrb6[0] = 1.265543519599e-20;
@@ -755,7 +755,7 @@
nfdB5earfcn500nrb6[3] = 1.265543519599e-20;
nfdB5earfcn500nrb6[4] = 1.265543519599e-20;
nfdB5earfcn500nrb6[5] = 1.265543519599e-20;
- AddTestCase (new LteNoisePsdTestCase ("nfdB5earfcn500nrb6", 500, 6, 5.000000, nfdB5earfcn500nrb6));
+ AddTestCase (new LteNoisePsdTestCase ("nfdB5earfcn500nrb6", 500, 6, 5.000000, nfdB5earfcn500nrb6), TestCase::QUICK);
SpectrumValue nfdB10earfcn500nrb6 (LteSpectrumValueHelper::GetSpectrumModel (500, 6));
nfdB10earfcn500nrb6[0] = 4.002000000000e-20;
@@ -764,7 +764,7 @@
nfdB10earfcn500nrb6[3] = 4.002000000000e-20;
nfdB10earfcn500nrb6[4] = 4.002000000000e-20;
nfdB10earfcn500nrb6[5] = 4.002000000000e-20;
- AddTestCase (new LteNoisePsdTestCase ("nfdB10earfcn500nrb6", 500, 6, 10.000000, nfdB10earfcn500nrb6));
+ AddTestCase (new LteNoisePsdTestCase ("nfdB10earfcn500nrb6", 500, 6, 10.000000, nfdB10earfcn500nrb6), TestCase::QUICK);
SpectrumValue nfdB0earfcn500nrb15 (LteSpectrumValueHelper::GetSpectrumModel (500, 15));
nfdB0earfcn500nrb15[0] = 4.002000000000e-21;
@@ -782,7 +782,7 @@
nfdB0earfcn500nrb15[12] = 4.002000000000e-21;
nfdB0earfcn500nrb15[13] = 4.002000000000e-21;
nfdB0earfcn500nrb15[14] = 4.002000000000e-21;
- AddTestCase (new LteNoisePsdTestCase ("nfdB0earfcn500nrb15", 500, 15, 0.000000, nfdB0earfcn500nrb15));
+ AddTestCase (new LteNoisePsdTestCase ("nfdB0earfcn500nrb15", 500, 15, 0.000000, nfdB0earfcn500nrb15), TestCase::QUICK);
SpectrumValue nfdB5earfcn500nrb15 (LteSpectrumValueHelper::GetSpectrumModel (500, 15));
nfdB5earfcn500nrb15[0] = 1.265543519599e-20;
@@ -800,7 +800,7 @@
nfdB5earfcn500nrb15[12] = 1.265543519599e-20;
nfdB5earfcn500nrb15[13] = 1.265543519599e-20;
nfdB5earfcn500nrb15[14] = 1.265543519599e-20;
- AddTestCase (new LteNoisePsdTestCase ("nfdB5earfcn500nrb15", 500, 15, 5.000000, nfdB5earfcn500nrb15));
+ AddTestCase (new LteNoisePsdTestCase ("nfdB5earfcn500nrb15", 500, 15, 5.000000, nfdB5earfcn500nrb15), TestCase::QUICK);
SpectrumValue nfdB10earfcn500nrb15 (LteSpectrumValueHelper::GetSpectrumModel (500, 15));
nfdB10earfcn500nrb15[0] = 4.002000000000e-20;
@@ -830,7 +830,7 @@
spectrumValue_txpowdB10nrb6run1earfcn500[3] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb6run1earfcn500[4] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb6run1earfcn500[5] = 0.000000000000e+00;
- AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb6run1earfcn500", 500, 6, 10.000000, activeRbs_txpowdB10nrb6run1earfcn500, spectrumValue_txpowdB10nrb6run1earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb6run1earfcn500", 500, 6, 10.000000, activeRbs_txpowdB10nrb6run1earfcn500, spectrumValue_txpowdB10nrb6run1earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB30nrb6run1earfcn500 (1);
activeRbs_txpowdB30nrb6run1earfcn500[0] = 5.000000000000e+00;
@@ -841,7 +841,7 @@
spectrumValue_txpowdB30nrb6run1earfcn500[3] = 0.000000000000e+00;
spectrumValue_txpowdB30nrb6run1earfcn500[4] = 0.000000000000e+00;
spectrumValue_txpowdB30nrb6run1earfcn500[5] = 9.259259259259e-07;
- AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb6run1earfcn500", 500, 6, 30.000000, activeRbs_txpowdB30nrb6run1earfcn500, spectrumValue_txpowdB30nrb6run1earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb6run1earfcn500", 500, 6, 30.000000, activeRbs_txpowdB30nrb6run1earfcn500, spectrumValue_txpowdB30nrb6run1earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB10nrb25run1earfcn500 (8);
activeRbs_txpowdB10nrb25run1earfcn500[0] = 1.000000000000e+00;
@@ -878,7 +878,7 @@
spectrumValue_txpowdB10nrb25run1earfcn500[22] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb25run1earfcn500[23] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb25run1earfcn500[24] = 2.222222222222e-09;
- AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb25run1earfcn500", 500, 25, 10.000000, activeRbs_txpowdB10nrb25run1earfcn500, spectrumValue_txpowdB10nrb25run1earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb25run1earfcn500", 500, 25, 10.000000, activeRbs_txpowdB10nrb25run1earfcn500, spectrumValue_txpowdB10nrb25run1earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB30nrb25run1earfcn500 (13);
activeRbs_txpowdB30nrb25run1earfcn500[0] = 0.000000000000e+00;
@@ -920,7 +920,7 @@
spectrumValue_txpowdB30nrb25run1earfcn500[22] = 0.000000000000e+00;
spectrumValue_txpowdB30nrb25run1earfcn500[23] = 0.000000000000e+00;
spectrumValue_txpowdB30nrb25run1earfcn500[24] = 2.222222222222e-07;
- AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb25run1earfcn500", 500, 25, 30.000000, activeRbs_txpowdB30nrb25run1earfcn500, spectrumValue_txpowdB30nrb25run1earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb25run1earfcn500", 500, 25, 30.000000, activeRbs_txpowdB30nrb25run1earfcn500, spectrumValue_txpowdB30nrb25run1earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB10nrb100run1earfcn500 (60);
activeRbs_txpowdB10nrb100run1earfcn500[0] = 0.000000000000e+00;
@@ -1084,7 +1084,7 @@
spectrumValue_txpowdB10nrb100run1earfcn500[97] = 5.555555555556e-10;
spectrumValue_txpowdB10nrb100run1earfcn500[98] = 5.555555555556e-10;
spectrumValue_txpowdB10nrb100run1earfcn500[99] = 0.000000000000e+00;
- AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb100run1earfcn500", 500, 100, 10.000000, activeRbs_txpowdB10nrb100run1earfcn500, spectrumValue_txpowdB10nrb100run1earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb100run1earfcn500", 500, 100, 10.000000, activeRbs_txpowdB10nrb100run1earfcn500, spectrumValue_txpowdB10nrb100run1earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB30nrb100run1earfcn500 (39);
activeRbs_txpowdB30nrb100run1earfcn500[0] = 0.000000000000e+00;
@@ -1227,7 +1227,7 @@
spectrumValue_txpowdB30nrb100run1earfcn500[97] = 0.000000000000e+00;
spectrumValue_txpowdB30nrb100run1earfcn500[98] = 5.555555555556e-08;
spectrumValue_txpowdB30nrb100run1earfcn500[99] = 5.555555555556e-08;
- AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb100run1earfcn500", 500, 100, 30.000000, activeRbs_txpowdB30nrb100run1earfcn500, spectrumValue_txpowdB30nrb100run1earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb100run1earfcn500", 500, 100, 30.000000, activeRbs_txpowdB30nrb100run1earfcn500, spectrumValue_txpowdB30nrb100run1earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB10nrb6run2earfcn500 (3);
activeRbs_txpowdB10nrb6run2earfcn500[0] = 1.000000000000e+00;
@@ -1240,7 +1240,7 @@
spectrumValue_txpowdB10nrb6run2earfcn500[3] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb6run2earfcn500[4] = 9.259259259259e-09;
spectrumValue_txpowdB10nrb6run2earfcn500[5] = 9.259259259259e-09;
- AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb6run2earfcn500", 500, 6, 10.000000, activeRbs_txpowdB10nrb6run2earfcn500, spectrumValue_txpowdB10nrb6run2earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb6run2earfcn500", 500, 6, 10.000000, activeRbs_txpowdB10nrb6run2earfcn500, spectrumValue_txpowdB10nrb6run2earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB30nrb6run2earfcn500 (3);
activeRbs_txpowdB30nrb6run2earfcn500[0] = 3.000000000000e+00;
@@ -1253,7 +1253,7 @@
spectrumValue_txpowdB30nrb6run2earfcn500[3] = 9.259259259259e-07;
spectrumValue_txpowdB30nrb6run2earfcn500[4] = 9.259259259259e-07;
spectrumValue_txpowdB30nrb6run2earfcn500[5] = 9.259259259259e-07;
- AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb6run2earfcn500", 500, 6, 30.000000, activeRbs_txpowdB30nrb6run2earfcn500, spectrumValue_txpowdB30nrb6run2earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb6run2earfcn500", 500, 6, 30.000000, activeRbs_txpowdB30nrb6run2earfcn500, spectrumValue_txpowdB30nrb6run2earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB10nrb25run2earfcn500 (15);
activeRbs_txpowdB10nrb25run2earfcn500[0] = 0.000000000000e+00;
@@ -1297,7 +1297,7 @@
spectrumValue_txpowdB10nrb25run2earfcn500[22] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb25run2earfcn500[23] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb25run2earfcn500[24] = 2.222222222222e-09;
- AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb25run2earfcn500", 500, 25, 10.000000, activeRbs_txpowdB10nrb25run2earfcn500, spectrumValue_txpowdB10nrb25run2earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb25run2earfcn500", 500, 25, 10.000000, activeRbs_txpowdB10nrb25run2earfcn500, spectrumValue_txpowdB10nrb25run2earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB30nrb25run2earfcn500 (13);
activeRbs_txpowdB30nrb25run2earfcn500[0] = 0.000000000000e+00;
@@ -1339,7 +1339,7 @@
spectrumValue_txpowdB30nrb25run2earfcn500[22] = 0.000000000000e+00;
spectrumValue_txpowdB30nrb25run2earfcn500[23] = 2.222222222222e-07;
spectrumValue_txpowdB30nrb25run2earfcn500[24] = 2.222222222222e-07;
- AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb25run2earfcn500", 500, 25, 30.000000, activeRbs_txpowdB30nrb25run2earfcn500, spectrumValue_txpowdB30nrb25run2earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb25run2earfcn500", 500, 25, 30.000000, activeRbs_txpowdB30nrb25run2earfcn500, spectrumValue_txpowdB30nrb25run2earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB10nrb100run2earfcn500 (48);
activeRbs_txpowdB10nrb100run2earfcn500[0] = 2.000000000000e+00;
@@ -1491,7 +1491,7 @@
spectrumValue_txpowdB10nrb100run2earfcn500[97] = 5.555555555556e-10;
spectrumValue_txpowdB10nrb100run2earfcn500[98] = 0.000000000000e+00;
spectrumValue_txpowdB10nrb100run2earfcn500[99] = 0.000000000000e+00;
- AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb100run2earfcn500", 500, 100, 10.000000, activeRbs_txpowdB10nrb100run2earfcn500, spectrumValue_txpowdB10nrb100run2earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB10nrb100run2earfcn500", 500, 100, 10.000000, activeRbs_txpowdB10nrb100run2earfcn500, spectrumValue_txpowdB10nrb100run2earfcn500), TestCase::QUICK);
std::vector<int> activeRbs_txpowdB30nrb100run2earfcn500 (52);
activeRbs_txpowdB30nrb100run2earfcn500[0] = 0.000000000000e+00;
@@ -1647,7 +1647,7 @@
spectrumValue_txpowdB30nrb100run2earfcn500[97] = 0.000000000000e+00;
spectrumValue_txpowdB30nrb100run2earfcn500[98] = 5.555555555556e-08;
spectrumValue_txpowdB30nrb100run2earfcn500[99] = 5.555555555556e-08;
- AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb100run2earfcn500", 500, 100, 30.000000, activeRbs_txpowdB30nrb100run2earfcn500, spectrumValue_txpowdB30nrb100run2earfcn500));
+ AddTestCase (new LteTxPsdTestCase ("txpowdB30nrb100run2earfcn500", 500, 100, 30.000000, activeRbs_txpowdB30nrb100run2earfcn500, spectrumValue_txpowdB30nrb100run2earfcn500), TestCase::QUICK);
--- a/src/lte/test/lte-test-tdbet-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-tdbet-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -77,10 +77,10 @@
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/12 UE/TTI -> 184670 bytes/sec
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,0,2196000,2292000, errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,0,732000,749000, errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,0,366000,373000, errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,0,183000,184670, errorModel));
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,0,2196000,2292000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,0,732000,749000, errorModel), TestCase::QUICK);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,0,366000,373000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,0,183000,184670, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 4800 -> MCS 22 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 20 -> 1383 -> 1383000 bytes/sec
@@ -93,10 +93,10 @@
// 6 users -> 4 PRB at Itbs 13 -> 125 -> 125000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/12 UE/TTI -> 62000 bytes/sec
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,4800,1383000,807000, errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,4800,461000,253000, errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,4800,230500,125000, errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,4800,115250,62000, errorModel));
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,4800,1383000,807000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,4800,461000,253000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,4800,230500,125000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,4800,115250,62000, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 14 -> Itbs 13 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 13 -> 775 -> 775000 bytes/sec
@@ -108,10 +108,10 @@
// 3 users -> 8 PRB at Itbs 11 -> 201 -> 201000 bytes/sec
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 bytes/sec
// 12 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/12 UE/TTI -> 48667 bytes/sec
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,6000,775000,621000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,6000,258333,201000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,6000,129166,97000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,6000,64583,48667,errorModel));
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,6000,775000,621000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,6000,258333,201000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,6000,129166,97000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,6000,64583,48667,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 10000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec
@@ -124,10 +124,10 @@
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/12 UE/TTI -> 32667 bytes/sec
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,10000,421000,421000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,10000,140333,137000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,10000,70166,67000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,10000,35083,32667,errorModel));
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,10000,421000,421000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,10000,140333,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,10000,70166,67000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,10000,35083,32667,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 20000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec
@@ -140,10 +140,10 @@
// 6 users -> 4 PRB at Itbs 2 -> 22 -> 22000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 2 -> 18 bytes * 8/12 UE/TTI -> 12000 bytes/sec
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,20000,421000,137000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,20000,140333,41000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,20000,70166,22000,errorModel));
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,20000,35083,12000,errorModel));
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (1,0,20000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (3,0,20000,140333,41000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (6,0,20000,70166,22000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase1 (12,0,20000,35083,12000,errorModel), TestCase::EXTENSIVE);
// Test Case 2: fairness check
@@ -165,7 +165,7 @@
estThrTdBetUl.push_back (125000); // User 2 estimated TTI throughput from TDBET
estThrTdBetUl.push_back (85000); // User 3 estimated TTI throughput from TDBET
estThrTdBetUl.push_back (26000); // User 4 estimated TTI throughput from TDBET
- AddTestCase (new LenaTdBetFfMacSchedulerTestCase2 (dist, estAchievableRateDl, estThrTdBetUl, errorModel));
+ AddTestCase (new LenaTdBetFfMacSchedulerTestCase2 (dist, estAchievableRateDl, estThrTdBetUl, errorModel), TestCase::QUICK);
}
static LenaTestTdBetFfMacSchedulerSuite lenaTestTdBetFfMacSchedulerSuite;
--- a/src/lte/test/lte-test-tdmt-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-tdmt-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -79,10 +79,10 @@
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/12 UE/TTI -> 184670 bytes/sec
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,0,2196000,2292000, errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,0,2196000,749000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,0,2196000,373000, errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,0,2196000,184670, errorModel));
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,0,2196000,2292000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,0,2196000,749000,errorModel), TestCase::QUICK);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,0,2196000,373000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,0,2196000,184670, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 4800 -> MCS 22 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 20 -> 1383 -> 1383000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -95,10 +95,10 @@
// 6 users -> 4 PRB at Itbs 13 -> 125 -> 125000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/12 UE/TTI -> 62000 bytes/sec
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,4800,1383000,807000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,4800,1383000,253000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,4800,1383000,125000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,4800,1383000,62000,errorModel));
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,4800,1383000,807000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,4800,1383000,253000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,4800,1383000,125000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,4800,1383000,62000,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 15 -> 775 -> 775000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -111,10 +111,10 @@
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/12 UE/TTI -> 48667 bytes/sec
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,6000,775000,621000, errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,6000,775000,201000, errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,6000,775000,97000, errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,6000,775000,48667, errorModel));
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,6000,775000,621000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,6000,775000,201000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,6000,775000,97000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,6000,775000,48667, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 10000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -127,10 +127,10 @@
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/12 UE/TTI -> 32667 bytes/sec
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,10000,421000,437000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,10000,421000,137000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,10000,421000,67000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,10000,421000,32667,errorModel));
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,10000,421000,437000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,10000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,10000,421000,67000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,10000,421000,32667,errorModel), TestCase::EXTENSIVE);
// DONWLINK - DISTANCE 20000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -143,10 +143,10 @@
// 6 users -> 4 PRB at Itbs 2 -> 32 -> 22000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 2 -> 26 bytes * 8/12 UE/TTI -> 12000 bytes/sec
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,20000,421000,41000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,20000,421000,22000,errorModel));
- AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,20000,421000,12000,errorModel));
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (3,0,20000,421000,41000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (6,0,20000,421000,22000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdMtFfMacSchedulerTestCase (12,0,20000,421000,12000,errorModel), TestCase::EXTENSIVE);
}
--- a/src/lte/test/lte-test-tdtbfq-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-tdtbfq-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -90,10 +90,10 @@
// 3 users -> 8 PRB at Itbs 26 -> 749 -> 749000 > 232000 -> throughput = 232000 bytes/sec
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 > 232000 -> throughput = 232000 bytes/sec
// 12 users -> 2 PRB at Itbs 26 -> 185 -> 185000 < 232000 -> throughput = 185000 bytes/sec
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,0,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,0,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,0,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,0,183000,185000,200,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,0,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,0,232000,232000,200,1), TestCase::QUICK);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,0,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,0,183000,185000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 3000 -> MCS 24 -> Itbs 20 (from table 7.1.7.2.1-1 of 36.213)
// DOWNLINK -> DISTANCE 0 -> MCS 28 -> Itbs 26 (from table 7.1.7.2.1-1 of 36.2 13)
@@ -110,10 +110,10 @@
// 3 users -> 8 PRB at Itbs 18 -> 389 -> 389000 > 232000 -> throughput = 232000 bytes/sec
// 6 users -> 4 PRB at Itbs 18 -> 193 -> 193000 < 232000 -> throughput = 193000 bytes/sec
// 12 users -> 2 PRB at Itbs 18 -> 97 -> 97000 < 232000 -> throughput = 97000 bytes/sec
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,3000,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,3000,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,3000,230500,193000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,3000,115250,97000,200,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,3000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,3000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,3000,230500,193000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,3000,115250,97000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -129,10 +129,10 @@
// 3 users -> 8 PRB at Itbs 11 -> 201 -> 201000 < 232000 -> throughput = 201000 bytes/sec
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 < 232000 -> throughput = 97000 bytes/sec
// 12 users -> 2 PRB at Itbs 11 -> 47 -> 47000 < 232000 -> throughput = 47000 bytes/sec
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,6000,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,6000,232000,201000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,6000,150500,97000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,6000,75250,47000,200,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,6000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,6000,232000,201000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,6000,150500,97000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,6000,75250,47000,200,1), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 9000 -> MCS 12 -> Itbs 11 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -148,10 +148,10 @@
// 3 users -> 8 PRB at Itbs 8 -> 137 -> 137000 < 232000 -> throughput = 137000 bytes/sec
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 < 232000 -> throughput = 67000 bytes/sec
// 12 users -> 2 PRB at Itbs 8 -> 32 -> 32000 < 232000 -> throughput = 32000 bytes/sec
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,9000,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,9000,199000,137000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,9000,99500,67000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,9000,49750,32000,200,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,9000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,9000,199000,137000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,9000,99500,67000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,9000,49750,32000,200,1), TestCase::EXTENSIVE);
// DONWLINK - DISTANCE 15000 -> MCS 6 -> Itbs 6 (from table 7.1.7.2.1-1 of 36.213)
// Traffic info
@@ -167,10 +167,10 @@
// 3 users -> 8 PRB at Itbs 6 -> 69 -> 69000 < 232000 -> throughput = 69000 bytes/sec
// 6 users -> 4 PRB at Itbs 6 -> 32 -> 32000 < 232000 -> throughput = 32000 bytes/sec
// 12 users -> 2 PRB at Itbs 6 -> 15 -> 15000 < 232000 -> throughput = 15000 bytes/sec
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,15000,232000,232000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,15000,103000,69000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,15000,51500,32000,200,1));
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,15000,25750,15000,200,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (1,0,15000,232000,232000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (3,0,15000,103000,69000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (6,0,15000,51500,32000,200,1), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase1 (12,0,15000,25750,15000,200,1), TestCase::EXTENSIVE);
// Test Case 2: homogeneous flow test in TDTBFQ (different distance)
// Traffic1 info
@@ -196,7 +196,7 @@
estThrTdTbfqDl1.push_back (132000); // User 2 estimated TTI throughput from TDTBFQ
estThrTdTbfqDl1.push_back (132000); // User 3 estimated TTI throughput from TDTBFQ
estThrTdTbfqDl1.push_back (132000); // User 4 estimated TTI throughput from TDTBFQ
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase2 (dist1,estThrTdTbfqDl1,packetSize1,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase2 (dist1,estThrTdTbfqDl1,packetSize1,1), TestCase::EXTENSIVE);
// Traffic2 info
// UDP traffic: payload size = 200 bytes, interval = 1 ms
@@ -221,7 +221,7 @@
estThrTdTbfqDl2.push_back (138944); // User 2 estimated TTI throughput from TDTBFQ
estThrTdTbfqDl2.push_back (138944); // User 3 estimated TTI throughput from TDTBFQ
estThrTdTbfqDl2.push_back (138944); // User 4 estimated TTI throughput from TDTBFQ
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase2 (dist2,estThrTdTbfqDl2,packetSize2,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase2 (dist2,estThrTdTbfqDl2,packetSize2,1), TestCase::EXTENSIVE);
// Test Case 3: heterogeneous flow test in TDTBFQ
// UDP traffic: payload size = [100,200,300] bytes, interval = 1 ms
@@ -240,7 +240,7 @@
estThrTdTbfqDl3.push_back (132000); // User 0 estimated TTI throughput from TDTBFQ
estThrTdTbfqDl3.push_back (232000); // User 1 estimated TTI throughput from TDTBFQ
estThrTdTbfqDl3.push_back (332000); // User 2 estimated TTI throughput from TDTBFQ
- AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase2 (dist3,estThrTdTbfqDl3,packetSize3,1));
+ AddTestCase (new LenaTdTbfqFfMacSchedulerTestCase2 (dist3,estThrTdTbfqDl3,packetSize3,1), TestCase::QUICK);
}
--- a/src/lte/test/lte-test-tta-ff-mac-scheduler.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-tta-ff-mac-scheduler.cc Fri Apr 05 17:59:11 2013 +0200
@@ -79,11 +79,11 @@
// 6 users -> 4 PRB at Itbs 26 -> 373 -> 373000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 26 -> 277 bytes * 8/12 UE/TTI -> 184670 bytes/sec
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,0,2196000,2292000, errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,0,2196000,749000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,0,2196000,373000, errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,0,2196000,184670, errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (15,0,0,2196000,147730, errorModel));
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,0,2196000,2292000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,0,2196000,749000,errorModel), TestCase::QUICK);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,0,2196000,373000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,0,2196000,184670, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (15,0,0,2196000,147730, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 4800 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 15 -> 903 -> 903000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -96,10 +96,10 @@
// 6 users -> 4 PRB at Itbs 13 -> 125 -> 125000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 13 -> 93 bytes * 8/12 UE/TTI -> 62000 bytes/sec
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,4800,903000,807000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,4800,903000,253000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,4800,903000,125000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,4800,903000,62000,errorModel));
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,4800,903000,807000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,4800,903000,253000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,4800,903000,125000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,4800,903000,62000,errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 6000 -> MCS 16 -> Itbs 15 (from table 7.1.7.2.1-1 of 36.213)
@@ -113,10 +113,10 @@
// 6 users -> 4 PRB at Itbs 11 -> 97 -> 97000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 11 -> 73 bytes * 8/12 UE/TTI -> 48667 bytes/sec
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,6000,775000,621000, errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,6000,775000,201000, errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,6000,775000,97000, errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,6000,775000,48667, errorModel));
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,6000,775000,621000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,6000,775000,201000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,6000,775000,97000, errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,6000,775000,48667, errorModel), TestCase::EXTENSIVE);
// DOWNLINK - DISTANCE 10000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -129,10 +129,10 @@
// 6 users -> 4 PRB at Itbs 8 -> 67 -> 67000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 8 -> 49 bytes * 8/12 UE/TTI -> 32667 bytes/sec
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,10000,421000,437000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,10000,421000,137000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,10000,421000,67000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,10000,421000,32667,errorModel));
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,10000,421000,437000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,10000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,10000,421000,67000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,10000,421000,32667,errorModel), TestCase::EXTENSIVE);
// DONWLINK - DISTANCE 20000 -> MCS 8 -> Itbs 8 (from table 7.1.7.2.1-1 of 36.213)
// 1 user -> 24 PRB at Itbs 8 -> 421 -> 421000 bytes/sec for one UE; 0 bytes/sec for other UEs
@@ -145,10 +145,10 @@
// 6 users -> 4 PRB at Itbs 2 -> 32 -> 22000 bytes/sec
// after the patch enforcing min 3 PRBs per UE:
// 12 users -> 3 PRB at Itbs 2 -> 26 bytes * 8/12 UE/TTI -> 12000 bytes/sec
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,20000,421000,41000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,20000,421000,22000,errorModel));
- AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,20000,421000,12000,errorModel));
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (1,0,20000,421000,137000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (3,0,20000,421000,41000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (6,0,20000,421000,22000,errorModel), TestCase::EXTENSIVE);
+ AddTestCase (new LenaTtaFfMacSchedulerTestCase (12,0,20000,421000,12000,errorModel), TestCase::EXTENSIVE);
}
--- a/src/lte/test/lte-test-uplink-sinr.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/lte-test-uplink-sinr.cc Fri Apr 05 17:59:11 2013 +0200
@@ -85,9 +85,9 @@
(*theoreticalSinr1)[0] = 3.72589167251055;
(*theoreticalSinr1)[1] = 3.72255684126076;
- AddTestCase (new LteUplinkDataSinrTestCase (rxPsd1, rxPsd2, theoreticalSinr1, "sdBm = [-46 -inf] and [-inf -48]"));
+ AddTestCase (new LteUplinkDataSinrTestCase (rxPsd1, rxPsd2, theoreticalSinr1, "sdBm = [-46 -inf] and [-inf -48]"), TestCase::QUICK);
- AddTestCase (new LteUplinkSrsSinrTestCase (rxPsd1, rxPsd2, theoreticalSinr1, "sdBm = [-46 -inf] and [-inf -48]"));
+ AddTestCase (new LteUplinkSrsSinrTestCase (rxPsd1, rxPsd2, theoreticalSinr1, "sdBm = [-46 -inf] and [-inf -48]"), TestCase::QUICK);
/**
* TX signals #2: Power Spectral Density of the signals of interest = [-63 -inf] and [-inf -61] dBm and BW = [20 22] MHz
@@ -104,9 +104,9 @@
(*theoreticalSinr2)[0] = 0.0743413124381667;
(*theoreticalSinr2)[1] = 0.1865697965291756;
- AddTestCase (new LteUplinkDataSinrTestCase (rxPsd3, rxPsd4, theoreticalSinr2, "sdBm = [-63 -inf] and [-inf -61]"));
+ AddTestCase (new LteUplinkDataSinrTestCase (rxPsd3, rxPsd4, theoreticalSinr2, "sdBm = [-63 -inf] and [-inf -61]"), TestCase::QUICK);
- AddTestCase (new LteUplinkSrsSinrTestCase (rxPsd3, rxPsd4, theoreticalSinr2, "sdBm = [-63 -inf] and [-inf -61]"));
+ AddTestCase (new LteUplinkSrsSinrTestCase (rxPsd3, rxPsd4, theoreticalSinr2, "sdBm = [-63 -inf] and [-inf -61]"), TestCase::QUICK);
}
--- a/src/lte/test/test-epc-tft-classifier.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/test-epc-tft-classifier.cc Fri Apr 05 17:59:11 2013 +0200
@@ -208,33 +208,33 @@
// ------------------------------------classifier---direction--------------src address---------------dst address---src port--dst port--ToS--TFT id
// test IP addresses
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.0.0.0"), 2, 123, 5, 1));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("6.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("3.3.4.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.2.1"), 4, 1234, 0, 0));
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.0.0.0"), 2, 123, 5, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("6.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("3.3.4.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.2.1"), 4, 1234, 0, 0), TestCase::QUICK);
// test remote port
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1234, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 0));
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1234, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 0), TestCase::QUICK);
// test local port
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3456, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3457, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3489, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3456, 6, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3461, 3461, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 7895, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 7895, 10, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 5897, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 5897, 10, 0, 2));
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3456, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3457, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3489, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3456, 6, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3461, 3461, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 7895, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 7895, 10, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 5897, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c1, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 5897, 10, 0, 2), TestCase::QUICK);
///////////////////////////
@@ -247,29 +247,29 @@
// ------------------------------------classifier---direction--------------src address---------------dst address---src port--dst port--ToS--TFT id
// test IP addresses
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.0.0.0"), 2, 123, 5, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("6.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("3.3.4.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.2.1"), 4, 1234, 0, 1));
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.0.0.0"), 2, 123, 5, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("6.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("3.3.4.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.2.1"), 4, 1234, 0, 1), TestCase::QUICK);
// test remote port
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 1));
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 1), TestCase::QUICK);
// test local port
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3456, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3457, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3489, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3456, 6, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3461, 3461, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 1));
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3456, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3457, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3489, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3456, 6, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3461, 3461, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c2, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 1), TestCase::QUICK);
@@ -285,29 +285,29 @@
// ------------------------------------classifier---direction--------------src address---------------dst address---src port--dst port--ToS--TFT id
// test IP addresses
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.0.0.0"), 2, 123, 5, 2));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("6.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("3.3.4.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.2.1"), 4, 1234, 0, 1));
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("2.2.3.4"), Ipv4Address ("1.0.0.0"), 2, 123, 5, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("6.2.3.4"), Ipv4Address ("1.1.1.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("3.3.4.4"), Ipv4Address ("4.4.4.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("3.3.3.4"), Ipv4Address ("4.4.2.1"), 4, 1234, 0, 1), TestCase::QUICK);
// test remote port
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 3));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 3));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 3));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1234, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 1));
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 3), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 3), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 3), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1234, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1024, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1025, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 1035, 0, 1), TestCase::QUICK);
// test local port
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3456, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3457, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3489, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3456, 6, 0, 3));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3461, 3461, 0, 3));
- AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 3));
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3456, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3457, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 4, 3489, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3456, 6, 0, 3), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 3461, 3461, 0, 3), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c3, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 3), TestCase::QUICK);
@@ -322,11 +322,11 @@
Ptr<EpcTft> tft4_2 = Create<EpcTft> ();
tft4_2->Add (pf1_2_4);
c4->Add (tft4_2, 2);
- AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 0));
- AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 7895, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 7895, 10, 0, 1));
- AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 5897, 0, 2));
- AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 5897, 10, 0, 2));
+ AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 3489, 0, 0), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 7895, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 7895, 10, 0, 1), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::UPLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 9, 5897, 0, 2), TestCase::QUICK);
+ AddTestCase (new EpcTftClassifierTestCase (c4, EpcTft::DOWNLINK, Ipv4Address ("9.1.1.1"), Ipv4Address ("8.1.1.1"), 5897, 10, 0, 2), TestCase::QUICK);
}
--- a/src/lte/test/test-lte-antenna.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/test-lte-antenna.cc Fri Apr 05 17:59:11 2013 +0200
@@ -225,32 +225,32 @@
NS_LOG_FUNCTION (this);
// orientation beamwidth x y gain
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, 1.0, 0.0, 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, 1.0, 1.0, -3.0));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, 1.0, -1.0, -3.0));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, -1.0, -1.0, -36.396));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, -1.0, -0.0, -1414.6));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, -1.0, 1.0, -36.396));
- AddTestCase (new LteEnbAntennaTestCase ( 45.0, 90.0, 1.0, 1.0, 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( -45.0, 90.0, 1.0, -1.0, 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( 90.0, 90.0, 1.0, 1.0, -3.0));
- AddTestCase (new LteEnbAntennaTestCase ( -90.0, 90.0, 1.0, -1.0, -3.0));
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, 1.0, 0.0, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, 1.0, 1.0, -3.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, 1.0, -1.0, -3.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, -1.0, -1.0, -36.396), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, -1.0, -0.0, -1414.6), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 90.0, -1.0, 1.0, -36.396), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 45.0, 90.0, 1.0, 1.0, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -45.0, 90.0, 1.0, -1.0, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 90.0, 90.0, 1.0, 1.0, -3.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -90.0, 90.0, 1.0, -1.0, -3.0), TestCase::QUICK);
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, 1.0, 0.0, 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, 0.5, sin(M_PI/3), -3.0));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, 0.5, -sin(M_PI/3), -3.0));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, -1.0, -2.0, -13.410));
- AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, -1.0, 1.0, -20.034));
- AddTestCase (new LteEnbAntennaTestCase ( 60.0, 120.0, 0.5, sin(M_PI/3), 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( -60.0, 120.0, 0.5, -sin(M_PI/3), 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( -60.0, 120.0, 0.5, -sin(M_PI/3), 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, -0.5, -sin(M_PI/3), 0.0));
- AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 0.5, -sin(M_PI/3), -3.0));
- AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, -1, 0, -3.0));
- AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, -1, 2, -15.578));
- AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 1, 0, -14.457));
- AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 1, 2, -73.154));
- AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 1, -0.1, -12.754));
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, 1.0, 0.0, 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, 0.5, sin(M_PI/3), -3.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, 0.5, -sin(M_PI/3), -3.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, -1.0, -2.0, -13.410), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 0.0, 120.0, -1.0, 1.0, -20.034), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( 60.0, 120.0, 0.5, sin(M_PI/3), 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -60.0, 120.0, 0.5, -sin(M_PI/3), 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -60.0, 120.0, 0.5, -sin(M_PI/3), 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, -0.5, -sin(M_PI/3), 0.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 0.5, -sin(M_PI/3), -3.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, -1, 0, -3.0), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, -1, 2, -15.578), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 1, 0, -14.457), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 1, 2, -73.154), TestCase::QUICK);
+ AddTestCase (new LteEnbAntennaTestCase ( -120.0, 120.0, 1, -0.1, -12.754), TestCase::QUICK);
}
--- a/src/lte/test/test-lte-epc-e2e-data.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/test/test-lte-epc-e2e-data.cc Fri Apr 05 17:59:11 2013 +0200
@@ -361,7 +361,7 @@
u1.bearers.push_back (f1);
e1.ues.push_back (u1);
v1.push_back (e1);
- AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE", v1));
+ AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE", v1), TestCase::QUICK);
std::vector<EnbTestData> v2;
EnbTestData e2;
@@ -374,12 +374,12 @@
u2_2.bearers.push_back (f2_2);
e2.ues.push_back (u2_2);
v2.push_back (e2);
- AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 2UEs", v2));
+ AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 2UEs", v2), TestCase::EXTENSIVE);
std::vector<EnbTestData> v3;
v3.push_back (e1);
v3.push_back (e2);
- AddTestCase (new LteEpcE2eDataTestCase ("2 eNBs", v3));
+ AddTestCase (new LteEpcE2eDataTestCase ("2 eNBs", v3), TestCase::EXTENSIVE);
EnbTestData e4;
UeTestData u4_1;
@@ -398,7 +398,7 @@
v4.push_back (e4);
v4.push_back (e1);
v4.push_back (e2);
- AddTestCase (new LteEpcE2eDataTestCase ("3 eNBs", v4));
+ AddTestCase (new LteEpcE2eDataTestCase ("3 eNBs", v4), TestCase::EXTENSIVE);
EnbTestData e5;
UeTestData u5;
@@ -407,7 +407,7 @@
e5.ues.push_back (u5);
std::vector<EnbTestData> v5;
v5.push_back (e5);
- AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with 1000 byte packets", v5));
+ AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with 1000 byte packets", v5), TestCase::EXTENSIVE);
EnbTestData e6;
@@ -417,7 +417,7 @@
e6.ues.push_back (u6);
std::vector<EnbTestData> v6;
v6.push_back (e6);
- AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with 1400 byte packets", v6));
+ AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with 1400 byte packets", v6), TestCase::EXTENSIVE);
EnbTestData e7;
UeTestData u7;
@@ -428,7 +428,7 @@
e7.ues.push_back (u7);
std::vector<EnbTestData> v7;
v7.push_back (e7);
- AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with 2 bearers", v7));
+ AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with 2 bearers", v7), TestCase::EXTENSIVE);
EnbTestData e8;
UeTestData u8;
@@ -437,7 +437,7 @@
e8.ues.push_back (u8);
std::vector<EnbTestData> v8;
v8.push_back (e8);
- AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with fragmentation", v8));
+ AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with fragmentation", v8), TestCase::EXTENSIVE);
EnbTestData e9;
@@ -447,7 +447,7 @@
e9.ues.push_back (u9);
std::vector<EnbTestData> v9;
v9.push_back (e9);
- AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with aggregation", v9));
+ AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with aggregation", v9), TestCase::EXTENSIVE);
}
--- a/src/lte/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/lte/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -142,7 +142,7 @@
'test/test-asn1-encoding.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'lte'
headers.source = [
'model/lte-common.h',
@@ -242,6 +242,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/mesh/test/dot11s/dot11s-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mesh/test/dot11s/dot11s-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -279,9 +279,9 @@
Dot11sTestSuite::Dot11sTestSuite ()
: TestSuite ("devices-mesh-dot11s", UNIT)
{
- AddTestCase (new MeshHeaderTest);
- AddTestCase (new HwmpRtableTest);
- AddTestCase (new PeerLinkFrameStartTest);
+ AddTestCase (new MeshHeaderTest, TestCase::QUICK);
+ AddTestCase (new HwmpRtableTest, TestCase::QUICK);
+ AddTestCase (new PeerLinkFrameStartTest, TestCase::QUICK);
}
static Dot11sTestSuite g_dot11sTestSuite;
--- a/src/mesh/test/dot11s/regression.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mesh/test/dot11s/regression.cc Fri Apr 05 17:59:11 2013 +0200
@@ -34,10 +34,10 @@
// We do not use NS_TEST_SOURCEDIR variable here since mesh/test has
// subdirectories
SetDataDir (std::string ("src/mesh/test/dot11s"));
- AddTestCase (new PeerManagementProtocolRegressionTest);
- AddTestCase (new HwmpSimplestRegressionTest);
- AddTestCase (new HwmpReactiveRegressionTest);
- AddTestCase (new HwmpProactiveRegressionTest);
- AddTestCase (new HwmpDoRfRegressionTest);
+ AddTestCase (new PeerManagementProtocolRegressionTest, TestCase::QUICK);
+ AddTestCase (new HwmpSimplestRegressionTest, TestCase::QUICK);
+ AddTestCase (new HwmpReactiveRegressionTest, TestCase::QUICK);
+ AddTestCase (new HwmpProactiveRegressionTest, TestCase::QUICK);
+ AddTestCase (new HwmpDoRfRegressionTest, TestCase::QUICK);
}
} g_dot11sRegressionSuite;
--- a/src/mesh/test/flame/flame-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mesh/test/flame/flame-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -145,8 +145,8 @@
FlameTestSuite::FlameTestSuite ()
: TestSuite ("devices-mesh-flame", UNIT)
{
- AddTestCase (new FlameHeaderTest);
- AddTestCase (new FlameRtableTest);
+ AddTestCase (new FlameHeaderTest, TestCase::QUICK);
+ AddTestCase (new FlameRtableTest, TestCase::QUICK);
}
static FlameTestSuite g_flameTestSuite;
--- a/src/mesh/test/flame/regression.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mesh/test/flame/regression.cc Fri Apr 05 17:59:11 2013 +0200
@@ -30,6 +30,6 @@
// We do not use NS_TEST_SOURCEDIR variable here since mesh/test has
// subdirectories
SetDataDir (std::string ("src/mesh/test/flame"));
- AddTestCase (new FlameRegressionTest);
+ AddTestCase (new FlameRegressionTest, TestCase::QUICK);
}
} g_flameRegressionSuite;
--- a/src/mesh/test/mesh-information-element-vector-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mesh/test/mesh-information-element-vector-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -151,7 +151,7 @@
MeshTestSuite::MeshTestSuite ()
: TestSuite ("devices-mesh", UNIT)
{
- AddTestCase (new MeshInformationElementVectorBist);
+ AddTestCase (new MeshInformationElementVectorBist, TestCase::QUICK);
}
static MeshTestSuite g_meshTestSuite;
--- a/src/mesh/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mesh/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -53,7 +53,7 @@
'test/flame/regression.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'mesh'
headers.source = [
'model/mesh-information-element.h',
@@ -90,6 +90,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/mobility/test/mobility-trace-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mobility/test/mobility-trace-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -123,7 +123,7 @@
MobilityTraceTestSuite::MobilityTraceTestSuite ()
: TestSuite ("mobility-trace", UNIT)
{
- AddTestCase (new MobilityTraceTestCase);
+ AddTestCase (new MobilityTraceTestCase, TestCase::QUICK);
}
static MobilityTraceTestSuite mobilityTraceTestSuite;
--- a/src/mobility/test/ns2-mobility-helper-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mobility/test/ns2-mobility-helper-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -273,7 +273,7 @@
"$node_(0) set Z_ 3.0\n"
);
t->AddReferencePoint ("0", 0, Vector (1, 2, 3), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Check parsing comments, empty lines and no EOF at the end of file
t = new Ns2MobilityHelperTest ("comments", Seconds (1));
@@ -285,7 +285,7 @@
"#$node_(0) set Z_ 100 #"
);
t->AddReferencePoint ("0", 0, Vector (1, 2, 3), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Simple setdest. Arguments are interpreted as x, y, speed by default
t = new Ns2MobilityHelperTest ("simple setdest", Seconds (10));
@@ -294,7 +294,7 @@
t->AddReferencePoint ("0", 0, Vector (0, 0, 0), Vector (0, 0, 0));
t->AddReferencePoint ("0", 1, Vector (0, 0, 0), Vector (5, 0, 0));
t->AddReferencePoint ("0", 6, Vector (25, 0, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Several set and setdest. Arguments are interpreted as x, y, speed by default
t = new Ns2MobilityHelperTest ("square setdest", Seconds (6));
@@ -315,7 +315,7 @@
t->AddReferencePoint ("0", 4, Vector (0, 5, 0), Vector (0, 0, 0));
t->AddReferencePoint ("0", 4, Vector (0, 5, 0), Vector (0, -5, 0));
t->AddReferencePoint ("0", 5, Vector (0, 0, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Copy of previous test case but with the initial positions at
// the end of the trace rather than at the beginning.
@@ -339,7 +339,7 @@
t->AddReferencePoint ("0", 4, Vector (10, 15, 0), Vector (0, 0, 0));
t->AddReferencePoint ("0", 4, Vector (10, 15, 0), Vector (0, -5, 0));
t->AddReferencePoint ("0", 5, Vector (10, 10, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Scheduled set position
t = new Ns2MobilityHelperTest ("scheduled set position", Seconds (2));
@@ -350,7 +350,7 @@
t->AddReferencePoint ("0", 1, Vector (10, 0, 0), Vector (0, 0, 0));
t->AddReferencePoint ("0", 1, Vector (10, 0, 10), Vector (0, 0, 0));
t->AddReferencePoint ("0", 1, Vector (10, 10, 10), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Malformed lines
t = new Ns2MobilityHelperTest ("malformed lines", Seconds (2));
@@ -366,7 +366,7 @@
t->AddReferencePoint ("0", 0, Vector (1, 2, 3), Vector (0, 0, 0));
t->AddReferencePoint ("0", 1, Vector (1, 2, 3), Vector (1, 0, 0));
t->AddReferencePoint ("0", 2, Vector (2, 2, 3), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Non possible values
t = new Ns2MobilityHelperTest ("non possible values", Seconds (2));
@@ -386,7 +386,7 @@
t->AddReferencePoint ("0", 0, Vector (1, 2, 3), Vector (0, 0, 0));
t->AddReferencePoint ("0", 1, Vector (1, 2, 3), Vector (1, 0, 0));
t->AddReferencePoint ("0", 2, Vector (2, 2, 3), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// More than one node
t = new Ns2MobilityHelperTest ("few nodes, combinations of set and setdest", Seconds (10), 3);
@@ -414,7 +414,7 @@
t->AddReferencePoint ("2", 4, Vector (0, 5, 0), Vector (0, 0, 0));
t->AddReferencePoint ("2", 4, Vector (0, 5, 0), Vector (0, -5, 0));
t->AddReferencePoint ("2", 5, Vector (0, 0, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Test for Speed == 0, that acts as stop the node.
t = new Ns2MobilityHelperTest ("setdest with speed cero", Seconds (10));
@@ -425,7 +425,7 @@
t->AddReferencePoint ("0", 1, Vector (0, 0, 0), Vector (5, 0, 0));
t->AddReferencePoint ("0", 6, Vector (25, 0, 0), Vector (0, 0, 0));
t->AddReferencePoint ("0", 7, Vector (25, 0, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Test negative positions
@@ -440,7 +440,7 @@
t->AddReferencePoint ("0", 2, Vector (0, 0, 0), Vector (0, 0, 0));
t->AddReferencePoint ("0", 2, Vector (0, 0, 0), Vector (0, -1, 0));
t->AddReferencePoint ("0", 3, Vector (0, -1, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
// Sqare setdest with values in the form 1.0e+2
t = new Ns2MobilityHelperTest ("Foalt numbers in 1.0e+2 format", Seconds (6));
@@ -460,7 +460,7 @@
t->AddReferencePoint ("0", 4, Vector (0, 100, 0), Vector (0, 0, 0));
t->AddReferencePoint ("0", 4, Vector (0, 100, 0), Vector (0, -100, 0));
t->AddReferencePoint ("0", 5, Vector (0, 0, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
t = new Ns2MobilityHelperTest ("Bug 1219 testcase", Seconds (16));
t->SetTrace ("$node_(0) set X_ 0.0\n"
"$node_(0) set Y_ 0.0\n"
@@ -472,14 +472,14 @@
t->AddReferencePoint ("0", 1, Vector (0, 0, 0), Vector (0, 1, 0));
t->AddReferencePoint ("0", 6, Vector (0, 5, 0), Vector (0, -1, 0));
t->AddReferencePoint ("0", 16, Vector (0, -10, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
t = new Ns2MobilityHelperTest ("Bug 1059 testcase", Seconds (16));
t->SetTrace ("$node_(0) set X_ 10.0\r\n"
"$node_(0) set Y_ 0.0\r\n"
);
// id t position velocity
t->AddReferencePoint ("0", 0, Vector (10, 0, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
t = new Ns2MobilityHelperTest ("Bug 1301 testcase", Seconds (16));
t->SetTrace ("$node_(0) set X_ 10.0\n"
"$node_(0) set Y_ 0.0\n"
@@ -489,7 +489,7 @@
// Moving to the current position must change nothing. No NaN
// speed must be.
t->AddReferencePoint ("0", 0, Vector (10, 0, 0), Vector (0, 0, 0));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
t = new Ns2MobilityHelperTest ("Bug 1316 testcase", Seconds (1000));
t->SetTrace ("$node_(0) set X_ 350.00000000000000\n"
@@ -513,7 +513,7 @@
t->AddReferencePoint ("0", 600.000, Vector (250.000, 50.000, 0.000), Vector (0.000, 2.000, 0.000));
t->AddReferencePoint ("0", 900.000, Vector (250.000, 650.000, 0.000), Vector (2.500, 0.000, 0.000));
t->AddReferencePoint ("0", 920.000, Vector (300.000, 650.000, 0.000), Vector (0.000, 0.000, 0.000));
- AddTestCase (t);
+ AddTestCase (t, TestCase::QUICK);
}
} g_ns2TransmobilityHelperTestSuite;
--- a/src/mobility/test/steady-state-random-waypoint-mobility-model-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mobility/test/steady-state-random-waypoint-mobility-model-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -141,7 +141,7 @@
{
SteadyStateRandomWaypointTestSuite () : TestSuite ("steady-state-rwp-mobility-model", UNIT)
{
- AddTestCase (new SteadyStateRandomWaypointTest);
+ AddTestCase (new SteadyStateRandomWaypointTest, TestCase::QUICK);
}
} g_steadyStateRandomWaypointTestSuite;
--- a/src/mobility/test/waypoint-mobility-model-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mobility/test/waypoint-mobility-model-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -151,8 +151,8 @@
{
WaypointMobilityModelTestSuite () : TestSuite ("waypoint-mobility-model", UNIT)
{
- AddTestCase (new WaypointMobilityModelNotifyTest (true));
- AddTestCase (new WaypointMobilityModelNotifyTest (false));
+ AddTestCase (new WaypointMobilityModelNotifyTest (true), TestCase::QUICK);
+ AddTestCase (new WaypointMobilityModelNotifyTest (false), TestCase::QUICK);
}
} g_waypointMobilityModelTestSuite;
--- a/src/mobility/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mobility/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -31,7 +31,7 @@
'test/waypoint-mobility-model-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'mobility'
headers.source = [
'model/box.h',
@@ -55,6 +55,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/mpi/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/mpi/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -1,7 +1,8 @@
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
import sys
import subprocess
-import Options
+
+from waflib import Options
from waflib.Errors import WafError
def configure(conf):
@@ -39,7 +40,7 @@
'model/mpi-receiver.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'mpi'
headers.source = [
'model/distributed-simulator-impl.h',
@@ -51,6 +52,6 @@
sim.use.append('MPI')
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/netanim/model/animation-interface.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/netanim/model/animation-interface.cc Fri Apr 05 17:59:11 2013 +0200
@@ -81,7 +81,7 @@
StopAnimation ();
}
-void AnimationInterface::EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, Time pollInterval)
+AnimationInterface & AnimationInterface::EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, Time pollInterval)
{
m_routingFileName = fileName;
SetRoutingOutputFile (m_routingFileName);
@@ -89,12 +89,13 @@
m_routingPollInterval = pollInterval;
WriteN (GetXMLOpen_anim (0), m_routingF);
Simulator::Schedule (startTime, &AnimationInterface::TrackIpv4Route, this);
+ return *this;
}
-void AnimationInterface::EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, NodeContainer nc, Time pollInterval)
+AnimationInterface & AnimationInterface::EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, NodeContainer nc, Time pollInterval)
{
m_routingNc = nc;
- EnableIpv4RouteTracking (fileName, startTime, stopTime, pollInterval);
+ return EnableIpv4RouteTracking (fileName, startTime, stopTime, pollInterval);
}
std::string AnimationInterface::GetIpv4RoutingTable (Ptr <Node> n)
@@ -114,6 +115,144 @@
}
+void AnimationInterface::RecursiveIpv4RoutePathSearch (std::string from, std::string to, Ipv4RoutePathElements & rpElements)
+{
+ NS_LOG_INFO ("RecursiveIpv4RoutePathSearch from:" << from.c_str () << " to:" << to.c_str ());
+ if ((from == "0.0.0.0") || (from == "127.0.0.1"))
+ {
+ NS_LOG_INFO ("Got " << from.c_str () << " End recursion");
+ return;
+ }
+ Ptr <Node> fromNode = NodeList::GetNode (m_ipv4ToNodeIdMap[from]);
+ Ptr <Node> toNode = NodeList::GetNode (m_ipv4ToNodeIdMap[to]);
+ if (fromNode->GetId () == toNode->GetId ())
+ {
+ Ipv4RoutePathElement elem = { fromNode->GetId (), "L" };
+ rpElements.push_back (elem);
+ return;
+ }
+ if (!fromNode)
+ {
+ NS_FATAL_ERROR ("Node: " << m_ipv4ToNodeIdMap[from] << " Not found");
+ return;
+ }
+ if (!toNode)
+ {
+ NS_FATAL_ERROR ("Node: " << m_ipv4ToNodeIdMap[to] << " Not found");
+ return;
+ }
+ Ptr <ns3::Ipv4> ipv4 = fromNode->GetObject <ns3::Ipv4> ();
+ if (!ipv4)
+ {
+ NS_LOG_WARN ("ipv4 object not found");
+ return;
+ }
+ Ptr <Ipv4RoutingProtocol> rp = ipv4->GetRoutingProtocol ();
+ if (!rp)
+ {
+ NS_LOG_WARN ("Routing protocol object not found");
+ return;
+ }
+ Ptr<Packet> pkt = 0;
+ Ipv4Header header;
+ header.SetDestination (Ipv4Address (to.c_str ()));
+ Socket::SocketErrno sockerr;
+ Ptr <Ipv4Route> rt = rp->RouteOutput (pkt, header, 0, sockerr);
+ if (!rt)
+ {
+ return;
+ }
+ NS_LOG_UNCOND ("Node: " << fromNode->GetId () << " G:" << rt->GetGateway ());
+ std::ostringstream oss;
+ oss << rt->GetGateway ();
+ if (oss.str () == "0.0.0.0" && (sockerr != Socket::ERROR_NOROUTETOHOST))
+ {
+ NS_LOG_INFO ("Null gw");
+ Ipv4RoutePathElement elem = { fromNode->GetId (), "C" };
+ rpElements.push_back (elem);
+ if ( m_ipv4ToNodeIdMap.find (to) != m_ipv4ToNodeIdMap.end ())
+ {
+ Ipv4RoutePathElement elem2 = { m_ipv4ToNodeIdMap[to], "L" };
+ rpElements.push_back (elem2);
+ }
+ return;
+ }
+ NS_LOG_INFO ("Node:" << fromNode->GetId () << "-->" << rt->GetGateway ());
+ Ipv4RoutePathElement elem = { fromNode->GetId (), oss.str () };
+ rpElements.push_back (elem);
+ RecursiveIpv4RoutePathSearch (oss.str (), to, rpElements);
+
+}
+
+void AnimationInterface::TrackIpv4RoutePaths ()
+{
+ if (m_ipv4RouteTrackElements.empty ())
+ {
+ return;
+ }
+ for (std::vector <Ipv4RouteTrackElement>::const_iterator i = m_ipv4RouteTrackElements.begin ();
+ i != m_ipv4RouteTrackElements.end ();
+ ++i)
+ {
+ Ipv4RouteTrackElement trackElement = *i;
+ Ptr <Node> fromNode = NodeList::GetNode (trackElement.fromNodeId);
+ if (!fromNode)
+ {
+ NS_FATAL_ERROR ("Node: " << trackElement.fromNodeId << " Not found");
+ continue;
+ }
+ Ptr <ns3::Ipv4> ipv4 = fromNode->GetObject <ns3::Ipv4> ();
+ if (!ipv4)
+ {
+ NS_LOG_WARN ("ipv4 object not found");
+ continue;
+ }
+ Ptr <Ipv4RoutingProtocol> rp = ipv4->GetRoutingProtocol ();
+ if (!rp)
+ {
+ NS_LOG_WARN ("Routing protocol object not found");
+ continue;
+ }
+ NS_LOG_INFO ("Begin Track Route for: " << trackElement.destination.c_str () << " From:" << trackElement.fromNodeId);
+ Ptr<Packet> pkt = 0;
+ Ipv4Header header;
+ header.SetDestination (Ipv4Address (trackElement.destination.c_str ()));
+ Socket::SocketErrno sockerr;
+ Ptr <Ipv4Route> rt = rp->RouteOutput (pkt, header, 0, sockerr);
+ if (!rt)
+ {
+ NS_LOG_INFO ("No route to :" << trackElement.destination.c_str ());
+ }
+ std::ostringstream oss;
+ oss << rt->GetGateway ();
+ NS_LOG_INFO ("Node:" << trackElement.fromNodeId << "-->" << rt->GetGateway ());
+ Ipv4RoutePathElements rpElements;
+ if (rt->GetGateway () == "0.0.0.0")
+ {
+ Ipv4RoutePathElement elem = { trackElement.fromNodeId, "C" };
+ rpElements.push_back (elem);
+ if ( m_ipv4ToNodeIdMap.find (trackElement.destination) != m_ipv4ToNodeIdMap.end ())
+ {
+ Ipv4RoutePathElement elem2 = { m_ipv4ToNodeIdMap[trackElement.destination], "L" };
+ rpElements.push_back (elem2);
+ }
+ }
+ else if (rt->GetGateway () == "127.0.0.1")
+ {
+ Ipv4RoutePathElement elem = { trackElement.fromNodeId, "-1" };
+ rpElements.push_back (elem);
+ }
+ else
+ {
+ Ipv4RoutePathElement elem = { trackElement.fromNodeId, oss.str () };
+ rpElements.push_back (elem);
+ }
+ RecursiveIpv4RoutePathSearch (oss.str (), trackElement.destination, rpElements);
+ WriteRoutePath (trackElement.fromNodeId, trackElement.destination, rpElements);
+ }
+
+}
+
void AnimationInterface::TrackIpv4Route ()
{
if (Simulator::Now () > m_routingStopTime)
@@ -137,6 +276,7 @@
WriteN (GetXMLOpenClose_routing (n->GetId (), GetIpv4RoutingTable (n)), m_routingF);
}
}
+ TrackIpv4RoutePaths ();
Simulator::Schedule (m_routingPollInterval, &AnimationInterface::TrackIpv4Route, this);
}
@@ -447,7 +587,10 @@
{
Ptr<Ipv4> ipv4 = NodeList::GetNode (nd->GetNode ()->GetId ())->GetObject <Ipv4> ();
if (!ipv4)
- return "0.0.0.0";
+ {
+ NS_LOG_WARN ("Node: " << nd->GetNode ()->GetId () << " No ipv4 object found");
+ return "0.0.0.0";
+ }
int32_t ifIndex = ipv4->GetInterfaceForDevice (nd);
if (ifIndex == -1)
{
@@ -519,9 +662,18 @@
if (!ch)
{
NS_LOG_DEBUG ("No channel can't be a p2p device");
+ // Try to see if it is an LTE NetDevice, which does not return a channel
+ if ((dev->GetInstanceTypeId ().GetName () == "ns3::LteUeNetDevice") ||
+ (dev->GetInstanceTypeId ().GetName () == "ns3::LteEnbNetDevice")||
+ (dev->GetInstanceTypeId ().GetName () == "ns3::VirtualNetDevice"))
+ {
+ WriteNonP2pLinkProperties (n->GetId (), GetIpv4Address (dev) + "~" + GetMacAddress (dev), dev->GetInstanceTypeId ().GetName ());
+ AddToIpv4AddressNodeIdTable (GetIpv4Address (dev), n->GetId ());
+ }
continue;
}
std::string channelType = ch->GetInstanceTypeId ().GetName ();
+ NS_LOG_DEBUG ("Got ChannelType" << channelType);
if (channelType == std::string ("ns3::PointToPointChannel"))
{ // Since these are duplex links, we only need to dump
// if srcid < dstid
@@ -535,6 +687,8 @@
// ouptut the p2p link
NS_LOG_INFO ("Link:" << GetIpv4Address (dev) << ":" << GetMacAddress (dev) << "----" << GetIpv4Address (chDev) << ":" << GetMacAddress (chDev) );
SetLinkDescription (n1Id, n2Id, "", GetIpv4Address (dev) + "~" + GetMacAddress (dev), GetIpv4Address (chDev) + "~" + GetMacAddress (chDev));
+ AddToIpv4AddressNodeIdTable (GetIpv4Address (dev), n1Id);
+ AddToIpv4AddressNodeIdTable (GetIpv4Address (chDev), n2Id);
std::ostringstream oss;
if (m_xml)
{
@@ -552,6 +706,7 @@
{
NS_LOG_INFO ("Link:" << GetIpv4Address (dev) << " Channel Type:" << channelType << " Mac: " << GetMacAddress (dev));
WriteNonP2pLinkProperties (n->GetId (), GetIpv4Address (dev) + "~" + GetMacAddress (dev), channelType);
+ AddToIpv4AddressNodeIdTable (GetIpv4Address (dev), n->GetId ());
}
}
}
@@ -565,6 +720,19 @@
ConnectCallbacks ();
}
+void AnimationInterface::AddToIpv4AddressNodeIdTable (std::string ipv4Address, uint32_t nodeId)
+{
+ m_ipv4ToNodeIdMap[ipv4Address] = nodeId;
+}
+
+AnimationInterface & AnimationInterface::AddSourceDestination (uint32_t fromNodeId, std::string ipv4Address)
+{
+ Ipv4RouteTrackElement element = { ipv4Address, fromNodeId };
+ m_ipv4RouteTrackElements.push_back (element);
+ return *this;
+}
+
+
void AnimationInterface::ConnectLteEnb (Ptr <Node> n, Ptr <LteEnbNetDevice> nd, uint32_t devIndex)
{
@@ -781,6 +949,21 @@
}
+void AnimationInterface::WriteRoutePath (uint32_t nodeId, std::string destination, Ipv4RoutePathElements rpElements)
+{
+ NS_LOG_INFO ("Writing Route Path From :" << nodeId << " To: " << destination.c_str ());
+ WriteN (GetXMLOpenClose_rp (nodeId, destination, rpElements), m_routingF);
+ /*for (Ipv4RoutePathElements::const_iterator i = rpElements.begin ();
+ i != rpElements.end ();
+ ++i)
+ {
+ Ipv4RoutePathElement rpElement = *i;
+ NS_LOG_INFO ("Node:" << rpElement.nodeId << "-->" << rpElement.nextHop.c_str ());
+ WriteN (GetXMLOpenClose_rp (rpElement.node, GetIpv4RoutingTable (n)), m_routingF);
+
+ }
+ */
+}
void AnimationInterface::WriteNonP2pLinkProperties (uint32_t id, std::string ipv4Address, std::string channelType)
{
@@ -1799,6 +1982,24 @@
return oss.str ();
}
+std::string AnimationInterface::GetXMLOpenClose_rp (uint32_t nodeId, std::string destination, Ipv4RoutePathElements rpElements)
+{
+ std::ostringstream oss;
+ oss << "<" << "rp" << " t =\"" << Simulator::Now ().GetSeconds () << "\""
+ << " id=\"" << nodeId << "\"" << " d=\"" << destination.c_str () << "\""
+ << " c=\"" << rpElements.size () << "\"" << ">" << std::endl;
+ for (Ipv4RoutePathElements::const_iterator i = rpElements.begin ();
+ i != rpElements.end ();
+ ++i)
+ {
+ Ipv4RoutePathElement rpElement = *i;
+ oss << "<rpe" << " n=\"" << rpElement.nodeId << "\"" << " nH=\"" << rpElement.nextHop.c_str () << "\"" << "/>" << std::endl;
+ }
+ oss << "<rp/>" << std::endl;
+ return oss.str ();
+}
+
+
std::string AnimationInterface::GetXMLOpenClose_p (std::string pktType, uint32_t fId, double fbTx, double lbTx,
uint32_t tId, double fbRx, double lbRx, std::string metaInfo,
std::string auxInfo)
--- a/src/netanim/model/animation-interface.h Fri Apr 05 16:50:37 2013 +0200
+++ b/src/netanim/model/animation-interface.h Fri Apr 05 17:59:11 2013 +0200
@@ -75,6 +75,18 @@
};
+struct Ipv4RouteTrackElement {
+ std::string destination;
+ uint32_t fromNodeId;
+};
+
+
+typedef struct {
+ uint32_t nodeId;
+ std::string nextHop;
+
+} Ipv4RoutePathElement;
+
/**
* \defgroup netanim Netanim
*
@@ -122,9 +134,9 @@
* \param pollInterval The periodic interval at which routing table information is polled
* Default: 5s
*
- * \returns none
+ * \returns reference to this AnimationInterface object
*/
- void EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, Time pollInterval = Seconds(5));
+ AnimationInterface & EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, Time pollInterval = Seconds(5));
/**
* \brief Enable tracking of the Ipv4 routing table for a set of Nodes
@@ -136,9 +148,9 @@
* \param pollInterval The periodic interval at which routing table information is polled
* Default: 5s
*
- * \returns none
+ * \returns reference to this AnimationInterface object
*/
- void EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, NodeContainer nc, Time pollInterval = Seconds(5));
+ AnimationInterface & EnableIpv4RouteTracking (std::string fileName, Time startTime, Time stopTime, NodeContainer nc, Time pollInterval = Seconds(5));
/**
* \brief Check if AnimationInterface is initialized
@@ -354,6 +366,14 @@
void UpdateLinkDescription (Ptr <Node> fromNode, Ptr <Node> toNode,
std::string linkDescription);
+ /**
+ * \brief Helper function to print the routing path from a source node to destination IP
+ * \param fromNodeId The source node
+ * \param destinationIpv4Address The destination Ipv4 Address
+ *
+ * \returns reference to this AnimationInterface object
+ */
+ AnimationInterface & AddSourceDestination (uint32_t fromNodeId, std::string destinationIpv4Address);
/**
* \brief Is AnimationInterface started
@@ -413,6 +433,7 @@
NodeContainer m_routingNc;
void TrackIpv4Route ();
+ void TrackIpv4RoutePaths ();
std::string GetIpv4RoutingTable (Ptr <Node> n);
/**
@@ -565,6 +586,12 @@
std::map <std::string, uint32_t> m_macToNodeIdMap;
+ std::map <std::string, uint32_t> m_ipv4ToNodeIdMap;
+ void AddToIpv4AddressNodeIdTable (std::string, uint32_t);
+ std::vector <Ipv4RouteTrackElement> m_ipv4RouteTrackElements;
+ typedef std::vector <Ipv4RoutePathElement> Ipv4RoutePathElements;
+ void RecursiveIpv4RoutePathSearch (std::string fromIpv4, std::string toIpv4, Ipv4RoutePathElements &);
+ void WriteRoutePath (uint32_t nodeId, std::string destination, Ipv4RoutePathElements rpElements);
bool IsInTimeWindow ();
// Path helper
@@ -610,6 +637,8 @@
std::string GetXMLOpenClose_meta (std::string metaInfo);
std::string GetXMLOpenClose_NonP2pLinkProperties (uint32_t id, std::string ipv4Address, std::string channelType);
std::string GetXMLOpenClose_routing (uint32_t id, std::string routingInfo);
+ std::string GetXMLOpenClose_rp (uint32_t nodeId, std::string destination, Ipv4RoutePathElements rpElements);
+
/// Provides uniform random variables.
--- a/src/netanim/test/netanim-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/netanim/test/netanim-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -112,7 +112,7 @@
AnimationInterfaceTestSuite () :
TestSuite ("animation-interface", UNIT)
{
- AddTestCase (new AnimationInterfaceTestCase ());
+ AddTestCase (new AnimationInterfaceTestCase (), TestCase::QUICK);
}
} g_animationInterfaceTestSuite;
--- a/src/netanim/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/netanim/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -18,7 +18,7 @@
'test/netanim-test.cc',
]
- headers = bld.new_task_gen (features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'netanim'
headers.source = [
'model/animation-interface.h',
@@ -26,5 +26,5 @@
]
if (bld.env['ENABLE_EXAMPLES']) :
- bld.add_subdirs ('examples')
+ bld.recurse('examples')
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/network/doc/error-model.rst Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,136 @@
+Error Model
+-----------
+.. include:: replace.txt
+
+.. heading hierarchy:
+ ------------- Chapter
+ ************* Section (#.#)
+ ============= Subsection (#.#.#)
+ ############# Paragraph (no number)
+
+This section documents a few error model objects, typically associated with
+NetDevice models, that are maintained as part of the ``network`` module:
+
+* RateErrorModel
+* ListErrorModel
+* ReceiveListErrorModel
+* BurstErrorModel
+
+Error models are used to indicate that a packet should be considered to
+be errored, according to the underlying (possibly stochastic or
+empirical) error model.
+
+Model Description
+*****************
+
+The source code for error models live in the directory ``src/packet/utils``.
+
+Two types of error models are generally provided. The first are stochastic
+models. In this case, packets are errored according to underlying
+random variable distributions. An example of this is the ``RateErrorModel``.
+The other type of model is a deterministic or empirical model, in which
+packets are errored according to a particular prescribed pattern.
+An example is the ``ListErrorModel`` that allows users to specify
+the list of packets to be errored, by listing the specific packet UIDs.
+
+The ``ns3::RateErrorModel`` errors packets according to an underlying
+random variable distribution, which is by default a UniformRandomVariable
+distributed between 0.0 and 1.0. The error rate and error units (bit,
+byte, or packet) are set by the user. For instance, by setting ErrorRate
+to 0.1 and ErrorUnit to "Packet", in the long run, around 10% of the
+packets will be lost.
+
+
+Design
+======
+
+Error models are |ns3| objects and can be created using the typical
+pattern of ``CreateObject<>()``. They have configuration attributes.
+
+An ErrorModel can be applied anywhere, but are commonly deployed on
+NetDevice models so that artificial losses (mimicing channel losses)
+can be induced.
+
+Scope and Limitations
+=====================
+
+No known limitations. There are no existing models that try to modify
+the packet contents (e.g. apply bit or byte errors to the byte buffers).
+This type of operation will likely be performance-expensive, and existing
+Packet APIs may not easily support it.
+
+The |ns3| spectrum model and devices that derive from it (e.g. LTE) have
+their own error model base class, found in
+
+References
+==========
+
+The initial |ns3| error models were ported from ns-2 (queue/errmodel.{cc,h})
+
+Usage
+*****
+
+The base class API is as follows:
+
+* ``bool ErrorModel::IsCorrupt (Ptr<Packet> pkt)``: Evaluate the packet and
+ return true or false whether the packet should be considered errored or not.
+ Some models could potentially alter the contents of the packet bit buffer.
+* ``void ErrorModel::Reset (void)``: Reset any state.
+* ``void ErrorModel::Enable (void)``: Enable the model
+* ``void ErrorModel::Disble (void)``: Disable the model; IsCorrupt() will
+ always return false.
+* ``bool ErrorModel::IsEnabled (void) const``: Return the enabled state
+
+
+Many |ns3| NetDevices contain attributes holding pointers to error
+models. The error model is applied in the notional physical layer
+processing chain of the device, and drops should show up on the ``PhyRxDrop``
+trace source of the device. The following are known to include an attribute
+with a pointer available to hold this type of error model:
+
+* ``SimpleNetDevice``
+* ``PointToPointNetDevice``
+* ``CsmaNetDevice``
+* ``VirtualNetDevice``
+
+However, the ErrorModel could be used anywhere where packets are used
+
+Helpers
+=======
+
+This model is typically not used with helpers.
+
+Attributes
+==========
+
+The ``RateErrorModel`` contains the following attributes:
+
+
+Output
+======
+
+What kind of data does the model generate? What are the key trace
+sources? What kind of logging output can be enabled?
+
+Examples
+========
+
+Error models are used in the tutorial ``fifth`` and ``sixth`` programs.
+
+The directory ``examples/error-model/`` contains an example
+``simple-error-model.cc`` that exercises the Rate and List error models.
+
+The TCP example ``examples/tcp/tcp-nsc-lfn.cc`` uses the Rate error model.
+
+Troubleshooting
+===============
+
+No known issues.
+
+Validation
+**********
+
+The ``error-model`` unit test suite provides a single test case of
+of a particular combination of ErrorRate and ErrorUnit for the
+``RateErrorModel`` applied to a ``SimpleNetDevice``.
+
--- a/src/network/model/address.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/model/address.cc Fri Apr 05 17:59:11 2013 +0200
@@ -123,7 +123,8 @@
{
NS_LOG_FUNCTION (this << static_cast<uint32_t> (type) << static_cast<uint32_t> (len));
NS_ASSERT (len <= MAX_SIZE);
- return m_len == len && (m_type == type || m_type == 0);
+ // Mac address type/length detection is discussed in bug 1568
+ return (m_len == len && m_type == type) || (m_len >= len && m_type == 0);
}
bool
Address::IsMatchingType (uint8_t type) const
--- a/src/network/test/buffer-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/buffer-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -332,7 +332,7 @@
BufferTestSuite::BufferTestSuite ()
: TestSuite ("buffer", UNIT)
{
- AddTestCase (new BufferTest);
+ AddTestCase (new BufferTest, TestCase::QUICK);
}
static BufferTestSuite g_bufferTestSuite;
--- a/src/network/test/drop-tail-queue-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/drop-tail-queue-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -83,6 +83,6 @@
DropTailQueueTestSuite ()
: TestSuite ("drop-tail-queue", UNIT)
{
- AddTestCase (new DropTailQueueTestCase ());
+ AddTestCase (new DropTailQueueTestCase (), TestCase::QUICK);
}
} g_dropTailQueueTestSuite;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/network/test/error-model-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,136 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+
+#include "ns3/test.h"
+#include "ns3/simple-net-device.h"
+#include "ns3/simple-channel.h"
+#include "ns3/address.h"
+#include "ns3/mac48-address.h"
+#include "ns3/packet.h"
+#include "ns3/callback.h"
+#include "ns3/node.h"
+#include "ns3/simulator.h"
+#include "ns3/error-model.h"
+#include "ns3/pointer.h"
+#include "ns3/double.h"
+#include "ns3/string.h"
+#include "ns3/rng-seed-manager.h"
+
+using namespace ns3;
+
+static void SendPacket (int num, Ptr<NetDevice> device, Address& addr)
+{
+ for (int i = 0; i < num; i++)
+ {
+ Ptr<Packet> pkt = Create<Packet> (1000); // 1000 dummy bytes of data
+ device->Send (pkt, addr, 0);
+ }
+}
+
+// Two nodes, two devices, one channel
+static void BuildSimpleTopology (Ptr<Node> a, Ptr<Node> b, Ptr<SimpleNetDevice> input, Ptr<SimpleNetDevice> output, Ptr<SimpleChannel> channel)
+{
+ a->AddDevice (input);
+ b->AddDevice (output);
+ input->SetAddress (Mac48Address::Allocate ());
+ input->SetChannel (channel);
+ input->SetNode (a);
+ output->SetChannel (channel);
+ output->SetNode (b);
+ output->SetAddress (Mac48Address::Allocate ());
+}
+
+class ErrorModelSimple : public TestCase
+{
+public:
+ ErrorModelSimple ();
+ virtual ~ErrorModelSimple ();
+
+private:
+ virtual void DoRun (void);
+ bool Receive (Ptr<NetDevice> nd, Ptr<const Packet> p, uint16_t protocol, const Address& addr);
+ void DropEvent (Ptr<const Packet> p);
+ uint32_t m_count;
+ uint32_t m_drops;
+};
+
+// Add some help text to this case to describe what it is intended to test
+ErrorModelSimple::ErrorModelSimple ()
+ : TestCase ("ErrorModel and PhyRxDrop trace for SimpleNetDevice"), m_count (0), m_drops (0)
+{
+}
+
+ErrorModelSimple::~ErrorModelSimple ()
+{
+}
+
+bool
+ErrorModelSimple::Receive (Ptr<NetDevice> nd, Ptr<const Packet> p, uint16_t protocol, const Address& addr)
+{
+ m_count++;
+ return true;
+}
+
+void
+ErrorModelSimple::DropEvent (Ptr<const Packet> p)
+{
+ m_drops++;
+}
+
+void
+ErrorModelSimple::DoRun (void)
+{
+ // Set some arbitrary deterministic values
+ RngSeedManager::SetSeed (7);
+ RngSeedManager::SetRun (2);
+
+ Ptr<Node> a = CreateObject<Node> ();
+ Ptr<Node> b = CreateObject<Node> ();
+
+ Ptr<SimpleNetDevice> input = CreateObject<SimpleNetDevice> ();
+ Ptr<SimpleNetDevice> output = CreateObject<SimpleNetDevice> ();
+ Ptr<SimpleChannel> channel = CreateObject<SimpleChannel> ();
+ BuildSimpleTopology (a, b, input, output, channel);
+
+ output->SetReceiveCallback (MakeCallback (&ErrorModelSimple::Receive, this));
+ Ptr<UniformRandomVariable> uv = CreateObject<UniformRandomVariable> ();
+ // Set this variable to a specific stream
+ uv->SetStream (50);
+
+ Ptr<RateErrorModel> em = CreateObject<RateErrorModel> ();
+ em->SetRandomVariable (uv);
+ em->SetAttribute ("ErrorRate", DoubleValue (0.001));
+ em->SetAttribute ("ErrorUnit", StringValue ("ERROR_UNIT_PACKET"));
+
+ // The below hooks will cause drops and receptions to be counted
+ output->SetAttribute ("ReceiveErrorModel", PointerValue (em));
+ output->TraceConnectWithoutContext ("PhyRxDrop", MakeCallback (&ErrorModelSimple::DropEvent, this));
+
+ // Send 10000 packets
+ Simulator::Schedule (Seconds (0), &SendPacket, 10000, input, output->GetAddress ());
+
+ Simulator::Run ();
+ Simulator::Destroy ();
+
+ // For this combination of values, we expect about 1 packet in 1000 to be
+ // dropped. For this specific RNG stream, we see 9991 receptions and 9 drops
+ NS_TEST_ASSERT_MSG_EQ (m_count, 9991, "Wrong number of receptions.");
+ NS_TEST_ASSERT_MSG_EQ (m_drops, 9, "Wrong number of drops.");
+}
+
+// This is the start of an error model test suite. For starters, this is
+// just testing that the SimpleNetDevice is working but this can be
+// extended to many more test cases in the future
+class ErrorModelTestSuite : public TestSuite
+{
+public:
+ ErrorModelTestSuite ();
+};
+
+ErrorModelTestSuite::ErrorModelTestSuite ()
+ : TestSuite ("error-model", UNIT)
+{
+ AddTestCase (new ErrorModelSimple, TestCase::QUICK);
+}
+
+// Do not forget to allocate an instance of this TestSuite
+static ErrorModelTestSuite errorModelTestSuite;
--- a/src/network/test/ipv6-address-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/ipv6-address-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -100,7 +100,7 @@
Ipv6AddressTestSuite::Ipv6AddressTestSuite ()
: TestSuite ("ipv6-address", UNIT)
{
- AddTestCase (new Ipv6AddressTestCase1);
+ AddTestCase (new Ipv6AddressTestCase1, TestCase::QUICK);
}
static Ipv6AddressTestSuite ipv6AddressTestSuite;
--- a/src/network/test/packet-metadata-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/packet-metadata-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -829,7 +829,7 @@
PacketMetadataTestSuite::PacketMetadataTestSuite ()
: TestSuite ("packet-metadata", UNIT)
{
- AddTestCase (new PacketMetadataTest);
+ AddTestCase (new PacketMetadataTest, TestCase::QUICK);
}
PacketMetadataTestSuite g_packetMetadataTest;
--- a/src/network/test/packet-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/packet-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -445,7 +445,7 @@
PacketTestSuite::PacketTestSuite ()
: TestSuite ("packet", UNIT)
{
- AddTestCase (new PacketTest);
+ AddTestCase (new PacketTest, TestCase::QUICK);
}
static PacketTestSuite g_packetTestSuite;
--- a/src/network/test/packetbb-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/packetbb-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -119,7 +119,7 @@
{
Ptr<PbbPacket> packet = Create<PbbPacket> ();
uint8_t buffer[] = { 0x00};
- AddTestCase (new PbbTestCase ("1", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("1", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 2
@@ -135,7 +135,7 @@
Ptr<PbbPacket> packet = Create<PbbPacket> ();
packet->SetSequenceNumber (2);
uint8_t buffer[] = { 0x08, 0x00, 0x02};
- AddTestCase (new PbbTestCase ("2", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("2", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 3
@@ -154,7 +154,7 @@
Ptr<PbbPacket> packet = Create<PbbPacket> ();
packet->SetSequenceNumber (3);
uint8_t buffer[] = { 0x0c, 0x00, 0x03, 0x00, 0x00};
- AddTestCase (new PbbTestCase ("3", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("3", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
#endif
@@ -183,7 +183,7 @@
0x0c, 0x00, 0x04, 0x00,
0x02, 0x01, 0x00
};
- AddTestCase (new PbbTestCase ("4", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("4", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 5
@@ -220,7 +220,7 @@
0x05, 0x01, 0x00, 0x02,
0x80, 0x64
};
- AddTestCase (new PbbTestCase ("5", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("5", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 6
@@ -263,7 +263,7 @@
0x90, 0x64, 0x04, 0x01,
0x02, 0x03, 0x04
};
- AddTestCase (new PbbTestCase ("6", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("6", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 7
@@ -530,7 +530,7 @@
0x25, 0x26, 0x27, 0x28,
0x29, 0x2a, 0x2b, 0x2c
};
- AddTestCase (new PbbTestCase ("7", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("7", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 8
@@ -571,7 +571,7 @@
0x03, 0x00, 0x06, 0x00,
0x00
};
- AddTestCase (new PbbTestCase ("8", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("8", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 9
@@ -627,7 +627,7 @@
0x0a, 0x0a, 0x00, 0x00,
0x01, 0x00, 0x00
};
- AddTestCase (new PbbTestCase ("9", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("9", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 10
@@ -685,7 +685,7 @@
0x0b, 0x0a, 0x00, 0x00,
0x01, 0x01, 0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("10", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("10", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 11
@@ -746,7 +746,7 @@
0x01, 0xff, 0x01, 0x00,
0x00
};
- AddTestCase (new PbbTestCase ("11", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("11", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 12
@@ -809,7 +809,7 @@
0x01, 0xff, 0x01, 0x30,
0x39, 0x00, 0x00
};
- AddTestCase (new PbbTestCase ("12", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("12", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 13
@@ -872,7 +872,7 @@
0x01, 0xff, 0x01, 0x30,
0x39, 0x00, 0x00
};
- AddTestCase (new PbbTestCase ("13", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("13", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 14
@@ -945,7 +945,7 @@
0x01, 0x30, 0x39, 0x00,
0x00
};
- AddTestCase (new PbbTestCase ("14", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("14", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 15
@@ -1029,7 +1029,7 @@
0x00, 0x00, 0x00, 0x00,
0x00
};
- AddTestCase (new PbbTestCase ("15", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("15", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 16
@@ -1113,7 +1113,7 @@
0xff, 0xff, 0xff, 0x00,
0x00,
};
- AddTestCase (new PbbTestCase ("16", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("16", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 17
@@ -1197,7 +1197,7 @@
0x00, 0x00, 0x01, 0x00,
0x00,
};
- AddTestCase (new PbbTestCase ("17", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("17", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 18
@@ -1281,7 +1281,7 @@
0x00, 0x00, 0x00, 0x00,
0x00,
};
- AddTestCase (new PbbTestCase ("18", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("18", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 19
@@ -1365,7 +1365,7 @@
0x00, 0x00, 0x01, 0x00,
0x00,
};
- AddTestCase (new PbbTestCase ("19", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("19", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 20
@@ -1451,7 +1451,7 @@
0x0a, 0x00, 0x00, 0x01,
0x02, 0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("20", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("20", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 21
@@ -1538,7 +1538,7 @@
0x00, 0x01, 0x01, 0x00,
0x00,
};
- AddTestCase (new PbbTestCase ("21", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("21", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 22
@@ -1636,7 +1636,7 @@
0x00, 0x02, 0x20, 0x03,
0x0a, 0x0b, 0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("22", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("22", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 23
@@ -1749,7 +1749,7 @@
0x20, 0x10, 0x18, 0x00,
0x00,
};
- AddTestCase (new PbbTestCase ("23", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("23", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 24
@@ -1869,7 +1869,7 @@
0x20, 0x10, 0x18, 0x00,
0x02, 0x01, 0x00,
};
- AddTestCase (new PbbTestCase ("24", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("24", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 25
@@ -1991,7 +1991,7 @@
0x20, 0x10, 0x18, 0x00,
0x03, 0x01, 0x40, 0x01,
};
- AddTestCase (new PbbTestCase ("25", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("25", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 26
@@ -2116,7 +2116,7 @@
0x04, 0x01, 0x20, 0x01,
0x03,
};
- AddTestCase (new PbbTestCase ("26", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("26", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 27
@@ -2247,7 +2247,7 @@
0x03, 0x03, 0x01, 0x02,
0x03,
};
- AddTestCase (new PbbTestCase ("27", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("27", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 28
@@ -2602,7 +2602,7 @@
0x26, 0x27, 0x28, 0x29,
0x2a, 0x2b, 0x2c
};
- AddTestCase (new PbbTestCase ("28", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("28", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 29
@@ -2632,7 +2632,7 @@
0x00, 0x01, 0x0f, 0x00,
0x06, 0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("29", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("29", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 30
@@ -2668,7 +2668,7 @@
0x00, 0x00, 0x00, 0x00,
0x01, 0x00, 0x00
};
- AddTestCase (new PbbTestCase ("30", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("30", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 31
@@ -2717,7 +2717,7 @@
0x00, 0x00, 0x00, 0x00,
0x01, 0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("31", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("31", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 32
@@ -2769,7 +2769,7 @@
0x00, 0x01, 0x02, 0x00,
0x00,
};
- AddTestCase (new PbbTestCase ("32", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("32", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 33
@@ -2821,7 +2821,7 @@
0x00, 0x02, 0x00, 0x11,
0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("33", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("33", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 34
@@ -2885,7 +2885,7 @@
0x01, 0x00, 0x0e, 0x10,
0x11, 0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("34", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("34", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 35
@@ -2972,7 +2972,7 @@
0x00, 0x06, 0x80, 0x80,
0x40, 0x30, 0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("35", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("35", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 36
@@ -3394,7 +3394,7 @@
0x80, 0x80, 0x40, 0x30,
0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("36", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("36", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
/* Test 37
@@ -3816,7 +3816,7 @@
0x80, 0x80, 0x40, 0x30,
0x00, 0x00,
};
- AddTestCase (new PbbTestCase ("37", packet, buffer, sizeof(buffer)));
+ AddTestCase (new PbbTestCase ("37", packet, buffer, sizeof(buffer)), TestCase::QUICK);
}
}
--- a/src/network/test/pcap-file-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/pcap-file-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -1111,13 +1111,13 @@
: TestSuite ("pcap-file", UNIT)
{
SetDataDir (NS_TEST_SOURCEDIR);
- AddTestCase (new WriteModeCreateTestCase);
- AddTestCase (new ReadModeCreateTestCase);
- //AddTestCase (new AppendModeCreateTestCase);
- AddTestCase (new FileHeaderTestCase);
- AddTestCase (new RecordHeaderTestCase);
- AddTestCase (new ReadFileTestCase);
- AddTestCase (new DiffTestCase);
+ AddTestCase (new WriteModeCreateTestCase, TestCase::QUICK);
+ AddTestCase (new ReadModeCreateTestCase, TestCase::QUICK);
+ //AddTestCase (new AppendModeCreateTestCase, TestCase::QUICK);
+ AddTestCase (new FileHeaderTestCase, TestCase::QUICK);
+ AddTestCase (new RecordHeaderTestCase, TestCase::QUICK);
+ AddTestCase (new ReadFileTestCase, TestCase::QUICK);
+ AddTestCase (new DiffTestCase, TestCase::QUICK);
}
static PcapFileTestSuite pcapFileTestSuite;
--- a/src/network/test/red-queue-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/red-queue-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -276,6 +276,6 @@
RedQueueTestSuite ()
: TestSuite ("red-queue", UNIT)
{
- AddTestCase (new RedQueueTestCase ());
+ AddTestCase (new RedQueueTestCase (), TestCase::QUICK);
}
} g_redQueueTestSuite;
--- a/src/network/test/sequence-number-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/test/sequence-number-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -186,6 +186,6 @@
SequenceNumberTestSuite ()
: TestSuite ("SequenceNumber", UNIT)
{
- AddTestCase (new SequenceNumberTestCase ());
+ AddTestCase (new SequenceNumberTestCase (), TestCase::QUICK);
}
} g_seqNumTests;
--- a/src/network/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/network/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -62,6 +62,7 @@
network_test.source = [
'test/buffer-test.cc',
'test/drop-tail-queue-test-suite.cc',
+ 'test/error-model-test-suite.cc',
'test/ipv6-address-test-suite.cc',
'test/packetbb-test-suite.cc',
'test/packet-test-suite.cc',
@@ -71,7 +72,7 @@
'test/sequence-number-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'network'
headers.source = [
'model/address.h',
@@ -135,6 +136,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/nix-vector-routing/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/nix-vector-routing/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -8,7 +8,7 @@
'helper/ipv4-nix-vector-helper.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'nix-vector-routing'
headers.source = [
'model/ipv4-nix-vector-routing.h',
@@ -16,6 +16,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/olsr/test/olsr-header-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/olsr/test/olsr-header-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -305,11 +305,11 @@
OlsrTestSuite::OlsrTestSuite()
: TestSuite ("routing-olsr-header", UNIT)
{
- AddTestCase (new OlsrHnaTestCase ());
- AddTestCase (new OlsrTcTestCase ());
- AddTestCase (new OlsrHelloTestCase ());
- AddTestCase (new OlsrMidTestCase ());
- AddTestCase (new OlsrEmfTestCase ());
+ AddTestCase (new OlsrHnaTestCase (), TestCase::QUICK);
+ AddTestCase (new OlsrTcTestCase (), TestCase::QUICK);
+ AddTestCase (new OlsrHelloTestCase (), TestCase::QUICK);
+ AddTestCase (new OlsrMidTestCase (), TestCase::QUICK);
+ AddTestCase (new OlsrEmfTestCase (), TestCase::QUICK);
}
} // namespace ns3
--- a/src/olsr/test/olsr-routing-protocol-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/olsr/test/olsr-routing-protocol-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -176,7 +176,7 @@
OlsrProtocolTestSuite::OlsrProtocolTestSuite()
: TestSuite ("routing-olsr", UNIT)
{
- AddTestCase (new OlsrMprTestCase ());
+ AddTestCase (new OlsrMprTestCase (), TestCase::QUICK);
}
}
--- a/src/olsr/test/regression-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/olsr/test/regression-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -31,9 +31,9 @@
RegressionTestSuite () : TestSuite ("routing-olsr-regression", SYSTEM)
{
SetDataDir (NS_TEST_SOURCEDIR);
- AddTestCase (new HelloRegressionTest);
- AddTestCase (new TcRegressionTest);
- AddTestCase (new Bug780Test);
+ AddTestCase (new HelloRegressionTest, TestCase::QUICK);
+ AddTestCase (new TcRegressionTest, TestCase::QUICK);
+ AddTestCase (new Bug780Test, TestCase::QUICK);
}
} g_olsrRegressionTestSuite;
--- a/src/olsr/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/olsr/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -20,7 +20,7 @@
'test/tc-regression-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'olsr'
headers.source = [
'model/olsr-routing-protocol.h',
@@ -32,6 +32,6 @@
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/openflow/model/openflow-switch-net-device.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/openflow/model/openflow-switch-net-device.cc Fri Apr 05 17:59:11 2013 +0200
@@ -522,8 +522,8 @@
{
buffer->l4 = new tcp_header;
tcp_header* tcp_h = (tcp_header*)buffer->l4;
- tcp_h->tcp_src = htonl (tcp_hd.GetSourcePort ()); // Source Port
- tcp_h->tcp_dst = htonl (tcp_hd.GetDestinationPort ()); // Destination Port
+ tcp_h->tcp_src = htons (tcp_hd.GetSourcePort ()); // Source Port
+ tcp_h->tcp_dst = htons (tcp_hd.GetDestinationPort ()); // Destination Port
tcp_h->tcp_seq = tcp_hd.GetSequenceNumber ().GetValue (); // Sequence Number
tcp_h->tcp_ack = tcp_hd.GetAckNumber ().GetValue (); // ACK Number
tcp_h->tcp_ctl = TCP_FLAGS (tcp_hd.GetFlags ()); // Data Offset + Reserved + Flags
@@ -541,8 +541,8 @@
{
buffer->l4 = new udp_header;
udp_header* udp_h = (udp_header*)buffer->l4;
- udp_h->udp_src = htonl (udp_hd.GetSourcePort ()); // Source Port
- udp_h->udp_dst = htonl (udp_hd.GetDestinationPort ()); // Destination Port
+ udp_h->udp_src = htons (udp_hd.GetSourcePort ()); // Source Port
+ udp_h->udp_dst = htons (udp_hd.GetDestinationPort ()); // Destination Port
udp_h->udp_len = htons (UDP_HEADER_LEN + packet->GetSize ());
if (protocol == Ipv4L3Protocol::PROT_NUMBER)
--- a/src/openflow/test/openflow-switch-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/openflow/test/openflow-switch-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -181,7 +181,7 @@
SwitchTestSuite::SwitchTestSuite () : TestSuite ("openflow", UNIT)
{
- AddTestCase (new SwitchFlowTableTestCase);
+ AddTestCase (new SwitchFlowTableTestCase, TestCase::QUICK);
}
// Do not forget to allocate an instance of this TestSuite
--- a/src/openflow/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/openflow/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -1,25 +1,21 @@
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
import os
-import Options
+from waflib import Logs, Options
from waflib.Errors import WafError
def options(opt):
opt.add_option('--with-openflow',
help=('Path to OFSID source for NS-3 OpenFlow Integration support'),
default='', dest='with_openflow')
- opt.tool_options('boost', tooldir=["waf-tools"])
+
+REQUIRED_BOOST_LIBS = ['system', 'signals', 'filesystem']
+
+def required_boost_libs(conf):
+ conf.env['REQUIRED_BOOST_LIBS'] += REQUIRED_BOOST_LIBS
def configure(conf):
- try:
- conf.check_tool('boost')
- conf.check_boost(lib='signals filesystem')
- if not conf.env.LIB_BOOST:
- conf.check_boost(lib='signals filesystem', libpath="/usr/lib64")
- except WafError:
- conf.env['LIB_BOOST'] = []
-
- if not conf.env.LIB_BOOST:
+ if not conf.env['LIB_BOOST']:
conf.report_optional_feature("openflow", "NS-3 OpenFlow Integration", False,
"Required boost libraries not found")
@@ -29,6 +25,25 @@
return
+ present_boost_libs = []
+ for boost_lib_name in conf.env['LIB_BOOST']:
+ if boost_lib_name.startswith("boost_"):
+ boost_lib_name = boost_lib_name[6:]
+ if boost_lib_name.endswith("-mt"):
+ boost_lib_name = boost_lib_name[:-3]
+ present_boost_libs.append(boost_lib_name)
+
+ missing_boost_libs = [lib for lib in REQUIRED_BOOST_LIBS if lib not in present_boost_libs]
+ if missing_boost_libs != []:
+ conf.report_optional_feature("openflow", "NS-3 OpenFlow Integration", False,
+ "Required boost libraries not found, missing: %s" % ', '.join(missing_boost_libs))
+
+ # Add this module to the list of modules that won't be built
+ # if they are enabled.
+ conf.env['MODULES_NOT_BUILT'].append('openflow')
+
+ return
+
if Options.options.with_openflow:
if os.path.isdir(Options.options.with_openflow):
conf.msg("Checking for OpenFlow location", ("%s (given)" % Options.options.with_openflow))
@@ -142,7 +157,7 @@
obj.use.extend('OPENFLOW DL XML2'.split())
obj_test.use.extend('OPENFLOW DL XML2'.split())
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'openflow'
headers.source = [
]
@@ -160,4 +175,4 @@
headers.source.append('helper/openflow-switch-helper.h')
if bld.env['ENABLE_EXAMPLES'] and bld.env['ENABLE_OPENFLOW']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
--- a/src/point-to-point-layout/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/point-to-point-layout/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -9,7 +9,7 @@
'model/point-to-point-star.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'point-to-point-layout'
headers.source = [
'model/point-to-point-dumbbell.h',
--- a/src/point-to-point/test/point-to-point-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/point-to-point/test/point-to-point-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -65,7 +65,7 @@
PointToPointTestSuite::PointToPointTestSuite ()
: TestSuite ("devices-point-to-point", UNIT)
{
- AddTestCase (new PointToPointTest);
+ AddTestCase (new PointToPointTest, TestCase::QUICK);
}
static PointToPointTestSuite g_pointToPointTestSuite;
--- a/src/point-to-point/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/point-to-point/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -16,7 +16,7 @@
'test/point-to-point-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'point-to-point'
headers.source = [
'model/point-to-point-net-device.h',
@@ -27,6 +27,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/propagation/test/itu-r-1411-los-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/propagation/test/itu-r-1411-los-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -110,9 +110,9 @@
// reference values obtained with the octave scripts in src/propagation/test/reference/
- AddTestCase (new ItuR1411LosPropagationLossModelTestCase (2.1140e9, 100, 30, 1, 81.005, "freq=2114MHz, dist=100m"));
+ AddTestCase (new ItuR1411LosPropagationLossModelTestCase (2.1140e9, 100, 30, 1, 81.005, "freq=2114MHz, dist=100m"), TestCase::QUICK);
- AddTestCase (new ItuR1411LosPropagationLossModelTestCase (1999e6, 200, 30, 1, 87.060, "freq=1999MHz, dist=200m"));
+ AddTestCase (new ItuR1411LosPropagationLossModelTestCase (1999e6, 200, 30, 1, 87.060, "freq=1999MHz, dist=200m"), TestCase::QUICK);
--- a/src/propagation/test/itu-r-1411-nlos-over-rooftop-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/propagation/test/itu-r-1411-nlos-over-rooftop-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -116,9 +116,9 @@
// reference values obtained with the octave scripts in src/propagation/test/reference/
- AddTestCase (new ItuR1411NlosOverRooftopPropagationLossModelTestCase (2.1140e9, 900, 30, 1, UrbanEnvironment, LargeCity, 143.68, "f=2114Mhz, dist=900, urban large city"));
+ AddTestCase (new ItuR1411NlosOverRooftopPropagationLossModelTestCase (2.1140e9, 900, 30, 1, UrbanEnvironment, LargeCity, 143.68, "f=2114Mhz, dist=900, urban large city"), TestCase::QUICK);
- AddTestCase (new ItuR1411NlosOverRooftopPropagationLossModelTestCase (1.865e9, 500, 30, 1, UrbanEnvironment, LargeCity, 132.84, "f=2114Mhz, dist=900, urban large city"));
+ AddTestCase (new ItuR1411NlosOverRooftopPropagationLossModelTestCase (1.865e9, 500, 30, 1, UrbanEnvironment, LargeCity, 132.84, "f=2114Mhz, dist=900, urban large city"), TestCase::QUICK);
}
--- a/src/propagation/test/kun-2600-mhz-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/propagation/test/kun-2600-mhz-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -105,7 +105,7 @@
LogComponentEnable ("Kun2600MhzPropagationLossModelTest", LOG_LEVEL_ALL);
- AddTestCase (new Kun2600MhzPropagationLossModelTestCase (2000, 30, 1, 121.83, "dist=2000m"));
+ AddTestCase (new Kun2600MhzPropagationLossModelTestCase (2000, 30, 1, 121.83, "dist=2000m"), TestCase::QUICK);
}
--- a/src/propagation/test/okumura-hata-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/propagation/test/okumura-hata-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -120,20 +120,20 @@
double freq = 869e6; // this will use the original OH model
- AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, LargeCity, 137.93, "original OH Urban Large city"));
+ AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, LargeCity, 137.93, "original OH Urban Large city"), TestCase::QUICK);
- AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, SmallCity, 137.88, "original OH Urban small city"));
+ AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, SmallCity, 137.88, "original OH Urban small city"), TestCase::QUICK);
- AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, SubUrbanEnvironment, LargeCity, 128.03, "original OH SubUrban"));
+ AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, SubUrbanEnvironment, LargeCity, 128.03, "original OH SubUrban"), TestCase::QUICK);
- AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, OpenAreasEnvironment, LargeCity, 110.21, "original OH OpenAreas"));
+ AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, OpenAreasEnvironment, LargeCity, 110.21, "original OH OpenAreas"), TestCase::QUICK);
freq = 2.1140e9; // this will use the extended COST231 OH model
- AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, LargeCity, 148.55, "COST231 OH Urban Large city"));
+ AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, LargeCity, 148.55, "COST231 OH Urban Large city"), TestCase::QUICK);
- AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, SmallCity, 150.64, "COST231 OH Urban small city and suburban"));
+ AddTestCase (new OkumuraHataPropagationLossModelTestCase (freq, 2000, 30, 1, UrbanEnvironment, SmallCity, 150.64, "COST231 OH Urban small city and suburban"), TestCase::QUICK);
}
--- a/src/propagation/test/propagation-loss-model-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/propagation/test/propagation-loss-model-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -443,11 +443,11 @@
PropagationLossModelsTestSuite::PropagationLossModelsTestSuite ()
: TestSuite ("propagation-loss-model", UNIT)
{
- AddTestCase (new FriisPropagationLossModelTestCase);
- AddTestCase (new TwoRayGroundPropagationLossModelTestCase);
- AddTestCase (new LogDistancePropagationLossModelTestCase);
- AddTestCase (new MatrixPropagationLossModelTestCase);
- AddTestCase (new RangePropagationLossModelTestCase);
+ AddTestCase (new FriisPropagationLossModelTestCase, TestCase::QUICK);
+ AddTestCase (new TwoRayGroundPropagationLossModelTestCase, TestCase::QUICK);
+ AddTestCase (new LogDistancePropagationLossModelTestCase, TestCase::QUICK);
+ AddTestCase (new MatrixPropagationLossModelTestCase, TestCase::QUICK);
+ AddTestCase (new RangePropagationLossModelTestCase, TestCase::QUICK);
}
static PropagationLossModelsTestSuite propagationLossModelsTestSuite;
--- a/src/propagation/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/propagation/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -24,7 +24,7 @@
'test/itu-r-1411-nlos-over-rooftop-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'propagation'
headers.source = [
'model/propagation-delay-model.h',
@@ -41,6 +41,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/spectrum/test/spectrum-ideal-phy-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/spectrum/test/spectrum-ideal-phy-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -224,22 +224,22 @@
for (double snr = 0.01; snr <= 10 ; snr *= 2)
{
double achievableRate = g_bandwidth*log2(1+snr);
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.1), true, "ns3::SingleModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.5), true, "ns3::SingleModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.95), true, "ns3::SingleModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*1.05), false, "ns3::SingleModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*2), false, "ns3::SingleModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*4), false, "ns3::SingleModelSpectrumChannel"));
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.1), true, "ns3::SingleModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.5), true, "ns3::SingleModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.95), true, "ns3::SingleModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*1.05), false, "ns3::SingleModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*2), false, "ns3::SingleModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*4), false, "ns3::SingleModelSpectrumChannel"), TestCase::QUICK);
}
for (double snr = 0.01; snr <= 10 ; snr *= 10)
{
double achievableRate = g_bandwidth*log2(1+snr);
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.1), true, "ns3::MultiModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.5), true, "ns3::MultiModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.95), true, "ns3::MultiModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*1.05), false, "ns3::MultiModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*2), false, "ns3::MultiModelSpectrumChannel"));
- AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*4), false, "ns3::MultiModelSpectrumChannel"));
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.1), true, "ns3::MultiModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.5), true, "ns3::MultiModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*0.95), true, "ns3::MultiModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*1.05), false, "ns3::MultiModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*2), false, "ns3::MultiModelSpectrumChannel"), TestCase::QUICK);
+ AddTestCase (new SpectrumIdealPhyTestCase (snr, static_cast<uint64_t> (achievableRate*4), false, "ns3::MultiModelSpectrumChannel"), TestCase::QUICK);
}
}
--- a/src/spectrum/test/spectrum-interference-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/spectrum/test/spectrum-interference-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -171,24 +171,24 @@
(*s1)[0] = 1.255943215755e-15;
(*s1)[1] = 7.204059965732e-16;
b = 10067205.5632012;
- AddTestCase (new SpectrumInterferenceTestCase (s1, 0, true, "sdBm = [-46 -48] tx bytes: 1"));
- AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * 0.5 + 0.5), true, "sdBm = [-46 -48] tx bytes: b*0.5"));
- AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * (1 - e) + 0.5), true, "sdBm = [-46 -48] tx bytes: b*(1-e)"));
- AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * (1 + e) + 0.5), false, "sdBm = [-46 -48] tx bytes: b*(1+e)"));
- AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * 1.5 + 0.5), false, "sdBm = [-46 -48] tx bytes: b*1.5"));
- AddTestCase (new SpectrumInterferenceTestCase (s1, 0xffffffff, false, "sdBm = [-46 -48] tx bytes: 2^32-1"));
+ AddTestCase (new SpectrumInterferenceTestCase (s1, 0, true, "sdBm = [-46 -48] tx bytes: 1"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * 0.5 + 0.5), true, "sdBm = [-46 -48] tx bytes: b*0.5"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * (1 - e) + 0.5), true, "sdBm = [-46 -48] tx bytes: b*(1-e)"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * (1 + e) + 0.5), false, "sdBm = [-46 -48] tx bytes: b*(1+e)"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s1, static_cast<uint32_t> (b * 1.5 + 0.5), false, "sdBm = [-46 -48] tx bytes: b*1.5"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s1, 0xffffffff, false, "sdBm = [-46 -48] tx bytes: 2^32-1"), TestCase::QUICK);
// Power Spectral Density of the signal of interest = [-63 -61] dBm;
Ptr<SpectrumValue> s2 = Create<SpectrumValue> (m);
(*s2)[0] = 2.505936168136e-17;
(*s2)[1] = 3.610582885110e-17;
b = 882401.591840728;
- AddTestCase (new SpectrumInterferenceTestCase (s2, 1, true, "sdBm = [-63 -61] tx bytes: 1"));
- AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * 0.5 + 0.5), true, "sdBm = [-63 -61] tx bytes: b*0.5"));
- AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * (1 - e) + 0.5), true, "sdBm = [-63 -61] tx bytes: b*(1-e)"));
- AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * (1 + e) + 0.5), false, "sdBm = [-63 -61] tx bytes: b*(1+e)"));
- AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * 1.5 + 0.5), false, "sdBm = [-63 -61] tx bytes: b*1.5"));
- AddTestCase (new SpectrumInterferenceTestCase (s2, 0xffffffff, false, "sdBm = [-63 -61] tx bytes: 2^32-1"));
+ AddTestCase (new SpectrumInterferenceTestCase (s2, 1, true, "sdBm = [-63 -61] tx bytes: 1"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * 0.5 + 0.5), true, "sdBm = [-63 -61] tx bytes: b*0.5"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * (1 - e) + 0.5), true, "sdBm = [-63 -61] tx bytes: b*(1-e)"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * (1 + e) + 0.5), false, "sdBm = [-63 -61] tx bytes: b*(1+e)"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s2, static_cast<uint32_t> (b * 1.5 + 0.5), false, "sdBm = [-63 -61] tx bytes: b*1.5"), TestCase::QUICK);
+ AddTestCase (new SpectrumInterferenceTestCase (s2, 0xffffffff, false, "sdBm = [-63 -61] tx bytes: 2^32-1"), TestCase::QUICK);
}
--- a/src/spectrum/test/spectrum-value-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/spectrum/test/spectrum-value-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -180,10 +180,10 @@
tv6 = v1 / v2;
- AddTestCase (new SpectrumValueTestCase (tv3, v3, "tv3 = v1 + v2"));
- AddTestCase (new SpectrumValueTestCase (tv4, v4, "tv4 = v1 - v2"));
- AddTestCase (new SpectrumValueTestCase (tv5, v5, "tv5 = v1 * v2"));
- AddTestCase (new SpectrumValueTestCase (tv6, v6, "tv6 = v1 div v2"));
+ AddTestCase (new SpectrumValueTestCase (tv3, v3, "tv3 = v1 + v2"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv4, v4, "tv4 = v1 - v2"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv5, v5, "tv5 = v1 * v2"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv6, v6, "tv6 = v1 div v2"), TestCase::QUICK);
// std::cerr << v6 << std::endl;
// std::cerr << tv6 << std::endl;
@@ -199,30 +199,30 @@
tv5 *= v2;
tv6 /= v2;
- AddTestCase (new SpectrumValueTestCase (tv3, v3, "tv3 += v2"));
- AddTestCase (new SpectrumValueTestCase (tv4, v4, "tv4 -= v2"));
- AddTestCase (new SpectrumValueTestCase (tv5, v5, "tv5 *= v2"));
- AddTestCase (new SpectrumValueTestCase (tv6, v6, "tv6 div= v2"));
+ AddTestCase (new SpectrumValueTestCase (tv3, v3, "tv3 += v2"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv4, v4, "tv4 -= v2"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv5, v5, "tv5 *= v2"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv6, v6, "tv6 div= v2"), TestCase::QUICK);
SpectrumValue tv7a (f), tv8a (f), tv9a (f), tv10a (f);
tv7a = v1 + doubleValue;
tv8a = v1 - doubleValue;
tv9a = v1 * doubleValue;
tv10a = v1 / doubleValue;
- AddTestCase (new SpectrumValueTestCase (tv7a, v7, "tv7a = v1 + doubleValue"));
- AddTestCase (new SpectrumValueTestCase (tv8a, v8, "tv8a = v1 - doubleValue"));
- AddTestCase (new SpectrumValueTestCase (tv9a, v9, "tv9a = v1 * doubleValue"));
- AddTestCase (new SpectrumValueTestCase (tv10a, v10, "tv10a = v1 div doubleValue"));
+ AddTestCase (new SpectrumValueTestCase (tv7a, v7, "tv7a = v1 + doubleValue"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv8a, v8, "tv8a = v1 - doubleValue"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv9a, v9, "tv9a = v1 * doubleValue"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv10a, v10, "tv10a = v1 div doubleValue"), TestCase::QUICK);
SpectrumValue tv7b (f), tv8b (f), tv9b (f), tv10b (f);
tv7b = doubleValue + v1;
tv8b = doubleValue - v1;
tv9b = doubleValue * v1;
tv10b = doubleValue / v1;
- AddTestCase (new SpectrumValueTestCase (tv7b, v7, "tv7b = doubleValue + v1"));
- AddTestCase (new SpectrumValueTestCase (tv8b, v8, "tv8b = doubleValue - v1"));
- AddTestCase (new SpectrumValueTestCase (tv9b, v9, "tv9b = doubleValue * v1"));
- AddTestCase (new SpectrumValueTestCase (tv10b, v10, "tv10b = doubleValue div v1"));
+ AddTestCase (new SpectrumValueTestCase (tv7b, v7, "tv7b = doubleValue + v1"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv8b, v8, "tv8b = doubleValue - v1"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv9b, v9, "tv9b = doubleValue * v1"), TestCase::QUICK);
+ AddTestCase (new SpectrumValueTestCase (tv10b, v10, "tv10b = doubleValue div v1"), TestCase::QUICK);
@@ -234,13 +234,13 @@
v1ls3[0] = v1[3];
v1ls3[1] = v1[4];
tv1ls3 = v1 << 3;
- AddTestCase (new SpectrumValueTestCase (tv1ls3, v1ls3, "tv1ls3 = v1 << 3"));
+ AddTestCase (new SpectrumValueTestCase (tv1ls3, v1ls3, "tv1ls3 = v1 << 3"), TestCase::QUICK);
v1rs3[3] = v1[0];
v1rs3[4] = v1[1];
tv1rs3 = v1 >> 3;
- AddTestCase (new SpectrumValueTestCase (tv1rs3, v1rs3, "tv1rs3 = v1 >> 3"));
+ AddTestCase (new SpectrumValueTestCase (tv1rs3, v1rs3, "tv1rs3 = v1 >> 3"), TestCase::QUICK);
}
@@ -296,7 +296,7 @@
// NS_LOG_LOGIC(t12);
// NS_LOG_LOGIC(*res);
- AddTestCase (new SpectrumValueTestCase (t12, *res, ""));
+ AddTestCase (new SpectrumValueTestCase (t12, *res, ""), TestCase::QUICK);
// TEST_ASSERT(MoreOrLessEqual(t12, *res));
Ptr<SpectrumValue> v2a = Create<SpectrumValue> (sof2);
@@ -308,7 +308,7 @@
// NS_LOG_LOGIC(*v2a);
// NS_LOG_LOGIC(t21a);
// NS_LOG_LOGIC(*res);
- AddTestCase (new SpectrumValueTestCase (t21a, *res, ""));
+ AddTestCase (new SpectrumValueTestCase (t21a, *res, ""), TestCase::QUICK);
// TEST_ASSERT(MoreOrLessEqual(t21a, *res));
Ptr<SpectrumValue> v2b = Create<SpectrumValue> (sof2);
@@ -327,7 +327,7 @@
// NS_LOG_LOGIC(*v2b);
// NS_LOG_LOGIC(t21b);
// NS_LOG_LOGIC(*res);
- AddTestCase (new SpectrumValueTestCase (t21b, *res, ""));
+ AddTestCase (new SpectrumValueTestCase (t21b, *res, ""), TestCase::QUICK);
}
--- a/src/spectrum/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/spectrum/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -41,7 +41,7 @@
'test/spectrum-ideal-phy-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'spectrum'
headers.source = [
'model/spectrum-model.h',
@@ -76,7 +76,7 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/stats/test/basic-data-calculators-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/stats/test/basic-data-calculators-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -270,9 +270,9 @@
BasicDataCalculatorsTestSuite::BasicDataCalculatorsTestSuite ()
: TestSuite ("basic-data-calculators", UNIT)
{
- AddTestCase (new OneIntegerTestCase);
- AddTestCase (new FiveIntegersTestCase);
- AddTestCase (new FiveDoublesTestCase);
+ AddTestCase (new OneIntegerTestCase, TestCase::QUICK);
+ AddTestCase (new FiveIntegersTestCase, TestCase::QUICK);
+ AddTestCase (new FiveDoublesTestCase, TestCase::QUICK);
}
static BasicDataCalculatorsTestSuite basicDataCalculatorsTestSuite;
--- a/src/stats/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/stats/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -1,13 +1,14 @@
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
def configure(conf):
- conf.env['SQLITE_STATS'] = conf.check_nonfatal(lib='sqlite3', define_name='SQLITE3', uselib_store='SQLITE3')
- if not conf.env['SQLITE_STATS']:
- conf.env['SQLITE_STATS'] = conf.pkg_check_modules('SQLITE3', 'sqlite3', mandatory=False)
- conf.report_optional_feature("SqliteDataOutput", "SQlite stats data output",
- conf.env['SQLITE_STATS'],
- "library 'sqlite3' not found")
+ have_sqlite3 = conf.check_cfg(package='sqlite3', uselib_store='SQLITE3',
+ args=['--cflags', '--libs'],
+ mandatory=False)
+ conf.env['SQLITE_STATS'] = have_sqlite3
+ conf.report_optional_feature("SqliteDataOutput", "SQlite stats data output",
+ conf.env['SQLITE_STATS'],
+ "library 'sqlite3' not found")
def build(bld):
obj = bld.create_ns3_module('stats', ['network'])
@@ -25,7 +26,7 @@
'test/basic-data-calculators-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'stats'
headers.source = [
'model/data-calculator.h',
--- a/src/tap-bridge/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/tap-bridge/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -34,7 +34,7 @@
'model/tap-encode-decode.cc',
'helper/tap-bridge-helper.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'tap-bridge'
headers.source = [
'model/tap-bridge.h',
@@ -52,6 +52,6 @@
module.env.append_value("DEFINES", "TAP_CREATOR=\"%s\"" % (tap_creator.target,))
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/test/csma-system-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/csma-system-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -1079,14 +1079,14 @@
CsmaSystemTestSuite::CsmaSystemTestSuite ()
: TestSuite ("csma-system", UNIT)
{
- AddTestCase (new CsmaBridgeTestCase);
- AddTestCase (new CsmaBroadcastTestCase);
- AddTestCase (new CsmaMulticastTestCase);
- AddTestCase (new CsmaOneSubnetTestCase);
- AddTestCase (new CsmaPacketSocketTestCase);
- AddTestCase (new CsmaPingTestCase);
- AddTestCase (new CsmaRawIpSocketTestCase);
- AddTestCase (new CsmaStarTestCase);
+ AddTestCase (new CsmaBridgeTestCase, TestCase::QUICK);
+ AddTestCase (new CsmaBroadcastTestCase, TestCase::QUICK);
+ AddTestCase (new CsmaMulticastTestCase, TestCase::QUICK);
+ AddTestCase (new CsmaOneSubnetTestCase, TestCase::QUICK);
+ AddTestCase (new CsmaPacketSocketTestCase, TestCase::QUICK);
+ AddTestCase (new CsmaPingTestCase, TestCase::QUICK);
+ AddTestCase (new CsmaRawIpSocketTestCase, TestCase::QUICK);
+ AddTestCase (new CsmaStarTestCase, TestCase::QUICK);
}
// Do not forget to allocate an instance of this TestSuite
--- a/src/test/error-model-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,136 +0,0 @@
-/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-
-#include "ns3/test.h"
-#include "ns3/simple-net-device.h"
-#include "ns3/simple-channel.h"
-#include "ns3/address.h"
-#include "ns3/mac48-address.h"
-#include "ns3/packet.h"
-#include "ns3/callback.h"
-#include "ns3/node.h"
-#include "ns3/simulator.h"
-#include "ns3/error-model.h"
-#include "ns3/pointer.h"
-#include "ns3/double.h"
-#include "ns3/string.h"
-#include "ns3/rng-seed-manager.h"
-
-using namespace ns3;
-
-static void SendPacket (int num, Ptr<NetDevice> device, Address& addr)
-{
- for (int i = 0; i < num; i++)
- {
- Ptr<Packet> pkt = Create<Packet> (1000); // 1000 dummy bytes of data
- device->Send (pkt, addr, 0);
- }
-}
-
-// Two nodes, two devices, one channel
-static void BuildSimpleTopology (Ptr<Node> a, Ptr<Node> b, Ptr<SimpleNetDevice> input, Ptr<SimpleNetDevice> output, Ptr<SimpleChannel> channel)
-{
- a->AddDevice (input);
- b->AddDevice (output);
- input->SetAddress (Mac48Address::Allocate ());
- input->SetChannel (channel);
- input->SetNode (a);
- output->SetChannel (channel);
- output->SetNode (b);
- output->SetAddress (Mac48Address::Allocate ());
-}
-
-class ErrorModelSimple : public TestCase
-{
-public:
- ErrorModelSimple ();
- virtual ~ErrorModelSimple ();
-
-private:
- virtual void DoRun (void);
- bool Receive (Ptr<NetDevice> nd, Ptr<const Packet> p, uint16_t protocol, const Address& addr);
- void DropEvent (Ptr<const Packet> p);
- uint32_t m_count;
- uint32_t m_drops;
-};
-
-// Add some help text to this case to describe what it is intended to test
-ErrorModelSimple::ErrorModelSimple ()
- : TestCase ("ErrorModel and PhyRxDrop trace for SimpleNetDevice"), m_count (0), m_drops (0)
-{
-}
-
-ErrorModelSimple::~ErrorModelSimple ()
-{
-}
-
-bool
-ErrorModelSimple::Receive (Ptr<NetDevice> nd, Ptr<const Packet> p, uint16_t protocol, const Address& addr)
-{
- m_count++;
- return true;
-}
-
-void
-ErrorModelSimple::DropEvent (Ptr<const Packet> p)
-{
- m_drops++;
-}
-
-void
-ErrorModelSimple::DoRun (void)
-{
- // Set some arbitrary deterministic values
- RngSeedManager::SetSeed (7);
- RngSeedManager::SetRun (2);
-
- Ptr<Node> a = CreateObject<Node> ();
- Ptr<Node> b = CreateObject<Node> ();
-
- Ptr<SimpleNetDevice> input = CreateObject<SimpleNetDevice> ();
- Ptr<SimpleNetDevice> output = CreateObject<SimpleNetDevice> ();
- Ptr<SimpleChannel> channel = CreateObject<SimpleChannel> ();
- BuildSimpleTopology (a, b, input, output, channel);
-
- output->SetReceiveCallback (MakeCallback (&ErrorModelSimple::Receive, this));
- Ptr<UniformRandomVariable> uv = CreateObject<UniformRandomVariable> ();
- // Set this variable to a specific stream
- uv->SetStream (50);
-
- Ptr<RateErrorModel> em = CreateObject<RateErrorModel> ();
- em->SetRandomVariable (uv);
- em->SetAttribute ("ErrorRate", DoubleValue (0.001));
- em->SetAttribute ("ErrorUnit", StringValue ("ERROR_UNIT_PACKET"));
-
- // The below hooks will cause drops and receptions to be counted
- output->SetAttribute ("ReceiveErrorModel", PointerValue (em));
- output->TraceConnectWithoutContext ("PhyRxDrop", MakeCallback (&ErrorModelSimple::DropEvent, this));
-
- // Send 10000 packets
- Simulator::Schedule (Seconds (0), &SendPacket, 10000, input, output->GetAddress ());
-
- Simulator::Run ();
- Simulator::Destroy ();
-
- // For this combination of values, we expect about 1 packet in 1000 to be
- // dropped. For this specific RNG stream, we see 9991 receptions and 9 drops
- NS_TEST_ASSERT_MSG_EQ (m_count, 9991, "Wrong number of receptions.");
- NS_TEST_ASSERT_MSG_EQ (m_drops, 9, "Wrong number of drops.");
-}
-
-// This is the start of an error model test suite. For starters, this is
-// just testing that the SimpleNetDevice is working but this can be
-// extended to many more test cases in the future
-class ErrorModelTestSuite : public TestSuite
-{
-public:
- ErrorModelTestSuite ();
-};
-
-ErrorModelTestSuite::ErrorModelTestSuite ()
- : TestSuite ("error-model", UNIT)
-{
- AddTestCase (new ErrorModelSimple);
-}
-
-// Do not forget to allocate an instance of this TestSuite
-static ErrorModelTestSuite errorModelTestSuite;
--- a/src/test/global-routing-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/global-routing-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -395,8 +395,8 @@
GlobalRoutingTestSuite::GlobalRoutingTestSuite ()
: TestSuite ("global-routing", UNIT)
{
- AddTestCase (new DynamicGlobalRoutingTestCase);
- AddTestCase (new GlobalRoutingSlash32TestCase);
+ AddTestCase (new DynamicGlobalRoutingTestCase, TestCase::QUICK);
+ AddTestCase (new GlobalRoutingSlash32TestCase, TestCase::QUICK);
}
// Do not forget to allocate an instance of this TestSuite
--- a/src/test/mobility-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/mobility-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -363,10 +363,10 @@
MobilityTestSuite::MobilityTestSuite ()
: TestSuite ("mobility", UNIT)
{
- AddTestCase (new WaypointLazyNotifyFalse);
- AddTestCase (new WaypointLazyNotifyTrue);
- AddTestCase (new WaypointInitialPositionIsWaypoint);
- AddTestCase (new WaypointMobilityModelViaHelper);
+ AddTestCase (new WaypointLazyNotifyFalse, TestCase::QUICK);
+ AddTestCase (new WaypointLazyNotifyTrue, TestCase::QUICK);
+ AddTestCase (new WaypointInitialPositionIsWaypoint, TestCase::QUICK);
+ AddTestCase (new WaypointMobilityModelViaHelper, TestCase::QUICK);
}
static MobilityTestSuite mobilityTestSuite;
--- a/src/test/ns3tcp/ns3tcp-cwnd-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3tcp/ns3tcp-cwnd-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -588,8 +588,8 @@
Ns3TcpCwndTestSuite::Ns3TcpCwndTestSuite ()
: TestSuite ("ns3-tcp-cwnd", SYSTEM)
{
- AddTestCase (new Ns3TcpCwndTestCase1);
- AddTestCase (new Ns3TcpCwndTestCase2);
+ AddTestCase (new Ns3TcpCwndTestCase1, TestCase::QUICK);
+ AddTestCase (new Ns3TcpCwndTestCase2, TestCase::QUICK);
}
Ns3TcpCwndTestSuite ns3TcpCwndTestSuite;
--- a/src/test/ns3tcp/ns3tcp-interop-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3tcp/ns3tcp-interop-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -311,7 +311,7 @@
Ns3TcpInteroperabilityTestSuite::Ns3TcpInteroperabilityTestSuite ()
: TestSuite ("ns3-tcp-interoperability", SYSTEM)
{
- AddTestCase (new Ns3TcpInteroperabilityTestCase);
+ AddTestCase (new Ns3TcpInteroperabilityTestCase, TestCase::QUICK);
}
static Ns3TcpInteroperabilityTestSuite ns3TcpInteroperabilityTestSuite;
--- a/src/test/ns3tcp/ns3tcp-loss-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3tcp/ns3tcp-loss-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -447,23 +447,23 @@
SetDataDir (NS_TEST_SOURCEDIR);
Packet::EnablePrinting (); // Enable packet metadata for all test cases
- AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 0));
- AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 1));
- AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 2));
- AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 3));
- AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 4));
+ AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 0), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 1), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 2), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 3), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Tahoe", 4), TestCase::QUICK);
- AddTestCase (new Ns3TcpLossTestCase ("Reno", 0));
- AddTestCase (new Ns3TcpLossTestCase ("Reno", 1));
- AddTestCase (new Ns3TcpLossTestCase ("Reno", 2));
- AddTestCase (new Ns3TcpLossTestCase ("Reno", 3));
- AddTestCase (new Ns3TcpLossTestCase ("Reno", 4));
+ AddTestCase (new Ns3TcpLossTestCase ("Reno", 0), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Reno", 1), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Reno", 2), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Reno", 3), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("Reno", 4), TestCase::QUICK);
- AddTestCase (new Ns3TcpLossTestCase ("NewReno", 0));
- AddTestCase (new Ns3TcpLossTestCase ("NewReno", 1));
- AddTestCase (new Ns3TcpLossTestCase ("NewReno", 2));
- AddTestCase (new Ns3TcpLossTestCase ("NewReno", 3));
- AddTestCase (new Ns3TcpLossTestCase ("NewReno", 4));
+ AddTestCase (new Ns3TcpLossTestCase ("NewReno", 0), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("NewReno", 1), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("NewReno", 2), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("NewReno", 3), TestCase::QUICK);
+ AddTestCase (new Ns3TcpLossTestCase ("NewReno", 4), TestCase::QUICK);
}
--- a/src/test/ns3tcp/ns3tcp-no-delay-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3tcp/ns3tcp-no-delay-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -199,8 +199,8 @@
Ns3TcpNoDelayTestSuite::Ns3TcpNoDelayTestSuite ()
: TestSuite ("ns3-tcp-no-delay", SYSTEM)
{
- AddTestCase (new Ns3TcpNoDelayTestCase (true));
- AddTestCase (new Ns3TcpNoDelayTestCase (false));
+ AddTestCase (new Ns3TcpNoDelayTestCase (true), TestCase::QUICK);
+ AddTestCase (new Ns3TcpNoDelayTestCase (false), TestCase::QUICK);
}
static Ns3TcpNoDelayTestSuite ns3TcpNoDelayTestSuite;
--- a/src/test/ns3tcp/ns3tcp-socket-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3tcp/ns3tcp-socket-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -271,8 +271,8 @@
Ns3TcpSocketTestSuite::Ns3TcpSocketTestSuite ()
: TestSuite ("ns3-tcp-socket", SYSTEM)
{
- AddTestCase (new Ns3TcpSocketTestCase1);
- AddTestCase (new Ns3TcpSocketTestCase2);
+ AddTestCase (new Ns3TcpSocketTestCase1, TestCase::QUICK);
+ AddTestCase (new Ns3TcpSocketTestCase2, TestCase::QUICK);
}
static Ns3TcpSocketTestSuite ns3TcpSocketTestSuite;
--- a/src/test/ns3tcp/ns3tcp-state-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3tcp/ns3tcp-state-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -449,15 +449,15 @@
: TestSuite ("ns3-tcp-state", SYSTEM)
{
Packet::EnablePrinting (); // Enable packet metadata for all test cases
- AddTestCase (new Ns3TcpStateTestCase (0));
- AddTestCase (new Ns3TcpStateTestCase (1));
- AddTestCase (new Ns3TcpStateTestCase (2));
- AddTestCase (new Ns3TcpStateTestCase (3));
- AddTestCase (new Ns3TcpStateTestCase (4));
- AddTestCase (new Ns3TcpStateTestCase (5));
- AddTestCase (new Ns3TcpStateTestCase (6));
- AddTestCase (new Ns3TcpStateTestCase (7));
- AddTestCase (new Ns3TcpStateTestCase (8));
+ AddTestCase (new Ns3TcpStateTestCase (0), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (1), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (2), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (3), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (4), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (5), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (6), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (7), TestCase::QUICK);
+ AddTestCase (new Ns3TcpStateTestCase (8), TestCase::QUICK);
}
static Ns3TcpStateTestSuite ns3TcpLossTestSuite;
--- a/src/test/ns3tcp/nsctcp-loss-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3tcp/nsctcp-loss-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -271,8 +271,8 @@
NscTcpLossTestSuite::NscTcpLossTestSuite ()
: TestSuite ("nsc-tcp-loss", SYSTEM)
{
- AddTestCase (new NscTcpLossTestCase1);
- AddTestCase (new NscTcpLossTestCase2);
+ AddTestCase (new NscTcpLossTestCase1, TestCase::QUICK);
+ AddTestCase (new NscTcpLossTestCase2, TestCase::QUICK);
}
static NscTcpLossTestSuite nscTcpLossTestSuite;
--- a/src/test/ns3wifi/wifi-interference-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3wifi/wifi-interference-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -282,7 +282,7 @@
WifiInterferenceTestSuite::WifiInterferenceTestSuite ()
: TestSuite ("ns3-wifi-interference", UNIT)
{
- AddTestCase (new WifiInterferenceTestCase);
+ AddTestCase (new WifiInterferenceTestCase, TestCase::QUICK);
}
static WifiInterferenceTestSuite wifiInterferenceTestSuite;
--- a/src/test/ns3wifi/wifi-msdu-aggregator-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/ns3wifi/wifi-msdu-aggregator-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -201,7 +201,7 @@
WifiMsduAggregatorTestSuite::WifiMsduAggregatorTestSuite ()
: TestSuite ("ns3-wifi-msdu-aggregator", SYSTEM)
{
- AddTestCase (new WifiMsduAggregatorThroughputTest);
+ AddTestCase (new WifiMsduAggregatorThroughputTest, TestCase::QUICK);
}
static WifiMsduAggregatorTestSuite wifiMsduAggregatorTestSuite;
--- a/src/test/static-routing-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/static-routing-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -163,7 +163,7 @@
StaticRoutingTestSuite::StaticRoutingTestSuite ()
: TestSuite ("static-routing", UNIT)
{
- AddTestCase (new StaticRoutingSlash32TestCase);
+ AddTestCase (new StaticRoutingSlash32TestCase, TestCase::QUICK);
}
// Do not forget to allocate an instance of this TestSuite
--- a/src/test/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/test/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -16,7 +16,7 @@
return
test = bld.create_ns3_module('test', ['internet', 'mobility', 'applications', 'csma', 'bridge', 'config-store', 'tools', 'point-to-point', 'csma-layout', 'flow-monitor', 'wifi'])
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'test'
test_test = bld.create_ns3_module_test_library('test')
@@ -24,7 +24,6 @@
'csma-system-test-suite.cc',
'global-routing-test-suite.cc',
'static-routing-test-suite.cc',
- 'error-model-test-suite.cc',
'mobility-test-suite.cc',
'ns3wifi/wifi-interference-test-suite.cc',
'ns3wifi/wifi-msdu-aggregator-test-suite.cc',
--- a/src/tools/test/average-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/tools/test/average-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -264,9 +264,9 @@
AverageTestSuite::AverageTestSuite ()
: TestSuite ("average", UNIT)
{
- AddTestCase (new OneIntegerAverageTestCase);
- AddTestCase (new FiveIntegersAverageTestCase);
- AddTestCase (new FiveDoublesAverageTestCase);
+ AddTestCase (new OneIntegerAverageTestCase, TestCase::QUICK);
+ AddTestCase (new FiveIntegersAverageTestCase, TestCase::QUICK);
+ AddTestCase (new FiveDoublesAverageTestCase, TestCase::QUICK);
}
static AverageTestSuite averageTestSuite;
--- a/src/tools/test/event-garbage-collector-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/tools/test/event-garbage-collector-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -81,7 +81,7 @@
EventGarbageCollectorTestSuite ()
: TestSuite ("event-garbage-collector", UNIT)
{
- AddTestCase (new EventGarbageCollectorTestCase ());
+ AddTestCase (new EventGarbageCollectorTestCase (), TestCase::QUICK);
}
} g_eventGarbageCollectorTests;
--- a/src/tools/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/tools/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -15,7 +15,7 @@
'test/event-garbage-collector-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'tools'
headers.source = [
'model/average.h',
@@ -25,6 +25,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/topology-read/examples/topology-example-sim.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/topology-read/examples/topology-example-sim.cc Fri Apr 05 17:59:11 2013 +0200
@@ -76,16 +76,13 @@
// --------------------------------------------
// Pick a topology reader based in the requested format.
-
- Ptr<TopologyReader> inFile = 0;
TopologyReaderHelper topoHelp;
+ topoHelp.SetFileName (input);
+ topoHelp.SetFileType (format);
+ Ptr<TopologyReader> inFile = topoHelp.GetTopologyReader ();
NodeContainer nodes;
- topoHelp.SetFileName (input);
- topoHelp.SetFileType (format);
- inFile = topoHelp.GetTopologyReader ();
-
if (inFile != 0)
{
nodes = inFile->Read ();
--- a/src/topology-read/model/inet-topology-reader.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/topology-read/model/inet-topology-reader.cc Fri Apr 05 17:59:11 2013 +0200
@@ -62,6 +62,7 @@
if ( !topgen.is_open () )
{
+ NS_LOG_WARN ("Inet topology file object is not open, check file name and permissions");
return nodes;
}
@@ -85,7 +86,7 @@
lineBuffer >> totlink;
NS_LOG_INFO ("Inet topology should have " << totnode << " nodes and " << totlink << " links");
- for (int i = 0; i <= totnode; i++)
+ for (int i = 0; i < totnode; i++)
{
getline (topgen,line);
}
@@ -102,10 +103,11 @@
if ( (!from.empty ()) && (!to.empty ()) )
{
- NS_LOG_INFO ( linksNumber << " From: " << from << " to: " << to );
+ NS_LOG_INFO ( "Link " << linksNumber << " from: " << from << " to: " << to);
if ( nodeMap[from] == 0 )
{
+ NS_LOG_INFO ( "Node " << nodesNumber << " name: " << from);
Ptr<Node> tmpNode = CreateObject<Node> ();
nodeMap[from] = tmpNode;
nodes.Add (tmpNode);
@@ -114,6 +116,7 @@
if (nodeMap[to] == 0)
{
+ NS_LOG_INFO ( "Node " << nodesNumber << " name: " << to);
Ptr<Node> tmpNode = CreateObject<Node> ();
nodeMap[to] = tmpNode;
nodes.Add (tmpNode);
@@ -123,6 +126,7 @@
Link link ( nodeMap[from], from, nodeMap[to], to );
if ( !linkAttr.empty () )
{
+ NS_LOG_INFO ( "Link " << linksNumber << " weight: " << linkAttr);
link.SetAttribute ("Weight", linkAttr);
}
AddLink (link);
--- a/src/topology-read/test/rocketfuel-topology-reader-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/topology-read/test/rocketfuel-topology-reader-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -82,7 +82,7 @@
RocketfuelTopologyReaderTestSuite::RocketfuelTopologyReaderTestSuite ()
: TestSuite ("rocketfuel-topology-reader", UNIT)
{
- AddTestCase (new RocketfuelTopologyReaderTest ());
+ AddTestCase (new RocketfuelTopologyReaderTest (), TestCase::QUICK);
}
static RocketfuelTopologyReaderTestSuite rocketfuelTopologyReaderTestSuite;
--- a/src/topology-read/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/topology-read/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -15,7 +15,7 @@
'test/rocketfuel-topology-reader-test-suite.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'topology-read'
headers.source = [
'model/topology-reader.h',
@@ -26,6 +26,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/uan/test/uan-energy-model-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/uan/test/uan-energy-model-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -303,8 +303,8 @@
UanEnergyModelTestSuite::UanEnergyModelTestSuite ()
: TestSuite ("uan-energy-model", UNIT)
{
- AddTestCase (new AcousticModemEnergyTestCase);
- AddTestCase (new AcousticModemEnergyDepletionTestCase);
+ AddTestCase (new AcousticModemEnergyTestCase, TestCase::QUICK);
+ AddTestCase (new AcousticModemEnergyDepletionTestCase, TestCase::QUICK);
}
// create an instance of the test suite
--- a/src/uan/test/uan-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/uan/test/uan-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -250,7 +250,7 @@
UanTestSuite::UanTestSuite ()
: TestSuite ("devices-uan", UNIT)
{
- AddTestCase (new UanTest);
+ AddTestCase (new UanTest, TestCase::QUICK);
}
static UanTestSuite g_uanTestSuite;
--- a/src/uan/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/uan/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -34,7 +34,7 @@
'test/uan-test.cc',
'test/uan-energy-model-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'uan'
headers.source = [
'model/uan-channel.h',
@@ -64,6 +64,6 @@
]
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/virtual-net-device/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/virtual-net-device/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -6,13 +6,13 @@
module.source = [
'model/virtual-net-device.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'virtual-net-device'
headers.source = [
'model/virtual-net-device.h',
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/visualizer/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/visualizer/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -1,5 +1,5 @@
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
-import Options
+from waflib import Options
required_python_modules = [
'gtk',
@@ -38,7 +38,7 @@
def build(bld):
module = bld.create_ns3_module('visualizer', ['internet', 'wifi', 'point-to-point'])
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'visualizer'
# Don't do anything more for this module if Python was explicitly
@@ -61,7 +61,7 @@
'model/dummy-file-for-static-builds.cc',
]
- module.features.append('pyembed')
+ module.features += ' pyembed'
#module.env.append_value('CXXFLAGS', module.env['shlib_CXXFLAGS'])
#module.includes = '.'
--- a/src/wifi/model/amsdu-subframe-header.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/model/amsdu-subframe-header.cc Fri Apr 05 17:59:11 2013 +0200
@@ -60,7 +60,7 @@
{
WriteTo (i, m_da);
WriteTo (i, m_sa);
- i.WriteHtolsbU16 (m_length);
+ i.WriteHtonU16 (m_length);
}
uint32_t
@@ -69,7 +69,7 @@
Buffer::Iterator i = start;
ReadFrom (i, m_da);
ReadFrom (i, m_sa);
- m_length = i.ReadLsbtohU16 ();
+ m_length = i.ReadNtohU16 ();
return i.GetDistanceFrom (start);
}
--- a/src/wifi/model/block-ack-manager.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/model/block-ack-manager.cc Fri Apr 05 17:59:11 2013 +0200
@@ -588,13 +588,17 @@
else
{
/* remove retry packet iterator if it's present in retry queue */
- for (std::list<PacketQueueI>::iterator it = m_retryPackets.begin (); it != m_retryPackets.end (); it++)
+ for (std::list<PacketQueueI>::iterator it = m_retryPackets.begin (); it != m_retryPackets.end ();)
{
if ((*it)->hdr.GetAddr1 () == j->second.first.GetPeer ()
&& (*it)->hdr.GetQosTid () == j->second.first.GetTid ()
&& (*it)->hdr.GetSequenceNumber () == i->hdr.GetSequenceNumber ())
{
- m_retryPackets.erase (it);
+ it = m_retryPackets.erase (it);
+ }
+ else
+ {
+ it++;
}
}
}
--- a/src/wifi/model/edca-txop-n.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/model/edca-txop-n.cc Fri Apr 05 17:59:11 2013 +0200
@@ -921,11 +921,6 @@
m_baManager->NotifyMpduTransmission (m_currentHdr.GetAddr1 (), m_currentHdr.GetQosTid (),
m_txMiddle->GetNextSeqNumberByTidAndAddress (m_currentHdr.GetQosTid (),
m_currentHdr.GetAddr1 ()));
- //we are not waiting for an ack: transmission is completed
- m_currentPacket = 0;
- m_dcf->ResetCw ();
- m_dcf->StartBackoffNow (m_rng->GetNext (0, m_dcf->GetCw ()));
- StartAccessIfNeeded ();
}
}
--- a/src/wifi/model/mac-low.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/model/mac-low.cc Fri Apr 05 17:59:11 2013 +0200
@@ -33,6 +33,7 @@
#include "wifi-mac-trailer.h"
#include "qos-utils.h"
#include "edca-txop-n.h"
+#include "snr-tag.h"
NS_LOG_COMPONENT_DEFINE ("MacLow");
@@ -42,74 +43,6 @@
namespace ns3 {
-class SnrTag : public Tag
-{
-public:
- static TypeId GetTypeId (void);
- virtual TypeId GetInstanceTypeId (void) const;
-
- virtual uint32_t GetSerializedSize (void) const;
- virtual void Serialize (TagBuffer i) const;
- virtual void Deserialize (TagBuffer i);
- virtual void Print (std::ostream &os) const;
-
- void Set (double snr);
- double Get (void) const;
-private:
- double m_snr;
-};
-
-TypeId
-SnrTag::GetTypeId (void)
-{
- static TypeId tid = TypeId ("ns3::SnrTag")
- .SetParent<Tag> ()
- .AddConstructor<SnrTag> ()
- .AddAttribute ("Snr", "The snr of the last packet received",
- DoubleValue (0.0),
- MakeDoubleAccessor (&SnrTag::Get),
- MakeDoubleChecker<double> ())
- ;
- return tid;
-}
-TypeId
-SnrTag::GetInstanceTypeId (void) const
-{
- return GetTypeId ();
-}
-
-uint32_t
-SnrTag::GetSerializedSize (void) const
-{
- return sizeof (double);
-}
-void
-SnrTag::Serialize (TagBuffer i) const
-{
- i.WriteDouble (m_snr);
-}
-void
-SnrTag::Deserialize (TagBuffer i)
-{
- m_snr = i.ReadDouble ();
-}
-void
-SnrTag::Print (std::ostream &os) const
-{
- os << "Snr=" << m_snr;
-}
-void
-SnrTag::Set (double snr)
-{
- m_snr = snr;
-}
-double
-SnrTag::Get (void) const
-{
- return m_snr;
-}
-
-
MacLowTransmissionListener::MacLowTransmissionListener ()
{
}
@@ -1771,7 +1704,10 @@
}
m_txParams.DisableNextData ();
- StartDataTxTimers ();
+ if (!immediate)
+ {
+ StartDataTxTimers ();
+ }
NS_ASSERT (duration >= MicroSeconds (0));
hdr.SetDuration (duration);
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/wifi/model/snr-tag.cc Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,94 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2005,2006 INRIA
+ * Copyright (c) 2009 MIRKO BANCHI
+ * Copyright (c) 2013 University of Surrey
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
+ * Author: Mirko Banchi <mk.banchi@gmail.com>
+ * Author: Konstantinos Katsaros <dinos.katsaros@gmail.com>
+ */
+
+#include "snr-tag.h"
+#include "ns3/tag.h"
+#include "ns3/double.h"
+
+namespace ns3 {
+
+NS_OBJECT_ENSURE_REGISTERED (SnrTag);
+
+TypeId
+SnrTag::GetTypeId (void)
+{
+ static TypeId tid = TypeId ("ns3::SnrTag")
+ .SetParent<Tag> ()
+ .AddConstructor<SnrTag> ()
+ .AddAttribute ("Snr", "The snr of the last packet received",
+ DoubleValue (0.0),
+ MakeDoubleAccessor (&SnrTag::Get),
+ MakeDoubleChecker<double> ())
+ ;
+ return tid;
+}
+TypeId
+SnrTag::GetInstanceTypeId (void) const
+{
+ return GetTypeId ();
+}
+
+SnrTag::SnrTag ()
+ : m_snr (0)
+{
+}
+SnrTag::SnrTag (double snr)
+ : m_snr (snr)
+{
+}
+
+
+uint32_t
+SnrTag::GetSerializedSize (void) const
+{
+ return sizeof (double);
+}
+void
+SnrTag::Serialize (TagBuffer i) const
+{
+ i.WriteDouble (m_snr);
+}
+void
+SnrTag::Deserialize (TagBuffer i)
+{
+ m_snr = i.ReadDouble ();
+}
+void
+SnrTag::Print (std::ostream &os) const
+{
+ os << "Snr=" << m_snr;
+}
+void
+SnrTag::Set (double snr)
+{
+ m_snr = snr;
+}
+double
+SnrTag::Get (void) const
+{
+ return m_snr;
+}
+
+
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/src/wifi/model/snr-tag.h Fri Apr 05 17:59:11 2013 +0200
@@ -0,0 +1,68 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2005,2006 INRIA
+ * Copyright (c) 2009 MIRKO BANCHI
+ * Copyright (c) 2013 University of Surrey
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
+ * Author: Mirko Banchi <mk.banchi@gmail.com>
+ * Author: Konstantinos Katsaros <dinos.katsaros@gmail.com>
+ */
+
+#ifndef SNR_TAG_H
+#define SNR_TAG_H
+
+#include "ns3/packet.h"
+
+namespace ns3 {
+
+class Tag;
+
+class SnrTag : public Tag
+{
+public:
+ static TypeId GetTypeId (void);
+ virtual TypeId GetInstanceTypeId (void) const;
+
+ /**
+ * Create a SnrTag with the default snr 0
+ */
+ SnrTag();
+
+ /**
+ * Create a SnrTag with the given snr value
+ */
+ SnrTag(double snr);
+
+ virtual uint32_t GetSerializedSize (void) const;
+ virtual void Serialize (TagBuffer i) const;
+ virtual void Deserialize (TagBuffer i);
+ virtual void Print (std::ostream &os) const;
+
+ /**
+ * Set the SNR to the given value.
+ *
+ * @param snr the value of the snr to set
+ */
+ void Set (double snr);
+ double Get (void) const;
+private:
+ double m_snr;
+};
+
+
+}
+#endif /* SNR_TAG_H */
--- a/src/wifi/test/block-ack-test-suite.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/test/block-ack-test-suite.cc Fri Apr 05 17:59:11 2013 +0200
@@ -284,9 +284,9 @@
BlockAckTestSuite::BlockAckTestSuite ()
: TestSuite ("wifi-block-ack", UNIT)
{
- AddTestCase (new PacketBufferingCaseA);
- AddTestCase (new PacketBufferingCaseB);
- AddTestCase (new CtrlBAckResponseHeaderTest);
+ AddTestCase (new PacketBufferingCaseA, TestCase::QUICK);
+ AddTestCase (new PacketBufferingCaseB, TestCase::QUICK);
+ AddTestCase (new CtrlBAckResponseHeaderTest, TestCase::QUICK);
}
static BlockAckTestSuite g_blockAckTestSuite;
--- a/src/wifi/test/dcf-manager-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/test/dcf-manager-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -682,7 +682,7 @@
DcfTestSuite::DcfTestSuite ()
: TestSuite ("devices-wifi-dcf", UNIT)
{
- AddTestCase (new DcfManagerTest);
+ AddTestCase (new DcfManagerTest, TestCase::QUICK);
}
static DcfTestSuite g_dcfTestSuite;
--- a/src/wifi/test/tx-duration-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/test/tx-duration-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -188,7 +188,7 @@
TxDurationTestSuite::TxDurationTestSuite ()
: TestSuite ("devices-wifi-tx-duration", UNIT)
{
- AddTestCase (new TxDurationTest);
+ AddTestCase (new TxDurationTest, TestCase::QUICK);
}
static TxDurationTestSuite g_txDurationTestSuite;
--- a/src/wifi/test/wifi-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/test/wifi-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -438,10 +438,10 @@
WifiTestSuite::WifiTestSuite ()
: TestSuite ("devices-wifi", UNIT)
{
- AddTestCase (new WifiTest);
- AddTestCase (new QosUtilsIsOldPacketTest);
- AddTestCase (new InterferenceHelperSequenceTest); // Bug 991
- AddTestCase (new Bug555TestCase); // Bug 555
+ AddTestCase (new WifiTest, TestCase::QUICK);
+ AddTestCase (new QosUtilsIsOldPacketTest, TestCase::QUICK);
+ AddTestCase (new InterferenceHelperSequenceTest, TestCase::QUICK); // Bug 991
+ AddTestCase (new Bug555TestCase, TestCase::QUICK); // Bug 555
}
static WifiTestSuite g_wifiTestSuite;
--- a/src/wifi/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wifi/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -60,6 +60,7 @@
'model/block-ack-agreement.cc',
'model/block-ack-manager.cc',
'model/block-ack-cache.cc',
+ 'model/snr-tag.cc',
'helper/athstats-helper.cc',
'helper/wifi-helper.cc',
'helper/yans-wifi-helper.cc',
@@ -75,7 +76,7 @@
'test/wifi-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'wifi'
headers.source = [
'model/wifi-information-element.h',
@@ -132,6 +133,7 @@
'model/block-ack-agreement.h',
'model/block-ack-manager.h',
'model/block-ack-cache.h',
+ 'model/snr-tag.h',
'helper/athstats-helper.h',
'helper/wifi-helper.h',
'helper/yans-wifi-helper.h',
@@ -144,7 +146,7 @@
obj_test.use.extend(['GSL', 'GSLCBLAS', 'M'])
if (bld.env['ENABLE_EXAMPLES']):
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/wimax/test/mac-messages-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/test/mac-messages-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -112,7 +112,7 @@
Ns3WimaxMacMessagesTestSuite::Ns3WimaxMacMessagesTestSuite ()
: TestSuite ("wimax-mac-messages", UNIT)
{
- AddTestCase (new DsaRequestTestCase);
+ AddTestCase (new DsaRequestTestCase, TestCase::QUICK);
}
static Ns3WimaxMacMessagesTestSuite ns3WimaxMacMessagesTestSuite;
--- a/src/wimax/test/phy-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/test/phy-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -180,8 +180,8 @@
Ns3WimaxPhyTestSuite::Ns3WimaxPhyTestSuite ()
: TestSuite ("wimax-phy-layer", UNIT)
{
- AddTestCase (new Ns3WimaxSNRtoBLERTestCase);
- AddTestCase (new Ns3WimaxSimpleOFDMTestCase);
+ AddTestCase (new Ns3WimaxSNRtoBLERTestCase, TestCase::QUICK);
+ AddTestCase (new Ns3WimaxSimpleOFDMTestCase, TestCase::QUICK);
}
--- a/src/wimax/test/qos-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/test/qos-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -287,8 +287,8 @@
Ns3WimaxQoSTestSuite::Ns3WimaxQoSTestSuite ()
: TestSuite ("wimax-qos", SYSTEM)
{
- AddTestCase (new Ns3WimaxSFTypeTestCase);
- AddTestCase (new Ns3WimaxSchedulingTestCase);
+ AddTestCase (new Ns3WimaxSFTypeTestCase, TestCase::QUICK);
+ AddTestCase (new Ns3WimaxSchedulingTestCase, TestCase::QUICK);
}
static Ns3WimaxQoSTestSuite ns3WimaxQoSTestSuite;
--- a/src/wimax/test/ss-mac-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/test/ss-mac-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -165,8 +165,8 @@
Ns3WimaxSSMacTestSuite::Ns3WimaxSSMacTestSuite ()
: TestSuite ("wimax-ss-mac-layer", UNIT)
{
- AddTestCase (new Ns3WimaxNetworkEntryTestCase);
- AddTestCase (new Ns3WimaxManagementConnectionsTestCase);
+ AddTestCase (new Ns3WimaxNetworkEntryTestCase, TestCase::QUICK);
+ AddTestCase (new Ns3WimaxManagementConnectionsTestCase, TestCase::QUICK);
}
static Ns3WimaxSSMacTestSuite ns3WimaxSSMacTestSuite;
--- a/src/wimax/test/wimax-fragmentation-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/test/wimax-fragmentation-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -161,7 +161,7 @@
Ns3WimaxFragmentationTestSuite::Ns3WimaxFragmentationTestSuite ()
: TestSuite ("wimax-fragmentation", UNIT)
{
- AddTestCase (new Ns3WimaxFragmentationTestCase);
+ AddTestCase (new Ns3WimaxFragmentationTestCase, TestCase::QUICK);
}
static Ns3WimaxFragmentationTestSuite ns3WimaxFragmentationTestSuite;
--- a/src/wimax/test/wimax-service-flow-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/test/wimax-service-flow-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -165,7 +165,7 @@
Ns3WimaxServiceFlowTestSuite::Ns3WimaxServiceFlowTestSuite ()
: TestSuite ("wimax-service-flow", UNIT)
{
- AddTestCase (new Ns3WimaxSfCreationTestCase);
+ AddTestCase (new Ns3WimaxSfCreationTestCase, TestCase::QUICK);
}
static Ns3WimaxServiceFlowTestSuite ns3WimaxServiceFlowTestSuite;
--- a/src/wimax/test/wimax-tlv-test.cc Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/test/wimax-tlv-test.cc Fri Apr 05 17:59:11 2013 +0200
@@ -208,8 +208,8 @@
Ns3WimaxTlvTestSuite::Ns3WimaxTlvTestSuite ()
: TestSuite ("wimax-tlv", UNIT)
{
- AddTestCase (new Ns3WimaxCsParamTlvTestCase);
- AddTestCase (new Ns3WimaxSfTlvTestCase);
+ AddTestCase (new Ns3WimaxCsParamTlvTestCase, TestCase::QUICK);
+ AddTestCase (new Ns3WimaxSfTlvTestCase, TestCase::QUICK);
}
static Ns3WimaxTlvTestSuite ns3WimaxTlvTestSuite;
--- a/src/wimax/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wimax/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -63,7 +63,7 @@
'test/wimax-fragmentation-test.cc',
]
- headers = bld.new_task_gen(features=['ns3header'])
+ headers = bld(features='ns3header')
headers.module = 'wimax'
headers.source = [
'model/wimax-channel.h',
@@ -113,6 +113,6 @@
]
if bld.env['ENABLE_EXAMPLES']:
- bld.add_subdirs('examples')
+ bld.recurse('examples')
bld.ns3_python_bindings()
--- a/src/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/src/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -6,14 +6,8 @@
import types
import warnings
+from waflib import TaskGen, Task, Options, Build, Utils
from waflib.Errors import WafError
-
-import TaskGen
-import Task
-import Options
-import Build
-import Utils
-
import wutils
try:
@@ -47,13 +41,26 @@
help=("Build only these modules (and dependencies)"),
dest='enable_modules')
+ opt.load('boost', tooldir=['waf-tools'])
+
for module in all_modules:
- opt.sub_options(module, mandatory=False)
-
+ opt.recurse(module, mandatory=False)
def configure(conf):
+ conf.env['REQUIRED_BOOST_LIBS'] = []
for module in all_modules:
- conf.sub_config(module, mandatory=False)
+ conf.recurse (module, name="required_boost_libs", mandatory=False)
+
+ if conf.env['REQUIRED_BOOST_LIBS'] is not []:
+ conf.load('boost')
+ conf.check_boost(lib=' '.join (conf.env['REQUIRED_BOOST_LIBS']), mandatory=False)
+ if not conf.env['LIB_BOOST']:
+ conf.check_boost(lib=' '.join (conf.env['REQUIRED_BOOST_LIBS']), libpath="/usr/lib64", mandatory=False)
+ if not conf.env['LIB_BOOST']:
+ conf.env['LIB_BOOST'] = []
+
+ for module in all_modules:
+ conf.recurse(module, mandatory=False)
blddir = os.path.abspath(os.path.join(conf.bldnode.abspath(), conf.variant))
conf.env.append_value('NS3_MODULE_PATH', blddir)
@@ -75,10 +82,10 @@
static = bool(bld.env.ENABLE_STATIC_NS3)
# Create a separate library for this module.
if static:
- module = bld.new_task_gen(features=['cxx', 'cxxstlib', 'ns3module'])
+ module = bld(features='cxx cxxstlib ns3module')
else:
- module = bld.new_task_gen(features=['cxx', 'cxxshlib', 'ns3module'])
- module.target = '%s/ns%s-%s%s' % (bld.srcnode.relpath_gen(module.path), wutils.VERSION,
+ module = bld(features='cxx cxxshlib ns3module')
+ module.target = '%s/ns%s-%s%s' % (bld.srcnode.path_from(module.path), wutils.VERSION,
name, bld.env.BUILD_SUFFIX)
linkflags = []
cxxflags = []
@@ -119,7 +126,7 @@
module.use = ['ns3-' + dep for dep in dependencies]
module.test = test
module.is_ns3_module = True
- module.ns3_dir_location = bld.path.relpath_gen(bld.srcnode)
+ module.ns3_dir_location = bld.path.path_from(bld.srcnode)
module.env.append_value("INCLUDES", '#')
@@ -133,7 +140,7 @@
def apply_incpaths_ns3testlib(self):
if not self.source:
return
- testdir = self.source[-1].parent.relpath_gen(self.bld.srcnode)
+ testdir = self.source[-1].parent.path_from(self.bld.srcnode)
self.env.append_value("DEFINES", 'NS_TEST_SOURCEDIR="%s"' % (testdir,))
@@ -142,7 +149,7 @@
# the module being tested.
library_name = name + "-test"
library = bld.create_ns3_module(library_name, [name], test=True)
- library.features.append("ns3testlib")
+ library.features += " ns3testlib"
# Modify attributes for the test library that are different from a
# normal module.
@@ -154,7 +161,7 @@
bld.env.append_value('NS3_MODULES_WITH_TEST_LIBRARIES', [(library.module_name, library.name)])
# Set the include path from the build directory to modules.
- relative_path_from_build_to_here = bld.path.relpath_gen(bld.bldnode)
+ relative_path_from_build_to_here = bld.path.path_from(bld.bldnode)
include_flag = '-I' + relative_path_from_build_to_here
library.env.append_value('CXXFLAGS', include_flag)
library.env.append_value('CCFLAGS', include_flag)
@@ -162,9 +169,9 @@
return library
def create_obj(bld, *args):
- warnings.warn("(in %s) Use bld.new_task_gen(...) now, instead of bld.create_obj(...)" % str(bld.path),
+ warnings.warn("(in %s) Use bld(...) call now, instead of bld.create_obj(...)" % str(bld.path),
DeprecationWarning, stacklevel=2)
- return bld.new_task_gen(*args)
+ return bld(*args)
def ns3_python_bindings(bld):
@@ -197,23 +204,24 @@
#debug = ('PYBINDGEN_DEBUG' in os.environ)
debug = True # XXX
- source = [bld.srcnode.find_resource('bindings/python/ns3modulegen-modular.py').relpath_gen(bld.path),
- "bindings/modulegen__%s.py" % apidefs]
+ source = [bld.srcnode.find_resource('bindings/python/ns3modulegen-modular.py'),
+ bld.path.find_resource("bindings/modulegen__%s.py" % apidefs)]
- if bindings_dir.find_resource("modulegen_customizations.py") is not None:
- source.append("bindings/modulegen_customizations.py")
+ modulegen_customizations = bindings_dir.find_resource("modulegen_customizations.py")
+ if modulegen_customizations is not None:
+ source.append(modulegen_customizations)
+ modulegen_local = bld.path.find_resource("bindings/modulegen_local.py")
# the local customization file may or not exist
- if bld.path.find_resource("bindings/modulegen_local.py"):
+ if modulegen_local is not None:
source.append("bindings/modulegen_local.py")
module_py_name = module.replace('-', '_')
- module_target_dir = bld.srcnode.find_dir("bindings/python/ns").relpath_gen(bld.path)
+ module_target_dir = bld.srcnode.find_dir("bindings/python/ns").path_from(bld.path)
# if bindings/<module>.py exists, it becomes the module frontend, and the C extension befomes _<module>
if bld.path.find_resource("bindings/%s.py" % (module_py_name,)) is not None:
- bld.new_task_gen(
- features='copy',
+ bld(features='copy',
source=("bindings/%s.py" % (module_py_name,)),
target=('%s/%s.py' % (module_target_dir, module_py_name)))
extension_name = '_%s' % (module_py_name,)
@@ -240,7 +248,7 @@
if was_enabled:
features.append(name)
- bindgen = bld.new_task_gen(features=['command'], source=source, target=target, command=argv)
+ bindgen = bld(features='command', source=source, target=target, command=argv)
bindgen.env['FEATURES'] = ','.join(features)
bindgen.dep_vars = ['FEATURES', "GCC_RTTI_ABI_COMPLETE"]
bindgen.before = 'cxx'
@@ -249,7 +257,7 @@
bindgen.install_path = None
# generate the extension module
- pymod = bld.new_task_gen(features='cxx cxxshlib pyext')
+ pymod = bld(features='cxx cxxshlib pyext')
pymod.source = ['bindings/ns3module.cc']
pymod.target = '%s/%s' % (module_target_dir, extension_name)
pymod.name = 'ns3module_%s' % module
@@ -305,14 +313,14 @@
if not_built in all_modules:
all_modules.remove(not_built)
- bld.add_subdirs(list(all_modules))
+ bld.recurse(list(all_modules))
for module in all_modules:
- modheader = bld.new_task_gen(features=['ns3moduleheader'])
+ modheader = bld(features='ns3moduleheader')
modheader.module = module.split('/')[-1]
class ns3pcfile_task(Task.Task):
- after = 'cc cxx'
+ after = 'cxx'
def __str__(self):
"string to display to the user"
@@ -448,7 +456,7 @@
class ns3header_task(Task.Task):
- before = 'cc cxx gen_ns3_module_header'
+ before = 'cxx gen_ns3_module_header'
color = 'BLUE'
def __str__(self):
@@ -517,7 +525,7 @@
class gen_ns3_module_header_task(Task.Task):
- before = 'cc cxx'
+ before = 'cxx'
after = 'ns3header'
color = 'BLUE'
--- a/test.py Fri Apr 05 16:50:37 2013 +0200
+++ b/test.py Fri Apr 05 17:59:11 2013 +0200
@@ -1334,8 +1334,14 @@
multiple = ""
else:
multiple = " --stop-on-failure"
+ if (len(options.fullness)):
+ fullness = options.fullness.upper()
+ fullness = " --fullness=%s" % fullness
+ else:
+ fullness = " --fullness=QUICK"
- path_cmd = os.path.join("utils", test_runner_name + " --test-name=%s%s" % (test, multiple))
+ path_cmd = os.path.join("utils", test_runner_name + " --test-name=%s%s%s" % (test, multiple, fullness))
+
job.set_shell_command(path_cmd)
if options.valgrind and test in core_valgrind_skip_tests:
@@ -1792,6 +1798,10 @@
parser.add_option("-u", "--update-data", action="store_true", dest="update_data", default=False,
help="If examples use reference data files, get them to re-generate them")
+ parser.add_option("-f", "--fullness", action="store", type="string", dest="fullness", default="QUICK",
+ metavar="FULLNESS",
+ help="choose the duration of tests to run: QUICK, EXTENSIVE, or TAKES_FOREVER, where EXTENSIVE includes QUICK and TAKES_FOREVER includes QUICK and EXTENSIVE (only QUICK tests are run by default)")
+
parser.add_option("-g", "--grind", action="store_true", dest="valgrind", default=False,
help="run the test suites and examples using valgrind")
Binary file waf has changed
--- a/waf-tools/boost.py Fri Apr 05 16:50:37 2013 +0200
+++ b/waf-tools/boost.py Fri Apr 05 17:59:11 2013 +0200
@@ -9,34 +9,53 @@
# rewritten for waf 1.6.2, Sylvain Rouquette, 2011
'''
+
+This is an extra tool, not bundled with the default waf binary.
To add the boost tool to the waf file:
$ ./waf-light --tools=compat15,boost
or, if you have waf >= 1.6.2
$ ./waf update --files=boost
-The wscript will look like:
+When using this tool, the wscript will look like:
+
+ def options(opt):
+ opt.load('compiler_cxx boost')
-def options(opt):
- opt.load('compiler_cxx boost')
+ def configure(conf):
+ conf.load('compiler_cxx boost')
+ conf.check_boost(lib='system filesystem')
+
+ def build(bld):
+ bld(source='main.cpp', target='app', use='BOOST')
-def configure(conf):
- conf.load('compiler_cxx boost')
- conf.check_boost(lib='system filesystem', mt=True, static=True)
+Options are generated, in order to specify the location of boost includes/libraries.
+The `check_boost` configuration function allows to specify the used boost libraries.
+It can also provide default arguments to the --boost-static and --boost-mt command-line arguments.
+Everything will be packaged together in a BOOST component that you can use.
-def build(bld):
- bld(source='main.cpp', target='app', use='BOOST')
+When using MSVC, a lot of compilation flags need to match your BOOST build configuration:
+ - you may have to add /EHsc to your CXXFLAGS or define boost::throw_exception if BOOST_NO_EXCEPTIONS is defined.
+ Errors: C4530
+ - boost libraries will try to be smart and use the (pretty but often not useful) auto-linking feature of MSVC
+ So before calling `conf.check_boost` you might want to disabling by adding:
+ conf.env.DEFINES_BOOST += ['BOOST_ALL_NO_LIB']
+ Errors:
+ - boost might also be compiled with /MT, which links the runtime statically.
+ If you have problems with redefined symbols,
+ self.env['DEFINES_%s' % var] += ['BOOST_ALL_NO_LIB']
+ self.env['CXXFLAGS_%s' % var] += ['/MD', '/EHsc']
+Passing `--boost-linkage_autodetect` might help ensuring having a correct linkage in some basic cases.
+
'''
import sys
import re
-from waflib import Utils, Logs
+from waflib import Utils, Logs, Errors
from waflib.Configure import conf
from waflib.Errors import WafError
-BOOST_LIBS = ('/usr/lib', '/usr/local/lib',
- '/opt/local/lib', '/sw/lib', '/lib')
-BOOST_INCLUDES = ('/usr/include', '/usr/local/include',
- '/opt/local/include', '/sw/include')
+BOOST_LIBS = ['/usr/lib', '/usr/local/lib', '/opt/local/lib', '/sw/lib', '/lib']
+BOOST_INCLUDES = ['/usr/include', '/usr/local/include', '/opt/local/include', '/sw/include']
BOOST_VERSION_FILE = 'boost/version.hpp'
BOOST_VERSION_CODE = '''
#include <iostream>
@@ -76,21 +95,23 @@
def options(opt):
opt.add_option('--boost-includes', type='string',
default='', dest='boost_includes',
- help='''path to the boost directory where the includes are
- e.g. /boost_1_45_0/include''')
+ help='''path to the boost includes root (~boost root)
+ e.g. /path/to/boost_1_47_0''')
opt.add_option('--boost-libs', type='string',
default='', dest='boost_libs',
help='''path to the directory where the boost libs are
- e.g. /boost_1_45_0/stage/lib''')
+ e.g. /path/to/boost_1_47_0/stage/lib''')
opt.add_option('--boost-static', action='store_true',
default=False, dest='boost_static',
- help='link static libraries')
+ help='link with static boost libraries (.lib/.a)')
opt.add_option('--boost-mt', action='store_true',
default=False, dest='boost_mt',
help='select multi-threaded libraries')
opt.add_option('--boost-abi', type='string', default='', dest='boost_abi',
help='''select libraries with tags (dgsyp, d for debug),
see doc Boost, Getting Started, chapter 6.1''')
+ opt.add_option('--boost-linkage_autodetect', action="store_true", dest='boost_linkage_autodetect',
+ help="auto-detect boost linkage options (don't get used to it / might break other stuff)")
opt.add_option('--boost-toolset', type='string',
default='', dest='boost_toolset',
help='force a toolset e.g. msvc, vc90, \
@@ -117,8 +138,7 @@
try:
val = re_but.search(self.__boost_get_version_file(dir).read()).group(1)
except:
- val = self.check_cxx(fragment=BOOST_VERSION_CODE, includes=[dir],
- execute=True, define_ret=True)
+ val = self.check_cxx(fragment=BOOST_VERSION_CODE, includes=[dir], execute=False, define_ret=True)
return val
@@ -130,10 +150,11 @@
for dir in BOOST_INCLUDES:
if self.__boost_get_version_file(dir):
return dir
- if includes:
- self.fatal('headers not found in %s' % includes)
- else:
- self.fatal('headers not found, use --boost-includes=/path/to/boost')
+ if kw.get('boost_mandatory', True):
+ if includes:
+ self.fatal('headers not found in %s' % includes)
+ else:
+ self.fatal('headers not found, please provide a --boost-includes argument (see help)')
@conf
@@ -176,11 +197,13 @@
if libs:
self.fatal('libs not found in %s' % libs)
else:
- self.fatal('libs not found, \
- use --boost-includes=/path/to/boost/lib')
+ self.fatal('libs not found, please provide a --boost-libs argument (see help)')
+
+ self.to_log('Found the boost path in %r with the libraries:' % path)
+ for x in files:
+ self.to_log(' %r' % x)
return path, files
-
@conf
def boost_get_libs(self, *k, **kw):
'''
@@ -194,37 +217,40 @@
if kw.get('abi', None):
t.append(kw['abi'])
tags = t and '(-%s)+' % '-'.join(t) or ''
- toolset = '(-%s[0-9]{0,3})+' % self.boost_get_toolset(kw.get('toolset', ''))
+ toolset = self.boost_get_toolset(kw.get('toolset', ''))
+ toolset_pat = '(-%s[0-9]{0,3})+' % toolset
version = '(-%s)+' % self.env.BOOST_VERSION
def find_lib(re_lib, files):
for file in files:
if re_lib.search(file.name):
+ self.to_log('Found boost lib %s' % file)
return file
return None
def format_lib_name(name):
- if name.startswith('lib'):
+ if name.startswith('lib') and self.env.CC_NAME != 'msvc':
name = name[3:]
- return name.split('.')[0]
+ return name[:name.rfind('.')]
libs = []
for lib in Utils.to_list(k and k[0] or kw.get('lib', None)):
py = (lib == 'python') and '(-py%s)+' % kw['python'] or ''
# Trying libraries, from most strict match to least one
- for pattern in ['boost_%s%s%s%s%s' % (lib, toolset, tags, py, version),
+ for pattern in ['boost_%s%s%s%s%s' % (lib, toolset_pat, tags, py, version),
'boost_%s%s%s%s' % (lib, tags, py, version),
'boost_%s%s%s' % (lib, tags, version),
# Give up trying to find the right version
- 'boost_%s%s%s%s' % (lib, toolset, tags, py),
+ 'boost_%s%s%s%s' % (lib, toolset_pat, tags, py),
'boost_%s%s%s' % (lib, tags, py),
'boost_%s%s' % (lib, tags)]:
+ self.to_log('Trying pattern %s' % pattern)
file = find_lib(re.compile(pattern), files)
if file:
libs.append(format_lib_name(file.name))
break
else:
- self.fatal('lib %s not found in %s' % (lib, path))
+ self.fatal('lib %s not found in %s' % (lib, path.abspath()))
return path.abspath(), libs
@@ -232,10 +258,10 @@
@conf
def check_boost(self, *k, **kw):
"""
- initialize boost
+ Initialize boost libraries to be used.
- You can pass the same parameters as the command line (without "--boost-"),
- but the command line has the priority.
+ Keywords: you can pass the same parameters as with the command line (without "--boost-").
+ Note that the command line has the priority, and should preferably be used.
"""
if not self.env['CXX']:
self.fatal('load a c++ compiler first, conf.load("compiler_cxx")')
@@ -256,6 +282,8 @@
except WafError:
self.end_msg("not found", 'YELLOW')
raise
+ #self.env['INCLUDES_%s' % var] = inc = self.boost_get_includes(**params)
+ #self.env.BOOST_VERSION = self.boost_get_version(inc)
self.end_msg(self.env.BOOST_VERSION)
if Logs.verbose:
Logs.pprint('CYAN', ' path : %s' % self.env['INCLUDES_%s' % var])
@@ -269,6 +297,8 @@
except WafError:
self.end_msg("not found", 'YELLOW')
raise
+ #suffix = params.get('static', None) and 'ST' or ''
+ #path, libs = self.boost_get_libs(**params)
self.env['%sLIBPATH_%s' % (suffix, var)] = [path]
self.env['%sLIB_%s' % (suffix, var)] = libs
self.end_msg('ok')
@@ -276,3 +306,69 @@
Logs.pprint('CYAN', ' path : %s' % path)
Logs.pprint('CYAN', ' libs : %s' % libs)
+
+ def try_link():
+ if 'system' in params['lib']:
+ self.check_cxx(
+ fragment="\n".join([
+ '#include <boost/system/error_code.hpp>',
+ 'int main() { boost::system::error_code c; }',
+ ]),
+ use=var,
+ execute=False,
+ )
+ if 'thread' in params['lib']:
+ self.check_cxx(
+ fragment="\n".join([
+ '#include <boost/thread.hpp>',
+ 'int main() { boost::thread t; }',
+ ]),
+ use=var,
+ execute=False,
+ )
+
+ if params.get('linkage_autodetect', False):
+ self.start_msg("Attempting to detect boost linkage flags")
+ toolset = self.boost_get_toolset(kw.get('toolset', ''))
+ if toolset in ['vc']:
+ # disable auto-linking feature, causing error LNK1181
+ # because the code wants to be linked against
+ self.env['DEFINES_%s' % var] += ['BOOST_ALL_NO_LIB']
+
+ # if no dlls are present, we guess the .lib files are not stubs
+ has_dlls = False
+ for x in Utils.listdir(path):
+ if x.endswith(self.env.cxxshlib_PATTERN % ''):
+ has_dlls = True
+ break
+ if not has_dlls:
+ self.env['STLIBPATH_%s' % var] = [path]
+ self.env['STLIB_%s' % var] = libs
+ del self.env['LIB_%s' % var]
+ del self.env['LIBPATH_%s' % var]
+
+ # we attempt to play with some known-to-work CXXFLAGS combinations
+ for cxxflags in (['/MD', '/EHsc'], []):
+ self.env.stash()
+ self.env["CXXFLAGS_%s" % var] += cxxflags
+ try:
+ try_link()
+ self.end_msg("ok: winning cxxflags combination: %s" % (self.env["CXXFLAGS_%s" % var]))
+ e = None
+ break
+ except Errors.ConfigurationError as exc:
+ self.env.revert()
+ e = exc
+
+ if e is not None:
+ self.fatal("Could not auto-detect boost linking flags combination, you may report it to boost.py author", ex=e)
+ else:
+ self.fatal("Boost linkage flags auto-detection not implemented (needed ?) for this toolchain")
+ else:
+ self.start_msg('Checking for boost linkage')
+ try:
+ try_link()
+ except Errors.ConfigurationError as e:
+ self.fatal("Could not link against boost libraries using supplied options")
+ self.end_msg('ok')
+
--- a/waf-tools/cflags.py Fri Apr 05 16:50:37 2013 +0200
+++ b/waf-tools/cflags.py Fri Apr 05 17:59:11 2013 +0200
@@ -1,6 +1,4 @@
-import Logs
-import Options
-import Utils
+from waflib import Logs, Options, Utils
class CompilerTraits(object):
--- a/waf-tools/command.py Fri Apr 05 16:50:37 2013 +0200
+++ b/waf-tools/command.py Fri Apr 05 17:59:11 2013 +0200
@@ -1,18 +1,15 @@
-import TaskGen# import feature, taskgen_method, before_method, task_gen
-import Node, Task, Utils, Build
+import re
import subprocess
-import Options
+
+# import feature, taskgen_method, before_method, task_gen
+from waflib import TaskGen, Node, Task, Utils, Build, Options, Logs, Task
+debug = Logs.debug
+error = Logs.error
import shellcmd
#shellcmd.subprocess = pproc # the WAF version of the subprocess module is supposedly less buggy
-
-from Logs import debug, error
shellcmd.debug = debug
-import Task
-
-import re
-
arg_rx = re.compile(r"(?P<dollar>\$\$)|(?P<subst>\$\{(?P<var>\w+)(?P<code>.*?)\})", re.M)
--- a/waf-tools/misc.py Fri Apr 05 16:50:37 2013 +0200
+++ b/waf-tools/misc.py Fri Apr 05 17:59:11 2013 +0200
@@ -322,9 +322,6 @@
if self.cwd is None:
cwd = None
- else:
- assert isinstance(cwd, CmdDirArg)
- self.cwd.find_node(self.path)
args = []
inputs = []
--- a/waf-tools/pkgconfig.py Fri Apr 05 16:50:37 2013 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,78 +0,0 @@
-# -*- mode: python; encoding: utf-8 -*-
-# Gustavo Carneiro (gjamc) 2008
-
-import Options
-import Configure
-import subprocess
-import config_c
-import sys
-
-def configure(conf):
- pkg_config = conf.find_program('pkg-config', var='PKG_CONFIG')
- if not pkg_config: return
-
-@Configure.conf
-def pkg_check_modules(conf, uselib_name, expression, mandatory=True):
- pkg_config = conf.env['PKG_CONFIG']
- if not pkg_config:
- if mandatory:
- conf.fatal("pkg-config is not available")
- else:
- return False
-
- if Options.options.verbose:
- extra_msg = ' (%s)' % expression
- else:
- extra_msg = ''
-
- conf.start_msg('Checking for pkg-config flags for %s%s' % (uselib_name, extra_msg))
-
- argv = [pkg_config, '--cflags', '--libs', expression]
- cmd = subprocess.Popen(argv, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
- out, err = cmd.communicate()
- retval = cmd.wait()
-
- conf.to_log('%r: %r (exit code %i)\n%s' % (argv, out, retval, err))
-
- if retval != 0:
- conf.end_msg(False)
- sys.stderr.write(err)
- else:
- if Options.options.verbose:
- conf.end_msg(out)
- else:
- conf.end_msg(True)
-
- if retval == 0:
- conf.parse_flags(out, uselib_name, conf.env)
- conf.env[uselib_name] = True
- return True
-
- else:
-
- conf.env[uselib_name] = False
- if mandatory:
- raise Configure.ConfigurationError('pkg-config check failed')
- else:
- return False
-
-@Configure.conf
-def pkg_check_module_variable(conf, module, variable):
- pkg_config = conf.env['PKG_CONFIG']
- if not pkg_config:
- conf.fatal("pkg-config is not available")
-
- argv = [pkg_config, '--variable', variable, module]
- cmd = subprocess.Popen(argv, stdout=subprocess.PIPE)
- out, dummy = cmd.communicate()
- retval = cmd.wait()
- out = out.rstrip() # strip the trailing newline
-
- msg_checking = ("Checking for pkg-config variable %r in %s" % (variable, module,))
- conf.check_message_custom(msg_checking, '', out)
- conf.log.write('%r: %r (exit code %i)\n' % (argv, out, retval))
-
- if retval == 0:
- return out
- else:
- raise Configure.ConfigurationError('pkg-config check failed')
--- a/waf-tools/relocation.py Fri Apr 05 16:50:37 2013 +0200
+++ b/waf-tools/relocation.py Fri Apr 05 17:59:11 2013 +0200
@@ -64,7 +64,7 @@
try:
return self.uid_
except AttributeError:
- # this is not a real hot zone, but we want to avoid surprizes here
+ # this is not a real hot zone, but we want to avoid surprises here
m = Utils.md5()
up = m.update
up(self.__class__.__name__.encode())
@@ -80,6 +80,6 @@
lst = self.to_incnodes(self.to_list(getattr(self, 'includes', [])) + self.env['INCLUDES'])
self.includes_nodes = lst
bld = self.bld
- self.env['INCPATHS'] = [x.is_child_of(bld.srcnode) and x.path_from(bld.srcnode) or x.abspath() for x in lst]
+ self.env['INCPATHS'] = [x.is_child_of(bld.srcnode) and x.path_from(bld.bldnode) or x.abspath() for x in lst]
--- a/wscript Fri Apr 05 16:50:37 2013 +0200
+++ b/wscript Fri Apr 05 17:59:11 2013 +0200
@@ -8,25 +8,20 @@
import os.path
import re
import shlex
+import subprocess
import textwrap
+from utils import read_config_file
+
+
# WAF modules
-import subprocess
-import Options
-
-import Logs
-import TaskGen
-
-import Task
-
-import Utils
-import Build
-import Configure
-import Scripting
-
+from waflib import Utils, Scripting, Configure, Build, Options, TaskGen, Context, Task, Logs, Errors
from waflib.Errors import WafError
-from utils import read_config_file
+
+# local modules
+import wutils
+
# By default, all modules will be enabled, examples will be disabled,
# and tests will be disabled.
@@ -52,9 +47,6 @@
}
cflags.default_profile = 'debug'
-# local modules
-import wutils
-
Configure.autoconfig = 0
# the following two variables are used by the target "waf dist"
@@ -214,9 +206,9 @@
dest='doxygen_no_build')
# options provided in subdirectories
- opt.sub_options('src')
- opt.sub_options('bindings/python')
- opt.sub_options('src/internet')
+ opt.recurse('src')
+ opt.recurse('bindings/python')
+ opt.recurse('src/internet')
def _check_compilation_flag(conf, flag, mode='cxx', linkflags=None):
@@ -240,7 +232,7 @@
flag_str = flag_str[:28] + "..."
conf.start_msg('Checking for compilation %s support' % (flag_str,))
- env = conf.env.copy()
+ env = conf.env.derive()
if mode == 'cc':
mode = 'c'
@@ -259,7 +251,7 @@
retval = conf.run_c_code(code='#include <stdio.h>\nint main() { return 0; }\n',
env=env, compile_filename=fname,
features=[mode, mode+'program'], execute=False)
- except Configure.ConfigurationError:
+ except Errors.ConfigurationError:
ok = False
else:
ok = (retval == 0)
@@ -286,7 +278,7 @@
return None
def configure(conf):
- conf.check_tool("relocation", ["waf-tools"])
+ conf.load('relocation', tooldir=['waf-tools'])
# attach some extra methods
conf.check_nonfatal = types.MethodType(_check_nonfatal, conf)
@@ -295,15 +287,11 @@
conf.check_optional_feature = types.MethodType(check_optional_feature, conf)
conf.env['NS3_OPTIONAL_FEATURES'] = []
- conf.check_tool('compiler_c')
- conf.check_tool('compiler_cxx')
- conf.check_tool('cflags', ['waf-tools'])
- try:
- conf.check_tool('pkgconfig', ['waf-tools'])
- except Configure.ConfigurationError:
- pass
- conf.check_tool('command', ['waf-tools'])
- conf.check_tool('gnu_dirs')
+ conf.load('compiler_c')
+ conf.load('compiler_cxx')
+ conf.load('cflags', tooldir=['waf-tools'])
+ conf.load('command', tooldir=['waf-tools'])
+ conf.load('gnu_dirs')
env = conf.env
@@ -376,9 +364,9 @@
conf.env['MODULES_NOT_BUILT'] = []
- conf.sub_config('bindings/python')
+ conf.recurse('bindings/python')
- conf.sub_config('src')
+ conf.recurse('src')
# Set the list of enabled modules.
if Options.options.enable_modules:
@@ -410,7 +398,7 @@
if not conf.env['NS3_ENABLED_MODULES']:
raise WafError('Exiting because the ' + not_built + ' module can not be built and it was the only one enabled.')
- conf.sub_config('src/mpi')
+ conf.recurse('src/mpi')
# for suid bits
try:
@@ -488,19 +476,18 @@
# These flags are used for the implicitly dependent modules.
if env['ENABLE_STATIC_NS3']:
if sys.platform == 'darwin':
- env.STATICLIB_MARKER = '-Wl,-all_load'
+ env.STLIB_MARKER = '-Wl,-all_load'
else:
- env.STATICLIB_MARKER = '-Wl,--whole-archive,-Bstatic'
+ env.STLIB_MARKER = '-Wl,--whole-archive,-Bstatic'
env.SHLIB_MARKER = '-Wl,-Bdynamic,--no-whole-archive'
- have_gsl = conf.pkg_check_modules('GSL', 'gsl', mandatory=False)
+
+ have_gsl = conf.check_cfg(package='gsl', args=['--cflags', '--libs'],
+ uselib_store='GSL', mandatory=False)
conf.env['ENABLE_GSL'] = have_gsl
-
conf.report_optional_feature("GSL", "GNU Scientific Library (GSL)",
conf.env['ENABLE_GSL'],
"GSL not found")
- if have_gsl:
- conf.env.append_value('DEFINES', "ENABLE_GSL")
# for compiling C code, copy over the CXX* flags
conf.env.append_value('CCFLAGS', conf.env['CXXFLAGS'])
@@ -543,7 +530,7 @@
print "%-30s: %s%s%s" % (caption, Logs.colors_lst[color], status, Logs.colors_lst['NORMAL'])
-class SuidBuild_task(Task.TaskBase):
+class SuidBuild_task(Task.Task):
"""task that makes a binary Suid
"""
after = 'link'
@@ -555,7 +542,7 @@
except ValueError, ex:
raise WafError(str(ex))
program_node = program_obj.path.find_or_declare(program_obj.target)
- self.filename = program_node.abspath()
+ self.filename = program_node.get_bld().abspath()
def run(self):
@@ -580,7 +567,7 @@
def create_suid_program(bld, name):
grp = bld.current_group
bld.add_group() # this to make sure no two sudo tasks run at the same time
- program = bld.new_task_gen(features=['cxx', 'cxxprogram'])
+ program = bld(features='cxx cxxprogram')
program.is_ns3_program = True
program.module_deps = list()
program.name = name
@@ -594,20 +581,20 @@
return program
def create_ns3_program(bld, name, dependencies=('core',)):
- program = bld.new_task_gen(features=['cxx', 'cxxprogram'])
+ program = bld(features='cxx cxxprogram')
program.is_ns3_program = True
program.name = name
program.target = "%s%s-%s%s" % (wutils.APPNAME, wutils.VERSION, name, bld.env.BUILD_SUFFIX)
# Each of the modules this program depends on has its own library.
program.ns3_module_dependencies = ['ns3-'+dep for dep in dependencies]
- program.includes = "# #/.."
+ program.includes = "#"
program.use = program.ns3_module_dependencies
if program.env['ENABLE_STATIC_NS3']:
if sys.platform == 'darwin':
program.env.STLIB_MARKER = '-Wl,-all_load'
else:
- program.env.STLIB_MARKER = '-Wl,--whole-archive,-Bstatic'
+ program.env.STLIB_MARKER = '-Wl,-Bstatic,--whole-archive'
program.env.SHLIB_MARKER = '-Wl,-Bdynamic,--no-whole-archive'
else:
if program.env.DEST_BINFMT == 'elf':
@@ -628,8 +615,7 @@
if dir.startswith('.') or dir == 'CVS':
continue
if os.path.isdir(os.path.join('examples', dir)):
- bld.add_subdirs(os.path.join('examples', dir))
-
+ bld.recurse(os.path.join('examples', dir))
def add_scratch_programs(bld):
all_modules = [mod[len("ns3-"):] for mod in bld.env['NS3_ENABLED_MODULES']]
@@ -652,7 +638,6 @@
obj.name = obj.target
obj.install_path = None
-
def _get_all_task_gen(self):
for group in self.groups:
for taskgen in group:
@@ -699,7 +684,7 @@
wutils.bld = bld
if Options.options.no_task_lines:
- import Runner
+ from waflib import Runner
def null_printout(s):
pass
Runner.printout = null_printout
@@ -712,8 +697,12 @@
bld.exclude_taskgen = types.MethodType(_exclude_taskgen, bld)
bld.find_ns3_module = types.MethodType(_find_ns3_module, bld)
+ # Clean documentation build directories; other cleaning happens later
+ if bld.cmd == 'clean':
+ _cleandocs()
+
# process subfolders from here
- bld.add_subdirs('src')
+ bld.recurse('src')
# If modules have been enabled, then set lists of enabled modules
# and enabled module test libraries.
@@ -780,7 +769,7 @@
# launch directory.
launch_dir = os.path.abspath(Context.launch_dir)
object_relative_path = os.path.join(
- wutils.relpath(obj.path.abspath(), launch_dir),
+ wutils.relpath(obj.path.get_bld().abspath(), launch_dir),
object_name)
bld.env.append_value('NS3_RUNNABLE_PROGRAMS', object_relative_path)
@@ -821,11 +810,11 @@
if script_runnable:
bld.env.append_value('NS3_RUNNABLE_SCRIPTS', script)
- bld.add_subdirs('bindings/python')
+ bld.recurse('bindings/python')
# Process this subfolder here after the lists of enabled modules
# and module test libraries have been set.
- bld.add_subdirs('utils')
+ bld.recurse('utils')
# Set this so that the lists will be printed at the end of this
# build command.
@@ -851,7 +840,26 @@
_doxygen(bld)
raise SystemExit(0)
+def _cleandir(name):
+ try:
+ shutil.rmtree(name)
+ except:
+ pass
+def _cleandocs():
+ _cleandir('doc/html')
+ _cleandir('doc/manual/build')
+ _cleandir('doc/tutorial/build')
+ _cleandir('doc/tutorial-pt/build')
+ _cleandir('doc/models/build')
+ _cleandir('doc/models/source-temp')
+
+# 'distclean' typically only cleans out build/ directory
+# Here we clean out any build or documentation artifacts not in build/
+def distclean(ctx):
+ _cleandocs()
+ # Now call waf's normal distclean
+ Scripting.distclean(ctx)
def shutdown(ctx):
bld = wutils.bld
@@ -920,7 +928,6 @@
-from waflib import Context, Build
class CheckContext(Context.Context):
"""run the equivalent of the old ns-3 unit tests using test.py"""
cmd = 'check'
@@ -938,7 +945,7 @@
class print_introspected_doxygen_task(Task.TaskBase):
- after = 'cc cxx link'
+ after = 'cxx link'
color = 'BLUE'
def __init__(self, bld):
@@ -962,7 +969,7 @@
# --enable-modules=xxx
pass
else:
- prog = program_obj.path.find_or_declare(ccroot.get_target_name(program_obj)).abspath(env)
+ prog = program_obj.path.find_or_declare(ccroot.get_target_name(program_obj)).get_bld().abspath(env)
# Create a header file with the introspected information.
doxygen_out = open(os.path.join('doc', 'introspected-doxygen.h'), 'w')
@@ -977,7 +984,7 @@
text_out.close()
class run_python_unit_tests_task(Task.TaskBase):
- after = 'cc cxx link'
+ after = 'cxx link'
color = 'BLUE'
def __init__(self, bld):
@@ -1016,7 +1023,6 @@
raise WafError(msg)
-from waflib import Context, Build
class Ns3ShellContext(Context.Context):
"""run a shell with an environment suitably modified to run locally built programs"""
cmd = 'shell'
@@ -1062,7 +1068,7 @@
raise SystemExit(1)
return
- prog = program_obj.path.find_or_declare(program_obj.target).abspath()
+ prog = program_obj.path.find_or_declare(program_obj.target).get_bld().abspath()
if not os.path.exists(prog):
Logs.error("print-introspected-doxygen has not been built yet."
@@ -1089,8 +1095,6 @@
raise SystemExit(1)
-from waflib import Context, Build
-
def _getVersion():
"""update the ns3_version.js file, when building documentation"""
@@ -1110,7 +1114,6 @@
bld.execute()
_doxygen(bld)
-from waflib import Context, Build
class Ns3SphinxContext(Context.Context):
"""build the Sphinx documentation: manual, tutorial, models"""
@@ -1131,7 +1134,6 @@
self.sphinx_build(os.path.join("doc", sphinxdir))
-from waflib import Context, Build
class Ns3DocContext(Context.Context):
"""build all the documentation: doxygen, manual, tutorial, models"""
--- a/wutils.py Fri Apr 05 16:50:37 2013 +0200
+++ b/wutils.py Fri Apr 05 17:59:11 2013 +0200
@@ -1,16 +1,12 @@
import os
import os.path
+import re
import sys
import subprocess
import shlex
# WAF modules
-import Options
-import Utils
-import Logs
-import TaskGen
-import Build
-import re
+from waflib import Options, Utils, Logs, TaskGen, Build, Context
from waflib.Errors import WafError
# these are set from the main wscript file
@@ -47,7 +43,7 @@
return os.path.curdir
return os.path.join(*rel_list)
-from waflib import Context
+
def find_program(program_name, env):
launch_dir = os.path.abspath(Context.launch_dir)
#top_dir = os.path.abspath(Options.cwd_launch)