diff -Naur ns-3.19/AUTHORS ns-3.20/AUTHORS --- ns-3.19/AUTHORS 2014-06-17 10:34:00.262638020 -0700 +++ ns-3.20/AUTHORS 2014-06-17 10:33:13.609998153 -0700 @@ -19,20 +19,24 @@ Junling Bu Elena Buchatskaia (borovkovaes@iitp.ru) Gustavo Carneiro (gjc@inescporto.pt, gjcarneiro@gmail.com) +Scott Carpenter (scarpen@ncsu.edu) Egemen K. Cetinkaya (ekc@iitc.ku.edu) Angelos Chatzipapas (chatzipa@ceid.upatras.gr) +Eugene Chemeritskiy (echemeritskiy@arccn.ru) Yufei Cheng (yfcheng@ittc.ku.edu) Andrey Churin (aachurin@gmail.com) Salva Climent (jocliba@gmail.com) Luis Cortes (cortes@gatech.edu) Luca Costantino (luca.costantino@gmail.com) Alexander D'souza (moijes12@gmail.com) +Sébastien Deronne (sebastien.deronne@gmail.com) Craig Dowell (craigdo@ee.washington.edu) Gilaras Drakeson Christian Facchini Denis Fakhriev (fakhriev@iitp.ru) Jahanzeb Farooq (Jahanzeb.Farooq@inria.fr, Jahanzeb.Farooq@gmail.com) Luca Favatella +Margherita Filippetti Pedro Fortuna (pedro.fortuna@inescporto.pt) Juliana Freitag Borin (juliana.freitag@gmail.com) Eric Gamess (egamess@gmail.com) @@ -41,6 +45,7 @@ Ashim Ghosh Martin Giachino (martin.giachino@gmail.com,giachino@fing.edu.uy) Tom Goff (tgoff@tgoff.net) +Juan C. Granda (jcgranda@uniovi.es) David Gross (gdavid.devel@gmail.com) Maja Grubišić (maja.grubisic@live.com) Charline Taibi Guguen (charline.guguen@gmail.com) @@ -51,6 +56,7 @@ Budiarto Herman Tom Hewer Kim Højgaard-Hansen +Chris Hood (chood8@gatech.edu) Blake Hurd (naimorai@gmail.com) ishan (ishan.chhabra@gmail.com) Mohamed Amine Ismail (amine.ismail@inria.fr, iamine@udcast.com) @@ -62,8 +68,10 @@ Piotr Jurkiewicz (piotr.jerzy.jurkiewicz@gmail.com) Evgeny Kalishenko (ydginster@gmail.com) Konstantinos Katsaros -Joe Kopena (tjkopena@cs.drexel.edu) +Morteza Kheirkhah (m.kheirkhah@sussex.ac.uk) Flavio Kobuta (flaviokubota@gmail.com) +Joe Kopena (tjkopena@cs.drexel.edu) +Christopher Kosecki (christopher.l.kosecki.ctr@mail.mil) Aleksey Kovalenko (kovalenko@iitp.ru) Mathieu Lacage (mathieu.lacage@inria.fr) Emmanuelle Laprise (emmmanuelle.laprise@bluekazoo.ca) @@ -71,10 +79,12 @@ Daniel Lertpratchya (nikkipui@gmail.com) Björn Lichtblau (lichtbla@informatik.hu-berlin.de) Timo Lindhorst +Erwan Livolant Keith Ma (keith.nwsuaf@gmail.com) Federico Maguolo (maguolof@dei.unipd.it) Antti Makela (zarhan@cc.hut.fi) Francesco Malandrino (francesco.malandrino@gmail.com) +Rubén Martínez (rmartinez@deic.uab.cat) Fabian Mauchle (f1mauchl@hsr.ch) Andrey Mazo (mazo@iitp.ru) Jonathan McCrohan (jmccroha@tcd.ie) @@ -115,8 +125,10 @@ Andrea Sacco (andrea.sacco85@gmail.com) Providence Salumu Munga (Providence.Salumu@gmail.com, Providence.Salumu_Munga@it-sudparis.eu) Francisco Javier Sánchez-Roselly +l.salameh@cs.ucl.ac.uk Florian Schmidt (Florian.Schmidt@cs.rwth-aachen.de) Guillaume Seguin (guillaume.seguin@inria.fr) +Tomasz Seweryn (tomasz.seweryn7@gmail.com) Kulin Shah (m.kulin@gmail.com) Guowang Shi Phillip Sitbon (phillip.sitbon@gmail.com) diff -Naur ns-3.19/bindings/python/ns3modulegen_core_customizations.py ns-3.20/bindings/python/ns3modulegen_core_customizations.py --- ns-3.19/bindings/python/ns3modulegen_core_customizations.py 2014-06-17 10:34:00.280637881 -0700 +++ ns-3.20/bindings/python/ns3modulegen_core_customizations.py 2014-06-17 10:33:13.628998007 -0700 @@ -1,3 +1,5 @@ +from __future__ import print_function +import sys import re from pybindgen.typehandlers import base as typehandlers @@ -26,11 +28,13 @@ def __init__(self): super(SmartPointerTransformation, self).__init__() self.rx = re.compile(r'(ns3::|::ns3::|)Ptr<([^>]+)>\s*$') + print("{0!r}".format(self), file=sys.stderr) def _get_untransformed_type_traits(self, name): m = self.rx.match(name) is_const = False if m is None: + print("{0!r} did not match".format(name), file=sys.stderr) return None, False else: name1 = m.group(2).strip() @@ -61,9 +65,9 @@ ## fix the ctype, add ns3:: namespace orig_ctype, is_const = self._get_untransformed_type_traits(args[0]) if is_const: - correct_ctype = 'ns3::Ptr< %s const >' % orig_ctype[:-2] + correct_ctype = 'ns3::Ptr< {0} const >'.format(orig_ctype[:-2]) else: - correct_ctype = 'ns3::Ptr< %s >' % orig_ctype[:-2] + correct_ctype = 'ns3::Ptr< {0} >'.format(orig_ctype[:-2]) args = tuple([correct_ctype] + list(args[1:])) handler = type_handler(*args, **kwargs) @@ -84,58 +88,6 @@ del transf -class ArgvParam(Parameter): - """ - Converts a python list-of-strings argument to a pair of 'int argc, - char *argv[]' arguments to pass into C. - - One Python argument becomes two C function arguments -> it's a miracle! - - Note: this parameter type handler is not registered by any name; - must be used explicitly. - """ - - DIRECTIONS = [Parameter.DIRECTION_IN] - CTYPES = [] - - def convert_c_to_python(self, wrapper): - raise NotImplementedError - - def convert_python_to_c(self, wrapper): - py_name = wrapper.declarations.declare_variable('PyObject*', 'py_' + self.name) - argc_var = wrapper.declarations.declare_variable('int', 'argc') - name = wrapper.declarations.declare_variable('char**', self.name) - idx = wrapper.declarations.declare_variable('Py_ssize_t', 'idx') - wrapper.parse_params.add_parameter('O!', ['&PyList_Type', '&'+py_name], self.name) - - #wrapper.before_call.write_error_check('!PyList_Check(%s)' % py_name) # XXX - - wrapper.before_call.write_code("%s = (char **) malloc(sizeof(char*)*PyList_Size(%s));" - % (name, py_name)) - wrapper.before_call.add_cleanup_code('free(%s);' % name) - wrapper.before_call.write_code(''' -for (%(idx)s = 0; %(idx)s < PyList_Size(%(py_name)s); %(idx)s++) -{ -''' % vars()) - wrapper.before_call.sink.indent() - wrapper.before_call.write_code(''' -PyObject *item = PyList_GET_ITEM(%(py_name)s, %(idx)s); -''' % vars()) - #wrapper.before_call.write_error_check('item == NULL') - wrapper.before_call.write_error_check( - '!PyString_Check(item)', - failure_cleanup=('PyErr_SetString(PyExc_TypeError, ' - '"argument %s must be a list of strings");') % self.name) - wrapper.before_call.write_code( - '%s[%s] = PyString_AsString(item);' % (name, idx)) - wrapper.before_call.sink.unindent() - wrapper.before_call.write_code('}') - wrapper.before_call.write_code('%s = PyList_Size(%s);' % (argc_var, py_name)) - - wrapper.call_params.append(argc_var) - wrapper.call_params.append(name) - - class CallbackImplProxyMethod(typehandlers.ReverseWrapperBase): """ Class that generates a proxy virtual method that calls a similarly named python method. @@ -204,7 +156,7 @@ kwargs = {} try: return_type = ReturnValue.new(str(return_ctype), **kwargs) - except (typehandlers.TypeLookupError, typehandlers.TypeConfigurationError), ex: + except (typehandlers.TypeLookupError, typehandlers.TypeConfigurationError) as ex: warnings.warn("***** Unable to register callback; Return value '%s' error (used in %s): %r" % (callback_return, cls_name, ex), Warning) @@ -223,7 +175,7 @@ kwargs = {} try: arguments.append(Parameter.new(str(param_ctype), arg_name, **kwargs)) - except (typehandlers.TypeLookupError, typehandlers.TypeConfigurationError), ex: + except (typehandlers.TypeLookupError, typehandlers.TypeConfigurationError) as ex: warnings.warn("***** Unable to register callback; parameter '%s %s' error (used in %s): %r" % (arg_type, arg_name, cls_name, ex), Warning) @@ -241,7 +193,7 @@ class PythonCallbackParameter(Parameter): "Class handlers" CTYPES = [cls_name] - print >> sys.stderr, "***** registering callback handler: %r" % ctypeparser.normalize_type_string(cls_name) + print("***** registering callback handler: %r" % ctypeparser.normalize_type_string(cls_name), file=sys.stderr) DIRECTIONS = [Parameter.DIRECTION_IN] PYTHON_CALLBACK_IMPL_NAME = class_name TEMPLATE_ARGS = template_parameters diff -Naur ns-3.19/bindings/python/ns3modulegen-modular.py ns-3.20/bindings/python/ns3modulegen-modular.py --- ns-3.19/bindings/python/ns3modulegen-modular.py 2014-06-17 10:34:00.278637897 -0700 +++ ns-3.20/bindings/python/ns3modulegen-modular.py 2014-06-17 10:33:13.626998022 -0700 @@ -1,3 +1,4 @@ +from __future__ import print_function import warnings import sys import os @@ -6,6 +7,8 @@ from pybindgen.module import MultiSectionFactory import ns3modulegen_core_customizations +import logging + pybindgen.settings.wrapper_registry = pybindgen.settings.StdMapWrapperRegistry import traceback @@ -55,6 +58,9 @@ def main(argv): + logging.basicConfig() + logging.getLogger("pybindgen.typehandlers").setLevel(logging.DEBUG) + module_abs_src_path, target, extension_name, output_cc_file_name = argv[1:] module_name = os.path.basename(module_abs_src_path) out = MyMultiSectionFactory(output_cc_file_name) @@ -71,11 +77,11 @@ try: from callbacks_list import callback_classes - except ImportError, ex: - print >> sys.stderr, "***************", repr(ex) + except ImportError as ex: + print("***************", repr(ex), file=sys.stderr) callback_classes = [] else: - print >> sys.stderr, ">>>>>>>>>>>>>>>>", repr(callback_classes) + print(">>>>>>>>>>>>>>>>", repr(callback_classes), file=sys.stderr) finally: sys.path.pop(0) diff -Naur ns-3.19/bindings/python/waf ns-3.20/bindings/python/waf --- ns-3.19/bindings/python/waf 2014-06-17 10:34:00.283637858 -0700 +++ ns-3.20/bindings/python/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" \ No newline at end of file diff -Naur ns-3.19/bindings/python/wscript ns-3.20/bindings/python/wscript --- ns-3.19/bindings/python/wscript 2014-06-17 10:34:00.286637835 -0700 +++ ns-3.20/bindings/python/wscript 2014-06-17 10:33:13.633997968 -0700 @@ -13,7 +13,7 @@ # after = TaskGen.after ## https://launchpad.net/pybindgen/ -REQUIRED_PYBINDGEN_VERSION = (0, 16, 0, 834) +REQUIRED_PYBINDGEN_VERSION = (0, 17, 0, 868) REQUIRED_PYGCCXML_VERSION = (0, 9, 5) RUN_ME=-3 @@ -47,6 +47,10 @@ opt.add_option('--with-python', help=('Path to the Python interpreter to use.'), default=None, dest='with_python', type="string") + opt.add_option('--no32bit-scan', + help=("Don't scan for the 32-bit variant of the bindings on 64-bit platforms."), + action="store_true", default=False, + dest='no32bit_scan') def configure(conf): @@ -161,7 +165,7 @@ else: out = subprocess.Popen([conf.env['PYTHON'][0], "-c", "import pybindgen.version; " - "print '.'.join([str(x) for x in pybindgen.version.__version__])"], + "print('.'.join([str(x) for x in pybindgen.version.__version__]))"], stdout=subprocess.PIPE).communicate()[0] pybindgen_version_str = out.strip() pybindgen_version = tuple([int(x) for x in pybindgen_version_str.split('.')]) @@ -436,7 +440,9 @@ else: import struct if struct.calcsize('I') == 4 and struct.calcsize('L') == 8 and struct.calcsize('P') == 8: - scan_targets.extend([('gcc_ILP32', '-m32'), ('gcc_LP64', '-m64')]) + if not Options.options.no32bit_scan: + scan_targets.append(('gcc_ILP32', '-m32')) + scan_targets.append(('gcc_LP64', '-m64')) elif struct.calcsize('I') == 4 and struct.calcsize('L') == 4 and struct.calcsize('P') == 4: scan_targets.append(('gcc_ILP32', '')) else: diff -Naur ns-3.19/CHANGES.html ns-3.20/CHANGES.html --- ns-3.19/CHANGES.html 2014-06-17 10:34:00.268637974 -0700 +++ ns-3.20/CHANGES.html 2014-06-17 10:33:13.616998099 -0700 @@ -51,6 +51,64 @@ us a note on ns-developers mailing list.


+

Changes from ns-3.19 to ns-3.20

+

New API:

+
    +
  • Models have been added for low-rate, wireless personal area networks +(LR-WPAN) as specified by IEEE standard 802.15.4 (2006). The current +emphasis is on the unslotted mode of 802.15.4 operation for use in Zigbee, +and the scope is limited to enabling a single mode (CSMA/CA) with basic +data transfer capabilities. Association with PAN coordinators is not yet +supported, nor the use of extended addressing. Interference is modeled as +AWGN but this is currently not thoroughly tested. The NetDevice Tx queue +is not limited, i.e., packets are never dropped due to queue becoming full. +They may be dropped due to excessive transmission retries or channel access +failure.
  • +
  • A new IPv6 routing protocol has been added: RIPng. This protocol is + an Interior Gateway Protocol and it is available in the Internet module.
  • +
  • A new LTE MAC downlink scheduling algorithm named Channel and QoS + Aware (CQA) Scheduler is provided by the new "ns3::CqaFfMacScheduler" object. +
  • +
  • Units may be attached to Time objects, to facilitate specific output + formats (see Time::As())
  • +
  • FlowMonitor "SerializeToXml" functions are now directly available + from the helper.
  • +
  • Access to OLSR's HNA table has been enabled
  • +
+ +

Changes to existing API:

+
    +
  • The SixLowPan model can now use uncompressed IPv6 headers. An option to + define the minimum compressed packet size has been added.
  • +
  • MinDistance wsa replaced by MinLoss in FriisPropagationLossModel, to + better handle conditions outside of the assumed far field region.
  • +
  • In the DSR model, the attribute DsrOptionRerrHeader::ErrorType" has + been removed.
  • +
+ +

Changes to build system:

+
    +
  • Python 3.3 is now supported for Python bindings for ns-3. Python 3.3 + support for API scanning is not supported. Python 3.2 is not supported.
  • +
  • Enable selection of high precision int64x64_t implementation + at configure time, for debugging purposes.
  • +
  • Optimized builds are now enabling signed overflow optimization + (-fstrict-overflow) and for gcc 4.8.2 and greater, also warning for cases + where an optimizization may occur due to compiler assumption that + overflow will not occur.
  • +
+ +

Changed behavior:

+
    +
  • The Internet FlowMonitor can now track IPv6 packets.
  • +
  • Ipv6Extension::m_dropTrace has been removed. Ipv6L3Protocol::m_dropTrace + is now fired when appropriate.
  • +
  • IPv4 identification field value is now dependent on the protocol + field.
  • +
  • Point-to-point trace sources now contain PPP headers
  • +
+ +

Changes from ns-3.18.1 to ns-3.19

New API:

diff -Naur ns-3.19/doc/doxygen.conf ns-3.20/doc/doxygen.conf --- ns-3.19/doc/doxygen.conf 2014-06-17 10:34:00.290637804 -0700 +++ ns-3.20/doc/doxygen.conf 2014-06-17 10:33:13.639997922 -0700 @@ -1,4 +1,6 @@ -# Doxyfile 1.8.1.1 +# -*-sh-*- + +# Doxyfile 1.8.3.1 # This file describes the settings to be used by the documentation system # doxygen (www.doxygen.org) for a project. @@ -126,7 +128,9 @@ # only done if one of the specified strings matches the left-hand part of # the path. The tag can be used to show relative paths in the file list. # If left blank the directory from which doxygen is run is used as the -# path to strip. +# path to strip. Note that you specify absolute paths here, but also +# relative paths, which will be relative from the directory where doxygen is +# started. STRIP_FROM_PATH = @@ -242,14 +246,15 @@ OPTIMIZE_OUTPUT_VHDL = NO # Doxygen selects the parser to use depending on the extension of the files it -# parses. With this tag you can assign which parser to use for a given extension. -# Doxygen has a built-in mapping, but you can override or extend it using this -# tag. The format is ext=language, where ext is a file extension, and language -# is one of the parsers supported by doxygen: IDL, Java, Javascript, CSharp, C, -# C++, D, PHP, Objective-C, Python, Fortran, VHDL, C, C++. For instance to make -# doxygen treat .inc files as Fortran files (default is PHP), and .f files as C -# (default is Fortran), use: inc=Fortran f=C. Note that for custom extensions -# you also need to set FILE_PATTERNS otherwise the files are not read by doxygen. +# parses. With this tag you can assign which parser to use for a given +# extension. Doxygen has a built-in mapping, but you can override or extend it +# using this tag. The format is ext=language, where ext is a file extension, +# and language is one of the parsers supported by doxygen: IDL, Java, +# Javascript, CSharp, C, C++, D, PHP, Objective-C, Python, Fortran, VHDL, C, +# C++. For instance to make doxygen treat .inc files as Fortran files (default +# is PHP), and .f files as C (default is Fortran), use: inc=Fortran f=C. Note +# that for custom extensions you also need to set FILE_PATTERNS otherwise the +# files are not read by doxygen. EXTENSION_MAPPING = @@ -262,6 +267,13 @@ MARKDOWN_SUPPORT = YES +# When enabled doxygen tries to link words that correspond to documented classes, +# or namespaces to their corresponding documentation. Such a link can be +# prevented in individual cases by by putting a % sign in front of the word or +# globally by setting AUTOLINK_SUPPORT to NO. + +AUTOLINK_SUPPORT = YES + # If you use STL classes (i.e. std::string, std::vector, etc.) but do not want # to include (a tag file for) the STL sources as input, then you should # set this tag to YES in order to let doxygen match functions declarations and @@ -282,10 +294,10 @@ SIP_SUPPORT = NO -# For Microsoft's IDL there are propget and propput attributes to indicate getter -# and setter methods for a property. Setting this option to YES (the default) -# will make doxygen replace the get and set methods by a property in the -# documentation. This will only work if the methods are indeed getting or +# For Microsoft's IDL there are propget and propput attributes to indicate +# getter and setter methods for a property. Setting this option to YES (the +# default) will make doxygen replace the get and set methods by a property in +# the documentation. This will only work if the methods are indeed getting or # setting a simple type. If this is not the case, or you want to show the # methods anyway, you should set this option to NO. @@ -346,7 +358,7 @@ # 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0, # corresponding to a cache size of 2^16 = 65536 symbols. -SYMBOL_CACHE_SIZE = 0 +SYMBOL_CACHE_SIZE = 1 # Similar to the SYMBOL_CACHE_SIZE the size of the symbol lookup cache can be # set using LOOKUP_CACHE_SIZE. This cache is used to resolve symbols given @@ -375,7 +387,8 @@ EXTRACT_PRIVATE = YES -# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal scope will be included in the documentation. +# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal +# scope will be included in the documentation. EXTRACT_PACKAGE = NO @@ -546,7 +559,8 @@ GENERATE_DEPRECATEDLIST= YES # The ENABLED_SECTIONS tag can be used to enable conditional -# documentation sections, marked by \if sectionname ... \endif. +# documentation sections, marked by \if section-label ... \endif +# and \cond section-label ... \endcond blocks. ENABLED_SECTIONS = @@ -604,7 +618,8 @@ # requires the bibtex tool to be installed. See also # http://en.wikipedia.org/wiki/BibTeX for more info. For LaTeX the style # of the bibliography can be controlled using LATEX_BIB_STYLE. To use this -# feature you need bibtex and perl available in the search path. +# feature you need bibtex and perl available in the search path. Do not use +# file names with spaces, bibtex cannot handle them. CITE_BIB_FILES = @@ -836,6 +851,13 @@ FILTER_SOURCE_PATTERNS = +# If the USE_MD_FILE_AS_MAINPAGE tag refers to the name of a markdown file that +# is part of the input, its contents will be placed on the main page (index.html). +# This can be useful if you have a project on for instance GitHub and want reuse +# the introduction page also for the doxygen output. + +USE_MDFILE_AS_MAINPAGE = + #--------------------------------------------------------------------------- # configuration options related to source browsing #--------------------------------------------------------------------------- @@ -957,12 +979,22 @@ # The HTML_STYLESHEET tag can be used to specify a user-defined cascading # style sheet that is used by each HTML page. It can be used to -# fine-tune the look of the HTML output. If the tag is left blank doxygen -# will generate a default style sheet. Note that doxygen will try to copy -# the style sheet file to the HTML output directory, so don't put your own -# style sheet in the HTML output directory as well, or it will be erased! +# fine-tune the look of the HTML output. If left blank doxygen will +# generate a default style sheet. Note that it is recommended to use +# HTML_EXTRA_STYLESHEET instead of this one, as it is more robust and this +# tag will in the future become obsolete. + +HTML_STYLESHEET = + +# The HTML_EXTRA_STYLESHEET tag can be used to specify an additional +# user-defined cascading style sheet that is included after the standard +# style sheets created by doxygen. Using this option one can overrule +# certain style aspects. This is preferred over using HTML_STYLESHEET +# since it does not replace the standard style sheet and is therefor more +# robust against future updates. Doxygen will copy the style sheet file to +# the output directory. -HTML_STYLESHEET = doc/ns3_html_theme/static/ns3_stylesheet.css +HTML_EXTRA_STYLESHEET = doc/ns3_html_theme/static/ns3_stylesheet.css # The HTML_EXTRA_FILES tag can be used to specify one or more extra images or # other source files which should be copied to the HTML output directory. Note @@ -971,8 +1003,7 @@ # files. In the HTML_STYLESHEET file, use the file name only. Also note that # the files will be copied as-is; there are no commands or markers available. -HTML_EXTRA_FILES = doc/ns3_html_theme/static/doxygen.css \ - doc/ns3_html_theme/static/bar-top.png \ +HTML_EXTRA_FILES = doc/ns3_html_theme/static/bar-top.png \ doc/ns3_html_theme/static/drop-down-menu.js \ doc/ns3_html_theme/static/favicon.ico \ doc/ns3_html_theme/static/menu-bgr-400.png \ @@ -1055,9 +1086,9 @@ DOCSET_BUNDLE_ID = org.nsnam.ns3 -# When GENERATE_PUBLISHER_ID tag specifies a string that should uniquely identify -# the documentation publisher. This should be a reverse domain-name style -# string, e.g. com.mycompany.MyDocSet.documentation. +# When GENERATE_PUBLISHER_ID tag specifies a string that should uniquely +# identify the documentation publisher. This should be a reverse domain-name +# style string, e.g. com.mycompany.MyDocSet.documentation. DOCSET_PUBLISHER_ID = org.nsnam.ns3 @@ -1242,6 +1273,13 @@ USE_MATHJAX = NO +# When MathJax is enabled you can set the default output format to be used for +# thA MathJax output. Supported types are HTML-CSS, NativeMML (i.e. MathML) and +# SVG. The default value is HTML-CSS, which is slower, but has the best +# compatibility. + +MATHJAX_FORMAT = HTML-CSS + # When MathJax is enabled you need to specify the location relative to the # HTML output directory using the MATHJAX_RELPATH option. The destination # directory should contain the MathJax.js script. For instance, if the mathjax @@ -1252,7 +1290,7 @@ # However, it is strongly recommended to install a local # copy of MathJax from http://www.mathjax.org before deployment. -MATHJAX_RELPATH = http://www.mathjax.org/mathjax +MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest # The MATHJAX_EXTENSIONS tag can be used to specify one or MathJax extension # names that should be enabled during MathJax rendering. @@ -1270,15 +1308,55 @@ SEARCHENGINE = YES # When the SERVER_BASED_SEARCH tag is enabled the search engine will be -# implemented using a PHP enabled web server instead of at the web client -# using Javascript. Doxygen will generate the search PHP script and index -# file to put on the web server. The advantage of the server -# based approach is that it scales better to large projects and allows -# full text search. The disadvantages are that it is more difficult to setup -# and does not have live searching capabilities. +# implemented using a web server instead of a web client using Javascript. +# There are two flavours of web server based search depending on the +# EXTERNAL_SEARCH setting. When disabled, doxygen will generate a PHP script for +# searching and an index file used by the script. When EXTERNAL_SEARCH is +# enabled the indexing and searching needs to be provided by external tools. +# See the manual for details. SERVER_BASED_SEARCH = NO +# When EXTERNAL_SEARCH is enabled doxygen will no longer generate the PHP +# script for searching. Instead the search results are written to an XML file +# which needs to be processed by an external indexer. Doxygen will invoke an +# external search engine pointed to by the SEARCHENGINE_URL option to obtain +# the search results. Doxygen ships with an example indexer (doxyindexer) and +# search engine (doxysearch.cgi) which are based on the open source search engine +# library Xapian. See the manual for configuration details. + +EXTERNAL_SEARCH = NO + +# The SEARCHENGINE_URL should point to a search engine hosted by a web server +# which will returned the search results when EXTERNAL_SEARCH is enabled. +# Doxygen ships with an example search engine (doxysearch) which is based on +# the open source search engine library Xapian. See the manual for configuration +# details. + +SEARCHENGINE_URL = + +# When SERVER_BASED_SEARCH and EXTERNAL_SEARCH are both enabled the unindexed +# search data is written to a file for indexing by an external tool. With the +# SEARCHDATA_FILE tag the name of this file can be specified. + +SEARCHDATA_FILE = searchdata.xml + +# When SERVER_BASED_SEARCH AND EXTERNAL_SEARCH are both enabled the +# EXTERNAL_SEARCH_ID tag can be used as an identifier for the project. This is +# useful in combination with EXTRA_SEARCH_MAPPINGS to search through multiple +# projects and redirect the results back to the right project. + +EXTERNAL_SEARCH_ID = + +# The EXTRA_SEARCH_MAPPINGS tag can be used to enable searching through doxygen +# projects other than the one defined by this configuration file, but that are +# all added to the same external search index. Each project needs to have a +# unique id set via EXTERNAL_SEARCH_ID. The search mapping then maps the id +# of to a relative location where the documentation can be found. +# The format is: EXTRA_SEARCH_MAPPINGS = id1=loc1 id2=loc2 ... + +EXTRA_SEARCH_MAPPINGS = + #--------------------------------------------------------------------------- # configuration options related to the LaTeX output #--------------------------------------------------------------------------- @@ -1564,6 +1642,9 @@ INCLUDE_PATH = +# Allow doxygen to find generated include files, such as ns3/core-config.h +INCLUDE_PATH += build + # You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard # patterns (like *.h and *.hpp) to filter out the header-files in the # directories. If left blank, the patterns specified with FILE_PATTERNS will @@ -1579,8 +1660,22 @@ # undefined via #undef or recursively expanded use the := operator # instead of the = operator. -PREDEFINED = NS3_ASSERT_ENABLE \ - NS3_LOG_ENABLE +# ns-3: +# +# We predefine NS3_ASSERT_ENABLE and NS3_LOG_ENABLE so doxygen sees +# the working definitions. (These are normally defined by waf +# in ns3/core-config.h) +# +# Function like macros at file global scope typically need to be here, +# since doxygen confuses invocations of these macros for function +# definitions. + +PREDEFINED = \ + NS3_ASSERT_ENABLE \ + NS3_LOG_ENABLE \ + NS_LOG_COMPONENT_DEFINE()=1 \ + NS_LOG_COMPONENT_DEFINE_MASK()=1 \ + NS_OBJECT_ENSURE_REGISTERED()=1 \ # If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then # this tag can be used to specify a list of macro names that should be expanded. diff -Naur ns-3.19/doc/doxygen.warnings.report.sh ns-3.20/doc/doxygen.warnings.report.sh --- ns-3.19/doc/doxygen.warnings.report.sh 2014-06-17 10:34:00.291637796 -0700 +++ ns-3.20/doc/doxygen.warnings.report.sh 2014-06-17 10:33:13.639997922 -0700 @@ -136,14 +136,14 @@ conf=$DIR/doxygen.conf sed -i.bak -E '/^EXTRACT_ALL |^HAVE_DOT |^WARNINGS /s/YES/no/' $conf - rm -f $conf.bak echo echo -n "Rebuilding doxygen docs with full errors..." (cd "$ROOT" && ./waf --doxygen >/dev/null 2>&1) status=$? - hg revert $conf + rm -f $conf + mv -f $conf.bak $conf if [ $status -eq 0 ]; then echo "Done." diff -Naur ns-3.19/doc/main.h ns-3.20/doc/main.h --- ns-3.19/doc/main.h 2014-06-17 10:34:00.292637789 -0700 +++ ns-3.20/doc/main.h 2014-06-17 10:33:13.640997914 -0700 @@ -71,3 +71,28 @@ * ns3 namespace. */ +// Macros defined by the build system. +// +// These have to be visible for doxygen to document them, +// so we put them here in a file only seen by doxygen, not the compiler. +/** + * \ingroup assert + * + * \def NS3_ASSERT_ENABLE + * + * Enable asserts at compile time. + * + * This is normally set by `./waf configure --build-profile=debug`. + */ +#define NS3_ASSERT_ENABLE + +/** + * \ingroup logging + * + * \def NS3_LOG_ENABLE + * + * Enable logging at compile time. + * + * This is normally set by `./waf configure --build-profile=debug`. + */ +#define NS3_LOG_ENABLE diff -Naur ns-3.19/doc/manual/source/attributes.rst ns-3.20/doc/manual/source/attributes.rst --- ns-3.19/doc/manual/source/attributes.rst 2014-06-17 10:34:00.296637758 -0700 +++ ns-3.20/doc/manual/source/attributes.rst 2014-06-17 10:33:13.644997883 -0700 @@ -741,6 +741,11 @@ Simulator::Destroy (); +Note the placement of these statements just prior to the +:cpp:func:`Simulator::Run ()` statement. This output logs all of the +values in place just prior to starting the simulation (i.e. after +all of the configuration has taken place). + After running, you can open the output-attributes.txt file and see: .. sourcecode:: text @@ -808,15 +813,34 @@ This file can be archived with your simulation script and output data. -While it is possible to generate a sample config file and lightly edit it to -change a couple of values, there are cases where this process will not work -because the same value on the same object can appear multiple times in the same -automatically-generated configuration file under different configuration paths. - -As such, the best way to use this class is to use it to generate an initial -configuration file, extract from that configuration file only the strictly -necessary elements, and move these minimal elements to a new configuration file -which can then safely be edited and loaded in a subsequent simulation run. +Next, we discuss using this to configure simulations via an input +configuration file. There are a couple of key differences when +compared to use for logging the final simulation configuration. First, we +need to place statements such as these at the beginning of the program, +before simulation configuration statements are written (so the values +are registered before being used in object construction). + +:: + + Config::SetDefault ("ns3::ConfigStore::Filename", StringValue ("input-defaults.xml")); + Config::SetDefault ("ns3::ConfigStore::Mode", StringValue ("Load")); + Config::SetDefault ("ns3::ConfigStore::FileFormat", StringValue ("Xml")); + ConfigStore inputConfig; + inputConfig.ConfigureDefaults (); + +Next, note that loading of input configuration data is limited to attribute +default (i.e. not instance) values, and global values. Attribute instance +values are not supported because at this stage of the simulation, before +any objects are constructed, there are no such object instances around. +(Note, future enhancements to the config store may change this behavior). + +Second, while the output of config store state will list everything in +the database, the input file need only contain the specific values to +be overridden. So, one way to use this class for input file configuration +is to generate an initial configuration using the output (Save) method +described above, extract from that configuration file only the elements +one wishes to change, and move these minimal elements to a new configuration +file which can then safely be edited and loaded in a subsequent simulation run. When the ConfigStore object is instantiated, its attributes Filename, Mode, and FileFormat must be set, either via command-line or via program statements. @@ -824,9 +848,7 @@ As a more complicated example, let's assume that we want to read in a configuration of defaults from an input file named "input-defaults.xml", and write out the resulting attributes to a separate file called -"output-attributes.xml". (Note-- to get this input xml file to begin with, it -is sometimes helpful to run the program to generate an output xml file first, -then hand-edit that file and re-input it for the next simulation run).:: +"output-attributes.xml".:: #include "ns3/config-store-module.h" ... diff -Naur ns-3.19/doc/manual/source/conf.py ns-3.20/doc/manual/source/conf.py --- ns-3.19/doc/manual/source/conf.py 2014-06-17 10:34:00.297637750 -0700 +++ ns-3.20/doc/manual/source/conf.py 2014-06-17 10:33:13.645997876 -0700 @@ -41,16 +41,16 @@ # General information about the project. project = u'ns-3' -copyright = u'2008-13, ns-3 project' +copyright = u'2010, ns-3 project' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. # # The short X.Y version. -version = 'ns-3.19' +version = 'ns-3.20' # The full version, including alpha/beta/rc tags. -release = 'ns-3.19' +release = 'ns-3.20' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff -Naur ns-3.19/doc/manual/source/object-model.rst ns-3.20/doc/manual/source/object-model.rst --- ns-3.19/doc/manual/source/object-model.rst 2014-06-17 10:34:00.303637704 -0700 +++ ns-3.20/doc/manual/source/object-model.rst 2014-06-17 10:33:13.651997829 -0700 @@ -176,7 +176,7 @@ binary-level compatibility of replaceable components is not supported and we have tried to simplify the syntax and impact on model developers. -Exmaples +Examples ******** Aggregation example diff -Naur ns-3.19/doc/models/Makefile ns-3.20/doc/models/Makefile --- ns-3.19/doc/models/Makefile 2014-06-17 10:34:00.310637650 -0700 +++ ns-3.20/doc/models/Makefile 2014-06-17 10:33:13.658997775 -0700 @@ -80,6 +80,7 @@ $(SRC)/flow-monitor/doc/flow-monitor.rst \ $(SRC)/wave/doc/wave.rst \ $(SRC)/sixlowpan/doc/sixlowpan.rst \ + $(SRC)/lr-wpan/doc/lr-wpan.rst \ # list all model library figure files that need to be copied to # $SOURCETEMP/figures. For each figure to be included in all @@ -213,28 +214,29 @@ $(SRC)/stats/doc/gnuplot-example.png \ $(SRC)/stats/doc/gnuplot-helper-example.png \ $(SRC)/stats/doc/seventh-packet-byte-count.png \ - $(SRC)/netanim/doc/figures/Dumbbell.png \ - $(SRC)/netanim/doc/figures/Dumbbell.pdf \ $(SRC)/netanim/doc/figures/PacketStatistics.png \ $(SRC)/netanim/doc/figures/PacketStatistics.pdf \ - $(SRC)/netanim/doc/figures/FastForward.png \ - $(SRC)/netanim/doc/figures/FastForward.pdf \ - $(SRC)/netanim/doc/figures/Wireless.png \ - $(SRC)/netanim/doc/figures/Wireless.pdf \ - $(SRC)/netanim/doc/figures/Precision.png \ - $(SRC)/netanim/doc/figures/Precision.pdf \ - $(SRC)/netanim/doc/figures/Persist.png \ - $(SRC)/netanim/doc/figures/Persist.pdf \ - $(SRC)/netanim/doc/figures/SimTime.png \ - $(SRC)/netanim/doc/figures/SimTime.pdf \ + $(SRC)/netanim/doc/figures/NetAnim_3_105.png \ + $(SRC)/netanim/doc/figures/NetAnim_3_105.pdf \ $(SRC)/netanim/doc/figures/Trajectory.png \ $(SRC)/netanim/doc/figures/Trajectory.pdf \ - $(SRC)/netanim/doc/figures/UpdateRateInterval.png \ - $(SRC)/netanim/doc/figures/UpdateRateInterval.pdf \ - $(SRC)/netanim/doc/figures/WithoutPrecision.png \ - $(SRC)/netanim/doc/figures/WithoutPrecision.pdf \ - $(SRC)/netanim/doc/figures/WithPrecision.png \ - $(SRC)/netanim/doc/figures/WithPrecision.pdf \ + $(SRC)/netanim/doc/figures/NodeCountersChart.png \ + $(SRC)/netanim/doc/figures/NodeCountersChart.pdf \ + $(SRC)/netanim/doc/figures/NodeCountersTable.png \ + $(SRC)/netanim/doc/figures/NodeCountersTable.pdf \ + $(SRC)/netanim/doc/figures/RoutingTables.png \ + $(SRC)/netanim/doc/figures/RoutingTables.pdf \ + $(SRC)/netanim/doc/figures/PacketTimeline.png \ + $(SRC)/netanim/doc/figures/PacketTimeline.pdf \ + $(SRC)/spectrum/doc/spectrum-channel-phy-interface.png \ + $(SRC)/spectrum/doc/spectrum-channel-phy-interface.pdf \ + $(SRC)/spectrum/doc/spectrum-analyzer-example.eps \ + $(SRC)/lr-wpan/doc/lr-wpan-arch.dia \ + $(SRC)/lr-wpan/doc/lr-wpan-data-example.dia \ + $(SRC)/lr-wpan/doc/lr-wpan-primitives.dia \ + $(SRC)/lr-wpan/doc/802-15-4-ber.eps \ + $(SRC)/lr-wpan/doc/802-15-4-per-sens.eps \ + $(SRC)/lr-wpan/doc/802-15-4-psr-distance.eps # specify figures from which .png and .pdf figures need to be # generated (all dia and eps figures) @@ -303,6 +305,13 @@ $(FIGURES)/lte-epc-x2-entity-saps.eps \ $(FIGURES)/lte-strongest-cell-handover-algorithm.eps \ $(FIGURES)/auvmobility-classes.eps \ + $(FIGURES)/spectrum-analyzer-example.eps \ + $(FIGURES)/lr-wpan-primitives.eps \ + $(FIGURES)/lr-wpan-data-example.eps \ + $(FIGURES)/lr-wpan-arch.eps \ + $(FIGURES)/802-15-4-ber.eps \ + $(FIGURES)/802-15-4-per-sens.eps \ + $(FIGURES)/802-15-4-psr-distance.eps # rescale pdf figures as necessary $(FIGURES)/testbed.pdf_width = 5in @@ -339,6 +348,9 @@ $(FIGURES)/mac-random-access-noncontention.pdf_width = 15cm $(FIGURES)/helpers.pdf_width = 8cm $(FIGURES)/auvmobility-classes.pdf_width = 10cm +$(FIGURES)/spectrum-analyzer-example.pdf_width = 15cm +$(FIGURES)/lr-wpan-primitives.pdf_width = 3in +$(FIGURES)/lr-wpan-arch.pdf_width = 2in IMAGES_PNG = ${IMAGES_EPS:.eps=.png} IMAGES_PDF = ${IMAGES_EPS:.eps=.pdf} @@ -389,11 +401,10 @@ @echo " doctest to run all doctests embedded in the documentation (if enabled)" copy-sources: $(SOURCES) - @rm -rf $(SOURCETEMP) @mkdir -p $(SOURCETEMP) @mkdir -p $(FIGURES) - @cp -r $(SOURCES) $(SOURCETEMP) - @cp -r $(SOURCEFIGS) $(FIGURES) + @cp -r -p $(SOURCES) $(SOURCETEMP) + @cp -r -p $(SOURCEFIGS) $(FIGURES) clean: -rm -rf $(BUILDDIR)/* diff -Naur ns-3.19/doc/models/source/conf.py ns-3.20/doc/models/source/conf.py --- ns-3.19/doc/models/source/conf.py 2014-06-17 10:34:00.312637634 -0700 +++ ns-3.20/doc/models/source/conf.py 2014-06-17 10:33:13.660997760 -0700 @@ -41,16 +41,16 @@ # General information about the project. project = u'ns-3' -copyright = u'2008-13, ns-3 project' +copyright = u'2011, ns-3 project' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. # # The short X.Y version. -version = 'ns-3.19' +version = 'ns-3.20' # The full version, including alpha/beta/rc tags. -release = 'ns-3.19' +release = 'ns-3.20' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff -Naur ns-3.19/doc/models/source/index.rst ns-3.20/doc/models/source/index.rst --- ns-3.19/doc/models/source/index.rst 2014-06-17 10:34:00.312637634 -0700 +++ ns-3.20/doc/models/source/index.rst 2014-06-17 10:33:13.661997752 -0700 @@ -33,6 +33,7 @@ energy flow-monitor internet-models + lr-wpan lte mesh distributed diff -Naur ns-3.19/doc/modules ns-3.20/doc/modules --- ns-3.19/doc/modules 2014-06-17 10:34:00.314637619 -0700 +++ ns-3.20/doc/modules 2014-06-17 10:33:13.662997744 -0700 @@ -1,33 +1,42 @@ /** * @anchor modules_anchor * - * @defgroup constructs Introspected Lists - * \brief These are lists of useful items found by examining the type system. - * * @defgroup constants Constants * @brief Constants you can change * * @defgroup utils Utils * @brief The utils directory is for various programs and scripts related * to code coverage, test suites, style checking, and benchmarking. - * + */ +/** * @defgroup core Core * \brief The "core" module contains: - * - a time management class to hold a time and convert between various time units: ns3::Time - * - a scheduler base class used to implement new simulation event schedulers: + * - a time management class to hold a time and convert between various + * time units: ns3::Time + * - a scheduler base class used to implement new simulation event + * schedulers: * ns3::Scheduler and ns3::SchedulerFactory - * - a simulator class used to create, schedule and cancel events: ns3::Simulator + * - a simulator class used to create, schedule and cancel events: + * ns3::Simulator * - a Functor class: ns3::Callback - * - an os-independent interface to get access to the elapsed wall clock time: ns3::SystemWallClockMs - * - a class to register regression tests with the test manager: ns3::Test and ns3::TestManager - * - debugging facilities: \ref logging, \ref assert + * - an os-independent interface to get access to the elapsed wall clock + * time: ns3::SystemWallClockMs + * - a class to register regression tests with the test manager: ns3::Test + * and ns3::TestManager + * - debugging facilities: \ref debugging * - \ref randomvariable - * - a base class for objects which need to support per-instance "attributes" and - * trace sources: ns3::ObjectBase + * - a base class for objects which need to support per-instance + * "attributes" and trace sources: ns3::ObjectBase * - a base class for objects which need to support reference counting * and dynamic object aggregation: ns3::Object - * - a smart-pointer class ns3::Ptr designed to work together with ns3::Object - * - a configuration class used to set and control all attributes and trace sources - * in a simulation: ns3::Config. + * - a smart-pointer class ns3::Ptr designed to work together with + * ns3::Object + * - a configuration class used to set and control all attributes and + * trace sources in a simulation: ns3::Config. + */ +/** + * @ingroup core + * @defgroup debugging Debugging tools * + * @brief Assertions, breakpoints, logging, and abnormal program termination */ diff -Naur ns-3.19/doc/ns3_html_theme/get_version.sh ns-3.20/doc/ns3_html_theme/get_version.sh --- ns-3.19/doc/ns3_html_theme/get_version.sh 2014-06-17 10:34:00.316637604 -0700 +++ ns-3.20/doc/ns3_html_theme/get_version.sh 2014-06-17 10:33:13.664997729 -0700 @@ -71,6 +71,7 @@ # script arguments say +say using doxygen: $(which doxygen) $(doxygen --version) public=0 nsnam=0 daily=0 diff -Naur ns-3.19/doc/ns3_html_theme/ns3_doxy_footer.html ns-3.20/doc/ns3_html_theme/ns3_doxy_footer.html --- ns-3.19/doc/ns3_html_theme/ns3_doxy_footer.html 2014-06-17 10:34:00.317637596 -0700 +++ ns-3.20/doc/ns3_html_theme/ns3_doxy_footer.html 2014-06-17 10:33:13.665997721 -0700 @@ -1,3 +1,7 @@ + diff -Naur ns-3.19/doc/ns3_html_theme/static/doxygen.css ns-3.20/doc/ns3_html_theme/static/doxygen.css --- ns-3.19/doc/ns3_html_theme/static/doxygen.css 2014-06-17 10:34:00.318637588 -0700 +++ ns-3.20/doc/ns3_html_theme/static/doxygen.css 1969-12-31 16:00:00.000000000 -0800 @@ -1,1156 +0,0 @@ -/* The standard CSS for doxygen */ - -body, table, div, p, dl { - font-family: Lucida Grande, Verdana, Geneva, Arial, sans-serif; - font-size: 13px; - line-height: 1.3; -} - -/* @group Heading Levels */ - -h1 { - font-size: 150%; -} - -.title { - font-size: 150%; - font-weight: bold; - margin: 10px 2px; -} - -h2 { - font-size: 120%; -} - -h3 { - font-size: 100%; -} - -h1, h2, h3, h4, h5, h6 { - -webkit-transition: text-shadow 0.5s linear; - -moz-transition: text-shadow 0.5s linear; - -ms-transition: text-shadow 0.5s linear; - -o-transition: text-shadow 0.5s linear; - transition: text-shadow 0.5s linear; - margin-right: 15px; -} - -h1.glow, h2.glow, h3.glow, h4.glow, h5.glow, h6.glow { - text-shadow: 0 0 15px cyan; -} - -dt { - font-weight: bold; -} - -div.multicol { - -moz-column-gap: 1em; - -webkit-column-gap: 1em; - -moz-column-count: 3; - -webkit-column-count: 3; -} - -p.startli, p.startdd, p.starttd { - margin-top: 2px; -} - -p.endli { - margin-bottom: 0px; -} - -p.enddd { - margin-bottom: 4px; -} - -p.endtd { - margin-bottom: 2px; -} - -/* @end */ - -caption { - font-weight: bold; -} - -span.legend { - font-size: 70%; - text-align: center; -} - -h3.version { - font-size: 90%; - text-align: center; -} - -div.qindex, div.navtab{ - background-color: #EFEFEF; - border: 1px solid #B5B5B5; - text-align: center; -} - -div.qindex, div.navpath { - width: 100%; - line-height: 140%; -} - -div.navtab { - margin-right: 15px; -} - -/* @group Link Styling */ - -a { - color: #585858; - font-weight: normal; - text-decoration: none; -} - -.contents a:visited { - color: #686868; -} - -a:hover { - text-decoration: underline; -} - -a.qindex { - font-weight: bold; -} - -a.qindexHL { - font-weight: bold; - background-color: #B0B0B0; - color: #ffffff; - border: 1px double #9F9F9F; -} - -.contents a.qindexHL:visited { - color: #ffffff; -} - -a.el { - font-weight: bold; -} - -a.elRef { -} - -a.code, a.code:visited { - color: #4665A2; -} - -a.codeRef, a.codeRef:visited { - color: #4665A2; -} - -/* @end */ - -dl.el { - margin-left: -1cm; -} - -pre.fragment { - border: 1px solid #C4CFE5; - background-color: #FBFCFD; - padding: 4px 6px; - margin: 4px 8px 4px 2px; - overflow: auto; - word-wrap: break-word; - font-size: 9pt; - line-height: 125%; - font-family: monospace, fixed; - font-size: 105%; -} - -div.fragment { - padding: 4px; - margin: 4px; - background-color: #FCFCFC; - border: 1px solid #D0D0D0; -} - -div.line { - font-family: monospace, fixed; - font-size: 13px; - min-height: 13px; - line-height: 1.0; - text-wrap: unrestricted; - white-space: -moz-pre-wrap; /* Moz */ - white-space: -pre-wrap; /* Opera 4-6 */ - white-space: -o-pre-wrap; /* Opera 7 */ - white-space: pre-wrap; /* CSS3 */ - word-wrap: break-word; /* IE 5.5+ */ - text-indent: -53px; - padding-left: 53px; - padding-bottom: 0px; - margin: 0px; - -webkit-transition-property: background-color, box-shadow; - -webkit-transition-duration: 0.5s; - -moz-transition-property: background-color, box-shadow; - -moz-transition-duration: 0.5s; - -ms-transition-property: background-color, box-shadow; - -ms-transition-duration: 0.5s; - -o-transition-property: background-color, box-shadow; - -o-transition-duration: 0.5s; - transition-property: background-color, box-shadow; - transition-duration: 0.5s; -} - -div.line.glow { - background-color: cyan; - box-shadow: 0 0 10px cyan; -} - - -span.lineno { - padding-right: 4px; - text-align: right; - border-right: 2px solid #0F0; - background-color: #E8E8E8; - white-space: pre; -} -span.lineno a { - background-color: #D8D8D8; -} - -span.lineno a:hover { - background-color: #C8C8C8; -} - -div.ah { - background-color: black; - font-weight: bold; - color: #ffffff; - margin-bottom: 3px; - margin-top: 3px; - padding: 0.2em; - border: solid thin #333; - border-radius: 0.5em; - -webkit-border-radius: .5em; - -moz-border-radius: .5em; - box-shadow: 2px 2px 3px #999; - -webkit-box-shadow: 2px 2px 3px #999; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; - background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444)); - background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000); -} - -div.groupHeader { - margin-left: 16px; - margin-top: 12px; - font-weight: bold; -} - -div.groupText { - margin-left: 16px; - font-style: italic; -} - -body { - background-color: white; - color: black; - margin: 0; -} - -div.contents { - margin-top: 10px; - margin-left: 12px; - margin-right: 8px; -} - -td.indexkey { - background-color: #EFEFEF; - font-weight: bold; - border: 1px solid #D0D0D0; - margin: 2px 0px 2px 0; - padding: 2px 10px; - white-space: nowrap; - vertical-align: top; -} - -td.indexvalue { - background-color: #EFEFEF; - border: 1px solid #D0D0D0; - padding: 2px 10px; - margin: 2px 0px; -} - -tr.memlist { - background-color: #F1F1F1; -} - -p.formulaDsp { - text-align: center; -} - -img.formulaDsp { - -} - -img.formulaInl { - vertical-align: middle; -} - -div.center { - text-align: center; - margin-top: 0px; - margin-bottom: 0px; - padding: 0px; -} - -div.center img { - border: 0px; -} - -address.footer { - text-align: right; - padding-right: 12px; -} - -img.footer { - border: 0px; - vertical-align: middle; -} - -/* @group Code Colorization */ - -span.keyword { - color: #008000 -} - -span.keywordtype { - color: #604020 -} - -span.keywordflow { - color: #e08000 -} - -span.comment { - color: #800000 -} - -span.preprocessor { - color: #806020 -} - -span.stringliteral { - color: #002080 -} - -span.charliteral { - color: #008080 -} - -span.vhdldigit { - color: #ff00ff -} - -span.vhdlchar { - color: #000000 -} - -span.vhdlkeyword { - color: #700070 -} - -span.vhdllogic { - color: #ff0000 -} - -blockquote { - background-color: #F8F8F8; - border-left: 2px solid #B0B0B0; - margin: 0 24px 0 4px; - padding: 0 12px 0 16px; -} - -/* @end */ - -/* -.search { - color: #003399; - font-weight: bold; -} - -form.search { - margin-bottom: 0px; - margin-top: 0px; -} - -input.search { - font-size: 75%; - color: #000080; - font-weight: normal; - background-color: #e8eef2; -} -*/ - -td.tiny { - font-size: 75%; -} - -.dirtab { - padding: 4px; - border-collapse: collapse; - border: 1px solid #B5B5B5; -} - -th.dirtab { - background: #EFEFEF; - font-weight: bold; -} - -hr { - height: 0px; - border: none; - border-top: 1px solid #6E6E6E; -} - -hr.footer { - height: 1px; -} - -/* @group Member Descriptions */ - -table.memberdecls { - border-spacing: 0px; - padding: 0px; -} - -.memberdecls td { - -webkit-transition-property: background-color, box-shadow; - -webkit-transition-duration: 0.5s; - -moz-transition-property: background-color, box-shadow; - -moz-transition-duration: 0.5s; - -ms-transition-property: background-color, box-shadow; - -ms-transition-duration: 0.5s; - -o-transition-property: background-color, box-shadow; - -o-transition-duration: 0.5s; - transition-property: background-color, box-shadow; - transition-duration: 0.5s; -} - -.memberdecls td.glow { - background-color: cyan; - box-shadow: 0 0 15px cyan; -} - -.mdescLeft, .mdescRight, -.memItemLeft, .memItemRight, -.memTemplItemLeft, .memTemplItemRight, .memTemplParams { - background-color: #FAFAFA; - border: none; - margin: 4px; - padding: 1px 0 0 8px; -} - -.mdescLeft, .mdescRight { - padding: 0px 8px 4px 8px; - color: #555; -} - -.memItemLeft, .memItemRight, .memTemplParams { - border-top: 1px solid #D0D0D0; -} - -.memItemLeft, .memTemplItemLeft { - white-space: nowrap; -} - -.memItemRight { - width: 100%; -} - -.memTemplParams { - color: #686868; - white-space: nowrap; -} - -/* @end */ - -/* @group Member Details */ - -/* Styles for detailed member documentation */ - -.memtemplate { - font-size: 80%; - color: #686868; - font-weight: normal; - margin-left: 9px; -} - -.memnav { - background-color: #EFEFEF; - border: 1px solid #B5B5B5; - text-align: center; - margin: 2px; - margin-right: 15px; - padding: 2px; -} - -.mempage { - width: 100%; -} - -.memitem { - padding: 0; - margin-bottom: 10px; - margin-right: 5px; - -webkit-transition: box-shadow 0.5s linear; - -moz-transition: box-shadow 0.5s linear; - -ms-transition: box-shadow 0.5s linear; - -o-transition: box-shadow 0.5s linear; - transition: box-shadow 0.5s linear; - display: table !important; - width: 100%; -} - -.memitem.glow { - box-shadow: 0 0 15px cyan; -} - -.memname { - font-weight: bold; - margin-left: 6px; -} - -.memname td { - vertical-align: bottom; -} - -.memproto, dl.reflist dt { - border-top: 1px solid #B9B9B9; - border-left: 1px solid #B9B9B9; - border-right: 1px solid #B9B9B9; - padding: 6px 0px 6px 0px; - color: #323232; - font-weight: bold; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - background-image:url('nav_f.png'); - background-repeat:repeat-x; - background-color: #E8E8E8; - /* opera specific markup */ - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - border-top-right-radius: 4px; - border-top-left-radius: 4px; - /* firefox specific markup */ - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - -moz-border-radius-topright: 4px; - -moz-border-radius-topleft: 4px; - /* webkit specific markup */ - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - -webkit-border-top-right-radius: 4px; - -webkit-border-top-left-radius: 4px; - -} - -.memdoc, dl.reflist dd { - border-bottom: 1px solid #B9B9B9; - border-left: 1px solid #B9B9B9; - border-right: 1px solid #B9B9B9; - padding: 6px 10px 2px 10px; - background-color: #FCFCFC; - border-top-width: 0; - background-image:url('nav_g.png'); - background-repeat:repeat-x; - background-color: #FFFFFF; - /* opera specific markup */ - border-bottom-left-radius: 4px; - border-bottom-right-radius: 4px; - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - /* firefox specific markup */ - -moz-border-radius-bottomleft: 4px; - -moz-border-radius-bottomright: 4px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - /* webkit specific markup */ - -webkit-border-bottom-left-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); -} - -dl.reflist dt { - padding: 5px; -} - -dl.reflist dd { - margin: 0px 0px 10px 0px; - padding: 5px; -} - -.paramkey { - text-align: right; -} - -.paramtype { - white-space: nowrap; -} - -.paramname { - color: #602020; - white-space: nowrap; -} -.paramname em { - font-style: normal; -} -.paramname code { - line-height: 14px; -} - -.params, .retval, .exception, .tparams { - margin-left: 0px; - padding-left: 0px; -} - -.params .paramname, .retval .paramname { - font-weight: bold; - vertical-align: top; -} - -.params .paramtype { - font-style: italic; - vertical-align: top; -} - -.params .paramdir { - font-family: "courier new",courier,monospace; - vertical-align: top; -} - -table.mlabels { - border-spacing: 0px; -} - -td.mlabels-left { - width: 100%; - padding: 0px; -} - -td.mlabels-right { - vertical-align: bottom; - padding: 0px; - white-space: nowrap; -} - -span.mlabels { - margin-left: 8px; -} - -span.mlabel { - background-color: #8F8F8F; - border-top:1px solid #787878; - border-left:1px solid #787878; - border-right:1px solid #D0D0D0; - border-bottom:1px solid #D0D0D0; - text-shadow: none; - color: white; - margin-right: 4px; - padding: 2px 3px; - border-radius: 3px; - font-size: 7pt; - white-space: nowrap; -} - - - -/* @end */ - -/* these are for tree view when not used as main index */ - -div.directory { - margin: 10px 0px; - border-top: 1px solid #A8B8D9; - border-bottom: 1px solid #A8B8D9; - width: 100%; -} - -.directory table { - border-collapse:collapse; -} - -.directory td { - margin: 0px; - padding: 0px; - vertical-align: top; -} - -.directory td.entry { - white-space: nowrap; - padding-right: 6px; -} - -.directory td.entry a { - outline:none; -} - -.directory td.entry a img { - border: none; -} - -.directory td.desc { - width: 100%; - padding-left: 6px; - padding-right: 6px; - border-left: 1px solid rgba(0,0,0,0.05); -} - -.directory tr.even { - padding-left: 6px; - background-color: #F8F8F8; -} - -.directory img { - vertical-align: -30%; -} - -.directory .levels { - white-space: nowrap; - width: 100%; - text-align: right; - font-size: 9pt; -} - -.directory .levels span { - cursor: pointer; - padding-left: 2px; - padding-right: 2px; - color: #585858; -} - -div.dynheader { - margin-top: 8px; - -webkit-touch-callout: none; - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} - -address { - font-style: normal; - color: #3A3A3A; -} - -table.doxtable { - border-collapse:collapse; - margin-top: 4px; - margin-bottom: 4px; -} - -table.doxtable td, table.doxtable th { - border: 1px solid #3F3F3F; - padding: 3px 7px 2px; -} - -table.doxtable th { - background-color: #4F4F4F; - color: #FFFFFF; - font-size: 110%; - padding-bottom: 4px; - padding-top: 5px; -} - -table.fieldtable { - width: 100%; - margin-bottom: 10px; - border: 1px solid #B9B9B9; - border-spacing: 0px; - -moz-border-radius: 4px; - -webkit-border-radius: 4px; - border-radius: 4px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; - -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); - box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); -} - -.fieldtable td, .fieldtable th { - padding: 3px 7px 2px; -} - -.fieldtable td.fieldtype, .fieldtable td.fieldname { - white-space: nowrap; - border-right: 1px solid #B9B9B9; - border-bottom: 1px solid #B9B9B9; - vertical-align: top; -} - -.fieldtable td.fielddoc { - border-bottom: 1px solid #B9B9B9; - width: 100%; -} - -.fieldtable tr:last-child td { - border-bottom: none; -} - -.fieldtable th { - background-image:url('nav_f.png'); - background-repeat:repeat-x; - background-color: #E8E8E8; - font-size: 90%; - color: #323232; - padding-bottom: 4px; - padding-top: 5px; - text-align:left; - -moz-border-radius-topleft: 4px; - -moz-border-radius-topright: 4px; - -webkit-border-top-left-radius: 4px; - -webkit-border-top-right-radius: 4px; - border-top-left-radius: 4px; - border-top-right-radius: 4px; - border-bottom: 1px solid #B9B9B9; -} - - -.tabsearch { - top: 0px; - left: 10px; - height: 36px; - background-image: url('tab_b.png'); - z-index: 101; - overflow: hidden; - font-size: 13px; -} - -.navpath ul -{ - font-size: 11px; - background-image:url('tab_b.png'); - background-repeat:repeat-x; - height:30px; - line-height:30px; - color:#A2A2A2; - border:solid 1px #CECECE; - overflow:hidden; - margin:0px; - padding:0px; -} - -.navpath li -{ - list-style-type:none; - float:left; - padding-left:10px; - padding-right:15px; - background-image:url('bc_s.png'); - background-repeat:no-repeat; - background-position:right; - color:#4D4D4D; -} - -.navpath li.navelem a -{ - height:32px; - display:block; - text-decoration: none; - outline: none; -} - -.navpath li.navelem a:hover -{ - color:#888888; -} - -.navpath li.footer -{ - list-style-type:none; - float:right; - padding-left:10px; - padding-right:15px; - background-image:none; - background-repeat:no-repeat; - background-position:right; - color:#4D4D4D; - font-size: 8pt; -} - - -div.summary -{ - float: right; - font-size: 8pt; - padding-right: 5px; - width: 50%; - text-align: right; -} - -div.summary a -{ - white-space: nowrap; -} - -div.ingroups -{ - font-size: 8pt; - width: 50%; - text-align: left; -} - -div.ingroups a -{ - white-space: nowrap; -} - -div.header -{ - background-image:url('nav_h.png'); - background-repeat:repeat-x; - background-color: #FAFAFA; - margin: 0px; - border-bottom: 1px solid #D0D0D0; -} - -div.headertitle -{ - padding: 5px 5px 5px 7px; -} - -dl -{ - padding: 0 0 0 10px; -} - -/* dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug */ -dl.section -{ - margin-left: 0px; - padding-left: 0px; -} - -dl.note -{ - margin-left:-7px; - padding-left: 3px; - border-left:4px solid; - border-color: #D0C000; -} - -dl.warning, dl.attention -{ - margin-left:-7px; - padding-left: 3px; - border-left:4px solid; - border-color: #FF0000; -} - -dl.pre, dl.post, dl.invariant -{ - margin-left:-7px; - padding-left: 3px; - border-left:4px solid; - border-color: #00D000; -} - -dl.deprecated -{ - margin-left:-7px; - padding-left: 3px; - border-left:4px solid; - border-color: #505050; -} - -dl.todo -{ - margin-left:-7px; - padding-left: 3px; - border-left:4px solid; - border-color: #00C0E0; -} - -dl.test -{ - margin-left:-7px; - padding-left: 3px; - border-left:4px solid; - border-color: #3030E0; -} - -dl.bug -{ - margin-left:-7px; - padding-left: 3px; - border-left:4px solid; - border-color: #C08050; -} - -dl.section dd { - margin-bottom: 6px; -} - - -#projectlogo -{ - text-align: center; - vertical-align: bottom; - border-collapse: separate; -} - -#projectlogo img -{ - border: 0px none; -} - -#projectname -{ - font: 300% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 2px 0px; -} - -#projectbrief -{ - font: 120% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#projectnumber -{ - font: 50% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#titlearea -{ - padding: 0px; - margin: 0px; - width: 100%; - border-bottom: 1px solid #787878; -} - -.image -{ - text-align: center; -} - -.dotgraph -{ - text-align: center; -} - -.mscgraph -{ - text-align: center; -} - -.caption -{ - font-weight: bold; -} - -div.zoom -{ - border: 1px solid #A6A6A6; -} - -dl.citelist { - margin-bottom:50px; -} - -dl.citelist dt { - color:#484848; - float:left; - font-weight:bold; - margin-right:10px; - padding:5px; -} - -dl.citelist dd { - margin:2px 0; - padding:5px 0; -} - -div.toc { - padding: 14px 25px; - background-color: #F6F6F6; - border: 1px solid #DFDFDF; - border-radius: 7px 7px 7px 7px; - float: right; - height: auto; - margin: 0 20px 10px 10px; - width: 200px; -} - -div.toc li { - background: url("bdwn.png") no-repeat scroll 0 5px transparent; - font: 10px/1.2 Verdana,DejaVu Sans,Geneva,sans-serif; - margin-top: 5px; - padding-left: 10px; - padding-top: 2px; -} - -div.toc h3 { - font: bold 12px/1.2 Arial,FreeSans,sans-serif; - color: #686868; - border-bottom: 0 none; - margin: 0; -} - -div.toc ul { - list-style: none outside none; - border: medium none; - padding: 0px; -} - -div.toc li.level1 { - margin-left: 0px; -} - -div.toc li.level2 { - margin-left: 15px; -} - -div.toc li.level3 { - margin-left: 30px; -} - -div.toc li.level4 { - margin-left: 45px; -} - -.inherit_header { - font-weight: bold; - color: gray; - cursor: pointer; - -webkit-touch-callout: none; - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} - -.inherit_header td { - padding: 6px 0px 2px 5px; -} - -.inherit { - display: none; -} - -tr.heading h2 { - margin-top: 12px; - margin-bottom: 4px; -} - -@media print -{ - #top { display: none; } - #side-nav { display: none; } - #nav-path { display: none; } - body { overflow:visible; } - h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } - .summary { display: none; } - .memitem { page-break-inside: avoid; } - #doc-content - { - margin-left:0 !important; - height:auto !important; - width:auto !important; - overflow:inherit; - display:inline; - } -} - diff -Naur ns-3.19/doc/ns3_html_theme/static/ns3_stylesheet.css ns-3.20/doc/ns3_html_theme/static/ns3_stylesheet.css --- ns-3.19/doc/ns3_html_theme/static/ns3_stylesheet.css 2014-06-17 10:34:00.321637565 -0700 +++ ns-3.20/doc/ns3_html_theme/static/ns3_stylesheet.css 2014-06-17 10:33:13.669997690 -0700 @@ -190,7 +190,7 @@ #ns3-menu .menu div { background: #94A901; - background-size: 100%; 100% + background-size: 100%; color:#ffffff; position: absolute; visibility: hidden; diff -Naur ns-3.19/doc/release_steps.txt ns-3.20/doc/release_steps.txt --- ns-3.19/doc/release_steps.txt 2014-06-17 10:34:00.323637549 -0700 +++ ns-3.20/doc/release_steps.txt 2014-06-17 10:33:13.671997675 -0700 @@ -144,6 +144,9 @@ 2. Check if these new files are available on the website +3. In ns-3-dev, edit the tutorial "Getting Started" page to + update the release version numbers. + preparing the Wordpress-based main website ------------------------------------------ diff -Naur ns-3.19/doc/tutorial/source/conf.py ns-3.20/doc/tutorial/source/conf.py --- ns-3.19/doc/tutorial/source/conf.py 2014-06-17 10:34:00.344637387 -0700 +++ ns-3.20/doc/tutorial/source/conf.py 2014-06-17 10:33:13.691997521 -0700 @@ -41,16 +41,16 @@ # General information about the project. project = u'ns-3' -copyright = u'2008-13, ns-3 project' +copyright = u'2010, ns-3 project' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. # # The short X.Y version. -version = 'ns-3.19' +version = 'ns-3.20' # The full version, including alpha/beta/rc tags. -release = 'ns-3.19' +release = 'ns-3.20' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff -Naur ns-3.19/doc/tutorial/source/getting-started.rst ns-3.20/doc/tutorial/source/getting-started.rst --- ns-3.19/doc/tutorial/source/getting-started.rst 2014-06-17 10:34:00.345637379 -0700 +++ ns-3.20/doc/tutorial/source/getting-started.rst 2014-06-17 10:33:13.693997505 -0700 @@ -33,8 +33,8 @@ copies of |ns3|. We'll walk through both examples since the tools involved are slightly different. -Downloading ns-3 -**************** +Downloading |ns3| +***************** The |ns3| system as a whole is a fairly complex system and has a number of dependencies on other components. Along with the systems you will @@ -72,8 +72,8 @@ downloading and building of various subsystems of |ns3| for you. We recommend that you begin your |ns3| work in this environment. -Downloading ns-3 Using a Tarball -++++++++++++++++++++++++++++++++ +Downloading |ns3| Using a Tarball ++++++++++++++++++++++++++++++++++ A tarball is a particular format of software archive where multiple files are bundled together and the archive possibly compressed. @@ -85,27 +85,24 @@ directory called ``workspace``. If you adopt the ``workspace`` directory approach, you can get a copy of a release by typing the following into your Linux shell -(substitute the appropriate version numbers, of course): - -:: +(substitute the appropriate version numbers, of course):: $ cd $ mkdir workspace $ cd workspace - $ wget http://www.nsnam.org/releases/ns-allinone-3.17.tar.bz2 - $ tar xjf ns-allinone-3.17.tar.bz2 + $ wget http://www.nsnam.org/releases/ns-allinone-3.20.tar.bz2 + $ tar xjf ns-allinone-3.20.tar.bz2 -If you change into the directory ``ns-allinone-3.17`` you should see a -number of files: +If you change into the directory ``ns-allinone-3.20`` you should see a +number of files:: -:: - - bake constants.py ns-3.17 README + $ ls + bake constants.py ns-3.20 README build.py netanim-3.103 pybindgen-0.16.0.825 util.py You are now ready to build the |ns3| distribution. -Downloading ns-3 Using Bake +Downloading |ns3| Using Bake ++++++++++++++++++++++++++++ Bake is a tool for distributed integration and building, @@ -119,9 +116,7 @@ Any directory name will do, but we'll assume that ``workspace`` is used herein (note: ``repos`` may also be used in some documentation as an example directory name). You can get a copy of ``bake`` by typing the -following into your Linux shell (assuming you have installed Mercurial): - -:: +following into your Linux shell (assuming you have installed Mercurial):: $ cd $ mkdir workspace @@ -133,6 +128,7 @@ :: + ... destination directory: bake requesting all changes adding changesets @@ -143,10 +139,9 @@ 45 files updated, 0 files merged, 0 files removed, 0 files unresolved After the clone command completes, you should have a directory called -``bake``, the contents of which should look something like the following: - -:: +``bake``, the contents of which should look something like the following:: + $ ls bake bakeconf.xml doc generate-binary.py TODO bake.py examples test @@ -157,10 +152,10 @@ There are a few configuration targets available: -1. ``ns-3.17``: the module corresponding to the release; it will download +1. ``ns-3.20``: the module corresponding to the release; it will download components similar to the release tarball. 2. ``ns-3-dev``: a similar module but using the development code tree -3. ``ns-allinone-3.17``: the module that includes other optional features +3. ``ns-allinone-3.20``: the module that includes other optional features such as click routing, openflow for |ns3|, and the Network Simulation Cradle 4. ``ns-3-allinone``: similar to the released version of the allinone @@ -178,7 +173,7 @@ `"ns-3 Releases" `_ web page and clicking on the latest release link. We'll proceed in -this tutorial example with ``ns-3.17``. +this tutorial example with ``ns-3.20``. We are now going to use the bake tool to pull down the various pieces of |ns3| you will be using. First, we'll say a word about running bake. @@ -187,9 +182,7 @@ and installing libraries into a build directory. bake can be run by referencing the binary, but if one chooses to run bake from outside of the directory it was downloaded into, it is advisable -to put bake into your path, such as follows (Linux bash shell example): - -:: +to put bake into your path, such as follows (Linux bash shell example):: $ export BAKE_HOME=`pwd`/bake $ export PATH=$PATH:$BAKE_HOME @@ -199,16 +192,12 @@ complete this tutorial, so we'll call bake directly by specifying the path to it in our shell commands. -Step into the workspace directory and type the following into your shell: - -:: +Step into the workspace directory and type the following into your shell:: - $ ./bake.py configure -e ns-3.17 + $ ./bake.py configure -e ns-3.20 Next, we'l ask bake to check whether we have enough tools to download -various components. Type: - -:: +various components. Type:: $ ./bake.py check @@ -240,15 +229,11 @@ are our principal concerns at this point, since they allow us to fetch the code. Please install missing tools at this stage if you are able to. -Next, try to download the software: +Next, try to download the software:: -:: + $ ./bake.py download - ./bake.py download - -should yield something like: - -:: +should yield something like:: >> Searching for system dependency pygoocanvas - OK >> Searching for system dependency python-dev - OK @@ -257,22 +242,21 @@ >> Searching for system dependency g++ - OK >> Searching for system dependency qt4 - OK >> Downloading netanim-3.103 - OK - >> Downloading ns-3.17 - OK + >> Downloading ns-3.20 - OK The above suggests that three sources have been downloaded. Check the -``source`` directory now and type ``ls``; one should see: +``source`` directory now and type ``ls``; one should see:: -:: - - netanim-3.103 ns-3.17 pybindgen-0.16.0.825 + $ ls + netanim-3.103 ns-3.20 pybindgen-0.16.0.825 You are now ready to build the |ns3| distribution. -Building ns-3 -************* +Building |ns3| +************** -Building with build.py -++++++++++++++++++++++ +Building with ``build.py`` +++++++++++++++++++++++++++ When working from a released tarball, the first time you build the |ns3| project you can build using a convenience program found in the ``allinone`` directory. This program is called ``build.py``. This @@ -283,10 +267,8 @@ If you downloaded using a tarball you should have a directory called something like -``ns-allinone-3.17`` under your ``~/workspace`` directory. -Type the following: - -:: +``ns-allinone-3.20`` under your ``~/workspace`` directory. +Type the following:: $ ./build.py --enable-examples --enable-tests @@ -299,11 +281,9 @@ You will see lots of typical compiler output messages displayed as the build script builds the various pieces you downloaded. Eventually you should see the -following magic words: - -:: +following magic words:: - Waf: Leaving directory `/path/to/workspace/ns-allinone-3.17/ns-3.17/build' + Waf: Leaving directory `/path/to/workspace/ns-allinone-3.20/ns-3.20/build' 'build' finished successfully (6m25.032s) Modules built: @@ -325,17 +305,15 @@ brite click openflow visualizer - Leaving directory `./ns-3.17' - -Regarding the portion about modules not built: + Leaving directory `./ns-3.20' -:: +Regarding the portion about modules not built:: Modules not built (see ns-3 tutorial for explanation): brite click openflow visualizer -This just means that some ns-3 modules that have dependencies on +This just means that some |ns3| modules that have dependencies on outside libraries may not have been built, or that the configuration specifically asked not to build them. It does not mean that the simulator did not build successfully or that it will provide wrong @@ -351,20 +329,16 @@ $ ./bake.py build -and you should see something like: - -:: +and you should see something like:: >> Building pybindgen-0.16.0.825 - OK >> Building netanim-3.103 - OK - >> Building ns-3.17 - OK + >> Building ns-3.20 - OK *Hint: you can also perform both steps, download and build by calling 'bake.py deploy'.* If there happens to be a failure, please have a look at what the following -command tells you; it may give a hint as to a missing dependency: - -:: +command tells you; it may give a hint as to a missing dependency:: $ ./bake.py show @@ -390,83 +364,96 @@ your project to build the debug version. Let's tell the project to make an optimized build. To explain to Waf that it should do optimized builds that include the examples and tests, you will need to execute the -following commands, - -:: +following commands:: $ ./waf clean - $ ./waf -d optimized --enable-examples --enable-tests configure + $ ./waf --build-profile=optimized --enable-examples --enable-tests configure This runs Waf out of the local directory (which is provided as a convenience for you). The first command to clean out the previous build is not -typically strictly necessary but is good practice; it will remove the +typically strictly necessary but is good practice (but see `Build Profiles`_, +below); it will remove the previously built libraries and object files found in directory ``build/``. When the project is reconfigured and the build system checks for various dependencies, you should see -output that looks similar to the following, - -:: +output that looks similar to the following:: - Checking for program g++ : ok /usr/bin/g++ - Checking for program cpp : ok /usr/bin/cpp - Checking for program ar : ok /usr/bin/ar - Checking for program ranlib : ok /usr/bin/ranlib - Checking for g++ : ok - Checking for program pkg-config : ok /usr/bin/pkg-config - Checking for -Wno-error=deprecated-declarations support : yes - Checking for -Wl,--soname=foo support : yes - Checking for header stdlib.h : ok - Checking for header signal.h : ok - Checking for header pthread.h : ok - Checking for high precision time implementation : 128-bit integer - Checking for header stdint.h : ok - Checking for header inttypes.h : ok - Checking for header sys/inttypes.h : not found - Checking for library rt : ok - Checking for header netpacket/packet.h : ok - Checking for pkg-config flags for GSL : ok - Checking for header linux/if_tun.h : ok - Checking for pkg-config flags for GTK_CONFIG_STORE : ok - Checking for pkg-config flags for LIBXML2 : ok - Checking for library sqlite3 : ok - Checking for NSC location : ok ../nsc (guessed) - Checking for library dl : ok - Checking for NSC supported architecture x86_64 : ok - Checking for program python : ok /usr/bin/python - Checking for Python version >= 2.3 : ok 2.5.2 - Checking for library python2.5 : ok - Checking for program python2.5-config : ok /usr/bin/python2.5-config - Checking for header Python.h : ok - Checking for -fvisibility=hidden support : yes - Checking for pybindgen location : ok ../pybindgen (guessed) - Checking for Python module pybindgen : ok - Checking for pybindgen version : ok 0.10.0.640 - Checking for Python module pygccxml : ok - Checking for pygccxml version : ok 0.9.5 - Checking for program gccxml : ok /usr/local/bin/gccxml - Checking for gccxml version : ok 0.9.0 - Checking for program sudo : ok /usr/bin/sudo - Checking for program hg : ok /usr/bin/hg - Checking for program valgrind : ok /usr/bin/valgrind + Setting top to : . + Setting out to : build + Checking for 'gcc' (c compiler) : /usr/bin/gcc + Checking for cc version : 4.2.1 + Checking for 'g++' (c++ compiler) : /usr/bin/g++ + Checking boost includes : 1_46_1 + Checking boost libs : ok + Checking for boost linkage : ok + Checking for click location : not found + Checking for program pkg-config : /sw/bin/pkg-config + Checking for 'gtk+-2.0' >= 2.12 : yes + Checking for 'libxml-2.0' >= 2.7 : yes + Checking for type uint128_t : not found + Checking for type __uint128_t : yes + Checking high precision implementation : 128-bit integer (default) + Checking for header stdint.h : yes + Checking for header inttypes.h : yes + Checking for header sys/inttypes.h : not found + Checking for header sys/types.h : yes + Checking for header sys/stat.h : yes + Checking for header dirent.h : yes + Checking for header stdlib.h : yes + Checking for header signal.h : yes + Checking for header pthread.h : yes + Checking for header stdint.h : yes + Checking for header inttypes.h : yes + Checking for header sys/inttypes.h : not found + Checking for library rt : not found + Checking for header netpacket/packet.h : not found + Checking for header sys/ioctl.h : yes + Checking for header net/if.h : not found + Checking for header net/ethernet.h : yes + Checking for header linux/if_tun.h : not found + Checking for header netpacket/packet.h : not found + Checking for NSC location : not found + Checking for 'mpic++' : yes + Checking for 'sqlite3' : yes + Checking for header linux/if_tun.h : not found + Checking for program sudo : /usr/bin/sudo + Checking for program valgrind : /sw/bin/valgrind + Checking for 'gsl' : yes + Checking for compilation flag -Wno-error=deprecated-d... support : ok + Checking for compilation flag -Wno-error=deprecated-d... support : ok + Checking for compilation flag -fstrict-aliasing... support : ok + Checking for compilation flag -fstrict-aliasing... support : ok + Checking for compilation flag -Wstrict-aliasing... support : ok + Checking for compilation flag -Wstrict-aliasing... support : ok + Checking for program doxygen : /usr/local/bin/doxygen ---- Summary of optional NS-3 features: - Threading Primitives : enabled - Real Time Simulator : enabled - Emulated Net Device : enabled - GNU Scientific Library (GSL) : enabled - Tap Bridge : enabled + Build profile : debug + Build directory : build + Python Bindings : enabled + BRITE Integration : not enabled (BRITE not enabled (see option --with-brite)) + NS-3 Click Integration : not enabled (nsclick not enabled (see option --with-nsclick)) GtkConfigStore : enabled XmlIo : enabled + Threading Primitives : enabled + Real Time Simulator : enabled (librt is not available) + Emulated Net Device : enabled ( include not detected) + File descriptor NetDevice : enabled + Tap FdNetDevice : not enabled (needs linux/if_tun.h) + Emulation FdNetDevice : not enabled (needs netpacket/packet.h) + PlanetLab FdNetDevice : not enabled (PlanetLab operating system not detected (see option --force-planetlab)) + Network Simulation Cradle : not enabled (NSC not found (see option --with-nsc)) + MPI Support : enabled + NS-3 OpenFlow Integration : not enabled (Required boost libraries not found, missing: system, signals, filesystem) SQlite stats data output : enabled - Network Simulation Cradle : enabled - Python Bindings : enabled - Python API Scanning Support : enabled + Tap Bridge : not enabled ( include not detected) + PyViz visualizer : enabled Use sudo to set suid bit : not enabled (option --enable-sudo not selected) Build tests : enabled Build examples : enabled - Static build : not enabled (option --enable-static not selected) - 'configure' finished successfully (2.870s) + GNU Scientific Library (GSL) : enabled + 'configure' finished successfully (1.944s) -Note the last part of the above output. Some ns-3 options are not enabled by +Note the last part of the above output. Some |ns3| options are not enabled by default or require support from the underlying system to work properly. For instance, to enable XmlTo, the library libxml-2.0 must be found on the system. If this library were not found, the corresponding |ns3| feature @@ -479,7 +466,7 @@ :: $ ./waf clean - $ ./waf -d debug --enable-examples --enable-tests configure + $ ./waf --build-profile=debug --enable-examples --enable-tests configure The build system is now configured and you can build the debug versions of the |ns3| programs by simply typing @@ -492,72 +479,146 @@ but now you know how to change the configuration and build optimized code. Here are a few more introductory tips about Waf. -Some waf commands are meaningful during the build phase and some commands are valid -in the configuration phase. For example, if you wanted to use the emulation + +Configure vs. Build +=================== + +Some Waf commands are only meaningful during the configure phase and some commands are valid +in the build phase. For example, if you wanted to use the emulation features of |ns3|, you might want to enable setting the suid bit using sudo as described above. This turns out to be a configuration-time command, and so -you could reconfigure using the following command that also includes the examples and tests +you could reconfigure using the following command that also includes the examples and tests. :: - $ ./waf configure -d debug --enable-sudo --enable-examples --enable-tests + $ ./waf configure --enable-sudo --enable-examples --enable-tests -If you do this, waf will have run sudo to change the socket creator programs of the -emulation code to run as root. There are many other configure- and build-time options -available in waf. To explore these options, type: +If you do this, Waf will have run sudo to change the socket creator programs of the +emulation code to run as root. -:: +There are many other configure- and build-time options +available in Waf. To explore these options, type:: $ ./waf --help We'll use some of the testing-related commands in the next section. -Finally, as an aside, it is possible to specify that waf builds the -project in -a directory different than the default ``build/`` directory by passing -the ``-o`` option to configure; e.g. +Build Profiles +============== -:: +We already saw how you can configure Waf for ``debug`` or ``optimized`` builds:: - $ ./waf configure -d debug -o build/debug --enable-examples --enable-tests + $ ./waf --build-profile=debug -This allows users to work with multiple builds rather than always -overwriting the last build. +There is also an intermediate build profile, ``release``. ``-d`` is a +synonym for ``--build-profile``. -In the examples above, waf uses GCC C++ compiler, command ``g++``, for -building ns-3. However, it's possible to change C++ compiler used by waf. -Say one wants to use Clang C++ compiler, command ``clang++``; it's done by +By default Waf puts the build artifacts in the ``build`` directory. +You can specify a different output directory with the ``--out`` +option, e.g. :: - $ CXX="clang++" ./waf configure + $ ./waf configure --out=foo + +Combining this with build profiles lets you switch between the different +compile options in a clean way:: + + $ ./waf configure --build-profile=debug --out=build/debug $ ./waf build + ... + $ ./waf configure --build-profile=optimized --out=build/optimized + $ ./waf build + ... -One can also set up waf to do distributed compilation with ``distcc`` in -a similar way: +This allows you to work with multiple builds rather than always +overwriting the last build. When you switch, Waf will only compile +what it has to, instead of recompiling everything. + +When you do switch build profiles like this, you have to be careful +to give the same configuration parameters each time. It may be convenient +to define some environment variables to help you avoid mistakes:: + + $ export NS3CONFIG="--enable-examples --enable-tests" + $ export NS3DEBUG="--build-profile=debug --out=build/debug" + $ export NS3OPT=="--build-profile=optimized --out=build/optimized" + + $ ./waf configure $NS3CONFIG $NS3DEBUG + $ ./waf build + ... + $ ./waf configure $NS3CONFIG $NS3OPT + $ ./waf build + +Compilers +========= + +In the examples above, Waf uses the GCC C++ compiler, ``g++``, for +building |ns3|. However, it's possible to change the C++ compiler used by Waf +by defining the ``CXX`` environment variable. +For example, to use the Clang C++ compiler, ``clang++``, :: + $ CXX="clang++" ./waf configure + $ ./waf build + +One can also set up Waf to do distributed compilation with ``distcc`` in +a similar way:: + $ CXX="distcc g++" ./waf configure $ ./waf build -More info on distcc and distributed compilation can be found on it's +More info on ``distcc`` and distributed compilation can be found on it's `project page `_ under Documentation section. -Testing ns-3 -************ +One Waf +======= -You can run the unit tests of the |ns3| distribution by running the -"./test.py -c core" script, +There is only one Waf script, at the top level of the |ns3| source tree. +As you work, you may find yourself spending a lot of time in ``scratch/``, +or deep in ``src/...``, and needing to invoke Waf. You could just +remember where you are, and invoke Waf like this:: -:: + $ ../../../waf ... + +but that get's tedious, and error prone, and there are better solutions. + +If you have the full |ns3| repository this little gem is a start:: + + $ cd $(hg root) && ./waf ... + +Even better is to define this as a shell function:: + + $ function waff { cd $(hg root) && ./waf $* ; } + + $ waff build + +If you only have the tarball, an environment variable can help:: + + $ export NS3DIR="$PWD" + $ function waff { cd $NS3DIR && ./waf $* ; } + + $ cd scratch + $ waff build + +It might be tempting in a module directory to add a trivial ``waf`` +script along the lines of ``exec ../../waf``. Please don't. It's +confusing to new-comers, and when done poorly it leads to subtle build +errors. The solutions above are the way to go. + + +Testing |ns3| +************* + +You can run the unit tests of the |ns3| distribution by running the +``./test.py -c core`` script:: $ ./test.py -c core -These tests are run in parallel by waf. You should eventually -see a report saying that, +These tests are run in parallel by Waf. You should eventually +see a report saying that :: @@ -565,9 +626,8 @@ This is the important message. -You will also see output from the test runner and the output will actually look something like, - -:: +You will also see the summary output from Waf and the test runner +executing each test, which will actually look something like:: Waf: Entering directory `/path/to/workspace/ns-3-allinone/ns-3-dev/build' Waf: Leaving directory `/path/to/workspace/ns-3-allinone/ns-3-dev/build' @@ -590,34 +650,26 @@ PASS: TestSuite ns3-wifi-interference PASS: TestSuite histogram - PASS: TestSuite sample - PASS: TestSuite ipv4-address-helper - PASS: TestSuite devices-wifi - PASS: TestSuite propagation-loss-model ... - PASS: TestSuite attributes - PASS: TestSuite config - PASS: TestSuite global-value - PASS: TestSuite command-line - PASS: TestSuite basic-random-number PASS: TestSuite object PASS: TestSuite random-number-generators 92 of 92 tests passed (92 passed, 0 failed, 0 crashed, 0 valgrind errors) This command is typically run by users to quickly verify that an -|ns3| distribution has built correctly. +|ns3| distribution has built correctly. (Note the order of the ``PASS: ...`` +lines can vary, which is okay. What's important is that the summary line at +the end report that all tests passed; none failed or crashed.) Running a Script **************** + We typically run scripts under the control of Waf. This allows the build system to ensure that the shared library paths are set correctly and that the libraries are available at run time. To run a program, simply use the ``--run`` option in Waf. Let's run the |ns3| equivalent of the -ubiquitous hello world program by typing the following: - -:: +ubiquitous hello world program by typing the following:: $ ./waf --run hello-simulator @@ -629,28 +681,26 @@ Hello Simulator -*Congratulations. You are now an ns-3 user.* +Congratulations! You are now an ns-3 user! -*What do I do if I don't see the output?* +**What do I do if I don't see the output?** -If you see ``waf`` messages indicating that the build was +If you see Waf messages indicating that the build was completed successfully, but do not see the "Hello Simulator" output, -chances are that you have switched your build mode to "optimized" in -the "Building with Waf" section, but have missed the change back to -"debug" mode. All of the console output used in this tutorial uses a +chances are that you have switched your build mode to ``optimized`` in +the `Building with Waf`_ section, but have missed the change back to +``debug`` mode. All of the console output used in this tutorial uses a special |ns3| logging component that is useful for printing user messages to the console. Output from this component is automatically disabled when you compile optimized code -- it is "optimized out." If you don't see the "Hello Simulator" output, -type the following, +type the following:: -:: + $ ./waf configure --build-profile=debug --enable-examples --enable-tests - $ ./waf configure -d debug --enable-examples --enable-tests - -to tell ``waf`` to build the debug versions of the |ns3| +to tell Waf to build the debug versions of the |ns3| programs that includes the examples and tests. You must still build -the actual debug version of the code by typing, +the actual debug version of the code by typing :: @@ -659,7 +709,80 @@ Now, if you run the ``hello-simulator`` program, you should see the expected output. -If you want to run programs under another tool such as gdb or valgrind, -see this `wiki entry -`_. +Program Arguments ++++++++++++++++++ + +To feed command line arguments to an |ns3| program use this pattern:: + + $ ./waf --run --command-template="%s " + +Substitute your program name for ````, and the arguments +for ````. The ``--command-template`` argument to Waf is +basically a recipe for constructing the actual command line Waf should use +to execute the program. Waf checks that the build is complete, +sets the shared library paths, then invokes the executable +using the provided command line template, +inserting the program name for the ``%s`` placeholder. +(I admit this is a bit awkward, but that's the way it is. Patches welcome!) + +Another particularly useful example is to run the ``mytest`` test suite +by itself. Above, we used the ``./test.py`` script to run a whole slew of +tests in parallel, by repeatedly invoking the real testing program, +``test-runner``. To invoke ``test-runner`` directly for a single test:: + + $ ./waf --run test-runner --command-template="% --suite=mytest --verbose" + +This passes the arguments to the ``test-runner`` program. To print the +available ``test-runner`` options:: + + $ ./waf --run test-runner --command-template="% --help" + +Debugging ++++++++++ + +To run |ns3| programs under the control of another utility, such as +a debugger (*e.g.* ``gdb``) or memory checker (*e.g.* ``valgrind``), +you use a similar ``--command-template="..."`` form. + +For example, to run your |ns3| program ``mysim`` with the arguments +```` under the ``gdb`` debugger:: + + $ ./waf --run=hello-simulator --command-template="gdb %s --args " + +Notice that the |ns3| program name goes with the ``--run`` argument, +and the control utility (here ``gdb``) is the first token +in the ``--commmand-template`` argument. The ``--args`` tells ``gdb`` +that the remainder of the command line belongs to the "inferior" program. +(Some ``gdb``'s don't understand the ``--args`` feature. In this case, +omit the program arguments from the ``--command-template``, +and use the ``gdb`` command ``set args``.) + +We can combine this recipe and the previous one to run a test under the +debugger:: + + $ ./waf --run test-runner --command-template="gdb %s --args --suite=mytest --verbose" + +Working Directory ++++++++++++++++++ +Waf needs to run from it's location at the top of the |ns3| tree. +This becomes the working directory where output files will be written. +But what if you want to keep those ouf to the |ns3| source tree? Use +the ``--cwd`` argument:: + + $ ./waf --cwd=... + +It may be more convenient to start with your working directory where +you want the output files, in which case a little indirection can help:: + + $ function waff { + CWD="$PWD" + cd $NS3DIR >/dev/null + ./waf --cwd="$CWD" $* + cd - >/dev/null + } + +This embellishment of the previous version saves the current working directory, +``cd``'s to the Waf directory, then instructs Waf to change the working +directory *back* to the saved current working directory before running the +program. diff -Naur ns-3.19/doc/tutorial-pt-br/source/conf.py ns-3.20/doc/tutorial-pt-br/source/conf.py --- ns-3.19/doc/tutorial-pt-br/source/conf.py 2014-06-17 10:34:00.331637488 -0700 +++ ns-3.20/doc/tutorial-pt-br/source/conf.py 2014-06-17 10:33:13.678997621 -0700 @@ -42,7 +42,7 @@ # General information about the project. project = u'ns-3' -copyright = u'2008-13, ns-3 project' +copyright = u'2008-11, ns-3 project' # The version info for the project you're documenting, acts as replacement for @@ -50,9 +50,9 @@ # built documents. # # The short X.Y version. -version = 'ns-3.19' +version = 'ns-3.20' # The full version, including alpha/beta/rc tags. -release = 'ns-3.19' +release = 'ns-3.20' # The language for content autogenerated by . Refer to babel documentation # for a list of supported languages. diff -Naur ns-3.19/examples/energy/waf ns-3.20/examples/energy/waf --- ns-3.19/examples/energy/waf 2014-06-17 10:34:00.351637333 -0700 +++ ns-3.20/examples/energy/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/error-model/waf ns-3.20/examples/error-model/waf --- ns-3.19/examples/error-model/waf 2014-06-17 10:34:00.352637325 -0700 +++ ns-3.20/examples/error-model/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/ipv6/waf ns-3.20/examples/ipv6/waf --- ns-3.19/examples/ipv6/waf 2014-06-17 10:34:00.356637295 -0700 +++ ns-3.20/examples/ipv6/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/ipv6/wscript ns-3.20/examples/ipv6/wscript --- ns-3.19/examples/ipv6/wscript 2014-06-17 10:34:00.357637287 -0700 +++ ns-3.20/examples/ipv6/wscript 2014-06-17 10:33:13.704997420 -0700 @@ -25,3 +25,6 @@ obj = bld.create_ns3_program('loose-routing-ipv6', ['csma', 'internet']) obj.source = 'loose-routing-ipv6.cc' + obj = bld.create_ns3_program('wsn-ping6', ['lr-wpan', 'internet', 'sixlowpan', 'mobility']) + obj.source = 'wsn-ping6.cc' + diff -Naur ns-3.19/examples/ipv6/wsn-ping6.cc ns-3.20/examples/ipv6/wsn-ping6.cc --- ns-3.19/examples/ipv6/wsn-ping6.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/examples/ipv6/wsn-ping6.cc 2014-06-17 10:33:13.704997420 -0700 @@ -0,0 +1,141 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze + * + * 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: Tommaso Pecorella + */ + +// Network topology +// +// n0 n1 +// | | +// ================= +// WSN (802.15.4) +// +// - ICMPv6 echo request flows from n0 to n1 and back with ICMPv6 echo reply +// - DropTail queues +// - Tracing of queues and packet receptions to file "wsn-ping6.tr" +// +// This example is based on the "ping6.cc" example. + +#include +#include "ns3/core-module.h" +#include "ns3/internet-module.h" +#include "ns3/sixlowpan-module.h" +#include "ns3/lr-wpan-module.h" +#include "ns3/applications-module.h" +#include "ns3/mobility-module.h" + +using namespace ns3; + +NS_LOG_COMPONENT_DEFINE ("Ping6WsnExample"); + +int main (int argc, char **argv) +{ + bool verbose = false; + + CommandLine cmd; + cmd.AddValue ("verbose", "turn on log components", verbose); + cmd.Parse (argc, argv); + + if (verbose) + { + LogComponentEnable ("Ping6WsnExample", LOG_LEVEL_INFO); + LogComponentEnable ("Ipv6EndPointDemux", LOG_LEVEL_ALL); + LogComponentEnable ("Ipv6L3Protocol", LOG_LEVEL_ALL); + LogComponentEnable ("Ipv6StaticRouting", LOG_LEVEL_ALL); + LogComponentEnable ("Ipv6ListRouting", LOG_LEVEL_ALL); + LogComponentEnable ("Ipv6Interface", LOG_LEVEL_ALL); + LogComponentEnable ("Icmpv6L4Protocol", LOG_LEVEL_ALL); + LogComponentEnable ("Ping6Application", LOG_LEVEL_ALL); + LogComponentEnable ("NdiscCache", LOG_LEVEL_ALL); + LogComponentEnable ("SixLowPanNetDevice", LOG_LEVEL_ALL); + } + + NS_LOG_INFO ("Create nodes."); + NodeContainer nodes; + nodes.Create (2); + + // Set seed for random numbers + SeedManager::SetSeed (167); + + // Install mobility + MobilityHelper mobility; + mobility.SetMobilityModel ("ns3::ConstantPositionMobilityModel"); + + Ptr nodesPositionAlloc = CreateObject (); + nodesPositionAlloc->Add (Vector (0.0, 0.0, 0.0)); + nodesPositionAlloc->Add (Vector (50.0, 0.0, 0.0)); + mobility.SetPositionAllocator (nodesPositionAlloc); + mobility.Install (nodes); + + NS_LOG_INFO ("Create channels."); + LrWpanHelper lrWpanHelper; + // Add and install the LrWpanNetDevice for each node + // lrWpanHelper.EnableLogComponents(); + NetDeviceContainer devContainer = lrWpanHelper.Install(nodes); + lrWpanHelper.AssociateToPan (devContainer, 10); + + std::cout << "Created " << devContainer.GetN() << " devices" << std::endl; + std::cout << "There are " << nodes.GetN() << " nodes" << std::endl; + + /* Install IPv4/IPv6 stack */ + NS_LOG_INFO ("Install Internet stack."); + InternetStackHelper internetv6; + internetv6.SetIpv4StackInstall (false); + internetv6.Install (nodes); + + // Install 6LowPan layer + NS_LOG_INFO ("Install 6LoWPAN."); + SixLowPanHelper sixlowpan; + NetDeviceContainer six1 = sixlowpan.Install (devContainer); + + NS_LOG_INFO ("Assign addresses."); + Ipv6AddressHelper ipv6; + ipv6.SetBase (Ipv6Address ("2001:1::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer i = ipv6.Assign (six1); + + NS_LOG_INFO ("Create Applications."); + + /* Create a Ping6 application to send ICMPv6 echo request from node zero to + * all-nodes (ff02::1). + */ + uint32_t packetSize = 10; + uint32_t maxPacketCount = 5; + Time interPacketInterval = Seconds (1.); + Ping6Helper ping6; + + ping6.SetLocal (i.GetAddress (0, 1)); + ping6.SetRemote (i.GetAddress (1, 1)); + // ping6.SetRemote (Ipv6Address::GetAllNodesMulticast ()); + + ping6.SetAttribute ("MaxPackets", UintegerValue (maxPacketCount)); + ping6.SetAttribute ("Interval", TimeValue (interPacketInterval)); + ping6.SetAttribute ("PacketSize", UintegerValue (packetSize)); + ApplicationContainer apps = ping6.Install (nodes.Get (0)); + apps.Start (Seconds (2.0)); + apps.Stop (Seconds (10.0)); + + AsciiTraceHelper ascii; + lrWpanHelper.EnableAsciiAll (ascii.CreateFileStream ("ping6wsn.tr")); + lrWpanHelper.EnablePcapAll (std::string ("ping6wsn"), true); + + NS_LOG_INFO ("Run Simulation."); + Simulator::Run (); + Simulator::Destroy (); + NS_LOG_INFO ("Done."); +} + diff -Naur ns-3.19/examples/naming/waf ns-3.20/examples/naming/waf --- ns-3.19/examples/naming/waf 2014-06-17 10:34:00.359637271 -0700 +++ ns-3.20/examples/naming/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/realtime/waf ns-3.20/examples/realtime/waf --- ns-3.19/examples/realtime/waf 2014-06-17 10:34:00.361637256 -0700 +++ ns-3.20/examples/realtime/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/routing/manet-routing-compare.cc ns-3.20/examples/routing/manet-routing-compare.cc --- ns-3.19/examples/routing/manet-routing-compare.cc 2014-06-17 10:34:00.378637125 -0700 +++ ns-3.20/examples/routing/manet-routing-compare.cc 2014-06-17 10:33:13.710997374 -0700 @@ -343,7 +343,7 @@ onoff1.SetAttribute ("OnTime", StringValue ("ns3::ConstantRandomVariable[Constant=1.0]")); onoff1.SetAttribute ("OffTime", StringValue ("ns3::ConstantRandomVariable[Constant=0.0]")); - for (int i = 0; i <= nSinks - 1; i++) + for (int i = 0; i < nSinks; i++) { Ptr sink = SetupPacketReceive (adhocInterfaces.GetAddress (i), adhocNodes.Get (i)); diff -Naur ns-3.19/examples/routing/ripng-simple-network.cc ns-3.20/examples/routing/ripng-simple-network.cc --- ns-3.19/examples/routing/ripng-simple-network.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/examples/routing/ripng-simple-network.cc 2014-06-17 10:33:13.711997366 -0700 @@ -0,0 +1,268 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze, Italy + * + * 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: Tommaso Pecorella + */ + +// Network topology +// +// SRC +// |<=== source network +// A-----B +// \ / \ all networks have cost 1, except +// \ / | for the direct link from C to D, which +// C / has cost 10 +// | / +// |/ +// D +// |<=== target network +// DST +// +// +// A, B, C and D are RIPng routers. +// A and D are configured with static addresses. +// SRC and DST will exchange packets. +// +// After about 3 seconds, the topology is built, and Echo Reply will be received. +// After 40 seconds, the link between B and D will break, causing a route failure. +// After 44 seconds from the failure, the routers will recovery from the failure. +// Split Horizoning should affect the recovery time, but it is not. See the manual +// for an explanation of this effect. +// +// If "showPings" is enabled, the user will see: +// 1) if the ping has been acknowledged +// 2) if a Destination Unreachable has been received by the sender +// 3) nothing, when the Echo Request has been received by the destination but +// the Echo Reply is unable to reach the sender. +// Examining the .pcap files with Wireshark can confirm this effect. + + +#include +#include "ns3/core-module.h" +#include "ns3/internet-module.h" +#include "ns3/csma-module.h" +#include "ns3/applications-module.h" +#include "ns3/ipv6-static-routing-helper.h" +#include "ns3/ipv6-routing-table-entry.h" + +using namespace ns3; + +NS_LOG_COMPONENT_DEFINE ("RipNgSimpleRouting"); + +void TearDownLink (Ptr nodeA, Ptr nodeB, uint32_t interfaceA, uint32_t interfaceB) +{ + nodeA->GetObject ()->SetDown (interfaceA); + nodeB->GetObject ()->SetDown (interfaceB); +} + +int main (int argc, char **argv) +{ + bool verbose = false; + bool printRoutingTables = false; + bool showPings = false; + std::string SplitHorizon ("PoisonReverse"); + + CommandLine cmd; + cmd.AddValue ("verbose", "turn on log components", verbose); + cmd.AddValue ("printRoutingTables", "Print routing tables at 30, 60 and 90 seconds", printRoutingTables); + cmd.AddValue ("showPings", "Show Ping6 reception", showPings); + cmd.AddValue ("splitHorizonStrategy", "Split Horizon strategy to use (NoSplitHorizon, SplitHorizon, PoisonReverse)", SplitHorizon); + cmd.Parse (argc, argv); + + if (verbose) + { + LogComponentEnable ("RipNgSimpleRouting", LOG_LEVEL_INFO); + LogComponentEnable ("RipNg", LOG_LEVEL_ALL); + LogComponentEnable ("Icmpv6L4Protocol", LOG_LEVEL_INFO); + LogComponentEnable ("Ipv6Interface", LOG_LEVEL_ALL); + LogComponentEnable ("Icmpv6L4Protocol", LOG_LEVEL_ALL); + LogComponentEnable ("NdiscCache", LOG_LEVEL_ALL); + LogComponentEnable ("Ping6Application", LOG_LEVEL_ALL); + } + + if (showPings) + { + LogComponentEnable ("Ping6Application", LOG_LEVEL_INFO); + } + + if (SplitHorizon == "NoSplitHorizon") + { + Config::SetDefault ("ns3::RipNg::SplitHorizon", EnumValue (RipNg::NO_SPLIT_HORIZON)); + } + else if (SplitHorizon == "SplitHorizon") + { + Config::SetDefault ("ns3::RipNg::SplitHorizon", EnumValue (RipNg::SPLIT_HORIZON)); + } + else + { + Config::SetDefault ("ns3::RipNg::SplitHorizon", EnumValue (RipNg::POISON_REVERSE)); + } + + NS_LOG_INFO ("Create nodes."); + Ptr src = CreateObject (); + Names::Add ("SrcNode", src); + Ptr dst = CreateObject (); + Names::Add ("DstNode", dst); + Ptr a = CreateObject (); + Names::Add ("RouterA", a); + Ptr b = CreateObject (); + Names::Add ("RouterB", b); + Ptr c = CreateObject (); + Names::Add ("RouterC", c); + Ptr d = CreateObject (); + Names::Add ("RouterD", d); + NodeContainer net1 (src, a); + NodeContainer net2 (a, b); + NodeContainer net3 (a, c); + NodeContainer net4 (b, c); + NodeContainer net5 (c, d); + NodeContainer net6 (b, d); + NodeContainer net7 (d, dst); + NodeContainer routers (a, b, c, d); + NodeContainer nodes (src, dst); + + + NS_LOG_INFO ("Create channels."); + CsmaHelper csma; + csma.SetChannelAttribute ("DataRate", DataRateValue (5000000)); + csma.SetChannelAttribute ("Delay", TimeValue (MilliSeconds (2))); + NetDeviceContainer ndc1 = csma.Install (net1); + NetDeviceContainer ndc2 = csma.Install (net2); + NetDeviceContainer ndc3 = csma.Install (net3); + NetDeviceContainer ndc4 = csma.Install (net4); + NetDeviceContainer ndc5 = csma.Install (net5); + NetDeviceContainer ndc6 = csma.Install (net6); + NetDeviceContainer ndc7 = csma.Install (net7); + + NS_LOG_INFO ("Create IPv6 and routing"); + RipNgHelper ripNgRouting; + + // Rule of thumb: + // Interfaces are added sequentially, starting from 0 + // However, interface 0 is always the loopback... + ripNgRouting.ExcludeInterface (a, 1); + ripNgRouting.ExcludeInterface (d, 3); + + ripNgRouting.SetInterfaceMetric (c, 3, 10); + ripNgRouting.SetInterfaceMetric (d, 1, 10); + + Ipv6ListRoutingHelper listRH; + listRH.Add (ripNgRouting, 0); + + InternetStackHelper internetv6; + internetv6.SetIpv4StackInstall (false); + internetv6.SetRoutingHelper (listRH); + internetv6.Install (routers); + + InternetStackHelper internetv6Nodes; + internetv6Nodes.SetIpv4StackInstall (false); + internetv6Nodes.Install (nodes); + + // Assign addresses. + // The source and destination networks have global addresses + // The "core" network just needs link-local addresses for routing. + // We assign global addresses to the routers as well to receive + // ICMPv6 errors. + NS_LOG_INFO ("Assign IPv6 Addresses."); + Ipv6AddressHelper ipv6; + + ipv6.SetBase (Ipv6Address ("2001:1::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic1 = ipv6.Assign (ndc1); + iic1.SetForwarding (1, true); + iic1.SetDefaultRouteInAllNodes (1); + + ipv6.SetBase (Ipv6Address ("2001:0:1::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic2 = ipv6.Assign (ndc2); + iic2.SetForwarding (0, true); + iic2.SetForwarding (1, true); + + ipv6.SetBase (Ipv6Address ("2001:0:2::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic3 = ipv6.Assign (ndc3); + iic3.SetForwarding (0, true); + iic3.SetForwarding (1, true); + + ipv6.SetBase (Ipv6Address ("2001:0:3::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic4 = ipv6.Assign (ndc4); + iic4.SetForwarding (0, true); + iic4.SetForwarding (1, true); + + ipv6.SetBase (Ipv6Address ("2001:0:4::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic5 = ipv6.Assign (ndc5); + iic5.SetForwarding (0, true); + iic5.SetForwarding (1, true); + + ipv6.SetBase (Ipv6Address ("2001:0:5::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic6 = ipv6.Assign (ndc6); + iic6.SetForwarding (0, true); + iic6.SetForwarding (1, true); + + ipv6.SetBase (Ipv6Address ("2001:2::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic7 = ipv6.Assign (ndc7); + iic7.SetForwarding (0, true); + iic7.SetDefaultRouteInAllNodes (0); + + if (printRoutingTables) + { + RipNgHelper routingHelper; + + Ptr routingStream = Create (&std::cout); + + routingHelper.PrintRoutingTableAt (Seconds (30.0), a, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (30.0), b, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (30.0), c, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (30.0), d, routingStream); + + routingHelper.PrintRoutingTableAt (Seconds (60.0), a, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (60.0), b, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (60.0), c, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (60.0), d, routingStream); + + routingHelper.PrintRoutingTableAt (Seconds (90.0), a, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (90.0), b, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (90.0), c, routingStream); + routingHelper.PrintRoutingTableAt (Seconds (90.0), d, routingStream); + } + + NS_LOG_INFO ("Create Applications."); + uint32_t packetSize = 1024; + uint32_t maxPacketCount = 100; + Time interPacketInterval = Seconds (1.0); + Ping6Helper ping6; + + ping6.SetLocal (iic1.GetAddress (0, 1)); + ping6.SetRemote (iic7.GetAddress (1, 1)); + ping6.SetAttribute ("MaxPackets", UintegerValue (maxPacketCount)); + ping6.SetAttribute ("Interval", TimeValue (interPacketInterval)); + ping6.SetAttribute ("PacketSize", UintegerValue (packetSize)); + ApplicationContainer apps = ping6.Install (src); + apps.Start (Seconds (1.0)); + apps.Stop (Seconds (110.0)); + + AsciiTraceHelper ascii; + csma.EnableAsciiAll (ascii.CreateFileStream ("ripng-simple-routing.tr")); + csma.EnablePcapAll ("ripng-simple-routing", true); + + Simulator::Schedule (Seconds (40), &TearDownLink, b, d, 3, 2); + + /* Now, do the actual simulation. */ + NS_LOG_INFO ("Run Simulation."); + Simulator::Stop (Seconds (120)); + Simulator::Run (); + Simulator::Destroy (); + NS_LOG_INFO ("Done."); +} + diff -Naur ns-3.19/examples/routing/simple-global-routing.cc ns-3.20/examples/routing/simple-global-routing.cc --- ns-3.19/examples/routing/simple-global-routing.cc 2014-06-17 10:34:00.379637117 -0700 +++ ns-3.20/examples/routing/simple-global-routing.cc 2014-06-17 10:33:13.712997359 -0700 @@ -149,11 +149,10 @@ p2p.EnablePcapAll ("simple-global-routing"); // Flow Monitor - Ptr flowmon; FlowMonitorHelper flowmonHelper; if (enableFlowMonitor) { - flowmon = flowmonHelper.InstallAll (); + flowmonHelper.InstallAll (); } NS_LOG_INFO ("Run Simulation."); @@ -163,7 +162,7 @@ if (enableFlowMonitor) { - flowmon->SerializeToXmlFile ("simple-global-routing.flowmon", false, false); + flowmonHelper.SerializeToXmlFile ("simple-global-routing.flowmon", false, false); } Simulator::Destroy (); diff -Naur ns-3.19/examples/routing/waf ns-3.20/examples/routing/waf --- ns-3.19/examples/routing/waf 2014-06-17 10:34:00.381637101 -0700 +++ ns-3.20/examples/routing/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/routing/wscript ns-3.20/examples/routing/wscript --- ns-3.19/examples/routing/wscript 2014-06-17 10:34:00.381637101 -0700 +++ ns-3.20/examples/routing/wscript 2014-06-17 10:33:13.714997343 -0700 @@ -37,4 +37,8 @@ ['wifi', 'dsr', 'dsdv', 'aodv', 'olsr', 'internet', 'applications']) obj.source = 'manet-routing-compare.cc' + obj = bld.create_ns3_program('ripng-simple-network', + ['csma', 'internet', 'applications']) + obj.source = 'ripng-simple-network.cc' + bld.register_ns3_script('simple-routing-ping6.py', ['csma', 'internet', 'applications']) diff -Naur ns-3.19/examples/socket/waf ns-3.20/examples/socket/waf --- ns-3.19/examples/socket/waf 2014-06-17 10:34:00.383637086 -0700 +++ ns-3.20/examples/socket/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/tcp/tcp-variants-comparison.cc ns-3.20/examples/tcp/tcp-variants-comparison.cc --- ns-3.19/examples/tcp/tcp-variants-comparison.cc 2014-06-17 10:34:00.390637032 -0700 +++ ns-3.20/examples/tcp/tcp-variants-comparison.cc 2014-06-17 10:33:13.723997274 -0700 @@ -339,11 +339,10 @@ LocalLink.EnablePcapAll("TcpVariantsComparison", true); // Flow monitor - Ptr flowMonitor; FlowMonitorHelper flowHelper; if (flow_monitor) { - flowMonitor = flowHelper.InstallAll(); + flowHelper.InstallAll(); } Simulator::Stop (Seconds(stop_time)); @@ -351,7 +350,7 @@ if (flow_monitor) { - flowMonitor->SerializeToXmlFile("TcpVariantsComparison.flowmonitor", true, true); + flowHelper.SerializeToXmlFile("TcpVariantsComparison.flowmonitor", true, true); } Simulator::Destroy (); diff -Naur ns-3.19/examples/tcp/waf ns-3.20/examples/tcp/waf --- ns-3.19/examples/tcp/waf 2014-06-17 10:34:00.391637024 -0700 +++ ns-3.20/examples/tcp/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/tutorial/waf ns-3.20/examples/tutorial/waf --- ns-3.19/examples/tutorial/waf 2014-06-17 10:34:00.395636994 -0700 +++ ns-3.20/examples/tutorial/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/udp/waf ns-3.20/examples/udp/waf --- ns-3.19/examples/udp/waf 2014-06-17 10:34:00.398636970 -0700 +++ ns-3.20/examples/udp/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/udp-client-server/waf ns-3.20/examples/udp-client-server/waf --- ns-3.19/examples/udp-client-server/waf 2014-06-17 10:34:00.397636978 -0700 +++ ns-3.20/examples/udp-client-server/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/waf ns-3.20/examples/waf --- ns-3.19/examples/waf 2014-06-17 10:34:00.398636970 -0700 +++ ns-3.20/examples/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../waf "$@" diff -Naur ns-3.19/examples/wireless/mixed-wireless.cc ns-3.20/examples/wireless/mixed-wireless.cc --- ns-3.19/examples/wireless/mixed-wireless.cc 2014-06-17 10:34:00.400636955 -0700 +++ ns-3.20/examples/wireless/mixed-wireless.cc 2014-06-17 10:33:13.731997212 -0700 @@ -69,6 +69,7 @@ #include "ns3/csma-module.h" #include "ns3/olsr-helper.h" #include "ns3/internet-module.h" +#include "ns3/netanim-module.h" using namespace ns3; @@ -96,18 +97,17 @@ // simulation parameters. // uint32_t backboneNodes = 10; - uint32_t infraNodes = 5; - uint32_t lanNodes = 5; - uint32_t stopTime = 10; + uint32_t infraNodes = 2; + uint32_t lanNodes = 2; + uint32_t stopTime = 20; bool useCourseChangeCallback = false; - bool enableTracing = false; // // Simulation defaults are typically set next, before command line // arguments are parsed. // - Config::SetDefault ("ns3::OnOffApplication::PacketSize", StringValue ("210")); - Config::SetDefault ("ns3::OnOffApplication::DataRate", StringValue ("10kb/s")); + Config::SetDefault ("ns3::OnOffApplication::PacketSize", StringValue ("1472")); + Config::SetDefault ("ns3::OnOffApplication::DataRate", StringValue ("100kb/s")); // // For convenience, we add the local variables to the command line argument @@ -120,7 +120,6 @@ cmd.AddValue ("lanNodes", "number of LAN nodes", lanNodes); cmd.AddValue ("stopTime", "simulation stop time (seconds)", stopTime); cmd.AddValue ("useCourseChangeCallback", "whether to enable course change tracing", useCourseChangeCallback); - cmd.AddValue ("enableTracing", "enable tracing", enableTracing); // // The system global variables and the local values added to the argument @@ -128,6 +127,11 @@ // cmd.Parse (argc, argv); + if (stopTime < 10) + { + std::cout << "Use a simulation stop time >= 10 seconds" << std::endl; + exit (1); + } /////////////////////////////////////////////////////////////////////////// // // // Construct the backbone // @@ -165,9 +169,6 @@ internet.SetRoutingHelper (olsr); // has effect on the next Install () internet.Install (backbone); - // re-initialize for non-olsr routing. - internet.Reset (); - // // Assign IPv4 addresses to the device drivers (actually to the associated // IPv4 interfaces) we just created. @@ -181,17 +182,15 @@ // each of the nodes we just finished building. // MobilityHelper mobility; - Ptr positionAlloc = - CreateObject (); - double x = 0.0; - for (uint32_t i = 0; i < backboneNodes; ++i) - { - positionAlloc->Add (Vector (x, 0.0, 0.0)); - x += 5.0; - } - mobility.SetPositionAllocator (positionAlloc); + mobility.SetPositionAllocator ("ns3::GridPositionAllocator", + "MinX", DoubleValue (20.0), + "MinY", DoubleValue (20.0), + "DeltaX", DoubleValue (20.0), + "DeltaY", DoubleValue (20.0), + "GridWidth", UintegerValue (5), + "LayoutType", StringValue ("RowFirst")); mobility.SetMobilityModel ("ns3::RandomDirection2dMobilityModel", - "Bounds", RectangleValue (Rectangle (0, 20, 0, 20)), + "Bounds", RectangleValue (Rectangle (-500, 500, -500, 500)), "Speed", StringValue ("ns3::ConstantRandomVariable[Constant=2]"), "Pause", StringValue ("ns3::ConstantRandomVariable[Constant=0.2]")); mobility.Install (backbone); @@ -242,6 +241,21 @@ // network mask initialized above // ipAddrs.NewNetwork (); + // + // The new LAN nodes need a mobility model so we aggregate one + // to each of the nodes we just finished building. + // + MobilityHelper mobilityLan; + Ptr subnetAlloc = + CreateObject (); + for (uint32_t j = 0; j < newLanNodes.GetN (); ++j) + { + subnetAlloc->Add (Vector (0.0, j*10 + 10, 0.0)); + } + mobilityLan.PushReferenceMobilityModel (backbone.Get (i)); + mobilityLan.SetPositionAllocator (subnetAlloc); + mobilityLan.SetMobilityModel ("ns3::ConstantPositionMobilityModel"); + mobilityLan.Install (newLanNodes); } /////////////////////////////////////////////////////////////////////////// @@ -286,7 +300,9 @@ NetDeviceContainer staDevices = wifiInfra.Install (wifiPhy, macInfra, stas); // setup ap. macInfra.SetType ("ns3::ApWifiMac", - "Ssid", SsidValue (ssid)); + "Ssid", SsidValue (ssid), + "BeaconGeneration", BooleanValue (true), + "BeaconInterval", TimeValue(Seconds(2.5))); NetDeviceContainer apDevices = wifiInfra.Install (wifiPhy, macInfra, backbone.Get (i)); // Collect all of these new devices NetDeviceContainer infraDevices (apDevices, staDevices); @@ -320,19 +336,8 @@ "Bounds", RectangleValue (Rectangle (-10, 10, -10, 10)), "Speed", StringValue ("ns3::ConstantRandomVariable[Constant=3]"), "Pause", StringValue ("ns3::ConstantRandomVariable[Constant=0.4]")); - mobility.Install (infra); + mobility.Install (stas); } - /////////////////////////////////////////////////////////////////////////// - // // - // Routing configuration // - // // - /////////////////////////////////////////////////////////////////////////// - - // The below global routing does not take into account wireless effects. - // However, it is useful for setting default routes for all of the nodes - // such as the LAN nodes. - NS_LOG_INFO ("Enabling global routing on all nodes"); - Ipv4GlobalRoutingHelper::PopulateRoutingTables (); /////////////////////////////////////////////////////////////////////////// // // @@ -363,17 +368,16 @@ OnOffHelper onoff ("ns3::UdpSocketFactory", Address (InetSocketAddress (remoteAddr, port))); - onoff.SetConstantRate (DataRate ("10kb/s")); ApplicationContainer apps = onoff.Install (appSource); - apps.Start (Seconds (3.0)); - apps.Stop (Seconds (20.0)); + apps.Start (Seconds (3)); + apps.Stop (Seconds (stopTime - 1)); // Create a packet sink to receive these packets PacketSinkHelper sink ("ns3::UdpSocketFactory", InetSocketAddress (Ipv4Address::GetAny (), port)); apps = sink.Install (appSink); - apps.Start (Seconds (3.0)); + apps.Start (Seconds (3)); /////////////////////////////////////////////////////////////////////////// // // @@ -382,36 +386,31 @@ /////////////////////////////////////////////////////////////////////////// NS_LOG_INFO ("Configure Tracing."); - if (enableTracing == true) - { - CsmaHelper csma; + CsmaHelper csma; - // - // Let's set up some ns-2-like ascii traces, using another helper class - // - AsciiTraceHelper ascii; - Ptr stream = ascii.CreateFileStream ("mixed-wireless.tr"); - wifiPhy.EnableAsciiAll (stream); - csma.EnableAsciiAll (stream); - internet.EnableAsciiIpv4All (stream); - - // Let's do a pcap trace on the application source and sink, ifIndex 0 - // Csma captures in non-promiscuous mode -#if 0 - csma.EnablePcap ("mixed-wireless", appSource->GetId (), 0, false); -#else - csma.EnablePcapAll ("mixed-wireless", false); -#endif - wifiPhy.EnablePcap ("mixed-wireless", appSink->GetId (), 0); - wifiPhy.EnablePcap ("mixed-wireless", 9, 2); - wifiPhy.EnablePcap ("mixed-wireless", 9, 0); - } + // + // Let's set up some ns-2-like ascii traces, using another helper class + // + AsciiTraceHelper ascii; + Ptr stream = ascii.CreateFileStream ("mixed-wireless.tr"); + wifiPhy.EnableAsciiAll (stream); + csma.EnableAsciiAll (stream); + internet.EnableAsciiIpv4All (stream); + + // Csma captures in non-promiscuous mode + csma.EnablePcapAll ("mixed-wireless", false); + // pcap captures on the backbone wifi devices + wifiPhy.EnablePcap ("mixed-wireless", backboneDevices, false); + // pcap trace on the application data sink + wifiPhy.EnablePcap ("mixed-wireless", appSink->GetId (), 0); if (useCourseChangeCallback == true) { Config::Connect ("/NodeList/*/$ns3::MobilityModel/CourseChange", MakeCallback (&CourseChangeCallback)); } + AnimationInterface anim ("mixed-wireless.xml"); + /////////////////////////////////////////////////////////////////////////// // // // Run simulation // diff -Naur ns-3.19/examples/wireless/mixed-wireless.py ns-3.20/examples/wireless/mixed-wireless.py --- ns-3.19/examples/wireless/mixed-wireless.py 2014-06-17 10:34:00.400636955 -0700 +++ ns-3.20/examples/wireless/mixed-wireless.py 2014-06-17 10:33:13.731997212 -0700 @@ -76,16 +76,16 @@ # simulation parameters. # backboneNodes = 10 - infraNodes = 5 - lanNodes = 5 - stopTime = 10 + infraNodes = 2 + lanNodes = 2 + stopTime = 20 # # Simulation defaults are typically set next, before command line # arguments are parsed. # - ns.core.Config.SetDefault("ns3::OnOffApplication::PacketSize", ns.core.StringValue("210")) - ns.core.Config.SetDefault("ns3::OnOffApplication::DataRate", ns.core.StringValue("448kb/s")) + ns.core.Config.SetDefault("ns3::OnOffApplication::PacketSize", ns.core.StringValue("1472")) + ns.core.Config.SetDefault("ns3::OnOffApplication::DataRate", ns.core.StringValue("100kb/s")) # # For convenience, we add the local variables to the command line argument @@ -93,10 +93,10 @@ # "--backboneNodes=20" # cmd = ns.core.CommandLine() - #cmd.AddValue("backboneNodes", "number of backbone nodes", backboneNodes) - #cmd.AddValue("infraNodes", "number of leaf nodes", infraNodes) - #cmd.AddValue("lanNodes", "number of LAN nodes", lanNodes) - #cmd.AddValue("stopTime", "simulation stop time(seconds)", stopTime) + cmd.AddValue("backboneNodes", "number of backbone nodes", str(backboneNodes)) + cmd.AddValue("infraNodes", "number of leaf nodes", str(infraNodes)) + cmd.AddValue("lanNodes", "number of LAN nodes", str(lanNodes)) + cmd.AddValue("stopTime", "simulation stop time(seconds)", str(stopTime)) # # The system global variables and the local values added to the argument @@ -104,6 +104,9 @@ # cmd.Parse(argv) + if (stopTime < 10): + print "Use a simulation stop time >= 10 seconds" + exit(1) # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # / # # # Construct the backbone # @@ -138,7 +141,7 @@ internet.SetRoutingHelper(olsr); # has effect on the next Install () internet.Install(backbone); # re-initialize for non-olsr routing. - internet.Reset() + # internet.Reset() # # Assign IPv4 addresses to the device drivers(actually to the associated # IPv4 interfaces) we just created. @@ -152,15 +155,16 @@ # each of the nodes we just finished building. # mobility = ns.mobility.MobilityHelper() - positionAlloc = ns.mobility.ListPositionAllocator() - x = 0.0 - for i in range(backboneNodes): - positionAlloc.Add(ns.core.Vector(x, 0.0, 0.0)) - x += 5.0 - mobility.SetPositionAllocator(positionAlloc) + mobility.SetPositionAllocator("ns3::GridPositionAllocator", + "MinX", ns.core.DoubleValue(20.0), + "MinY", ns.core.DoubleValue(20.0), + "DeltaX", ns.core.DoubleValue(20.0), + "DeltaY", ns.core.DoubleValue(20.0), + "GridWidth", ns.core.UintegerValue(5), + "LayoutType", ns.core.StringValue("RowFirst")) mobility.SetMobilityModel("ns3::RandomDirection2dMobilityModel", - "Bounds", ns.mobility.RectangleValue(ns.mobility.Rectangle(0, 1000, 0, 1000)), - "Speed", ns.core.StringValue ("ns3::ConstantRandomVariable[Constant=2000]"), + "Bounds", ns.mobility.RectangleValue(ns.mobility.Rectangle(-500, 500, -500, 500)), + "Speed", ns.core.StringValue ("ns3::ConstantRandomVariable[Constant=2]"), "Pause", ns.core.StringValue ("ns3::ConstantRandomVariable[Constant=0.2]")) mobility.Install(backbone) @@ -207,6 +211,19 @@ # network mask initialized above # ipAddrs.NewNetwork() + # + # The new LAN nodes need a mobility model so we aggregate one + # to each of the nodes we just finished building. + # + mobilityLan = ns.mobility.MobilityHelper() + positionAlloc = ns.mobility.ListPositionAllocator() + for j in range(newLanNodes.GetN()): + positionAlloc.Add(ns.core.Vector(0.0, (j*10 + 10), 0.0)) + + mobilityLan.SetPositionAllocator(positionAlloc) + mobilityLan.PushReferenceMobilityModel(backbone.Get(i)) + mobilityLan.SetMobilityModel("ns3::ConstantPositionMobilityModel") + mobilityLan.Install(newLanNodes); # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # / # # @@ -276,10 +293,10 @@ mobility.PushReferenceMobilityModel(backbone.Get(i)) mobility.SetPositionAllocator(subnetAlloc) mobility.SetMobilityModel("ns3::RandomDirection2dMobilityModel", - "Bounds", ns.mobility.RectangleValue(ns.mobility.Rectangle(-25, 25, -25, 25)), - "Speed", ns.core.StringValue ("ns3::ConstantRandomVariable[Constant=30]"), + "Bounds", ns.mobility.RectangleValue(ns.mobility.Rectangle(-10, 10, -10, 10)), + "Speed", ns.core.StringValue ("ns3::ConstantRandomVariable[Constant=3]"), "Pause", ns.core.StringValue ("ns3::ConstantRandomVariable[Constant=0.4]")) - mobility.Install(infra) + mobility.Install(stas) # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # / # # @@ -292,25 +309,23 @@ print "Create Applications." port = 9 # Discard port(RFC 863) - # Let's make sure that the user does not define too few LAN nodes - # to make this example work. We need lanNodes >= 5 - assert(lanNodes >= 5) - appSource = ns.network.NodeList.GetNode(11) - appSink = ns.network.NodeList.GetNode(13) - remoteAddr = ns.network.Ipv4Address("172.16.0.5") + appSource = ns.network.NodeList.GetNode(backboneNodes) + lastNodeIndex = backboneNodes + backboneNodes*(lanNodes - 1) + backboneNodes*(infraNodes - 1) - 1 + appSink = ns.network.NodeList.GetNode(lastNodeIndex) + # Let's fetch the IP address of the last node, which is on Ipv4Interface 1 + remoteAddr = appSink.GetObject(ns.internet.Ipv4.GetTypeId()).GetAddress(1,0).GetLocal() onoff = ns.applications.OnOffHelper("ns3::UdpSocketFactory", ns.network.Address(ns.network.InetSocketAddress(remoteAddr, port))) - onoff.SetConstantRate (ns.network.DataRate ("10kb/s")) apps = onoff.Install(ns.network.NodeContainer(appSource)) - apps.Start(ns.core.Seconds(3.0)) - apps.Stop(ns.core.Seconds(20.0)) + apps.Start(ns.core.Seconds(3)) + apps.Stop(ns.core.Seconds(stopTime - 1)) # Create a packet sink to receive these packets sink = ns.applications.PacketSinkHelper("ns3::UdpSocketFactory", ns.network.InetSocketAddress(ns.network.Ipv4Address.GetAny(), port)) apps = sink.Install(ns.network.NodeContainer(appSink)) - apps.Start(ns.core.Seconds(3.0)) + apps.Start(ns.core.Seconds(3)) # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # / # # @@ -319,24 +334,21 @@ # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # / print "Configure Tracing." + csma = ns.csma.CsmaHelper() # # Let's set up some ns-2-like ascii traces, using another helper class # - #std.ofstream ascii - #ascii = ns.core.AsciiTraceHelper(); - #stream = ascii.CreateFileStream("mixed-wireless.tr"); - #wifiPhy.EnableAsciiAll(stream); - #csma.EnableAsciiAll(stream); - print "(tracing not done for Python)" - # Look at nodes 11, 13 only - # WifiHelper.EnableAscii(ascii, 11, 0); - # WifiHelper.EnableAscii(ascii, 13, 0); + ascii = ns.network.AsciiTraceHelper(); + stream = ascii.CreateFileStream("mixed-wireless.tr"); + wifiPhy.EnableAsciiAll(stream); + csma.EnableAsciiAll(stream); + internet.EnableAsciiIpv4All(stream); + # Csma captures in non-promiscuous mode + csma.EnablePcapAll("mixed-wireless", False) # Let's do a pcap trace on the backbone devices wifiPhy.EnablePcap("mixed-wireless", backboneDevices) - # Let's additionally trace the application Sink, ifIndex 0 - csma = ns.csma.CsmaHelper() - csma.EnablePcapAll("mixed-wireless", False) + wifiPhy.EnablePcap("mixed-wireless", appSink.GetId(), 0) # #ifdef ENABLE_FOR_TRACING_EXAMPLE # Config.Connect("/NodeList/*/$MobilityModel/CourseChange", diff -Naur ns-3.19/examples/wireless/multirate.cc ns-3.20/examples/wireless/multirate.cc --- ns-3.19/examples/wireless/multirate.cc 2014-06-17 10:34:00.401636947 -0700 +++ ns-3.20/examples/wireless/multirate.cc 2014-06-17 10:33:13.732997204 -0700 @@ -508,12 +508,11 @@ phy.EnableAsciiAll (ascii.CreateFileStream (GetOutputFileName () + ".tr")); } - Ptr flowmon; FlowMonitorHelper flowmonHelper; if (enableFlowMon) { - flowmon = flowmonHelper.InstallAll (); + flowmonHelper.InstallAll (); } Simulator::Stop (Seconds (totalTime)); @@ -521,7 +520,7 @@ if (enableFlowMon) { - flowmon->SerializeToXmlFile ((GetOutputFileName () + ".flomon"), false, false); + flowmonHelper.SerializeToXmlFile ((GetOutputFileName () + ".flomon"), false, false); } Simulator::Destroy (); diff -Naur ns-3.19/examples/wireless/waf ns-3.20/examples/wireless/waf --- ns-3.19/examples/wireless/waf 2014-06-17 10:34:00.402636940 -0700 +++ ns-3.20/examples/wireless/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/examples/wireless/wscript ns-3.20/examples/wireless/wscript --- ns-3.19/examples/wireless/wscript 2014-06-17 10:34:00.408636893 -0700 +++ ns-3.20/examples/wireless/wscript 2014-06-17 10:33:13.739997150 -0700 @@ -2,7 +2,7 @@ def build(bld): obj = bld.create_ns3_program('mixed-wireless', ['core', 'mobility', 'wifi', 'applications', 'point-to-point', - 'internet', 'csma', 'olsr']) + 'internet', 'csma', 'olsr', 'netanim']) obj.source = 'mixed-wireless.cc' bld.register_ns3_script('mixed-wireless.py', ['core', 'mobility', 'wifi', 'applications', 'point-to-point', diff -Naur ns-3.19/.hgignore ns-3.20/.hgignore --- ns-3.19/.hgignore 2014-06-17 10:34:00.259638043 -0700 +++ ns-3.20/.hgignore 2014-06-17 10:33:13.606998177 -0700 @@ -42,5 +42,7 @@ \.plt$ \#[^\#/]+\#$ ^coverity +^(D|U)l[A-Z][a-z]*Stats.txt$ syntax: glob TAGS +waf diff -Naur ns-3.19/.hgtags ns-3.20/.hgtags --- ns-3.19/.hgtags 2014-06-17 10:34:00.261638028 -0700 +++ ns-3.20/.hgtags 2014-06-17 10:33:13.608998161 -0700 @@ -66,4 +66,5 @@ 49d343e55caec257bb01e400eef6c14522f37e1b ns-3.16 b4a70b99171ade6e9628a87780994238950a1df1 ns-3.17 cfbc9491d7e7c9d346cc042fd35b8afb8836e81f ns-3.18 -a831982d3190a1ff8d4be3c36befc2abf78a6009 ns-3.19 +322102df792e2be6c74df74f776b3470fb1db795 ns-3.19 +0430f8ab48f8177999b5203700dfb0edca1e2056 ns-3.20 diff -Naur ns-3.19/RELEASE_NOTES ns-3.20/RELEASE_NOTES --- ns-3.19/RELEASE_NOTES 2014-06-17 10:34:00.276637912 -0700 +++ ns-3.20/RELEASE_NOTES 2014-06-17 10:33:13.624998038 -0700 @@ -9,6 +9,115 @@ Consult the file CHANGES.html for more detailed information about changed API and behavior across ns-3 releases. +Release 3.20 +============= + +Availability +------------ +This release is available from: +http://www.nsnam.org/release/ns-allinone-3.20.tar.bz2 + +Supported platforms +------------------- +- Fedora Core 20 (32/64 bit) with g++-4.8.2 +- Ubuntu 14.04 (32/64 bit) with g++-4.8.2 +- Ubuntu 12.04.4 (64 bit) with g++-4.6.3 +- Ubuntu 10.04.4 LTS (64 bit) with g++-4.4.3 +- CentOS/RHEL 6.5 (64-bit) with g++-4.4.7 +- OS X Mavericks 10.9 with Xcode 5.1.1 and clang-503.0.40 +- FreeBSD 9.2-RELEASE (64 bit) with clang-3.3 + +New user-visible features +------------------------- + +- A new LrWpan model, providing initial support for IEEE 802.15.4 networks +- A new IPv6 routing protocol has been added: RIPng. This protocol is + an Interior Gateway Protocol and it is available in the Internet module. +- A new LTE MAC downlink scheduling algorithm named Channel and QoS Aware (CQA) + Scheduler is provided by the new ``ns3::CqaFfMacScheduler`` object. +- The Internet FlowMonitor can now track IPv6 packets. +- FlowMonitor no longer tracks multicast/broadcast packets, reflecting + its original design. +- FlowMonitor "SerializeToXml" functions are now directly available + from the helper. +- The SixLowPan model can now use uncompressed IPv6 headers. An option to + define the minimum compressed packet size has been added. +- Simplify output of Times in a specific unit; see Time::As () +- Ipv6Extension::m_dropTrace has been removed. Ipv6L3Protocol::m_dropTrace + is now fired when appropriate. +- IPv4 identification field value is now dependent on the protocol field. +- Fixes to support Python >= 3.3 in ns3 Python bindings +- Enable selection of high precision int64x64_t implementation + at configure time, for debugging purposes. + +Bugs fixed +---------- +- Bug 1276 - optimize NistErrorRateModel +- Bug 1294 - New PeekU8 () and Read (Buffer::Iterator start, uint32_t size) methods in Buffer::Iterator +- Bug 1443 - MinDistance replaced by MinLoss in FriisPropagationLossModel, to + better handle conditions outside of the assumed far field region. +- Bug 1653 - Extension of CommandLine interface: restored operator << (CommandLine) +- Bug 1717 - Detect unsettable attributes +- Bug 1730 - no model library documentation for spectrum module +- Bug 1739 - The endpoint is not deallocated for UDP sockets +- Bug 1786 - os << int64x64_t prints un-normalized fractional values +- Bug 1787 - Runtime error when using AnimationInterface::EnablePacketMetadata() to fetch metadata of CSMA packet +- Bug 1792 - Parameter logger constructor +- Bug 1808 - FlowMon relies on IPv4's Identification field to trace packets +- Bug 1817 - IPv4 Identification field should consider protocol as well. +- Bug 1818 - FlowMonitor needs IPv6 support +- Bug 1820 - models library doc: make should not rm -rf figures +- Bug 1821 - Setting an interface to Down state will cause various asserts in IPv6 +- Bug 1829 - Multiple TCP socket entries +- Bug 1837 - AODV crashes when using multiple interfaces +- Bug 1838 - FlowMonitorHelper must not be copied. +- Bug 1841 - FlowMonitor fails to install if IPv4 is not installed in the node +- Bug 1842 - FlowMonitor SerializeToXml should be called by the helper +- Bug 1843 - IPv6 extensions dropped packets do not fire L3 drop trace +- Bug 1845 - FlowMonitor should discard any broadcast/multicast packet +- Bug 1846 - IPv6 should send Destination Unreachable if no route is available +- Bug 1850 - TCP NewReno loss behavior +- Bug 1852 - cairo-wideint-private.h error cannot find definitions for fixed-width integral types +- Bug 1853 - NS_LOG_FUNCTION broken on OSX 10.9 +- Bug 1855 - SixLowPanNetDevice is not correctly indexed +- Bug 1857 - Detect location of installed boost libraries +- Bug 1862 - NS_LOG="Time=*|prefix_time" causes stack overflow +- Bug 1868 - Optimized builds are sensitive to -fstrict-overflow +- Bug 1870 - Remove unnecessary AsInt functions +- Bug 1872 - Inside RREQ processing, in case of IP duplication, packet dropped instead of being forwarded +- Bug 1873 - Energy source checked to be aggregated to the node +- Bug 1874 - Ipv4L3Protocol::ProcessFragment: addressCombination and idProto identifiers not properly computed +- Bug 1876 - enable OLSR HNA table access +- Bug 1877 - constructors missing for PropagationLossModels +- Bug 1882 - int64x64 tests trigger valgrind bug +- Bug 1883 - IPv6 don't consider the prefix and network when choosing output address +- Bug 1885 - WifiSpectrumValue5MhzFactory::CreateRfFilter does not align with the used 5Mhz SpectrumModel +- Bug 1887 - Point-to-point traces should contain PPP headers +- Bug 1888 - COST231 propagation loss model: corrections +- Bug 1889 - PointToPointNetDevice: In some cases MacTxDrop trace is not called +- Bug 1890 - UdpClientTrace: MPEG frame size is squeezed into (insufficient) 16 bit integer +- Bug 1891 - UdpSocketImpl::GetSockName doesn't return the IPv6 address +- Bug 1894 - CqaFfMacScheduler needs an update +- Bug 1895 - IP header Source Address changed while forwarding RREQ +- Bug 1900 - Avoid floating point differences across platforms in test outputs +- Bug 1903 - Namespace usage in olsr-state.cc/h +- Bug 1907 - Add IsSupportedMcs method in YansWifiPhy +- Bug 1912 - Avoid multiple Wifi MacTxMiddle instances +- Bug 1913 - Avoid crash in Wifi BlockAckManager::GetNextPacket() +- Bug 1915 - BRITE channel delay is rounded to an integer +- Bug 1916 - RandomWalk2dMobilityMode default "Bounds" attribute is not a rectangle +- Bug 1919 - Strip trailing semi-colons from mobility trace files +- Bug 1920 - Remove DSR attributes so file can be re-loaded by config-store +- Bug 1922 - WAVE GetSsid should not be fatal +- Bug 1923 - Setting Active Probing to false in Wifi Sta has no effect +- Bug 1924 - sensing radius and CCA + +Known issues +------------ +- Bug 1770 - The mesh module will crash if used for g++ version >= 4.8.1 +in optimized mode, on a 32-bit Linux machine. Lowering the optimization +level to -O1 in this case can be used as a workaround. + Release 3.19 ============= @@ -115,6 +224,7 @@ - Bug 1814 - IPv6 Packet with length not multiple of 8 bytes are fragmented incorrectly. - Bug 1815 - Python bindings compilation with clang compiler toolchain - Bug 1816 - IPv4 fragmentation loses Packet tags +- Bug 1877 - constructor missing for PropagationLossModels Release 3.18.2 ============== diff -Naur ns-3.19/src/antenna/bindings/modulegen__gcc_ILP32.py ns-3.20/src/antenna/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/antenna/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.411636870 -0700 +++ ns-3.20/src/antenna/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.741997135 -0700 @@ -102,17 +102,17 @@ module.add_class('Vector3DChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker']) ## vector.h (module 'core'): ns3::Vector3DValue [class] module.add_class('Vector3DValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) - typehandlers.add_type_alias('ns3::Vector3D', 'ns3::Vector') - typehandlers.add_type_alias('ns3::Vector3D*', 'ns3::Vector*') - typehandlers.add_type_alias('ns3::Vector3D&', 'ns3::Vector&') + typehandlers.add_type_alias(u'ns3::Vector3D', u'ns3::Vector') + typehandlers.add_type_alias(u'ns3::Vector3D*', u'ns3::Vector*') + typehandlers.add_type_alias(u'ns3::Vector3D&', u'ns3::Vector&') module.add_typedef(root_module['ns3::Vector3D'], 'Vector') - typehandlers.add_type_alias('ns3::Vector3DValue', 'ns3::VectorValue') - typehandlers.add_type_alias('ns3::Vector3DValue*', 'ns3::VectorValue*') - typehandlers.add_type_alias('ns3::Vector3DValue&', 'ns3::VectorValue&') + typehandlers.add_type_alias(u'ns3::Vector3DValue', u'ns3::VectorValue') + typehandlers.add_type_alias(u'ns3::Vector3DValue*', u'ns3::VectorValue*') + typehandlers.add_type_alias(u'ns3::Vector3DValue&', u'ns3::VectorValue&') module.add_typedef(root_module['ns3::Vector3DValue'], 'VectorValue') - typehandlers.add_type_alias('ns3::Vector3DChecker', 'ns3::VectorChecker') - typehandlers.add_type_alias('ns3::Vector3DChecker*', 'ns3::VectorChecker*') - typehandlers.add_type_alias('ns3::Vector3DChecker&', 'ns3::VectorChecker&') + typehandlers.add_type_alias(u'ns3::Vector3DChecker', u'ns3::VectorChecker') + typehandlers.add_type_alias(u'ns3::Vector3DChecker*', u'ns3::VectorChecker*') + typehandlers.add_type_alias(u'ns3::Vector3DChecker&', u'ns3::VectorChecker&') module.add_typedef(root_module['ns3::Vector3DChecker'], 'VectorChecker') ## Register a nested module for the namespace FatalImpl @@ -136,12 +136,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function diff -Naur ns-3.19/src/antenna/bindings/modulegen__gcc_LP64.py ns-3.20/src/antenna/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/antenna/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.412636862 -0700 +++ ns-3.20/src/antenna/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.742997127 -0700 @@ -102,17 +102,17 @@ module.add_class('Vector3DChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker']) ## vector.h (module 'core'): ns3::Vector3DValue [class] module.add_class('Vector3DValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) - typehandlers.add_type_alias('ns3::Vector3D', 'ns3::Vector') - typehandlers.add_type_alias('ns3::Vector3D*', 'ns3::Vector*') - typehandlers.add_type_alias('ns3::Vector3D&', 'ns3::Vector&') + typehandlers.add_type_alias(u'ns3::Vector3D', u'ns3::Vector') + typehandlers.add_type_alias(u'ns3::Vector3D*', u'ns3::Vector*') + typehandlers.add_type_alias(u'ns3::Vector3D&', u'ns3::Vector&') module.add_typedef(root_module['ns3::Vector3D'], 'Vector') - typehandlers.add_type_alias('ns3::Vector3DValue', 'ns3::VectorValue') - typehandlers.add_type_alias('ns3::Vector3DValue*', 'ns3::VectorValue*') - typehandlers.add_type_alias('ns3::Vector3DValue&', 'ns3::VectorValue&') + typehandlers.add_type_alias(u'ns3::Vector3DValue', u'ns3::VectorValue') + typehandlers.add_type_alias(u'ns3::Vector3DValue*', u'ns3::VectorValue*') + typehandlers.add_type_alias(u'ns3::Vector3DValue&', u'ns3::VectorValue&') module.add_typedef(root_module['ns3::Vector3DValue'], 'VectorValue') - typehandlers.add_type_alias('ns3::Vector3DChecker', 'ns3::VectorChecker') - typehandlers.add_type_alias('ns3::Vector3DChecker*', 'ns3::VectorChecker*') - typehandlers.add_type_alias('ns3::Vector3DChecker&', 'ns3::VectorChecker&') + typehandlers.add_type_alias(u'ns3::Vector3DChecker', u'ns3::VectorChecker') + typehandlers.add_type_alias(u'ns3::Vector3DChecker*', u'ns3::VectorChecker*') + typehandlers.add_type_alias(u'ns3::Vector3DChecker&', u'ns3::VectorChecker&') module.add_typedef(root_module['ns3::Vector3DChecker'], 'VectorChecker') ## Register a nested module for the namespace FatalImpl @@ -136,12 +136,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function diff -Naur ns-3.19/src/antenna/model/antenna-model.cc ns-3.20/src/antenna/model/antenna-model.cc --- ns-3.19/src/antenna/model/antenna-model.cc 2014-06-17 10:34:00.416636831 -0700 +++ ns-3.20/src/antenna/model/antenna-model.cc 2014-06-17 10:33:13.746997096 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (AntennaModel) - ; +NS_OBJECT_ENSURE_REGISTERED (AntennaModel); AntennaModel::AntennaModel () diff -Naur ns-3.19/src/antenna/model/cosine-antenna-model.cc ns-3.20/src/antenna/model/cosine-antenna-model.cc --- ns-3.19/src/antenna/model/cosine-antenna-model.cc 2014-06-17 10:34:00.417636824 -0700 +++ ns-3.20/src/antenna/model/cosine-antenna-model.cc 2014-06-17 10:33:13.747997088 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (CosineAntennaModel) - ; +NS_OBJECT_ENSURE_REGISTERED (CosineAntennaModel); TypeId diff -Naur ns-3.19/src/antenna/model/isotropic-antenna-model.cc ns-3.20/src/antenna/model/isotropic-antenna-model.cc --- ns-3.19/src/antenna/model/isotropic-antenna-model.cc 2014-06-17 10:34:00.418636816 -0700 +++ ns-3.20/src/antenna/model/isotropic-antenna-model.cc 2014-06-17 10:33:13.748997081 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (IsotropicAntennaModel) - ; +NS_OBJECT_ENSURE_REGISTERED (IsotropicAntennaModel); TypeId diff -Naur ns-3.19/src/antenna/model/parabolic-antenna-model.cc ns-3.20/src/antenna/model/parabolic-antenna-model.cc --- ns-3.19/src/antenna/model/parabolic-antenna-model.cc 2014-06-17 10:34:00.419636808 -0700 +++ ns-3.20/src/antenna/model/parabolic-antenna-model.cc 2014-06-17 10:33:13.748997081 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ParabolicAntennaModel) - ; +NS_OBJECT_ENSURE_REGISTERED (ParabolicAntennaModel); TypeId diff -Naur ns-3.19/src/antenna/test/test-angles.cc ns-3.20/src/antenna/test/test-angles.cc --- ns-3.19/src/antenna/test/test-angles.cc 2014-06-17 10:34:00.419636808 -0700 +++ ns-3.20/src/antenna/test/test-angles.cc 2014-06-17 10:33:13.749997073 -0700 @@ -26,7 +26,7 @@ #include #include -namespace ns3 { +using namespace ns3; class OneVectorConstructorTestCase : public TestCase { @@ -209,8 +209,3 @@ }; static AnglesTestSuite staticAnglesTestSuiteInstance; - - - - -} // namespace ns3 diff -Naur ns-3.19/src/antenna/test/test-cosine-antenna.cc ns-3.20/src/antenna/test/test-cosine-antenna.cc --- ns-3.19/src/antenna/test/test-cosine-antenna.cc 2014-06-17 10:34:00.420636800 -0700 +++ ns-3.20/src/antenna/test/test-cosine-antenna.cc 2014-06-17 10:33:13.750997065 -0700 @@ -31,7 +31,7 @@ NS_LOG_COMPONENT_DEFINE ("TestCosineAntennaModel"); -namespace ns3 { +using namespace ns3; enum CosineAntennaModelGainTestCondition { EQUAL = 0, @@ -204,8 +204,3 @@ }; static CosineAntennaModelTestSuite staticCosineAntennaModelTestSuiteInstance; - - - - -} // namespace ns3 diff -Naur ns-3.19/src/antenna/test/test-degrees-radians.cc ns-3.20/src/antenna/test/test-degrees-radians.cc --- ns-3.19/src/antenna/test/test-degrees-radians.cc 2014-06-17 10:34:00.420636800 -0700 +++ ns-3.20/src/antenna/test/test-degrees-radians.cc 2014-06-17 10:33:13.750997065 -0700 @@ -26,7 +26,7 @@ #include #include -namespace ns3 { +using namespace ns3; class DegreesToRadiansTestCase : public TestCase { @@ -132,8 +132,3 @@ }; static DegreesRadiansTestSuite staticDegreesRadiansTestSuiteInstance; - - - - -} // namespace ns3 diff -Naur ns-3.19/src/antenna/test/test-isotropic-antenna.cc ns-3.20/src/antenna/test/test-isotropic-antenna.cc --- ns-3.19/src/antenna/test/test-isotropic-antenna.cc 2014-06-17 10:34:00.421636793 -0700 +++ ns-3.20/src/antenna/test/test-isotropic-antenna.cc 2014-06-17 10:33:13.750997065 -0700 @@ -26,7 +26,7 @@ #include #include -namespace ns3 { +using namespace ns3; class IsotropicAntennaModelTestCase : public TestCase { @@ -90,8 +90,3 @@ }; static IsotropicAntennaModelTestSuite staticIsotropicAntennaModelTestSuiteInstance; - - - - -} // namespace ns3 diff -Naur ns-3.19/src/antenna/test/test-parabolic-antenna.cc ns-3.20/src/antenna/test/test-parabolic-antenna.cc --- ns-3.19/src/antenna/test/test-parabolic-antenna.cc 2014-06-17 10:34:00.421636793 -0700 +++ ns-3.20/src/antenna/test/test-parabolic-antenna.cc 2014-06-17 10:33:13.751997058 -0700 @@ -31,7 +31,7 @@ NS_LOG_COMPONENT_DEFINE ("TestParabolicAntennaModel"); -namespace ns3 { +using namespace ns3; enum ParabolicAntennaModelGainTestCondition { EQUAL = 0, @@ -183,8 +183,3 @@ }; static ParabolicAntennaModelTestSuite staticParabolicAntennaModelTestSuiteInstance; - - - - -} // namespace ns3 diff -Naur ns-3.19/src/aodv/bindings/modulegen__gcc_ILP32.py ns-3.20/src/aodv/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/aodv/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.428636739 -0700 +++ ns-3.20/src/aodv/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.757997011 -0700 @@ -102,12 +102,6 @@ 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-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress [class] - module.add_class('Ipv6InterfaceAddress', import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e [enumeration] - module.add_enum('State_e', ['TENTATIVE', 'DEPRECATED', 'PREFERRED', 'PERMANENT', 'HOMEADDRESS', 'TENTATIVE_OPTIMISTIC', 'INVALID'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e [enumeration] - module.add_enum('Scope_e', ['HOST', 'LINKLOCAL', 'GLOBAL'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') ## 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] @@ -148,6 +142,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -168,6 +164,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## aodv-helper.h (module 'aodv'): ns3::AodvHelper [class] module.add_class('AodvHelper', parent=root_module['ns3::Ipv4RoutingHelper']) ## chunk.h (module 'network'): ns3::Chunk [class] @@ -180,10 +178,6 @@ module.add_enum('DscpType', ['DscpDefault', 'DSCP_CS1', 'DSCP_AF11', 'DSCP_AF12', 'DSCP_AF13', 'DSCP_CS2', 'DSCP_AF21', 'DSCP_AF22', 'DSCP_AF23', 'DSCP_CS3', 'DSCP_AF31', 'DSCP_AF32', 'DSCP_AF33', 'DSCP_CS4', 'DSCP_AF41', 'DSCP_AF42', 'DSCP_AF43', 'DSCP_CS5', 'DSCP_EF', 'DSCP_CS6', 'DSCP_CS7'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType [enumeration] module.add_enum('EcnType', ['ECN_NotECT', 'ECN_ECT1', 'ECN_ECT0', 'ECN_CE'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header [class] - module.add_class('Ipv6Header', import_from_module='ns.internet', parent=root_module['ns3::Header']) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::NextHeader_e [enumeration] - module.add_enum('NextHeader_e', ['IPV6_EXT_HOP_BY_HOP', 'IPV6_IPV4', 'IPV6_TCP', 'IPV6_UDP', 'IPV6_IPV6', 'IPV6_EXT_ROUTING', 'IPV6_EXT_FRAGMENTATION', 'IPV6_EXT_CONFIDENTIALITY', 'IPV6_EXT_AUTHENTIFICATION', 'IPV6_ICMPV6', 'IPV6_EXT_END', 'IPV6_EXT_DESTINATION', 'IPV6_SCTP', 'IPV6_EXT_MOBILITY', 'IPV6_UDP_LITE'], outer_class=root_module['ns3::Ipv6Header'], import_from_module='ns.internet') ## 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] @@ -296,10 +290,6 @@ module.add_class('ExponentialRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::GammaRandomVariable [class] module.add_class('GammaRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -326,8 +316,6 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -370,8 +358,8 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv4-list-routing.h (module 'internet'): ns3::Ipv4ListRouting [class] module.add_class('Ipv4ListRouting', import_from_module='ns.internet', parent=root_module['ns3::Ipv4RoutingProtocol']) - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') ## Register a nested module for the namespace FatalImpl @@ -400,12 +388,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') ## Register a nested module for the namespace Function @@ -460,8 +448,8 @@ module.add_class('RreqHeader', parent=root_module['ns3::Header']) ## aodv-packet.h (module 'aodv'): ns3::aodv::TypeHeader [class] module.add_class('TypeHeader', parent=root_module['ns3::Header']) - module.add_container('std::map< ns3::Ipv4Address, unsigned int >', ('ns3::Ipv4Address', 'unsigned int'), container_type='map') - module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type='vector') + module.add_container('std::map< ns3::Ipv4Address, unsigned int >', ('ns3::Ipv4Address', 'unsigned int'), container_type=u'map') + module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type=u'vector') def register_methods(root_module): register_Ns3Address_methods(root_module, root_module['ns3::Address']) @@ -491,7 +479,6 @@ register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) register_Ns3Ipv4RoutingHelper_methods(root_module, root_module['ns3::Ipv4RoutingHelper']) register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address']) - register_Ns3Ipv6InterfaceAddress_methods(root_module, root_module['ns3::Ipv6InterfaceAddress']) register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix']) register_Ns3Mac48Address_methods(root_module, root_module['ns3::Mac48Address']) register_Ns3NodeContainer_methods(root_module, root_module['ns3::NodeContainer']) @@ -509,6 +496,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) @@ -520,7 +508,6 @@ register_Ns3Chunk_methods(root_module, root_module['ns3::Chunk']) register_Ns3Header_methods(root_module, root_module['ns3::Header']) register_Ns3Ipv4Header_methods(root_module, root_module['ns3::Ipv4Header']) - register_Ns3Ipv6Header_methods(root_module, root_module['ns3::Ipv6Header']) register_Ns3Object_methods(root_module, root_module['ns3::Object']) register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3RandomVariableStream_methods(root_module, root_module['ns3::RandomVariableStream']) @@ -571,7 +558,6 @@ register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) register_Ns3ExponentialRandomVariable_methods(root_module, root_module['ns3::ExponentialRandomVariable']) register_Ns3GammaRandomVariable_methods(root_module, root_module['ns3::GammaRandomVariable']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -584,7 +570,6 @@ register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3LogNormalRandomVariable_methods(root_module, root_module['ns3::LogNormalRandomVariable']) @@ -871,6 +856,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -883,6 +872,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1781,61 +1774,6 @@ [param('uint8_t *', 'address')]) return -def register_Ns3Ipv6InterfaceAddress_methods(root_module, cls): - cls.add_binary_comparison_operator('!=') - cls.add_output_stream_operator() - cls.add_binary_comparison_operator('==') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress() [constructor] - cls.add_constructor([]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address, ns3::Ipv6Prefix prefix) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'prefix')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6InterfaceAddress const & o) [copy constructor] - cls.add_constructor([param('ns3::Ipv6InterfaceAddress const &', 'o')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6InterfaceAddress::GetAddress() const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): uint32_t ns3::Ipv6InterfaceAddress::GetNsDadUid() const [member function] - cls.add_method('GetNsDadUid', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Prefix ns3::Ipv6InterfaceAddress::GetPrefix() const [member function] - cls.add_method('GetPrefix', - 'ns3::Ipv6Prefix', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e ns3::Ipv6InterfaceAddress::GetScope() const [member function] - cls.add_method('GetScope', - 'ns3::Ipv6InterfaceAddress::Scope_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e ns3::Ipv6InterfaceAddress::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Ipv6InterfaceAddress::State_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] - cls.add_method('SetAddress', - 'void', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetNsDadUid(uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('uint32_t', 'uid')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetScope(ns3::Ipv6InterfaceAddress::Scope_e scope) [member function] - cls.add_method('SetScope', - 'void', - [param('ns3::Ipv6InterfaceAddress::Scope_e', 'scope')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetState(ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - return - def register_Ns3Ipv6Prefix_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() @@ -2517,6 +2455,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -2800,61 +2746,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -2862,6 +2764,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2902,6 +2806,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3AodvHelper_methods(root_module, cls): @@ -3156,106 +3062,6 @@ [param('uint8_t', 'ttl')]) return -def register_Ns3Ipv6Header_methods(root_module, cls): - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header(ns3::Ipv6Header const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Header const &', 'arg0')]) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header() [constructor] - cls.add_constructor([]) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::Deserialize(ns3::Buffer::Iterator start) [member function] - cls.add_method('Deserialize', - 'uint32_t', - [param('ns3::Buffer::Iterator', 'start')], - is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetDestinationAddress() const [member function] - cls.add_method('GetDestinationAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetFlowLabel() const [member function] - cls.add_method('GetFlowLabel', - 'uint32_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetHopLimit() const [member function] - cls.add_method('GetHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): ns3::TypeId ns3::Ipv6Header::GetInstanceTypeId() const [member function] - cls.add_method('GetInstanceTypeId', - 'ns3::TypeId', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetNextHeader() const [member function] - cls.add_method('GetNextHeader', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint16_t ns3::Ipv6Header::GetPayloadLength() const [member function] - cls.add_method('GetPayloadLength', - 'uint16_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetSerializedSize() const [member function] - cls.add_method('GetSerializedSize', - 'uint32_t', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetSourceAddress() const [member function] - cls.add_method('GetSourceAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetTrafficClass() const [member function] - cls.add_method('GetTrafficClass', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): static ns3::TypeId ns3::Ipv6Header::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Print(std::ostream & os) const [member function] - cls.add_method('Print', - 'void', - [param('std::ostream &', 'os')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Serialize(ns3::Buffer::Iterator start) const [member function] - cls.add_method('Serialize', - 'void', - [param('ns3::Buffer::Iterator', 'start')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetDestinationAddress(ns3::Ipv6Address dst) [member function] - cls.add_method('SetDestinationAddress', - 'void', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetFlowLabel(uint32_t flow) [member function] - cls.add_method('SetFlowLabel', - 'void', - [param('uint32_t', 'flow')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetHopLimit(uint8_t limit) [member function] - cls.add_method('SetHopLimit', - 'void', - [param('uint8_t', 'limit')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetNextHeader(uint8_t next) [member function] - cls.add_method('SetNextHeader', - 'void', - [param('uint8_t', 'next')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetPayloadLength(uint16_t len) [member function] - cls.add_method('SetPayloadLength', - 'void', - [param('uint16_t', 'len')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetSourceAddress(ns3::Ipv6Address src) [member function] - cls.add_method('SetSourceAddress', - 'void', - [param('ns3::Ipv6Address', 'src')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetTrafficClass(uint8_t traffic) [member function] - cls.add_method('SetTrafficClass', - 'void', - [param('uint8_t', 'traffic')]) - return - def register_Ns3Object_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::Object() [constructor] cls.add_constructor([]) @@ -4163,12 +3969,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -4194,6 +4002,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -5647,63 +5460,6 @@ is_virtual=True) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -6127,6 +5883,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -6460,151 +6221,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor] cls.add_constructor([]) @@ -7259,10 +6875,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): diff -Naur ns-3.19/src/aodv/bindings/modulegen__gcc_LP64.py ns-3.20/src/aodv/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/aodv/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.433636700 -0700 +++ ns-3.20/src/aodv/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.762996973 -0700 @@ -102,12 +102,6 @@ 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-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress [class] - module.add_class('Ipv6InterfaceAddress', import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e [enumeration] - module.add_enum('State_e', ['TENTATIVE', 'DEPRECATED', 'PREFERRED', 'PERMANENT', 'HOMEADDRESS', 'TENTATIVE_OPTIMISTIC', 'INVALID'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e [enumeration] - module.add_enum('Scope_e', ['HOST', 'LINKLOCAL', 'GLOBAL'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') ## 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] @@ -148,6 +142,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -168,6 +164,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## aodv-helper.h (module 'aodv'): ns3::AodvHelper [class] module.add_class('AodvHelper', parent=root_module['ns3::Ipv4RoutingHelper']) ## chunk.h (module 'network'): ns3::Chunk [class] @@ -180,10 +178,6 @@ module.add_enum('DscpType', ['DscpDefault', 'DSCP_CS1', 'DSCP_AF11', 'DSCP_AF12', 'DSCP_AF13', 'DSCP_CS2', 'DSCP_AF21', 'DSCP_AF22', 'DSCP_AF23', 'DSCP_CS3', 'DSCP_AF31', 'DSCP_AF32', 'DSCP_AF33', 'DSCP_CS4', 'DSCP_AF41', 'DSCP_AF42', 'DSCP_AF43', 'DSCP_CS5', 'DSCP_EF', 'DSCP_CS6', 'DSCP_CS7'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType [enumeration] module.add_enum('EcnType', ['ECN_NotECT', 'ECN_ECT1', 'ECN_ECT0', 'ECN_CE'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header [class] - module.add_class('Ipv6Header', import_from_module='ns.internet', parent=root_module['ns3::Header']) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::NextHeader_e [enumeration] - module.add_enum('NextHeader_e', ['IPV6_EXT_HOP_BY_HOP', 'IPV6_IPV4', 'IPV6_TCP', 'IPV6_UDP', 'IPV6_IPV6', 'IPV6_EXT_ROUTING', 'IPV6_EXT_FRAGMENTATION', 'IPV6_EXT_CONFIDENTIALITY', 'IPV6_EXT_AUTHENTIFICATION', 'IPV6_ICMPV6', 'IPV6_EXT_END', 'IPV6_EXT_DESTINATION', 'IPV6_SCTP', 'IPV6_EXT_MOBILITY', 'IPV6_UDP_LITE'], outer_class=root_module['ns3::Ipv6Header'], import_from_module='ns.internet') ## 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] @@ -296,10 +290,6 @@ module.add_class('ExponentialRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::GammaRandomVariable [class] module.add_class('GammaRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -326,8 +316,6 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -370,8 +358,8 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv4-list-routing.h (module 'internet'): ns3::Ipv4ListRouting [class] module.add_class('Ipv4ListRouting', import_from_module='ns.internet', parent=root_module['ns3::Ipv4RoutingProtocol']) - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') ## Register a nested module for the namespace FatalImpl @@ -400,12 +388,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') ## Register a nested module for the namespace Function @@ -460,8 +448,8 @@ module.add_class('RreqHeader', parent=root_module['ns3::Header']) ## aodv-packet.h (module 'aodv'): ns3::aodv::TypeHeader [class] module.add_class('TypeHeader', parent=root_module['ns3::Header']) - module.add_container('std::map< ns3::Ipv4Address, unsigned int >', ('ns3::Ipv4Address', 'unsigned int'), container_type='map') - module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type='vector') + module.add_container('std::map< ns3::Ipv4Address, unsigned int >', ('ns3::Ipv4Address', 'unsigned int'), container_type=u'map') + module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type=u'vector') def register_methods(root_module): register_Ns3Address_methods(root_module, root_module['ns3::Address']) @@ -491,7 +479,6 @@ register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) register_Ns3Ipv4RoutingHelper_methods(root_module, root_module['ns3::Ipv4RoutingHelper']) register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address']) - register_Ns3Ipv6InterfaceAddress_methods(root_module, root_module['ns3::Ipv6InterfaceAddress']) register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix']) register_Ns3Mac48Address_methods(root_module, root_module['ns3::Mac48Address']) register_Ns3NodeContainer_methods(root_module, root_module['ns3::NodeContainer']) @@ -509,6 +496,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) @@ -520,7 +508,6 @@ register_Ns3Chunk_methods(root_module, root_module['ns3::Chunk']) register_Ns3Header_methods(root_module, root_module['ns3::Header']) register_Ns3Ipv4Header_methods(root_module, root_module['ns3::Ipv4Header']) - register_Ns3Ipv6Header_methods(root_module, root_module['ns3::Ipv6Header']) register_Ns3Object_methods(root_module, root_module['ns3::Object']) register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3RandomVariableStream_methods(root_module, root_module['ns3::RandomVariableStream']) @@ -571,7 +558,6 @@ register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) register_Ns3ExponentialRandomVariable_methods(root_module, root_module['ns3::ExponentialRandomVariable']) register_Ns3GammaRandomVariable_methods(root_module, root_module['ns3::GammaRandomVariable']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -584,7 +570,6 @@ register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3LogNormalRandomVariable_methods(root_module, root_module['ns3::LogNormalRandomVariable']) @@ -871,6 +856,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -883,6 +872,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1781,61 +1774,6 @@ [param('uint8_t *', 'address')]) return -def register_Ns3Ipv6InterfaceAddress_methods(root_module, cls): - cls.add_binary_comparison_operator('!=') - cls.add_output_stream_operator() - cls.add_binary_comparison_operator('==') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress() [constructor] - cls.add_constructor([]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address, ns3::Ipv6Prefix prefix) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'prefix')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6InterfaceAddress const & o) [copy constructor] - cls.add_constructor([param('ns3::Ipv6InterfaceAddress const &', 'o')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6InterfaceAddress::GetAddress() const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): uint32_t ns3::Ipv6InterfaceAddress::GetNsDadUid() const [member function] - cls.add_method('GetNsDadUid', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Prefix ns3::Ipv6InterfaceAddress::GetPrefix() const [member function] - cls.add_method('GetPrefix', - 'ns3::Ipv6Prefix', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e ns3::Ipv6InterfaceAddress::GetScope() const [member function] - cls.add_method('GetScope', - 'ns3::Ipv6InterfaceAddress::Scope_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e ns3::Ipv6InterfaceAddress::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Ipv6InterfaceAddress::State_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] - cls.add_method('SetAddress', - 'void', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetNsDadUid(uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('uint32_t', 'uid')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetScope(ns3::Ipv6InterfaceAddress::Scope_e scope) [member function] - cls.add_method('SetScope', - 'void', - [param('ns3::Ipv6InterfaceAddress::Scope_e', 'scope')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetState(ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - return - def register_Ns3Ipv6Prefix_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() @@ -2517,6 +2455,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -2800,61 +2746,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -2862,6 +2764,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2902,6 +2806,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3AodvHelper_methods(root_module, cls): @@ -3156,106 +3062,6 @@ [param('uint8_t', 'ttl')]) return -def register_Ns3Ipv6Header_methods(root_module, cls): - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header(ns3::Ipv6Header const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Header const &', 'arg0')]) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header() [constructor] - cls.add_constructor([]) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::Deserialize(ns3::Buffer::Iterator start) [member function] - cls.add_method('Deserialize', - 'uint32_t', - [param('ns3::Buffer::Iterator', 'start')], - is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetDestinationAddress() const [member function] - cls.add_method('GetDestinationAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetFlowLabel() const [member function] - cls.add_method('GetFlowLabel', - 'uint32_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetHopLimit() const [member function] - cls.add_method('GetHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): ns3::TypeId ns3::Ipv6Header::GetInstanceTypeId() const [member function] - cls.add_method('GetInstanceTypeId', - 'ns3::TypeId', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetNextHeader() const [member function] - cls.add_method('GetNextHeader', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint16_t ns3::Ipv6Header::GetPayloadLength() const [member function] - cls.add_method('GetPayloadLength', - 'uint16_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetSerializedSize() const [member function] - cls.add_method('GetSerializedSize', - 'uint32_t', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetSourceAddress() const [member function] - cls.add_method('GetSourceAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetTrafficClass() const [member function] - cls.add_method('GetTrafficClass', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): static ns3::TypeId ns3::Ipv6Header::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Print(std::ostream & os) const [member function] - cls.add_method('Print', - 'void', - [param('std::ostream &', 'os')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Serialize(ns3::Buffer::Iterator start) const [member function] - cls.add_method('Serialize', - 'void', - [param('ns3::Buffer::Iterator', 'start')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetDestinationAddress(ns3::Ipv6Address dst) [member function] - cls.add_method('SetDestinationAddress', - 'void', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetFlowLabel(uint32_t flow) [member function] - cls.add_method('SetFlowLabel', - 'void', - [param('uint32_t', 'flow')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetHopLimit(uint8_t limit) [member function] - cls.add_method('SetHopLimit', - 'void', - [param('uint8_t', 'limit')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetNextHeader(uint8_t next) [member function] - cls.add_method('SetNextHeader', - 'void', - [param('uint8_t', 'next')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetPayloadLength(uint16_t len) [member function] - cls.add_method('SetPayloadLength', - 'void', - [param('uint16_t', 'len')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetSourceAddress(ns3::Ipv6Address src) [member function] - cls.add_method('SetSourceAddress', - 'void', - [param('ns3::Ipv6Address', 'src')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetTrafficClass(uint8_t traffic) [member function] - cls.add_method('SetTrafficClass', - 'void', - [param('uint8_t', 'traffic')]) - return - def register_Ns3Object_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::Object() [constructor] cls.add_constructor([]) @@ -4163,12 +3969,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -4194,6 +4002,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -5647,63 +5460,6 @@ is_virtual=True) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -6127,6 +5883,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -6460,151 +6221,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor] cls.add_constructor([]) @@ -7259,10 +6875,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): diff -Naur ns-3.19/src/aodv/model/aodv-packet.cc ns-3.20/src/aodv/model/aodv-packet.cc --- ns-3.19/src/aodv/model/aodv-packet.cc 2014-06-17 10:34:00.438636662 -0700 +++ ns-3.20/src/aodv/model/aodv-packet.cc 2014-06-17 10:33:13.767996934 -0700 @@ -34,8 +34,7 @@ namespace aodv { -NS_OBJECT_ENSURE_REGISTERED (TypeHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (TypeHeader); TypeHeader::TypeHeader (MessageType t) : m_type (t), m_valid (true) @@ -147,8 +146,7 @@ { } -NS_OBJECT_ENSURE_REGISTERED (RreqHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (RreqHeader); TypeId RreqHeader::GetTypeId () @@ -287,8 +285,7 @@ m_lifeTime = uint32_t (lifeTime.GetMilliSeconds ()); } -NS_OBJECT_ENSURE_REGISTERED (RrepHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (RrepHeader); TypeId RrepHeader::GetTypeId () @@ -430,8 +427,7 @@ { } -NS_OBJECT_ENSURE_REGISTERED (RrepAckHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (RrepAckHeader); TypeId RrepAckHeader::GetTypeId () @@ -497,8 +493,7 @@ { } -NS_OBJECT_ENSURE_REGISTERED (RerrHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (RerrHeader); TypeId RerrHeader::GetTypeId () diff -Naur ns-3.19/src/aodv/model/aodv-routing-protocol.cc ns-3.20/src/aodv/model/aodv-routing-protocol.cc --- ns-3.19/src/aodv/model/aodv-routing-protocol.cc 2014-06-17 10:34:00.439636654 -0700 +++ ns-3.20/src/aodv/model/aodv-routing-protocol.cc 2014-06-17 10:33:13.769996919 -0700 @@ -48,8 +48,7 @@ { namespace aodv { -NS_OBJECT_ENSURE_REGISTERED (RoutingProtocol) - ; +NS_OBJECT_ENSURE_REGISTERED (RoutingProtocol); /// UDP Port for AODV control traffic const uint32_t RoutingProtocol::AODV_PORT = 654; @@ -112,8 +111,7 @@ int32_t m_oif; }; -NS_OBJECT_ENSURE_REGISTERED (DeferredRouteOutputTag) - ; +NS_OBJECT_ENSURE_REGISTERED (DeferredRouteOutputTag); //----------------------------------------------------------------------------- @@ -1746,7 +1744,7 @@ { destination = iface.GetBroadcast (); } - socket->SendTo (packet, 0, InetSocketAddress (destination, AODV_PORT)); + socket->SendTo (packet->Copy (), 0, InetSocketAddress (destination, AODV_PORT)); } } } diff -Naur ns-3.19/src/aodv/test/aodv-chain-regression-test-0-0.pcap ns-3.20/src/aodv/test/aodv-chain-regression-test-0-0.pcap --- ns-3.19/src/aodv/test/aodv-chain-regression-test-0-0.pcap 2014-06-17 10:34:00.442636631 -0700 +++ ns-3.20/src/aodv/test/aodv-chain-regression-test-0-0.pcap 2014-06-17 10:33:13.772996895 -0700 @@ -1,4 +1,4 @@ -òiXXE4 +òiXXE4   (  @@ -22,73 +22,74 @@  ԀAxx<0ET@  -5Ԁ @@P +6Ԁ +@@P  Ԁ xx<`ET?  -HTT@E0 +HTT@E0    -Ԁxx<pET= +Ԁxx<pET=  -Ԁxx<PET@ +Ԁxx<PET@  -Ԁxx<ET? +Ԁxx<ET?  -Ԁpxx<ET= +Ԁpxx<ET=  Ԁ((TTE0    -TT`E0 +TT`E0    -xx<pET@ +xx<pET@  -Ԁxx<ET? +Ԁxx<ET?  -Ԁpxx<ET= +Ԁpxx<ET=  ԀTTE0    - TTE0 + TTE0    -xx<ET@ +xx<ET@  -Ԁxx<ET? +Ԁxx<ET?  -Ԁxx<ET= +Ԁxx<ET=  ԀTTE0    -TTE0 +TTE0    -xx<ET @ +xx<ET@  -Ԁxx<ET ? +Ԁxx<ET?  -xx<ET ? +xx<ET?  -`xx<ET ? +`xx<ET?  -xx<ET ? +xx<ET?  -xx<ET ? +xx<ET?  -!xx<ET ? +!xx<ET?  -*xx<ET ? +*xx<ET?  +TT E0  @@ -98,12 +99,11 @@    -FԀ TTE0 - +FԀ TTE0    -XXE4  +XXE4      @@ -115,7 +115,7 @@      -(#TTE0 +(#TTE0    @@ -123,7 +123,7 @@    -TTE0 +TTE0    @@ -132,7 +132,7 @@    -'X XXE4 +'X XXE4       @@ -140,7 +140,8 @@      -@ TTE0 +@ TTE0 +    @@ -148,7 +149,7 @@    - < TT E0 + < TT E0     diff -Naur ns-3.19/src/aodv/test/aodv-chain-regression-test-1-0.pcap ns-3.20/src/aodv/test/aodv-chain-regression-test-1-0.pcap --- ns-3.19/src/aodv/test/aodv-chain-regression-test-1-0.pcap 2014-06-17 10:34:00.443636623 -0700 +++ ns-3.20/src/aodv/test/aodv-chain-regression-test-1-0.pcap 2014-06-17 10:33:13.773996888 -0700 @@ -1,4 +1,4 @@ -òi`XXE4 +òi`XXE4   (  @@ -22,9 +22,9 @@  +Ԁ?@@   -A@@< +B@@<  -QԀբTT<0E0 +RԀ֢TT<0E0    @@ -40,21 +40,21 @@  ԀTxx<`ET?  -IԀԀ"xx<`ET> +IԀԀ#xx<`ET>  -Ԁxx<pET> +Ԁxx<pET>  -Ԁxx<pET= +Ԁxx<pET=  -Ԁxx<PET@ +Ԁxx<PET@  -Ԁxx<ET? +Ԁxx<ET?  - Ԁxx<ET> + Ԁxx<ET>  -ԀYxx<ET> +ԀYxx<ET>  -iԀxx<ET= +iԀxx<ET=  Ԁ'TTE0  @@ -64,19 +64,19 @@    -@TT`E0 +@TT`E0    -xx<pET@ +xx<pET@  -Ԁxx<ET? +Ԁxx<ET?  - Ԁxx<ET> + Ԁxx<ET>  -ԀYxx<ET> +ԀYxx<ET>  -iԀxx<ET= +iԀxx<ET=  ԀTTE0  @@ -87,19 +87,19 @@   ( -TTE0 +TTE0    -xx<ET@ +xx<ET@  -Ԁxx<ET? +Ԁxx<ET?  - Ԁxx<ET> + Ԁxx<ET>  -Ԁxx<ET> +Ԁxx<ET>  -Ԁxx<ET= +Ԁxx<ET=   ԀTTE0  @@ -109,25 +109,25 @@    -TTE0 +TTE0    -xx<ET @ +xx<ET@  -Ԁxx<ET ? +Ԁxx<ET?  -Vxx<ET ? +Vxx<ET?  -xx<ET ? +xx<ET?  -1xx<ET ? +1xx<ET?  -6xx<ET ? +6xx<ET?  - xx<ET ? + xx<ET?  -)xx<ET ? +)xx<ET?  N+TT E0  @@ -138,12 +138,11 @@   FԀ( -TTE0 - +TTE0    -XXE4  +XXE4      @@ -155,7 +154,7 @@      -#TTE0 +#TTE0    @@ -163,7 +162,7 @@    -XTTE0 +XTTE0    @@ -172,7 +171,7 @@    -X XXE4 +X XXE4       @@ -180,7 +179,8 @@      -@A TTE0 +@A TTE0 +    @@ -188,7 +188,7 @@    - X= TT E0 + X= TT E0     diff -Naur ns-3.19/src/aodv/test/aodv-chain-regression-test-2-0.pcap ns-3.20/src/aodv/test/aodv-chain-regression-test-2-0.pcap --- ns-3.19/src/aodv/test/aodv-chain-regression-test-2-0.pcap 2014-06-17 10:34:00.443636623 -0700 +++ ns-3.20/src/aodv/test/aodv-chain-regression-test-2-0.pcap 2014-06-17 10:33:13.773996888 -0700 @@ -20,11 +20,11 @@  މ@@<  -ԀaTT<@E0 +ԀbTT<@E0    -+qԀI@@  ++rԀJ@@   L@@<  @@ -40,9 +40,10 @@  +@@<@  -5Ԁ @@P +6Ԁ +@@P  -+@@<@ +,@@<@  Ԁ xx<`ET?  @@ -56,23 +57,23 @@  Ԁxx<pET=  -OԀxx<ET? +PԀxx<ET?  -Ԁxx<pET> +Ԁxx<pET>  -Ԁxx<pET= +Ԁxx<pET=  -Ԁxx<ET? +Ԁxx<ET?  -Ԁ,xx<ET> +Ԁ,xx<ET>  -!Ԁxx<ET= +!Ԁxx<ET=  -NԀCxx<ET? +NԀCxx<ET?  -SԀxx<ET> +SԀxx<ET>  -Ԁpxx<ET= +Ԁpxx<ET=  ((TTE0  @@ -86,17 +87,17 @@    -Ԁxx<ET? +Ԁxx<ET?  -Ԁ,xx<ET> +Ԁ,xx<ET>  -!Ԁxx<ET= +!Ԁxx<ET=  -NԀCxx<ET? +NԀCxx<ET?  -SԀxx<ET> +SԀxx<ET>  -Ԁpxx<ET= +Ԁpxx<ET=  TTE0  @@ -110,17 +111,17 @@    -Ԁxx<ET? +Ԁxx<ET?  -Ԁ,xx<ET> +Ԁ,xx<ET>  -!Ԁxx<ET= +!Ԁxx<ET=  -NԀxx<ET? +NԀxx<ET?  -Ԁxx<ET> +Ԁxx<ET>  -Ԁxx<ET= +Ԁxx<ET=  TTE0  diff -Naur ns-3.19/src/aodv/test/aodv-chain-regression-test-3-0.pcap ns-3.20/src/aodv/test/aodv-chain-regression-test-3-0.pcap --- ns-3.19/src/aodv/test/aodv-chain-regression-test-3-0.pcap 2014-06-17 10:34:00.444636615 -0700 +++ ns-3.20/src/aodv/test/aodv-chain-regression-test-3-0.pcap 2014-06-17 10:33:13.774996880 -0700 @@ -10,9 +10,9 @@    -s@@ +s@@  -t@@<  +t@@<   tԀuTT<E0  @@ -38,33 +38,33 @@  '@@<P  -Ԁ"xx<`ET> +Ԁ#xx<`ET>  -2Ԁ@@` +3Ԁ@@`  @@<   ԀDxx<pET=  -9Ԁxx<0ET@ +9Ԁxx<0ET@  -#Ԁxx<ET? +#Ԁxx<ET?  -Ԁxx<pET> +Ԁxx<pET>  -TT@E0 +TT@E0    - Ԁxx<ET> + Ԁxx<ET>  -ԀCxx<ET= +ԀCxx<ET=  -7Ԁxx<PET@ +8Ԁxx<PET@  -!Ԁxx<ET? +"Ԁxx<ET?  -ԀYxx<ET> +ԀYxx<ET>  0TTE0  @@ -74,19 +74,19 @@    -XTT`E0 +XTT`E0    - Ԁxx<ET> + Ԁxx<ET>  -ԀCxx<ET= +ԀCxx<ET=  -7Ԁxx<pET@ +8Ԁxx<pET@  -!Ԁxx<ET? +"Ԁxx<ET?  -ԀYxx<ET> +ԀYxx<ET>   TTE0  @@ -96,19 +96,19 @@    -TTE0 +TTE0    - Ԁxx<ET> + Ԁxx<ET>  -ԀCxx<ET= +ԀCxx<ET=  -7Ԁxx<ET@ +8Ԁxx<ET@  -!Ԁxx<ET? +"Ԁxx<ET?  -Ԁxx<ET> +Ԁxx<ET>  DTTE0  @@ -118,7 +118,7 @@    -TTE0 +TTE0    @@ -126,7 +126,7 @@    -TTE0  +TTE0    @@ -134,8 +134,7 @@    -TTE0 - +TTE0    @@ -143,11 +142,11 @@    -z TT<PE0  +{ TT<PE0     -? ԀTTE0  +? ԀTTE0    @@ -156,7 +155,7 @@    -TTE0  +TTE0    @@ -164,7 +163,7 @@    -TTE0  +TTE0     @@ -172,7 +171,8 @@    - XTTE0 + XTTE0 +    diff -Naur ns-3.19/src/aodv/test/aodv-chain-regression-test-4-0.pcap ns-3.20/src/aodv/test/aodv-chain-regression-test-4-0.pcap --- ns-3.19/src/aodv/test/aodv-chain-regression-test-4-0.pcap 2014-06-17 10:34:00.444636615 -0700 +++ ns-3.20/src/aodv/test/aodv-chain-regression-test-4-0.pcap 2014-06-17 10:33:13.774996880 -0700 @@ -16,7 +16,7 @@  +vԀ@@0  -ԀaTT<@E0 +ԀbTT<@E0    @@ -28,53 +28,53 @@  Ԁxx<pET=  - Ԁ[xx<0ET@ + Ԁ[xx<0ET@  -OԀxx<ET? +PԀxx<ET?  -XTT@E0 +XTT@E0    -!Ԁxx<ET= +!Ԁxx<ET=  - ԀYxx<PET@ + ԀYxx<PET@  -NԀCxx<ET? +NԀCxx<ET?  @TTE0    -TT`E0 +TT`E0    -!Ԁxx<ET= +!Ԁxx<ET=  - ԀYxx<pET@ + ԀYxx<pET@  -NԀCxx<ET? +NԀCxx<ET?  HTTE0    -TTE0 +TTE0    -!Ԁxx<ET= +!Ԁxx<ET=  - ԀYxx<ET@ + ԀYxx<ET@  -NԀxx<ET? +NԀxx<ET?  ATTTE0    - TTE0 + TTE0    @@ -82,7 +82,7 @@    - TTE0  + TTE0    @@ -90,8 +90,7 @@    -TTE0 - +TTE0    @@ -103,7 +102,7 @@    - Ԁ@TTE0  + Ԁ@TTE0    @@ -112,7 +111,7 @@    -XTTE0  +XTTE0    @@ -120,7 +119,7 @@    -TTE0  +TTE0     @@ -128,7 +127,8 @@    - TTE0 + TTE0 +    diff -Naur ns-3.19/src/aodv/test/aodv-regression.cc ns-3.20/src/aodv/test/aodv-regression.cc --- ns-3.19/src/aodv/test/aodv-regression.cc 2014-06-17 10:34:00.445636607 -0700 +++ ns-3.20/src/aodv/test/aodv-regression.cc 2014-06-17 10:33:13.775996872 -0700 @@ -44,8 +44,8 @@ #include "ns3/rng-seed-manager.h" #include -namespace ns3 { -namespace aodv { +using namespace ns3; +using namespace aodv; //----------------------------------------------------------------------------- // Test suite //----------------------------------------------------------------------------- @@ -192,6 +192,3 @@ NS_PCAP_TEST_EXPECT_EQ (m_prefix << "-" << i << "-0.pcap"); } } - -} -} diff -Naur ns-3.19/src/aodv/test/aodv-regression.h ns-3.20/src/aodv/test/aodv-regression.h --- ns-3.19/src/aodv/test/aodv-regression.h 2014-06-17 10:34:00.445636607 -0700 +++ ns-3.20/src/aodv/test/aodv-regression.h 2014-06-17 10:33:13.776996865 -0700 @@ -25,8 +25,7 @@ #include "ns3/nstime.h" #include "ns3/node-container.h" -namespace ns3 { -namespace aodv { +using namespace ns3; /** * \ingroup aodv @@ -189,7 +188,4 @@ void DoRun (); }; -} -} - #endif /* AODV_REGRESSION_H */ diff -Naur ns-3.19/src/aodv/test/bug-606-test-0-0.pcap ns-3.20/src/aodv/test/bug-606-test-0-0.pcap --- ns-3.19/src/aodv/test/bug-606-test-0-0.pcap 2014-06-17 10:34:00.447636592 -0700 +++ ns-3.20/src/aodv/test/bug-606-test-0-0.pcap 2014-06-17 10:33:13.777996857 -0700 @@ -1,4 +1,4 @@ -òiXXE4 +òiXXE4   (  @@ -18,11 +18,11 @@  +KԀ1W@@   -3X@@<@ +4X@@<@  -CXԀXxx<0ET@ +DXԀXxx<0ET@  -YԀHqTT@E0 +YԀHqTT@E0    @@ -30,19 +30,19 @@  #zԀW{xx<`ET?  -|Ԁ}xx<pET? +|Ԁ}xx<pET?  -}Ԁxx<PET@ +}Ԁxx<PET@  -Ԁxx<ET? +Ԁxx<ET?  -!Ԁ1xx<ET? +!Ԁ1xx<ET?  AԀTTE0    -HqTT`E0 +HqTT`E0    @@ -50,7 +50,7 @@  *$@@<  -:$Ԁ$xx<ET@ +:$Ԁ$xx<ET@  %Ԁ/TTE0  @@ -58,68 +58,68 @@  fE@@  -5FԀGxx<ET? +5FԀGxx<ET?  -RTTE0 +RTTE0    \@@<  -]Ԁ|@@ +]Ԁ|@@  -}@@< +}@@<  -}Ԁ~xx<ET? +}Ԁ~xx<ET?  -~Ԁxx<ET@ +~Ԁxx<ET@  -Ԁxx< ET? +Ԁxx< ET?  -!Ԁxx<0ET? +!Ԁxx<0ET?  ԀTT@E0    -eTTE0 +eTTE0    (#@@  -0uTTE0 - +0uTTE0    @@  -UTTE0  +UTTE0    @@  -HqTT E0 +HqTT E0    @@0  -XX@E4 +XX@E4      -'TTPE0 +'TTPE0     - (#TT`E0 + (#TT`E0 +    - @ XXpE4 + @ XXpE4       diff -Naur ns-3.19/src/aodv/test/bug-606-test-1-0.pcap ns-3.20/src/aodv/test/bug-606-test-1-0.pcap --- ns-3.19/src/aodv/test/bug-606-test-1-0.pcap 2014-06-17 10:34:00.447636592 -0700 +++ ns-3.20/src/aodv/test/bug-606-test-1-0.pcap 2014-06-17 10:33:13.778996849 -0700 @@ -1,4 +1,4 @@ -òi`XXE4 +òi`XXE4   (  @@ -10,11 +10,11 @@  (@@<  -o)Ԁ*TT<E0 +p)Ԁ*TT<E0    -+)*ԀYI@@  ++**ԀZI@@   \J@@<  @@ -28,7 +28,7 @@  pXԀYxx<0ET@  -YԀqTT@E0 +YԀqTT@E0    @@ -38,31 +38,31 @@  yԀzxx<`ET?  -{Ԁ|xx<0ET@ +{Ԁ|xx<0ET@  -|Ԁ%}xx<pET? +|Ԁ&}xx<pET?  -~Ԁ(TT@E0 +~Ԁ(TT@E0    -xx<PET@ +xx<PET@  -Ԁxx<ET? +Ԁxx<ET?  - Ԁxx<PET@ + Ԁxx<PET@  -Ԁyxx<ET? +Ԁyxx<ET?  -mԀ0TTE0 +nԀ0TTE0    -qTT`E0 +qTT`E0    -8TT`E0 +8TT`E0    @@ -70,7 +70,7 @@  #@@<  -g$Ԁ%xx<ET@ +g$Ԁ%xx<ET@  %Ԁp/TTE0  @@ -78,11 +78,11 @@  D@@  -E@@<p +E@@<p  -FԀFxx<ET? + FԀFxx<ET?  -GԀRTTE0 +GԀRTTE0    @@ -90,35 +90,35 @@  [@@<  -T\ԀI]xx<ET@ +T\ԀI]xx<ET@  Y]Ԁ|@@  }@@<  -}Ԁ2~xx<ET? +}Ԁ2~xx<ET?  -'ԀTTE0 +'ԀTTE0    -xx<ET@ +xx<ET@  -Ԁxx< ET? +Ԁxx< ET?  - Ԁxx<ET@ + Ԁxx<ET@  -ԀLxx<0ET? +ԀLxx<0ET?  -@Ԁ0TT@E0 +AԀ0TT@E0    -fTTE0 +fTTE0    -TTE0 +TTE0    diff -Naur ns-3.19/src/aodv/test/bug-606-test-2-0.pcap ns-3.20/src/aodv/test/bug-606-test-2-0.pcap --- ns-3.19/src/aodv/test/bug-606-test-2-0.pcap 2014-06-17 10:34:00.448636584 -0700 +++ ns-3.20/src/aodv/test/bug-606-test-2-0.pcap 2014-06-17 10:33:13.778996849 -0700 @@ -16,7 +16,7 @@    -+3X@@<@ ++4X@@<@  YԀTy@@P  @@ -24,25 +24,25 @@  #zԀW{xx<`ET?  -g{Ԁ{xx<0ET@ +g{Ԁ{xx<0ET@  -|Ԁ}xx<pET? +|Ԁ}xx<pET?  -TT@E0 +TT@E0    -Ԁxx<ET? +Ԁxx<ET?  -Ԁ,xx<PET@ +Ԁ,xx<PET@  -!Ԁ1xx<ET? +!Ԁ1xx<ET?  TTE0    -TT`E0 +TT`E0    @@ -56,58 +56,58 @@  E@@<p  -5FԀGxx<ET? +5FԀGxx<ET?  GԀ[@@  \@@<  -(\Ԁ\xx<ET@ +(\Ԁ\xx<ET@  -]Ԁ|@@ +]Ԁ|@@  -}Ԁ~xx<ET? +}Ԁ~xx<ET?  -TTE0 +TTE0    -Ԁxx< ET? +Ԁxx< ET?  -Ԁ,xx<ET@ +Ԁ,xx<ET@  -!Ԁxx<0ET? +!Ԁxx<0ET?  TT@E0    -pTTE0 +pTTE0    -ȯTTE0  +ȯTTE0    -@TTE0 - +@TTE0    -TTE0  +TTE0    -TTE0  +TTE0    -XTTE0  +XTTE0     - @TT E0 + @TT E0 +    diff -Naur ns-3.19/src/aodv/test/bug-772.cc ns-3.20/src/aodv/test/bug-772.cc --- ns-3.19/src/aodv/test/bug-772.cc 2014-06-17 10:34:00.448636584 -0700 +++ ns-3.20/src/aodv/test/bug-772.cc 2014-06-17 10:33:13.779996841 -0700 @@ -48,8 +48,7 @@ #include "ns3/pcap-test.h" #include -namespace ns3 { -namespace aodv { +using namespace ns3; //----------------------------------------------------------------------------- // UdpChainTest @@ -146,7 +145,7 @@ uint16_t port = 9; // Discard port (RFC 863) OnOffHelper onoff (m_proto, Address (InetSocketAddress (interfaces.GetAddress (m_size-1), port))); onoff.SetConstantRate (DataRate (64000)); - onoff.SetAttribute ("PacketSize", UintegerValue (1200)); + onoff.SetAttribute ("PacketSize", UintegerValue (1000)); ApplicationContainer app = onoff.Install (m_nodes->Get (0)); app.Start (Seconds (1.0)); app.Stop (m_time); @@ -167,6 +166,3 @@ NS_PCAP_TEST_EXPECT_EQ(m_prefix << "-" << i << "-0.pcap"); } } - -} -} diff -Naur ns-3.19/src/aodv/test/bug-772.h ns-3.20/src/aodv/test/bug-772.h --- ns-3.19/src/aodv/test/bug-772.h 2014-06-17 10:34:00.449636577 -0700 +++ ns-3.20/src/aodv/test/bug-772.h 2014-06-17 10:33:13.779996841 -0700 @@ -25,8 +25,7 @@ #include "ns3/nstime.h" #include "ns3/node-container.h" -namespace ns3 { -namespace aodv { +using namespace ns3; /** * \ingroup aodv @@ -74,7 +73,4 @@ void DoRun (); }; -} -} - #endif /* BUG_772_H */ diff -Naur ns-3.19/src/aodv/test/tcp-chain-test-0-0.pcap ns-3.20/src/aodv/test/tcp-chain-test-0-0.pcap --- ns-3.19/src/aodv/test/tcp-chain-test-0-0.pcap 2014-06-17 10:34:00.451636561 -0700 +++ ns-3.20/src/aodv/test/tcp-chain-test-0-0.pcap 2014-06-17 10:33:13.782996818 -0700 @@ -6,7 +6,7 @@    -@XXE4 +@XXE4   (  @@ -18,9 +18,9 @@ G(@@<   -)Ԁ-@@0 +)Ԁ-@@0  --@@<  +-@@<   .Ԁ/TT<@E0  @@ -31,270 +31,307 @@  S@@<P  -TԀVTLL<@E(@ +TԀVTLL<@E(@    PUԀ/Y@@`  -YԀZLL<pE(? +YԀZLL<pE(?   - PԀ+LL<E(8 + PԀ+LL<E(8  - P;ԀLL<PE(@ + P;ԀLL<PE(@   - PFԀLL<E(? + PFԀLL<E(?   - PIdd<`E@@ + PHdd<`E@@   - PtMԀPdd<E@? + PԀ6dd<E@?   - PqԀarLL<E(8 + PԀLL<E(8  - PqrԀrdd<pE@@ + PԀ<pE@   - PCvԀydd<E@? + P<Ԁj<E?   - Pz<E@ + Pdd<E@@   - 1P|<E@ + PԀ~dd<E@?   - 1P<E@ + PԀ%LL<E(8 + + + P5Ԁ<E@   - 1PԀM<E? + PԀ<E?   - 1PXԀLL<E(8 + Pظdd<E@@ +  - - P -Ԁߓdd<E@@ + P\Ԁ~<E@   - PdԀΚdd<E@? + PB<E@   - PYdd<E@@ + PB<E@   - P_dd<E@@ + PgԀq<E?   - PԀNdd<E@? + P +ԀLL< E(8 + + +  PԀ dd<E@@   - PǦ<E @ + PԀdd<0E@?   - P,Ԁ<E ? + P~<E @   - PQԀLL< E(8 + P<E @ + + + PٯԀ<@E ? + + + PԀLL<PE(8  - PԀdd<E@ +  PԀh dd<E@ @   - aPTԀdd<0E@ + P ԀV dd<`E@ ?   - aPdd<E@ @ + P <E @   - yPadd<E@ @ + P) <E @   - yPԀPdd<@E@ ? + PN ԀX <pE ?   - yP<E @ + Pa Ԁ LL<E(8 + + + P Ԁq dd<E@ @   - Pc<E @ + P4u Ԁx dd<E@ ?   - P*<E @ + P)y <E @   - PԀ<PE ? + PD} <E @   - Pa<PE ? + Pi Ԁs <E ?   - PԀLL<`E(8 + P- Ԁϟ LL<E(8  -  yPԀ%ԀZ&LL<pE(8 - - - Pj&Ԁ' dd<E@ @ + Pߟ ԀY dd< E@@   - PD+ Ԁ. dd<E@ ? + qP|] Ԁ` dd<E@?   - Po/ dd<E@@ + qPa <0E@   - )P24 dd<E@@ + Pe <0E@   - )P7 Ԁ!; dd<E@? + Pi Ԁ l <E?   - )P; <E@ + P ԀB LL<E(8 + + + PR Ԁdd<@E@@   - APX> <E@ + YPԀ<PE@   - AP@ <E@ + qP<PE@   - AP*B ԀtC <E? + qP +<PE@   - APE <E? + qP ԀH<E?   - AP{ Ԁ{ LL<E(8 + qPTT`E0 + + + +;Ԁ3<LL<E(8  - AP{ Ԁq dd< E@@ + qPC<Ԁ?TT E0 + + + +@@p + +@@<0 + +Ԁdd<E@@   - P4u ԀVu dd<0E@@ + AP Ԁ<E@   - PAy dd<0E@@ + !YPԀ @@@ + +ԀOdd<PE@?   - P~ dd<0E@@ + AP <`E?   - P" Ԁ dd<E@? - + !YP@@<p + +EԀa@@ + +@@< + +0ԀYLL<E( 8  - PD <@E@ + + !YPiԀdd<E@@   - P Ԁ <E? + #)PԀ~dd<E@?   - P <E? + #)P-<E@   - P <E? + %AP$<E@   - P Ԁ LL<E( 8 + %APIԀS<E? +  - - P Ԁy Ԁ LL<E( + %AP Ԁ% LL<E( 8  - qP+ Ԁ dd<PE@@ + %AP5 Ԁظdd<E@@   - qP$ Ԁ dd<E@? + 'P\Ԁƿdd<E@?   - qPO dd<`E@@ + 'PH<E@   - P dd<`E@@ + ))P<E@   - PF Ԁ dd< E@? + ))PԀ<E?   - P <pE@ + ))PwԀLL<E( 8 + + + ))P)Ԁ dd<E@@   - P <pE@ + *PԀdd<E@?   - P <pE@ + *PϨ<E@   - P Ԁ] <0E? + -P)<E@   - P <0E? + -PNԀX<E?   - P ԀH LL<@E( 8 + -PԀqLL< E( 8  - PX ԀTTE0 + -PԀh dd<E@@  - - -?TTPE0 - - - -Odd<E@@ + + .P ԀV dd<0E@?   - !PԀ>dd<`E@? + .P < E@   - !Pdd<E@@ + 0PD < E@   - 9Pdd<E@@ + 0Pi Ԁs <@E?   - 9PGԀdd<pE@? + 0Pk Ԁ LL<PE( 8 + + + 0P Ԁq dd<0E@@   - 9Pr<E@ + 2P4u Ԁx dd<`E@?   - QP <E@ + 2P)y <@E@   - QPy<E@ + 4Pq} <@E@   - QPԀ(<E? + 4P Ԁ <pE?   - QP;<E? + 4P" ԀĨ LL<E(8 + + + 4PԨ ԀY dd<PE@@   - QP@@ - -@@< - -Ԁdd<E@@ + 6P|] Ԁ` dd<E@?   - PdԀh@@ - -7Ԁdd<E@? + 6Pa <`E@   - Pdd<E@@ + 8Pe <`E@   - PMԀdd<E@? + 8Ph Ԁk <E?   - P \ No newline at end of file + 8P Ԁ+ LL<E(8 + + + 8P; Ԁ \ No newline at end of file diff -Naur ns-3.19/src/aodv/test/tcp-chain-test-9-0.pcap ns-3.20/src/aodv/test/tcp-chain-test-9-0.pcap --- ns-3.19/src/aodv/test/tcp-chain-test-9-0.pcap 2014-06-17 10:34:00.452636553 -0700 +++ ns-3.20/src/aodv/test/tcp-chain-test-9-0.pcap 2014-06-17 10:33:13.784996803 -0700 @@ -30,7 +30,7 @@  _HԀ!@@<P   -4ԀDTT`E0 +5ԀDTT`E0    @@ -41,232 +41,330 @@   -8ԀڵLL<pE(8 +9Ԁ۵LL<pE(8   - PԀ2@@0 + PԀ3@@0   5@@<    -EԀLL<@E(@ +EԀLL<@E(@  - PPԀLL<E(? + PPԀLL<E(?  - PԀ2LL<E(8 + PԀ3LL<E(8   - PBԀgԀkjdd<E@8 + PCԀYԀdd<E@8   - P{jԀjLL<PE(@ + PԀ! LL<PE(@  - PkԀLlLL<E(? + P Ԁ +LL<E(?  - PԀ^dd<E@8 + PL+ԀV.<E8   - PnԀԀ<E8 + Pf.ԀԀ dd<E@8   - 1PԀ>LL<`E(@ + PԀiLL<`E(@  - PԀLL<E(? + P&ԀLL<E(?  - PԀ[dd<E@8 + PԀ<E8   - PkԀ;Ԁdd<E@8 + PԀԀSdd<E@8   - PԀLL<pE(@ + PcԀLL<pE(@  - PԀLL< E(? +  PnԀsLL< E(?  - PLL< E(? +  PLL< E(?  - PԀ:<0E 8 +  PLL< E(? + + +  PLL< E(? + + +  PNLL< E(? + + +  PLL< E(? + + +  PԀLL< E(? + + +  P<0E8   - PJԀԀKdd<@E@ -8 + PԀ1Ԁdd<@E@8   - aP[ԀLL<E(@ + PԀLL<E(@  -  yPfԀ>LL<PE(? +  PԀ|LL<PE(?  -  yPjLL<PE(? +  PLL<PE(?  -  yPLL<PE(? +  PLL<PE(?  -  yP{LL<PE(? +  PԀLL<PE(?  -  yPmLL<PE(? +  P<`E 8 +  - -  yPԀ=LL<PE(? + P)Ԁy Ԁ dd<pE@ +8 + + + P ԀA LL<E(@  -  yPԀLL<PE(? + P Ԁ LL<E(?  -  yPdd<`E@ 8 + P Ԁ <E 8   - yPԀ@<pE 8 + P# Ԁ Ԁ+ dd<E@ 8   - PPԀLL<E(@ + P; Ԁ LL<E(@ + + + PF Ԁ LL<E(?  - P[ԀE LL<E(? + P LL<E(?  - PD Ԁ;H dd<E@ 8 + P Ԁ <E 8   - PKH ԀIR ԀU dd<E@8 + P. Ԁ w Ԁsz dd<E@8   - )PU ԀV LL<E(@ + qPz Ԁz LL<E(@  - APV ԀW LL<E(? + P{ ԀK| LL<E(?  - APY LL<E(? + P8} LL<E(?  - APZ LL<E(? + P~ LL<E(?  - APk_ LL<E(? + Pn LL<E(?  - APd LL<E(? + P LL<E(?  - APr Ԁu LL<E(? + Pp Ԁ- LL<E(?  - APx <E8 + PǛ <E8   - AP%x Ԁ Ԁ+ dd<E@8 + Pכ ԀԀ{ dd<E@8   - P; Ԁ LL<E( @ + YP Ԁ LL<E(@ + + + qP!ԀA"LL<E(? + + + qP@#LL<E(? + + + qPz%LL<E(? + + + qP*LL<E(? + + + qP+LL<E(? + + + qP/LL<E(?  - PF Ԁ LL<E( ? + qP 7Ԁ:< E8 + + + qP&:Ԁ`TT0E0 + + + + `gTTE0  - PL Ԁ dd<E@8 + + + + +Ɨ@@<@ +  +Ԁ@@P + + +@@< + + + QԀQdd<`E@8 + + + APaԀԀ<pE8   - Pƶ Ԁ Ԁ <E8 + !YPԀ@@ + + + Ļ@@< +  + +ԻԀOLL<E( @ + + + !YP Ԁ@@ + +ԀLL<E( ? + + + !YPԀ dd<E@8   - P Ԁ` LL<E( + #)PԀiLL<E( @  - qP Ԁ LL<E( + %AP&ԀLL<E( +? + + + %APLL<E( +? + + + %APLL<E( +? + + + %APJLL<E( +? + + + %AP&ԀLL<E( ?  - qP Ԁ dd< E@8 + %APG <E8   - qP+ Ԁ ԀB dd<0E@8 + %APW ԀԀSdd<E@8   - PR Ԁ LL<E( @ + 'PcԀLL< E( @  - P] Ԁ LL<@E( ? + ))PnԀ|LL<E( ?  - P LL<@E( ? + ))PLL<E( ?  - P Ԁ> <PE8 + ))PԀ<E8   - PN Ԁ@@<` -  -Ԁ@@p - + ))PԀ1Ԁdd<E@8 +  -@@< + *PԀLL<0E( @  - - dԀdd<E@8 - + + -PԀjLL< E( ?  - !PԀ"LL<E( @ + + -PLL< E( ?  - 9PrLL<E( @ + -PELL< E( ?  - 9PLL<E( @ + -PLL< E( ?  - 9PԀ^@@ - -ԀCdd<E@8 + -PԀ'<0E8   - 9PSԀL Ԁ <E8 + -P7Ԁy Ԁ dd<@E@8   - QP Ԁ LL<E( @ + .P ԀA LL<@E( @  -  PԀ`TTE0 - - - - `gTTE0 + 0P Ԁ֫ LL<PE( ?  - - - + 0Pݴ Ԁ <`E8 +  -hԀfldd<E@8 + 0P Ԁ Ԁ+ dd<pE@8   - PvlԀփ@@  + 2P; Ԁ LL<PE(@  - - ل@@< -  + + 4PF Ԁ' LL<E(? + + + 4P LL<E(?  -ԀvLL<0E(@ + + 4P LL<E(? + + + 4PA LL<E(?  -  P3ԀԀDdd<E@8 + 4PC ԀM <E8   - PTԀLL<@E(@ + 4P] Ԁ w Ԁsz dd<E@8 + + + 6Pz Ԁz LL<`E(@ + + + 8P{ Ԁ| LL<E(?  -  P_Ԁ \ No newline at end of file + 8P ԀƇ <E8 + + + 8Pև Ԁ \ No newline at end of file diff -Naur ns-3.19/src/aodv/test/udp-chain-test-0-0.pcap ns-3.20/src/aodv/test/udp-chain-test-0-0.pcap --- ns-3.19/src/aodv/test/udp-chain-test-0-0.pcap 2014-06-17 10:34:00.453636546 -0700 +++ ns-3.20/src/aodv/test/udp-chain-test-0-0.pcap 2014-06-17 10:33:13.785996795 -0700 @@ -18,192 +18,211 @@    -YXX E4 +XX E4   (  -yXX +HXX E4   (  - @@< +eA@@< 0  -xԀ |@@ +BԀ J@@ @  -@@< +J@@< 0  -KԀ =TT< +KԀ LTT< PE0    - EMԀ - @@ @ + ^LԀ +eT@@ @  -@@< +hU@@< `  - Ԁ -w< - PE@ +xUԀ +U((< + PE@   - cԀ @@ + [Ԁ _@@ p  -NԀ 2< +`Ԁ rf((< -E? +E?   - ߓ< - `E@ + ((< + `E@   - ̚Ԁ < + pԀ 6((< -E? +E?   - < - pE@ + ظ((< + pE@   - Ԁ < + Ԁ ~((< -E? +E?   - ' < - E@ +  ((< + E@   - . Ԁ ~5 < + Ԁ Ƭ((< -E? +E?   - q < - E@ + h ((< + E@   - x Ԁ n < + H Ԁ  ((< -E? +E?   -  < - E@ + q ((< + E@   -  Ԁ ^ < + w Ԁ V} ((< -E? +E?   - O< - E @ + Y ((< + E @   - <Ԁ < + _ Ԁ e ((< -E ? +E ?   - YTT E0 - + ((< + E +@  - - -^TT + + Ԁ  ((< -E0 - - - -? < - E @ +E +? + + + H((< + E @   - ,Ԁ < + (Ԁ ((< -E ? +E ?   - [@@  + TT E0  + + + +TT + +E0 + + + +x@@   -\@@< +z@@< - +   -*\Ԁ -\< - E @ +Ԁ +D((< + E @   - wcԀ @@ + %Ԁ @@ -  +0  -Ԁ < +Ԁ ((< + +@E ? + + + ظ((< + E@ + + + Ԁ ~((< -0E ? +PE?   - < - E @ +  ((< + E@   -  Ԁ ޮ< + Ԁ Ƭ((< -@E ? +`E?   -  < - E@ + h ((< + 0E@   -  Ԁ  < + H Ԁ  ((< -PE? +pE?   - 4 < - E@ + q ((< + @E@   - ; Ԁ B < + w Ԁ V} ((< -`E? +E?   - ~< - 0E@ + Y ((< + PE@   - ܅Ԁ < + _ Ԁ e ((< -pE? +E?   -  \ No newline at end of file +  \ No newline at end of file diff -Naur ns-3.19/src/aodv/test/udp-chain-test-9-0.pcap ns-3.20/src/aodv/test/udp-chain-test-9-0.pcap --- ns-3.19/src/aodv/test/udp-chain-test-9-0.pcap 2014-06-17 10:34:00.454636538 -0700 +++ ns-3.20/src/aodv/test/udp-chain-test-9-0.pcap 2014-06-17 10:33:13.786996787 -0700 @@ -20,88 +20,90 @@   -c -@@  +@@    - -@@<  +ݨ@@<    - 2 Ԁ6 TT<0E0 + ԀTT<0E0      -_F Ԁ@@@ +_Ԁ[@@@  -ԀTT<PE0 +*ԀTT<PE0  @  - E4@@<` + ^Y@@<`   -6Ԁ|iԀNp<pE8 + ԀԀ((<pE8   - ^pԀ1Ԁ<E8 + ԀԀ((<E8   - Ԁ!Ԁ<E8 + ԀԀ((<E8   - Ԁ` Ԁf <E8 + ԀԀ((<E8   - f Ԁ ԀӰ <E8 + ԀY Ԁ ((<E8   -  Ԁ Ԁ <E8 + / Ԁ Ԁg ((<E8   -  ԀuTTE0 + w Ԁ Ԁ ((<E 8 + + +  Ԁ/Ԁ5((<E +8 + + + 5ԀuTTE0    - Ԁs<E 8 - - - Ԁ8TT0E0 + 8TT0E0     -V@@< +9Ԁ((<E 8 + + + Ԁ@@<   -^^Ԁ}@@ +gԀ@@    -}@@<@ +@@<@   - ~Ԁͅ<E 8 + Ԁ((<0E 8   - ݅Ԁ%!Ԁ'< E 8 + ԀԀ((<@E8   - (ԀqԀC<0E 8 + ԀԀ((<PE8   - SԀa# -Ԁ3* -<@E8 + ԀY Ԁ ((<`E8   - C* -ԀQm Ԁ#t <PE8 + / Ԁ Ԁg ((<pE8   - 3t ԀAԀ<`E8 + w Ԁ Ԁ ((<E8   - #Ԁ \ No newline at end of file +  Ԁ \ No newline at end of file diff -Naur ns-3.19/src/aodv/waf ns-3.20/src/aodv/waf --- ns-3.19/src/aodv/waf 2014-06-17 10:34:00.454636538 -0700 +++ ns-3.20/src/aodv/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../../../waf "$@" diff -Naur ns-3.19/src/applications/bindings/modulegen__gcc_ILP32.py ns-3.20/src/applications/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/applications/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.461636484 -0700 +++ ns-3.20/src/applications/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.793996733 -0700 @@ -155,7 +155,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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') ## ping6-helper.h (module 'applications'): ns3::Ping6Helper [class] @@ -174,6 +174,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -198,6 +200,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## packet-socket.h (module 'network'): ns3::DeviceNameTag [class] @@ -514,32 +518,35 @@ module.add_class('PacketProbe', import_from_module='ns.network', parent=root_module['ns3::Probe']) ## packetbb.h (module 'network'): ns3::PbbAddressTlv [class] module.add_class('PbbAddressTlv', import_from_module='ns.network', parent=root_module['ns3::PbbTlv']) - module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type='vector') - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::list< unsigned int >', 'unsigned int', container_type='list') - module.add_container('std::list< ns3::Ptr< ns3::Socket > >', 'ns3::Ptr< ns3::Socket >', container_type='list') - module.add_container('std::list< ns3::Ptr< ns3::RadvdPrefix > >', 'ns3::Ptr< ns3::RadvdPrefix >', container_type='list') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyTxEndCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyTxEndCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyTxEndCallback&') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >', 'ns3::SequenceNumber16') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >*', 'ns3::SequenceNumber16*') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >&', 'ns3::SequenceNumber16&') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >', 'ns3::SequenceNumber32') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >*', 'ns3::SequenceNumber32*') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >&', 'ns3::SequenceNumber32&') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyRxStartCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyRxStartCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyRxStartCallback&') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyRxEndErrorCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyRxEndErrorCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyRxEndErrorCallback&') - typehandlers.add_type_alias('ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyTxStartCallback') - typehandlers.add_type_alias('ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyTxStartCallback*') - typehandlers.add_type_alias('ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyTxStartCallback&') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyRxEndOkCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyRxEndOkCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyRxEndOkCallback&') + module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type=u'vector') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::list< unsigned int >', 'unsigned int', container_type=u'list') + module.add_container('std::list< ns3::Ptr< ns3::Socket > >', 'ns3::Ptr< ns3::Socket >', container_type=u'list') + module.add_container('std::list< ns3::Ptr< ns3::RadvdPrefix > >', 'ns3::Ptr< ns3::RadvdPrefix >', container_type=u'list') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyTxEndCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyTxEndCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyTxEndCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >', u'ns3::SequenceNumber16') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >*', u'ns3::SequenceNumber16*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >&', u'ns3::SequenceNumber16&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >', u'ns3::SequenceNumber32') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >*', u'ns3::SequenceNumber32*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >&', u'ns3::SequenceNumber32&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyRxStartCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyRxStartCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyRxStartCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >', u'ns3::SequenceNumber8') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >*', u'ns3::SequenceNumber8*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >&', u'ns3::SequenceNumber8&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyRxEndErrorCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyRxEndErrorCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyRxEndErrorCallback&') + typehandlers.add_type_alias(u'ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyTxStartCallback') + typehandlers.add_type_alias(u'ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyTxStartCallback*') + typehandlers.add_type_alias(u'ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyTxStartCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyRxEndOkCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyRxEndOkCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyRxEndOkCallback&') ## Register a nested module for the namespace FatalImpl @@ -574,12 +581,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -671,6 +678,7 @@ register_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -1349,6 +1357,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1361,6 +1373,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -3745,6 +3761,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('<') @@ -4101,61 +4125,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -4163,6 +4143,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -4203,6 +4185,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -5861,12 +5845,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -5892,6 +5878,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -7081,10 +7072,10 @@ cls.add_method('Reset', 'void', []) - ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr arg0) [member function] + ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr p) [member function] cls.add_method('DoCorrupt', 'bool', - [param('ns3::Ptr< ns3::Packet >', 'arg0')], + [param('ns3::Ptr< ns3::Packet >', 'p')], is_pure_virtual=True, visibility='private', is_virtual=True) ## error-model.h (module 'network'): void ns3::ErrorModel::DoReset() [member function] cls.add_method('DoReset', @@ -8429,10 +8420,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3PacketSink_methods(root_module, cls): diff -Naur ns-3.19/src/applications/bindings/modulegen__gcc_LP64.py ns-3.20/src/applications/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/applications/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.468636430 -0700 +++ ns-3.20/src/applications/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.799996687 -0700 @@ -155,7 +155,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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') ## ping6-helper.h (module 'applications'): ns3::Ping6Helper [class] @@ -174,6 +174,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -198,6 +200,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## packet-socket.h (module 'network'): ns3::DeviceNameTag [class] @@ -514,32 +518,35 @@ module.add_class('PacketProbe', import_from_module='ns.network', parent=root_module['ns3::Probe']) ## packetbb.h (module 'network'): ns3::PbbAddressTlv [class] module.add_class('PbbAddressTlv', import_from_module='ns.network', parent=root_module['ns3::PbbTlv']) - module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type='vector') - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::list< unsigned int >', 'unsigned int', container_type='list') - module.add_container('std::list< ns3::Ptr< ns3::Socket > >', 'ns3::Ptr< ns3::Socket >', container_type='list') - module.add_container('std::list< ns3::Ptr< ns3::RadvdPrefix > >', 'ns3::Ptr< ns3::RadvdPrefix >', container_type='list') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyTxEndCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyTxEndCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyTxEndCallback&') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >', 'ns3::SequenceNumber16') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >*', 'ns3::SequenceNumber16*') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >&', 'ns3::SequenceNumber16&') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >', 'ns3::SequenceNumber32') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >*', 'ns3::SequenceNumber32*') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >&', 'ns3::SequenceNumber32&') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyRxStartCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyRxStartCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyRxStartCallback&') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyRxEndErrorCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyRxEndErrorCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyRxEndErrorCallback&') - typehandlers.add_type_alias('ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyTxStartCallback') - typehandlers.add_type_alias('ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyTxStartCallback*') - typehandlers.add_type_alias('ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyTxStartCallback&') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ns3::GenericPhyRxEndOkCallback') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', 'ns3::GenericPhyRxEndOkCallback*') - typehandlers.add_type_alias('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', 'ns3::GenericPhyRxEndOkCallback&') + module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type=u'vector') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::list< unsigned int >', 'unsigned int', container_type=u'list') + module.add_container('std::list< ns3::Ptr< ns3::Socket > >', 'ns3::Ptr< ns3::Socket >', container_type=u'list') + module.add_container('std::list< ns3::Ptr< ns3::RadvdPrefix > >', 'ns3::Ptr< ns3::RadvdPrefix >', container_type=u'list') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyTxEndCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyTxEndCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyTxEndCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >', u'ns3::SequenceNumber16') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >*', u'ns3::SequenceNumber16*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >&', u'ns3::SequenceNumber16&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >', u'ns3::SequenceNumber32') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >*', u'ns3::SequenceNumber32*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >&', u'ns3::SequenceNumber32&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyRxStartCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyRxStartCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyRxStartCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >', u'ns3::SequenceNumber8') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >*', u'ns3::SequenceNumber8*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >&', u'ns3::SequenceNumber8&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyRxEndErrorCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyRxEndErrorCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyRxEndErrorCallback&') + typehandlers.add_type_alias(u'ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyTxStartCallback') + typehandlers.add_type_alias(u'ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyTxStartCallback*') + typehandlers.add_type_alias(u'ns3::Callback< bool, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyTxStartCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::GenericPhyRxEndOkCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::GenericPhyRxEndOkCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::GenericPhyRxEndOkCallback&') ## Register a nested module for the namespace FatalImpl @@ -574,12 +581,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -671,6 +678,7 @@ register_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -1349,6 +1357,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1361,6 +1373,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -3745,6 +3761,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('<') @@ -4101,61 +4125,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -4163,6 +4143,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -4203,6 +4185,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -5861,12 +5845,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -5892,6 +5878,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -7081,10 +7072,10 @@ cls.add_method('Reset', 'void', []) - ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr arg0) [member function] + ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr p) [member function] cls.add_method('DoCorrupt', 'bool', - [param('ns3::Ptr< ns3::Packet >', 'arg0')], + [param('ns3::Ptr< ns3::Packet >', 'p')], is_pure_virtual=True, visibility='private', is_virtual=True) ## error-model.h (module 'network'): void ns3::ErrorModel::DoReset() [member function] cls.add_method('DoReset', @@ -8429,10 +8420,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3PacketSink_methods(root_module, cls): diff -Naur ns-3.19/src/applications/model/application-packet-probe.cc ns-3.20/src/applications/model/application-packet-probe.cc --- ns-3.19/src/applications/model/application-packet-probe.cc 2014-06-17 10:34:00.475636376 -0700 +++ ns-3.20/src/applications/model/application-packet-probe.cc 2014-06-17 10:33:13.806996633 -0700 @@ -32,8 +32,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ApplicationPacketProbe) - ; +NS_OBJECT_ENSURE_REGISTERED (ApplicationPacketProbe); TypeId ApplicationPacketProbe::GetTypeId () diff -Naur ns-3.19/src/applications/model/bulk-send-application.cc ns-3.20/src/applications/model/bulk-send-application.cc --- ns-3.19/src/applications/model/bulk-send-application.cc 2014-06-17 10:34:00.475636376 -0700 +++ ns-3.20/src/applications/model/bulk-send-application.cc 2014-06-17 10:33:13.807996625 -0700 @@ -35,8 +35,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (BulkSendApplication) - ; +NS_OBJECT_ENSURE_REGISTERED (BulkSendApplication); TypeId BulkSendApplication::GetTypeId (void) diff -Naur ns-3.19/src/applications/model/onoff-application.cc ns-3.20/src/applications/model/onoff-application.cc --- ns-3.19/src/applications/model/onoff-application.cc 2014-06-17 10:34:00.476636368 -0700 +++ ns-3.20/src/applications/model/onoff-application.cc 2014-06-17 10:33:13.808996618 -0700 @@ -46,8 +46,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (OnOffApplication) - ; +NS_OBJECT_ENSURE_REGISTERED (OnOffApplication); TypeId OnOffApplication::GetTypeId (void) diff -Naur ns-3.19/src/applications/model/packet-loss-counter.cc ns-3.20/src/applications/model/packet-loss-counter.cc --- ns-3.19/src/applications/model/packet-loss-counter.cc 2014-06-17 10:34:00.477636360 -0700 +++ ns-3.20/src/applications/model/packet-loss-counter.cc 2014-06-17 10:33:13.809996610 -0700 @@ -26,8 +26,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("PacketLossCounter") - ; +NS_LOG_COMPONENT_DEFINE ("PacketLossCounter"); PacketLossCounter::PacketLossCounter (uint8_t bitmapSize) diff -Naur ns-3.19/src/applications/model/packet-sink.cc ns-3.20/src/applications/model/packet-sink.cc --- ns-3.19/src/applications/model/packet-sink.cc 2014-06-17 10:34:00.478636352 -0700 +++ ns-3.20/src/applications/model/packet-sink.cc 2014-06-17 10:33:13.809996610 -0700 @@ -34,10 +34,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("PacketSink") - ; -NS_OBJECT_ENSURE_REGISTERED (PacketSink) - ; +NS_LOG_COMPONENT_DEFINE ("PacketSink"); +NS_OBJECT_ENSURE_REGISTERED (PacketSink); TypeId PacketSink::GetTypeId (void) diff -Naur ns-3.19/src/applications/model/ping6.cc ns-3.20/src/applications/model/ping6.cc --- ns-3.19/src/applications/model/ping6.cc 2014-06-17 10:34:00.479636345 -0700 +++ ns-3.20/src/applications/model/ping6.cc 2014-06-17 10:33:13.810996602 -0700 @@ -38,11 +38,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ping6Application") - ; +NS_LOG_COMPONENT_DEFINE ("Ping6Application"); -NS_OBJECT_ENSURE_REGISTERED (Ping6) - ; +NS_OBJECT_ENSURE_REGISTERED (Ping6); TypeId Ping6::GetTypeId () { @@ -111,7 +109,6 @@ NS_ASSERT (m_socket); m_socket->Bind (Inet6SocketAddress (m_localAddress, 0)); - m_socket->Connect (Inet6SocketAddress (m_peerAddress, 0)); m_socket->SetAttribute ("Protocol", UintegerValue (Ipv6Header::IPV6_ICMPV6)); m_socket->SetRecvCallback (MakeCallback (&Ping6::HandleRead, this)); } @@ -173,13 +170,14 @@ /* hack to have ifIndex in Ipv6RawSocketImpl * maybe add a SetIfIndex in Ipv6RawSocketImpl directly */ - Ipv6InterfaceAddress dstIa (m_peerAddress); for (uint32_t i = 0; i < GetNode ()->GetObject ()->GetNAddresses (m_ifIndex); i++) { - src = GetNode ()->GetObject ()->GetAddress (m_ifIndex, i).GetAddress (); - Ipv6InterfaceAddress srcIa (src); - if ( srcIa.GetScope() == dstIa.GetScope() ) + Ipv6InterfaceAddress srcIa; + srcIa = GetNode ()->GetObject ()->GetAddress (m_ifIndex, i); + + if (srcIa.IsInSameSubnet (m_peerAddress)) { + src = srcIa.GetAddress (); break; } } @@ -223,7 +221,7 @@ m_socket->SetAttribute ("Protocol", UintegerValue (Ipv6Header::IPV6_EXT_ROUTING)); } - m_socket->Send (p, 0); + m_socket->SendTo (p, 0, Inet6SocketAddress (m_peerAddress, 0)); ++m_sent; NS_LOG_INFO ("Sent " << p->GetSize () << " bytes to " << m_peerAddress); @@ -248,6 +246,8 @@ { Ipv6Header hdr; Icmpv6Echo reply (0); + Icmpv6DestinationUnreachable destUnreach; + Icmpv6TimeExceeded timeExceeded; Inet6SocketAddress address = Inet6SocketAddress::ConvertFrom (from); packet->RemoveHeader (hdr); @@ -260,10 +260,23 @@ case Icmpv6Header::ICMPV6_ECHO_REPLY: packet->RemoveHeader (reply); - NS_LOG_INFO ("Received Echo Reply size = " << std::dec << packet->GetSize () << " bytes from " << address.GetIpv6 () << " id = " << (uint16_t)reply.GetId () << " seq = " << (uint16_t)reply.GetSeq ()); + NS_LOG_INFO ("Received Echo Reply size = " << std::dec << packet->GetSize () << + " bytes from " << address.GetIpv6 () << + " id = " << (uint16_t)reply.GetId () << + " seq = " << (uint16_t)reply.GetSeq () << + " Hop Count = " << (uint16_t) (64 - hdr.GetHopLimit ())); + break; + case Icmpv6Header::ICMPV6_ERROR_DESTINATION_UNREACHABLE: + packet->RemoveHeader (destUnreach); + + NS_LOG_INFO ("Received Destination Unreachable from " << address.GetIpv6 ()); + break; + case Icmpv6Header::ICMPV6_ERROR_TIME_EXCEEDED: + packet->RemoveHeader (timeExceeded); + + NS_LOG_INFO ("Received Time Exceeded from " << address.GetIpv6 ()); break; default: - /* other type, discard */ break; } } diff -Naur ns-3.19/src/applications/model/radvd.cc ns-3.20/src/applications/model/radvd.cc --- ns-3.19/src/applications/model/radvd.cc 2014-06-17 10:34:00.481636330 -0700 +++ ns-3.20/src/applications/model/radvd.cc 2014-06-17 10:33:13.812996587 -0700 @@ -40,11 +40,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("RadvdApplication") - ; +NS_LOG_COMPONENT_DEFINE ("RadvdApplication"); -NS_OBJECT_ENSURE_REGISTERED (Radvd) - ; +NS_OBJECT_ENSURE_REGISTERED (Radvd); TypeId Radvd::GetTypeId () { diff -Naur ns-3.19/src/applications/model/radvd-interface.cc ns-3.20/src/applications/model/radvd-interface.cc --- ns-3.19/src/applications/model/radvd-interface.cc 2014-06-17 10:34:00.479636345 -0700 +++ ns-3.20/src/applications/model/radvd-interface.cc 2014-06-17 10:33:13.811996595 -0700 @@ -24,8 +24,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("RadvdInterface") - ; +NS_LOG_COMPONENT_DEFINE ("RadvdInterface"); RadvdInterface::RadvdInterface (uint32_t interface) : m_interface (interface) diff -Naur ns-3.19/src/applications/model/radvd-prefix.cc ns-3.20/src/applications/model/radvd-prefix.cc --- ns-3.19/src/applications/model/radvd-prefix.cc 2014-06-17 10:34:00.480636337 -0700 +++ ns-3.20/src/applications/model/radvd-prefix.cc 2014-06-17 10:33:13.812996587 -0700 @@ -24,8 +24,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("RadvdPrefix") - ; +NS_LOG_COMPONENT_DEFINE ("RadvdPrefix"); RadvdPrefix::RadvdPrefix (Ipv6Address network, uint8_t prefixLength, uint32_t preferredLifeTime, uint32_t validLifeTime, bool onLinkFlag, bool autonomousFlag, bool routerAddrFlag) : m_network (network), diff -Naur ns-3.19/src/applications/model/seq-ts-header.cc ns-3.20/src/applications/model/seq-ts-header.cc --- ns-3.19/src/applications/model/seq-ts-header.cc 2014-06-17 10:34:00.482636322 -0700 +++ ns-3.20/src/applications/model/seq-ts-header.cc 2014-06-17 10:33:13.813996579 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (SeqTsHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (SeqTsHeader); SeqTsHeader::SeqTsHeader () : m_seq (0), diff -Naur ns-3.19/src/applications/model/udp-client.cc ns-3.20/src/applications/model/udp-client.cc --- ns-3.19/src/applications/model/udp-client.cc 2014-06-17 10:34:00.482636322 -0700 +++ ns-3.20/src/applications/model/udp-client.cc 2014-06-17 10:33:13.814996571 -0700 @@ -35,10 +35,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("UdpClient") - ; -NS_OBJECT_ENSURE_REGISTERED (UdpClient) - ; +NS_LOG_COMPONENT_DEFINE ("UdpClient"); +NS_OBJECT_ENSURE_REGISTERED (UdpClient); TypeId UdpClient::GetTypeId (void) diff -Naur ns-3.19/src/applications/model/udp-echo-client.cc ns-3.20/src/applications/model/udp-echo-client.cc --- ns-3.19/src/applications/model/udp-echo-client.cc 2014-06-17 10:34:00.483636314 -0700 +++ ns-3.20/src/applications/model/udp-echo-client.cc 2014-06-17 10:33:13.815996564 -0700 @@ -31,10 +31,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("UdpEchoClientApplication") - ; -NS_OBJECT_ENSURE_REGISTERED (UdpEchoClient) - ; +NS_LOG_COMPONENT_DEFINE ("UdpEchoClientApplication"); +NS_OBJECT_ENSURE_REGISTERED (UdpEchoClient); TypeId UdpEchoClient::GetTypeId (void) diff -Naur ns-3.19/src/applications/model/udp-echo-server.cc ns-3.20/src/applications/model/udp-echo-server.cc --- ns-3.19/src/applications/model/udp-echo-server.cc 2014-06-17 10:34:00.484636306 -0700 +++ ns-3.20/src/applications/model/udp-echo-server.cc 2014-06-17 10:33:13.816996556 -0700 @@ -34,10 +34,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("UdpEchoServerApplication") - ; -NS_OBJECT_ENSURE_REGISTERED (UdpEchoServer) - ; +NS_LOG_COMPONENT_DEFINE ("UdpEchoServerApplication"); +NS_OBJECT_ENSURE_REGISTERED (UdpEchoServer); TypeId UdpEchoServer::GetTypeId (void) diff -Naur ns-3.19/src/applications/model/udp-server.cc ns-3.20/src/applications/model/udp-server.cc --- ns-3.19/src/applications/model/udp-server.cc 2014-06-17 10:34:00.485636299 -0700 +++ ns-3.20/src/applications/model/udp-server.cc 2014-06-17 10:33:13.816996556 -0700 @@ -36,10 +36,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("UdpServer") - ; -NS_OBJECT_ENSURE_REGISTERED (UdpServer) - ; +NS_LOG_COMPONENT_DEFINE ("UdpServer"); +NS_OBJECT_ENSURE_REGISTERED (UdpServer); TypeId diff -Naur ns-3.19/src/applications/model/udp-trace-client.cc ns-3.20/src/applications/model/udp-trace-client.cc --- ns-3.19/src/applications/model/udp-trace-client.cc 2014-06-17 10:34:00.486636291 -0700 +++ ns-3.20/src/applications/model/udp-trace-client.cc 2014-06-17 10:33:13.817996548 -0700 @@ -37,10 +37,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("UdpTraceClient") - ; -NS_OBJECT_ENSURE_REGISTERED (UdpTraceClient) - ; +NS_LOG_COMPONENT_DEFINE ("UdpTraceClient"); +NS_OBJECT_ENSURE_REGISTERED (UdpTraceClient); /** * \brief Default trace to send @@ -188,8 +186,7 @@ UdpTraceClient::LoadTrace (std::string filename) { NS_LOG_FUNCTION (this << filename); - uint32_t time, index, prevTime = 0; - uint16_t size; + uint32_t time, index, size, prevTime = 0; char frameType; TraceEntry entry; std::ifstream ifTraceFile; @@ -329,7 +326,7 @@ struct TraceEntry *entry = &m_entries[m_currentEntry]; do { - for (int i = 0; i < entry->packetSize / m_maxPacketSize; i++) + for (uint32_t i = 0; i < entry->packetSize / m_maxPacketSize; i++) { SendPacket (m_maxPacketSize); } diff -Naur ns-3.19/src/applications/model/udp-trace-client.h ns-3.20/src/applications/model/udp-trace-client.h --- ns-3.19/src/applications/model/udp-trace-client.h 2014-06-17 10:34:00.486636291 -0700 +++ ns-3.20/src/applications/model/udp-trace-client.h 2014-06-17 10:33:13.817996548 -0700 @@ -150,7 +150,7 @@ struct TraceEntry { uint32_t timeToSend; //!< Time to send the frame - uint16_t packetSize; //!< Size of the frame + uint32_t packetSize; //!< Size of the frame char frameType; //!< Frame type (I, P or B) }; diff -Naur ns-3.19/src/applications/model/v4ping.cc ns-3.20/src/applications/model/v4ping.cc --- ns-3.19/src/applications/model/v4ping.cc 2014-06-17 10:34:00.486636291 -0700 +++ ns-3.20/src/applications/model/v4ping.cc 2014-06-17 10:33:13.818996541 -0700 @@ -28,10 +28,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("V4Ping") - ; -NS_OBJECT_ENSURE_REGISTERED (V4Ping) - ; +NS_LOG_COMPONENT_DEFINE ("V4Ping"); +NS_OBJECT_ENSURE_REGISTERED (V4Ping); TypeId V4Ping::GetTypeId (void) diff -Naur ns-3.19/src/applications/waf ns-3.20/src/applications/waf --- ns-3.19/src/applications/waf 2014-06-17 10:34:00.489636268 -0700 +++ ns-3.20/src/applications/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1,162 +0,0 @@ -#!/usr/bin/env python -# encoding: ISO8859-1 -# Thomas Nagy, 2005-2010 - -""" -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions -are met: - -1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - -2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - -3. The name of the author may not be used to endorse or promote products - derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR -IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, -INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING -IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -POSSIBILITY OF SUCH DAMAGE. -""" - -import os, sys -if sys.hexversion<0x203000f: raise ImportError("Waf requires Python >= 2.3") - -if 'PSYCOWAF' in os.environ: - try:import psyco;psyco.full() - except:pass - -VERSION="1.5.16" -REVISION="e6d03192b5ddfa5ef2c8d65308e48e42" -INSTALL='' -C1='#5' -C2='#,' -cwd = os.getcwd() -join = os.path.join - -WAF='waf' -def b(x): - return x - -if sys.hexversion>0x300000f: - WAF='waf3' - def b(x): - return x.encode() - -def err(m): - print(('\033[91mError: %s\033[0m' % m)) - sys.exit(1) - -def unpack_wafdir(dir): - f = open(sys.argv[0],'rb') - c = "corrupted waf (%d)" - while 1: - line = f.readline() - if not line: err("run waf-light from a folder containing wafadmin") - if line == b('#==>\n'): - txt = f.readline() - if not txt: err(c % 1) - if f.readline()!=b('#<==\n'): err(c % 2) - break - if not txt: err(c % 3) - txt = txt[1:-1].replace(b(C1), b('\n')).replace(b(C2), b('\r')) - - import shutil, tarfile - try: shutil.rmtree(dir) - except OSError: pass - try: - for x in ['Tools', '3rdparty']: - os.makedirs(join(dir, 'wafadmin', x)) - except OSError: - err("Cannot unpack waf lib into %s\nMove waf into a writeable directory" % dir) - - os.chdir(dir) - tmp = 't.bz2' - t = open(tmp,'wb') - t.write(txt) - t.close() - - t = None - try: - t = tarfile.open(tmp) - except: - try: - os.system('bunzip2 t.bz2') - t = tarfile.open('t') - except: - os.chdir(cwd) - try: shutil.rmtree(dir) - except OSError: pass - err("Waf cannot be unpacked, check that bzip2 support is present") - - for x in t: t.extract(x) - t.close() - - for x in ['Tools', '3rdparty']: - os.chmod(join('wafadmin',x), 493) - - if sys.hexversion>0x300000f: - sys.path = [join(dir, 'wafadmin')] + sys.path - import py3kfixes - py3kfixes.fixdir(dir) - - os.chdir(cwd) - -def test(dir): - try: os.stat(join(dir, 'wafadmin')); return os.path.abspath(dir) - except OSError: pass - -def find_lib(): - name = sys.argv[0] - base = os.path.dirname(os.path.abspath(name)) - - #devs use $WAFDIR - w=test(os.environ.get('WAFDIR', '')) - if w: return w - - #waf-light - if name.endswith('waf-light'): - w = test(base) - if w: return w - err("waf-light requires wafadmin -> export WAFDIR=/folder") - - dir = "/lib/%s-%s-%s/" % (WAF, VERSION, REVISION) - for i in [INSTALL,'/usr','/usr/local','/opt']: - w = test(i+dir) - if w: return w - - #waf-local - s = '.%s-%s-%s' - if sys.platform == 'win32': s = s[1:] - dir = join(base, s % (WAF, VERSION, REVISION)) - w = test(dir) - if w: return w - - #unpack - unpack_wafdir(dir) - return dir - -wafdir = find_lib() -w = join(wafdir, 'wafadmin') -t = join(w, 'Tools') -f = join(w, '3rdparty') -sys.path = [w, t, f] + sys.path - -if __name__ == '__main__': - import Scripting - Scripting.prepare(t, cwd, VERSION, wafdir) - -#==> -#BZh91AY&SY< H JH0B,aps#]vzW;-ʹV:.X{7ջknsVP^}m2kP7ȗl}Q;WT>vzځ˻vћo}|1@";;ey㷣iop4t[{lՃMO@z4٨" ]*T2((5C*-}ugsYqQgw-ʍ4Vxo;ڻȾom{tv뷯^K[#,y{ކۖw{0ѶuAZH5.;bH VݷAX{jXUaMm۫YGn=u]}nnNuӝ!}7k֣xǭU}J7cbr⚠oEO>K.}>jEvwofz׎ znݪUլUj|ן|>Ogwo}ٔ|旵{۾3ywn]:.%ݻtɖ=wz{̀V#,JK@nu [AQs-]N 2es6헃)}n۾PQWy׸mۺklFyWoUZwot|ܖϑ;rNF]k{}}jms󎋱y=MrsE)@rvDX>ϫ]ݺ޵kfǦngmȒkZ,mIݶ\h)ͭ۷ݗWZ+ӝ_ZzT:]5˞}=l[\esNAL&&M 2ddz=4A @4&='<502C  "d #5mh?Щ&4CLPFm@ =RF2S3&5hFC@B@hM&LdhLL54iC#,MDB&h#5m2(Df$SM4h9DW!0FP`J2YQʀ~k˕rmȒt=VK, h{?_HPi  %Hh%eb*m5i,AX՚Ib#Fl#,&C4E)C5A"JeZl$ c+S i%"V%55 M52KRljJIYdbMcJM"Y1eeQQThƪXI3Z-EZ#,H`ȖƃZ,!l[EDc4b(LX-MdڙIVRkMզMc635ҋ#lU4JQ&Zi1&lL*Vf#5Yjk$PM"4)$X-- QF#,(FQP"dI$F6#6M`JlZ,2JfhY,e&K$24lRZLbllђjfً%$`FBPE3 64mdY(ٱ526-EŦAlʣ2b+hєhJ0PE3`X2֒A -04"i%hSM&+%bZIFe $ŋkƥ5meE4L,XSJ$S10)"C3")2Q dh6C[)0fDMQdȒi506Q2T,LF,Q4L(QV@2QҙF,,`eE11QbIKbb,2H Tڔ1EhjMبMbRYJi`iXf5%%&b[*4 %QM0,b5$fQIQ3 #5K)VX[ҔL-&5i*[clUQd6H5Fm"mj#5-Df-H)4*h,!RhM%Q2 fF3 1P5%UMjCbF(%1YIPf2BR,@ P#m+id#5QQ#,#aM5!d(LѤj#T&幣$A&eF#)_{s]#5eX#50`bcn_yMJJW̾KxDy_y駣s!!I?k=+Cٳ3)]u#mihcgd*`h#,/&`4ZdFK]hT1(*twHr+jvBҚiuAji!fM~;;QI)xbF#5։偷v'8n2qfm}w.nW6n#,̅blE8N]Db/qkM-TN9>q/\7:g`~Īߕ"YBo@#ӉcA!"5NcJ֔সB !kUKd6p3؜m+JՁ+&2~Fr4v%^p\s#ڇNT  dׄ)&F ̭)_*򖴾gNtC*j4NGdg9?i%! SS ɢ#58M*+k$P+wS4LiKWBg%#۹='-ln;/h͇<_+Jz(Kxq2EnLu֬>WǃqOl%$:a 4{o#9#,bWJoZ ]zn߂(kƉТmT r5E)GFXHUUtPvl"~`Onۤ9c>vb !,KzCC|fg{=7钢I"8e_`Ro:VQ~qݔew xymPP9e|[>n޸3w6Ns,np[",!H )'c PHg_bO';z6B<ўipKi+;[ٹ)~3~+מyח@a>}!B!,=w0-]AjJkQfU #5dvsEQQfW_u]xjiaMqH|a.mil;ȶÂ[z3g*Qw?c#5Zwd'LXBMk)wM[gR0M84y+qa8(&d]0t-z>9GwYb)A]#2#aLջ`}ha:A3I*;Jl&I&HTR)WmzBGEPl?u6ndי^ԛS=PpL%zw/FįqPl̅$~6W'٘#,GuXlhg2#A8\lU+#Wš3tfHJQ=\N׉2#,x"i}TzwyYM@:J~ 1dxfjer;5Ng Lo~bcEf4faC 8AՊZ$# ugkQ /u)2 µөF#,ūRB#,"/PiID<lLS$Dgg-ҍ;󭕄@)1Ƒhq"!Ƽgf6k==fKp7] ֊gύ[?{YI(\8xQ6:PɫpH _|îF?]/POʐwmWM vh#NMį),#̿YQdQQL :UCz㤷h[/<(0_!jkuXS>kl1)"#5{*?:pJMePRd.\7|7ܟǻWKfU/lS% YyC+Al TqeBIYgH~#5ti領xd0f#,y.LtOj<&#,QX6Ѯq4#,i¬Z0@>.}#5GSӗtų!m֓n5턕ֹ6QXzBM|[;xQꤙp;穬^P)!""L۩]fqs1߳]Mfٟc:䲤Dž/3.5닇; |G1(%vyjg0H@倡{F]|SV_7{QNBԪ6[TH(C|L !' ct,l(>MqŞx-;9Uo>8k.gkqQ#۷hE%oUaZbBȁ!Jt e6 N,u0~3uQrX4ÂcI?Q*MeԩNmE"{wpk*<7 ~:f>IVYA#5G1*K:?z.`?[#5Lȭ@ q2WsYٌ;uwÞ#[-T4wn^h y v! @BF@9y r$cmJ19NI[;nٹ9(qИwSW>l>h L0@=Q.JHo"O \`.)@WM—  xieC PU2€Jɩi?2/ 2y]gQ{đCJ$)M)TU2 6,N^'P;oa. 6{V(wFߍd~,0@Qu8? >{w#,(g,hM}݇xT `n&+P>ٺiƿByP;}I{zC鳗fn]'o??L)$Td)c}3^䃫-o)mu3`F~~eoqA_j-N5/llQbۼp ˚ R;r OWE:Pv,@^7#, !sV[ʆ$.t9=tzq#,CXro~y1U@sUҪbf {>ApD/[hF>,KWI/d_C$a~qH1qr4:Qsd] (< uUZ'錫cs|wm)cJuU42s߫4.nlԮrt"P}oVKS#5 ξ,KU9˥k rbs9;gL׵MݣMMsѡHܓ(UZez^UYՐUE?>o8*{bkެAl]tQ'uDTTC޳5~Nd,s7߮tl/hʤG>pP~Kw6vpS$1)$`F2\{7Yoysύfns:6ny_E~Ѧxp0,;PH/7`rT#,v sS)>o5|bP&1stݫkk4 7g:k"<n ˘/eۖ29W|IgŨq/)ylZz_+CMMwM܎+( adVHE|t;k2l;=s<>ZS?+}F `x'Z]Q!?:BJuFLa2}"_8.h撺s;VT3c#-edS)#5OC'ƺi(*ۓwߌ 1t4#, ̍1 ?+(BSyH7Jİ2GNCȀTpQ5p#5sfyJ*gV@Q>m*gk~^ #5NUН̏Kb4fz؅?ڈɎU&a!&u铤F+]K͑`a-iV~u3@aU>[vGxŨ,(wP[xO;mmH~/kxAŢn)Cn*-~5^i\E1iyvU(3Mԛx%ޡI߽i9Ü{D`H#@С1+KA_^0؁Vxr>HbǟKlgW0{t!&獞qƠޜX.jh-t"*Woߣ}<2yQf#|Ax,P`D1QB }xNAjaLs=bLqgvmKTYCw;(,Y2ֱ]zRW K~|Ό#,E*)#Q;Tolq{#fDq@>RVMV/^v-7o<3VzGDXL${X 94"28dPE8cZdmel'?ɫn xJi`84$!6%U0h؈db'0:I0Á1@J8&Xݖ,n,ZΛo4$ݕ60x'(KO`nJT:ud쫟Èv)|lA̡ fd e56iQCs)f={[ʿuwqsΡ hPpL;-q~'.[#5ːȀ5: #55"ApU 袌#_|٬SGO? B@A.kr@u"jMsgFLtBoCCtL$uOokScR1T7?#,VN+lYDMƻ_r L,hp> H,<#50;S!9$7GK qvL#5E9\@_Ϻڪ.9^(@4=-$r9XVnZJ)UDH!mTl_uZ}Sie11j-jhagP/-WiK!×)󆉙(?7t߰e2??#,{h~$&\ڛ8uK.ҿILj-x曈sc`t2BCѩ:Q%-u^,!ᵭchm/ 85guk\^ kTi+Q!B#5Nb݃dbWT -+"߷w i]I>˕,cP@HPi9"Ɖ 3WId 6ǚrM "XlI䉰4رY%kܒuztmĹNݴDeWLƱ(1F"|4wq㭁mBD쬴oTi8`b4#,\-s!ͺk2xC6i˙/SR!a2jA "jU @ XL !DvIax)f!dgT#64tKFa͛{t4D=1 vm5m7L5SMO70/x'"Vhϟĸx?N-3" :5xV$X|Ry,5Ldi?-1hάRgq _lHD]0֯G.,eѹe3eVMw šd~?yп5 w- b>O fИe7znlz< 1>=ȋ@B6|BfRJ%$ 9ZkIۏR_qxKb낥;[ 28̬5ǟK0 ɠ&gq!LrCٱn} _rUiГ J@m$r6u2 + ކiH0nM,b wZC[w#5kn;X#E tBFø/J4s ϴ=pu#,Ik_go#,iѠ.=װזgi>+"PwUA Cu}uG]}y`w'iO#,.ysi*Rg$  k_C*bGrJ+5I8ř8,z7&-t@jA%=,#r&9j+]ғ)l5d| ML>\kry<H8ף@xr >msV4۾zo-O#5N[tQZGrG-]gv ~ۣצtP|wdh#5<`<bˋ;mv{=8jB!@Ղ6OK.R8rGTyBՌyUV#5ԫ4+Ma5O]D%S0FeHa#,cN6aw<-SdWؚH#5 ƏH*7PŔwuy#"2)};k V*u#,RPvh4| BҐ1uΓo=O)¢]!M($0&=cLnӈ$H[_kIn@RZSTT]m2 d?I#,*)ܵ"*0(i3-q'e B lc%IaK!Ǵj"O7nF`џ$j#5'!`LjE!P;<ꝸ*S=bsyI5м6s\ސPzް<8w~b:CIg[R:ȯPG#Lg൳P "! LBC4@TQ&pA<{Ɛ2"oᗯsj5&Xb?b&YFq)QwMv>nQ){})~botCxcTD;}U%eQhҡ>΂b~Yڣ' Sqp,0C%$<$F&ϵctaV"kUR6~#5&;?G7v#,7~\P;]R(uTkuu"[~GO w 1NWbQ[FI.h]6#5HOa"FkG/H#5kℳWN[ ңXzvmRj&yxo9OHsnz1*>N,rձ趺^O| O$e{wtY~M?(5Yw3nJFEG"c[WO FLs`A#5ܙcF\9olGGy]Z~;ƿ]2QX)?o]W!욻0󘺻hR_Bkc8lR)C^B$X^5T G5$ςh鯗ˢA*ӧ6x7_@?UewNB=[Ǣm.I|4'fkwIwhfs6FbζaճS^>͍EHg|= e˭,W?[O?W(iiǃWv&%gn#5~j\Y-7{MpAr>8&?7DiBڕcV[BYZ>MjxP3k9G :N"˖_=89#PhQm'50jΑz[q ?u߫|%˝ctEn)hϟ"Ԑ#J` '^!#,MUWFF^sӻ>yJy9;<ۺ;>x~"` |O~0r2}Z0|do<1ZDOģkk@{)@X2"pr=#5 W^̱n-?BBf8㿎{"|ܜ%~?9¯A#5ht{#,+ZB".#,FwY_~Ha7?|@BXTo3Ǘ@,(f|~ϗ:{z00,PU&$ci8aH(Yu{ŽAD{D)#5hrE2af;GK?vfLQU;#p!?TTPQ#5r1nqi-1ӛP k@7o B@'X;-5?_ψGYD45GK,1vȟ$fەg ZX-S^Kc0I&5WOyƯ!?:vR8_JL=] ;~957vYU{+H|uރVo'B#5/q*~1?|wڄTaM!>~]c8~-҃SA(҉5G@»n`4hήӷ,dԽ8 %)ϧsHJ=4,QUPKMnNT9{`($Pw~\lN|cs:dVׅ b#,f!yGa^\z!wl1Uwϒx&|0p4K?hj`,WΏ\=!@9(OVn/@'AY8xuu4Y]wM%fU CxG#eܤJ!hH9;v)]^Z۷iȨwD(l%WhN?Vq}4i?{Gd{*LJZ@b#5 %hB0Z",71eSAP vBTU0lQ)v]uI G4ѧK43V1l8<iA>rl}f1VQRXMs}}~{=C5=Fzs $hiTB2 4`Ȳ#,Qe)s#wAꭽ~zi{]#fl}Vb1j9 e8,e?]>(碽~'|hGc4HѯkE5͟ysN~Zz_?+ŒSǴ##.zuy(U޿wγlh$X+?5Uݣw%a0 1f#5z8~!b<}C]+ݰ_x_sa ~Oh:;#,EBnA=}[oZ?s}jJ*K$7QZhn'caV7@0A@Sl;VgȂ ]2FtnA+°cMؘF$2;lnθe7`B2֤=X̦c"JC#N"4N:aVrh9KJ!řMoڂ80#,sFO-.u`ڶ\5X+B8611ƅ(dtUtXE%^k,0!7DhJBi1ī)[RFM )wge$jw1#,KanF6Bee5FЃ 1xyT4ٴp}w7-joS=((*~u@ʑH%DGԽӭSJP|O;o0S^0} S:bkx#DŽP`?hpP0Ngm s9SwxE9{QʜUb !Ln#,yK߷\⛼X!-հ慜,TcoP")sޯ.ǙTI$,fBS_]Ɗ^3~̞\#5$"X"9뼙OÞ>eͶ*+=uh .0,WNV Nl"4F#&&@c;DIF@`@%oQ0|}?1Ǝϻa7nΚw+>2#,~rj6(+J(`D0U*IۻЇkֺ1cn`.szY***. B0#7jQok}M-q\!Z/#, ^A5"@Үٙ(5!!f%LPIӣc۲v֗]w d;;x2:#,;P"jiVčmcZ #,XҦ30"Wa-2%-o-2IrdO016ޏ!_W:BCZĢo{&*#O!xIbU#, A`Y^Gͣv ck[R [8ETS C6=@3=l)"(D.l5zErUe/f#DlXbg,1VPJ։8Eh5]d$ȨbpCw뿳HΈ#583W8k]۽:jjuR\,F{`miRk{ٖyI#54l\WN^ amVa=ǨOdJȢf9k"xt4dqllLhItPz26,H(#5EF홬) FP)Gv1RsӦ8 l*004 pαtbJL$*ğn~)ҸC52(/$dlʌ3݁t8/U#H~GKtܓo-zqzUNV#䛬SN^-(cd7{0۫&7O֙f2YMwIaHpܓk^7Iy)(@zSr퇆wwVu8jQpMR(J6xCjINmBl8,0᫁" DY tފU{,ؚ Y?Ezan<5['\iPiig׍\vâeK“-\˫6M=zhmlSCUW#,#5&RS)'6M]- $)M4+߮/v6n_bq򯶎spԝ#,KfA66:FLw q?vHH;B\TY6BNAh6 b{e+MgN,PQ: H@>PnJ谍)IӒދ:6DDBN"8N4#,4eًr<X5RER|6~>&5Af~.!]m5{eUgoi)ef; /#jP7MUk)fELͪlÒrFo]8/B~UmmvgSQzDoX>O0﬒pBU%YNQJD.uv]mVM؊nNRȸ*͠uҦڶ,'MTWGv5_[Zv8MQV5~,AaK]S$C'_b\B;ÍVS*mƢeK#;Oy4tV^Q[Έ 5T!Yn1XJuߤЅyb̺[(+76<>J=O'#,K!\O"[lX-3C;q؉9$>=DMk(Q{3mIw!i٭H@9i='G90A.lZ$WsːwcwqOC29%1'T3pVî]e=.I۪bepɕy!!LG76)%@$pK +$8( g^\I2RJ>fj4c߮d z** PE~E"ʯ3^p}xz/ho Bo3 :,&C0qmb2gDqP;/㴋'[~jX0gk$ZGwp]9af&ft"um K)}v?w#fF*h cAKn7|,8AYO.'{|4#,Df65aXi5#,Hk0{ O1%{ɛ=RwEVխVWZMN8{liZclARD7*%LZGJsPFLʨ[0ze#A(&KA[r7Am x5sUn@a,{ {t咴',c#50v . 4诤(݉M8!0釅M80_.#5jڃFvh>$#;.V?f"gOзqIh#}`)3+ʨw-z{hίҪr,L]Ndgυ3 ":R)*~:uX<3;JQghaOyut<5+)8EU, =JOjJCdUG5} W33C}Lb461 Xw-8!!fF,ZDMG'q9ijngb7|9vOY:gMq8#,ٛ*M#mɗһyƻKu#5c)IUzccukwI2MfRġdVΝva2kU~HלMJu R;bi+nO`H`kZHS\*ׂEYȟ&U ?,:`[$X>zY1/_ M,~*Zo7cruc:Ut CdBB5tH2.;gJF2;V/PA-6D!B HЁ"WT~:[W_eql"G]a:)Cǰk%ΊZvvZŵz_e-/Ba6qD<p]XE*%v&۲^?rڢw:Eѕ\tf ?t*sXU&\ 9bvH,"Զ5Fl$rfZص[z[<>*ϭ-Z&|`cTpvd=E~W|;vne\AZ$)]i4Q?x/6ϼQ\J!!)BӢ4R4+5$3-@q7G>ovrSY4c3/3?n~l7~mM|:co1l+(Xl\K9c=N7Fr羇ypꅍu]灓+Et1ݡ[Q-F~)UmE3 bNQqR7ѢJ1)(0J:fwάIŠYٖuE5:)@mR"{ʧ[.gEGp#5,v?Q#5YBCidv3XZ  _',8*,$s i ϰ#q}49w)SՐ[ǬȳCͲR%0%4oR*\x(|hBi}8 Q;F)LWs;jƆ75(ί@E6B(2ŋ+4-YGd]Si}r'"~|Y?)GRrE^m9*CZ/#f\#,TX 8p,dD ?c%cNkJW'>)Վ|[0 H[˚Xž]ZN4{RƗ^YQ'+U(NPTIeA-y%m*zOhf45:@E]Ud0r#,DzǶmQWlTʕ FN#,#5sܧho|pb!YM *3#53Yy,KpԷƚm`sMǮr#,X7s>2GMw)5Ҧ*?EǞΛ?%r׾uP9a. m^ D_#5JF4 w>Ǧ=:$gxƍz?noV&? _[SƿHOV8h:y.dNH:x^<nM7տeʺYת1V/\Ydu?\8 ӳ4- d@M!(>v!!i_oI5OAG?>Ɩ].|y6N*)奢CǿZaE"[}l#)M^RP;7Fc@4 E]1F:VN?}T޹`K~>O>O4*fy]|{/樧ڸmˌL#_[Of&|f޳1'HMC TЍ#,5{L/Zv}FBר59s p P)ZEǓ|ׂVZ=Da߯z>##~#W}Qfun|z[#5}mN՗P٣.]|f,n0U\`!QlC|?#5M#äNjSm{e##6?1./S6c(}p7`W;^X+X/+7U#;$u5 Ζ@&~iI`Q̽q =Lqb9U{_b^.E&L]^7K-=2^06yZq.d0Z=V/o wo kNU[JbK*VSx`OTGD{l:a3Gwbk/lmKm9p"3uFgwGАsH[4$VX<iCJ$ˈF\z߉GS&y^Ux"s?y~6"@`?%Iŭk*pt'4X":n= +{ <:A!u0{bUA"&L>|l#5e1:5y3mi+rJ._[|P|6̞HGy&n74󴣶b]ZtzCluE!(J9 5nv:ۿn섴-&rp]N6Nx&1>uGT~G$'fMtiG4='Ojzc=ÞԽ}0jV<[xeMø12L|O-?|BnYxm<!ejU#,0Rt'fCD1QIB(8~r~y#,B=er].?rmz]׋p0mFA1wWH7+rێJ\;ѰxWO^xpK#,7_.mOP&')AHԢ=+ ;QP q8S*ɜFq]P1s,ԸhXC>m=Pm&f.GAw#,oz?7hZ@˶u>tUYwdaIfJM|8oǟw'Q;EsL-N#5" y\~wEoU]3:Q˙ 푆&jeΘ.sC!d)o_T:l(ҍ=SttVyp֌γ@ogͮf_c"і~6t|s:>9?yS~qhH) ԣ&4T*T2qAݖsuXDzm EqTX3jh0Y!N=U)ͽ uw;yGB7o2&G~hퟍ!k~7{vi 0aIAD1D g蛔I[k\-D=SF 5i p͗$B‘":ȒJ)-&dLR@* L-RABf`]b)&:N&)!X#5G8] #5.Ņ:m#5RB<2F_x#,F3_Uש䖯q`Cgt[ܱe;f|P}Ӧ"vcN|ͅZfSGYv=:|ihaFvUKyZ7nrͮtng\pVE;b2hp˛O:0{ڟgu]ηk_#,n?gg͉ B/Kx/nnKU(v"#54Lb#Y\'C3LԙTc͚6~M0Wb0ݖIK ]&}]F_(Q`}㖱Ytj#, `GjhPJUxxX#5r3/Ķek=5\÷"RVw#,SךE2#'xGgM8}3C|Nqijkn6FB^cX; |'d<#дs#[;<*ΚҧCd|#54>dE"ߤ/!AE>ۣkymH\u@@cAbTqһl4?(1VHnKgM*gCgA;aa䑬0`#,;?QK6L#5M]Ҕx%'SI.s Ċj{DP>*.p`T-+\OQP/1#5ՉXpߍ`RRsc$`5 =DtY'e?؝`aߟIཪwqh5LB=V #,s"G`P44Q_$C '2ðuKdꑳNDռAPA)~G: ~*r*I5Q[:T+Wt $>Mt3j []&ab| Hg_Ԍ_9"s1KՕ*asT541TD $3&;;4cVv4VN-i}8hӵ|*p,1l2iR9J ѹ!3Ҷwae٫ILسJPs;tz:ۻ S"AӀCuؗx(kh2DF=vH%w 燴d :J4:rK%&6 eN*:.vdf"PNgqë57#5p#,g#58˼Spku(zZi9Hٚ!l")'(q<ˏy' ?{ZqCoP7+#=W=X11q#5}+-H7 "كL ̯|a( 2m ܪ8xH SvA?̭و Φ+c#5r@̛׏<]Z QD@ji:Wc֨޽zp@Ljt4>S@3I@/>"2 #o?_)6 QK/#,ss*n3I}WPhqݨr9Y1#,Bx0gzBW\ښ;O͑;K \#5P|.o6ö$HCYgy vb # :l⇧h8 9.®4<`8h}My,F(XAa0v]1$쥥^MY=XK)Kyf#%N * #,!5J*mPǬ1 q` !7)/[wuy݈\ѳ%ߪ5h;r1$ ">v1CZ×iBk'C\ viOK>R0ɱF, <ТmXӞL=Χ歃M1}O6}a0Y70/^↍oo6C 9FK5I3yhӴ2=ӭrtyx{/փ֚IBk|c朐4q[CTaB uɯaP1l?.- rʑk(o5#,$C ǁX'Wr}P$>vE705wLS(R@df2sX +\>~1眮N'gطpFU'&˯KvSgR|L1'ldH{Y2U]5μ9ܸ˷\ڹCLϫ.#,O`m| k 0 \j$aҙ;O>^߸>:x ZXhN;a{˯<bx.x7q3㷆N Lv=I'/%h4ӂ^Q=rV^|etID4i&UPi!{$soO#Ilyk2㘀&@(@z|'ёDOu!+үFՍ v0|%R!5Ym7+PP  /LT/;*WŘ) <3ر'G]u'{"3Kȸ88**F@[OEXFxDvWtVQo?,߷,M'710CT55۱:O?{@@_ߔiTkJ "Ȱ1_3#*SeE0=&pCDl4WU;ș#5-Q@a9&m-2'pI*9?K($~yᝑ*dOE N_/ߍ#@~͌c%ܴQ*2BQNlqH  ~$@J1T00ɬ `H '' _v֣Xm깶n"zpW|.RBvBd2CF67֕QWǤQ얿#A2E~P&8U#.AZRIϸ2p{/]'fuך&I\3!C)o}ZFxr@ aiJ$]g'&E͊C#5A㞥~XO@UW07 lG#ៗ7 _XRצ5jllJf~baT0H a!ǿf6L280a;A/8uCB#bP E:<]\))Ǡ1&T78ɵΙSH1cq)>2Oz{R6· ' 9REX_x Uy B,d x ԨBxݢKxdi^ʅTHJiM]=*&;7xR%}8 sDnȘ )B'<~J hzll<)Ô0}ٰ3_ i(QgJSar얷y(rpBxP?k#,B=W#wBvAj4T \$ώUPKy⯿ڜܪ'u3_*́GUtA펂H/րEuqң7;f]4_[_j'Pj@;_J >P,AdHl~S<}:jLl? 0]0#5uz_9}r{{|t.A׼r)+T(@UhAnn@CaCh0wb* P8w7v'P'A+κ陀R*qx"Z )¶X߶#5r$>!r잯~C$OwcB˛d6pt7;YHj1r1RIMx@Y*W|q'5aap)R"uOfײxs__Ԇjm¥I5P1/E=?S= z묢\/A#5[ݰ#Ej956;^%d[HN_ɯۼ #,qGr87S}?} y噿oIS9lPRYFJ$`g9rt$"Vs$OCɑjhj:=BnNNY-g븾um=3GPw<˺ CTu'x_K#6v!BJ10׏I˺AFxhR\ ~ h y9[ZG!t ߺwrĤWP(#,5 kBP08~':5X!l/'zWM"uQ7w+ڳڞm;yQ~fӘnjdYj7S83,#5]t]hFjfD)hD=2~:Gьn/i ×oa+Xnz_tf 3<76jm)*ևvnxߕ0vkgFnK{/HI/vK[T9Z:q-U!qMS/g^q춑,)J&gF1؜BPzä~Oz0?(:+,%EHo٩#,/W8&N,Jَ`}v}_Ϧo׶sp}{8z"KL*{x[^ҵSGJ'S>5 ľB{)NN=-`G#z/79=mNoTvOV0b Tg4x*ۙ]4bDU2WTfWIl&KqǷ#_qȓO cj@#vZMd&QaEOuA) ᥚe5D=,4$3V盿ڬ2u]WVHGAy^M;^yRbgKyI鞗iQv/mb0KpQ6#me#5Kfg:][hu\6g˜E.*ۙXW'ƥY/Wث.Wz93t!hb31)#-pTj[l5i93;$ϵ'MI+*w[!.Bs! UJMhN#k"Wp5ELYH#,>*O{QR<ꮠM9S飔Gh|Lx@t1.#,B";71l& E <f&|iGtUUM/k8;n {lPz>J~Qq$5 q04Q|oz پ"= tL&JQ,@̯vV,QFA )P wm]t.ۓ&pazg~yLipbUgO<48x0˄Lݤ{贳vrsΜ`1M>Gk4qf`BgVHwkstn|/˛u7wT0c᫭jx}x6 n.`Ld'+&~#,#,U<*QCi;[l()Ͳ?,QOfs'r=emx|ydDLqOƆx=I-dΉX.GA"A.PU} 飿w>˖(9~Ho hɻy _!Aف}5!GGRdfCvcu>ܾƧX5gs=E?-en𓄯FWfTȰYoiMH!&Nb#5^`$Wޣ7H `FRr#,KY쐳#Y`3=r.ޡ ϾkD_7g7Py퓳-ξ!PcdehD+f~|) MPVQ&ABf'_#5 !Dn/zO)uq#,.]#+#5-+wM`Mr)!s7ShcD;]S#+cԡ89p! jJ?`|Q.\!Qf`G4XaxAT)=/Z^BO'W&I&/V3b4+ x-hlgՉ)e<>ok^kml'5|Y#ntp]Hy!hB2SokjlН38D:eFZw_ !ϕפ B#5SOTqNF#5G<_խ$*ӂeb`?_y>vWХ#5;b#,#,6^$O9e#lh#=(+?scY8u_ZZ(82F4ۚW[@VЩ#,FJ1f?& YẦPՂGɛs'~ǏJU4un+.YZ`Wk߰P%wGzCPgM%d$z{٦8|yNPO>އngaxVT5,HY_U\EJJxj3#,#5'*\Jfc SY[УUV64]JP#,sL#`sl|hn뽠d^նUQy+#,O/>^t@a7:\t޻Q̡f3y&A¯_]7= Cchm)FA9&OQǓG3koY:bZ,$DjV:q1ETkX1dasQ)L]= Re99$ [bz6#5 j0L'(㺺gDˈZ]ivFStEt P0 C]V` d =Y?9o]Gsvڪi$i;4=QUmbHsG),яXV+<|QF^#vc +}7,*1\&;+vt=դFњzS#,iBAQ"mo#5n߻`'NAN8K/I6vfxk4!?ķun5mџCB!^EXꫬ^~)҉GB6źYˆ6LI|(?HMR0xBdu9IMoovf*Gç1]% rZ|osUH~E-KzvBo RVi0ca*^ @-$04@I.8y:m 4$Cl"B4g"L9mỀX$1|YQX*4AY?jd~׍/o,߃)tGD;p2t5i^@G6/5!@fY@28E׹ś]`1*Os#,E19#١F?(snƵ6Ivip:kC4,@BTBY-#5r?nxvH$({P2C"?æCs emZZY0kl0)L@vw'#Ihp|;yhq|P󋑱Fn"'p:XI8L{'|'3)W$s*wi?=E-&f84wnH}:jKT7I|N%|bZ(P` '@V8nFr#5/ܶNó5qm=.KIt>1{IvȲnKڵO_&j(pBv,dŔ~l$49D?'H1O@C`ykռ(ޒ]E{v*\J<v.Ir$)fft;#,ky=Dy"n{Q*(zskΨk1 iI9 2#X鞎0ݴ|rI(R6#,3YsGB3w;76X.kFaTԗP 9=P! NίzASqãg(jWp1ʯT0 Xcgn5w4 cg:EQO|ye3 Y}qs 63AN໡aIkr 0^?j"l4p';\( ^#58CxgzǠ~.;˰7,>(~II#,geP {CyaC_j}3w:ņc_7xQ%oB!E,ܝpBB)A+#5 vy4,rMHGZ5`F;#,8q5ןW_Fȹf]t(ޘu\msڲ6dW50d6c(Nwnkӓ. mP3Xjn8>n'{H,D"UUFp /*JɎBcb'i G>yBR3#zwʉB$Ȥ%:HU-@T}2&!?oH^p{<˱2ļm[6,FkXn ЭN*6;;7I(ܙHYKfe$^Ba5Z8S .s9? ccHN勣cQU dx#,jq(!=^>Z`Y-<=!ۑ1U,O"E&U9x~ϿViwxw"{U#,cŰNԔ$>gOngYE{w#5>gfuŲŜ}U AUO廈~?/g1؀%'Os9^/g@g@&N}JA@=5&F|OLIf! Y3xg;ho` );9$#,R x5qZ@W+ʿ*HKA&Mu聆 FOO>{s>b|'0#,?q$*AZaI%UIQKxMߠ#"x|@#PSrMOCMn4Ig] pώ4NV>䟅 D_^?X?q"O0yN'0G)ܑI&ӯ?wX3_+ cs#,G ?x?>/(с@Iχ6#H\zʊo1s#5)k;hBn @C@_,Fxs~-Gofșz]YD0DU&Thج,\lZEhD\#5wlfv5#,{{ASM<ITRDa#,ujeS#D[Fr\u8CۺTGT(T#,PljR pHLytda$!j.hbA0qe[Y-N |KgK[(+2QbiQaY硣{G/2 CTǟP{?}ƻQR?,me #,\s Hmn>C.wO)#,Ojr 吚#,ki cw؃D}ư\ۥ{mQhLG*ec"!<ןKqC׎>OҲz~Go*`},2Ѝ'gaGMC懩 G狤rLn!}r9|R{V#,#k qa!4(vBʛN]@k2 c|-ُUu ]w4BNW69'&=;z7olSb#5k<5VfJiCd&߫9 3ru#Tf]Љ4JR/y~50}'xT:2Y=E}yp43^߯FFg!a<@چ&H1r eڊBEZ0L.=Ca!iNpo }aN^z#XM~x#,Ld噦F?q_M7cyr?5b|`dn^0ITύ%/glzNؽAK| =(tHed}ZLoݷ>_@HIYo6}LQO"2x*MXtό@E-6OP$8{ {H,"~{lyIױ=_埛}蒲+j|:l'gi( < 0#,w{wJ8,cC>^]?3[.>nQÔpٍ @ ߻xȓ(&{υTeH-&, af"s@!}a!K"Ɛl'8{d\bYH5gCY]@z}x0 R&.PQ]TMǼ= '[ӳ0@Åxݧ7<9>r$HBX''3f].At4ۡv {@W1iC]y|flt6$O&Ÿlsk$zx'g DU`u{#,D !(:t DHD@`4<9~Tʃ-~Ra@ #5SP:{C7x>S,s.É.iA#54Ex|f=+t*#,3f54$dF҈ P;'יRT%>I7$brSx'l64%^@!'~6S=C'` #5ORONAcNTTsX^rI0{a 5(E.3;Lkgp) c꒥C0/{#]gb0>O`$2Pצ "$C8Ƴm׾o6/mZ]54DP<(cbHA>O,$PBf>]ɹPKI5yE!巄P'/YOr_Fx#,X.pl=_`.x~E?0۠\MhrGϏ|(*JHM>tћJfbr !u$fUXLGpQПVf6ID7qϾUFc`Qcg/qטBK >I0o-iY7ƃo[r(~D]B:,@lcg{TgAx Rr܋1C:kqBZ= Po,DV)>3gRT._Ɩv1(22̱.AYH1 =;CX-9R0ٛvf4:^M@IH!R{LP԰|Gz;X'@6OHuˮtU)1')]^@Qa 2 Z0%R5Nf%D @ faр[bPսf~F Y7g7R4B6a5q`2غI].d8:oX~U=Dz#(t'CDnzr)& s\1BUR9S8H>S|!s+U??\@I_]FrnX.D}1ࠄpTT$TivGQ*M57-{NYkFQ);&38=\U:R1k?a P~sE;$6'c yo37}|W~ u_}i`+Ҕ4Ö#,Ff@U50Ƚ.>$Iqgg/uCx;ew,T)gHyc/g~ڃ!yϊ TU{Rr7yѽ5jǦ#,oMNl/Pӵ|33Ǔ~WZYZ"5ŹxCޘy,ʪ#5qjnfAKHqD LåD L4{uxl;ȳZy=֨h*Lc[+1Jno[2آ?u|KF#,wrvA#,M|C#,>Rvګy{H:l߶,,(CK[DfVPQMyjܬ,]H{1wo}}5kcuyO]<*-N BDN=syT4~XZOVᦖpS7wBGPpT&_ɲ. /`tϾNѮg#5,7EqG"?l|Zus1F̼Yru-I^?s荃:~#,jr[%hw yr'ePB#,y$<{"|1+Bk`s7lfp:E !9bsOLf!9ǙфKo3r]0t fC7%`0CI*>'ttP@IQM\ա.yx+J(W_F5$Zb6h1,<2E(jT}``W?UkPi5$ɕ#Tڊ(-?"Oޮs;KdD;B "K2v3m߇+ԁ{%5T_ 8R>!lhY#, M@rGzO wΦM:#VF`c JK~;g7Qt'g%F!)v'AyU+:cl0#,la2a \pV($IGni4I/!jDo%X2ʫZr2$񛻭g`σ̌eh6;`MDw1&d -6#|`٤N'pf};M! psY I~3OZbSyx`_Ah]z>35,ePF$?iEna{Txȏ)ly:Tܰ֍+DF'(Oilj@l]0~e >>>#Џ:\=hyQDV4,>K }t=>dO7ů崇 e<ra*1<ٜ|աS$3M;?#r)vס,.#Rt/p`N{DyWxɍ{ĝ#,Ő 恵y@GW>D5M{zzdUE S'rN;S;{ZoP#,]sr.ǧg^vkT*V4ۀY4,&өىD‹5/^RnRB[ Ap {C6W;>mfok`dcݬ:[ql#Ȑ. c#,C&cچҜ' !Cf\I9CKLKY1VLJxG3y{ڌQ6oYpsv=:2Bme5ٶf/9-pp9ӠE40Qy}_fW*F,:"db,30kǤmy7(&4+݂TN!85f;#,ò(,mܪ"NSg5(#dZ=TlErץnUUD77FW"oua될c{Ghz܍Fwx̑ہͦzY^dWBMuMXѹ8I*zLs!Պ#;`6Ӧ.2kE_TZNã+,P+a^,'2:S#5#ܴkSĽVW.o{/cB6t=q CSXw4E-4mQ7OQMja}h'A ꃨ@`i{\ |'ȡ *\U{aqE)k*x02J;,? j==%_0Є5w <60SW:?tAkd"))Oy80gO$y|5!?uM% bb~gۦЭwDi`ML P#,bS8mPh ;)g! R3{h4*+covB&D#,#,ɓQLOٝGުkڧHhe<=\1bYYy#E9iNA#t @V Jabq6"S~:ye䞠/` CG 61w4߯T4@"'gǴJ-aZ/-c[iFٰ.xz3ߟ^ƾK3*/ B7= C>]TZ n7}WdsRIPw#, n`F{ t* Jο<0|<|ρ#5HJNo A>XDqs!zN++@4 J ʆ|g$= .)??U٣ͪyn_AkU @db:s;b2 rO ːJMj"AAZ%:#MP l`Q#,*ne'|$D'CI#5 h=x\.߱WU PK䜠yyOH 0=-N ӠK"7c Oǿ/Ix!NUNT8D)2[PuG~n3 !1u{Gc}BМ&v%C07{齙sy GmtP)~#)CTX-)!<02!iЊ9"H3zu>iTͦLY*~?υgӉM.Q4!@b(MFʣYY)QjѤP*ҋm('E<6t=P{ (RU#5PH}R`ȫCٝcUrBNL1w#,8,]ʠHK!sƓ&sF}^X023N;"6y( Tش0ks~L#B1yN{(끃S[iܢA1G'DNOW|wh#5K'"375_LVLk".bJulWx-:GihBE#J z0 FN|o;TAV/>[) _< 'ͩQ F!T*Q ^'|PB&‰طog{% *jM3qb:{hivqÛ81Ѐzl,qQWX$&,W:w2?hC *%zy5°htm/bvqVZ-3:~:~>)3tl .0~aӷx低w#5n0\ tL2X㿟Ir?ªsӾ>#5u qyfR鸝2T(h.vnO!CiKMhգ,](ƓӉ++Z`ƈjy1nn80hrJ0o4klA8#,c#5_R!H P/P휼!a0UdObLƛ#,mwfۢl3oJţ cmRJ'pwsW=G~v>dɉ#5QSo^>\ۖ6k됮K`^軃񢴕% Kktq3q?ݾ,0gahfg."{11]=\yI$9F,0ew<ń&2MZ"F+K t+5~u&+k T%СlaPH^)ػl340͑"t٣v#,G;0a {*T38GopM:-1 4l}L:7{݄T[ejԏH09kڟ;g ] ?bH㯔IU_g63#59P]hc̶M"0dq!a%O_23Q#,|Z hdKf_5 1S]_Otۿǧá2VcҞ܃P_5$&@%j!tۥP#5*n )\DT#56&46`65~8#,! $"!1(:sg:yma$ al,}Fo{ZppcqK9wD(wM₌:u:B~zӳF7m5)vm]&$n͙#,z!#5=O~V-C{꣖Q=V1?{:oњL#]]ѣ0E)cB z)YDlJ(ufޅ--w8-&k--h#,MF,R͓\at;6#I΃IrCrF#!zҍQB'uS0o"4q{{;]1#,Z7&G ܉:y2p!o2~?>ܬ91O.5}Ϸ^?afnޭ |4J׭)ڽptv{(gԂ)~z.GD%4{}{{t_N>]udf*u6Z*--dJ@u* 08Nr|SJ@)AWyb[ Suށd&mϴsy$ ̽lèrX|eJaq}!BD0US8@m2JT4,Z)MT̍b)lɠiFEdJH4dYCf0J&Ŗ3)Hhwk%*&"$$"¼q:'CvCRC-Y4|wQuI T߆F#,4#,ZM+(7C^ttx.rYXf.Kd5`s#5iK(0cϻñ#5)ephf=J9i'EXIuan1OL{Gzk61JLWl2` ³+GRӳ53I͏T1ydi3q1 6dcHJ#lKHbfF i*M)2&ys#5A(wŦ5Ɨ,٬k!"I3 cK#,:+n<'i$C{f`sǪfcdb.xMj0O -7݋ff/ |ڢ}NtZ;2j&5#5cJ_Vf/颩@ UXzZ5~&7Exmm<Q7摺H'$*"W57+W3EdK8sSݤ# lO{mQþ|#%Z\.]S7i_˞sh9ѴblLFEZ#5M zD¡,cUGlVaB}[{@=#4?sY6Fu\)}k6Z;Sfșc>_񟾼ӄq()LaB 5^$}J}4uŴRZ@$=l A.Ŝ#5eGu߸vF3T.zPE{{I^PwWƊ/F,U` H,IsCy(pv^gvxDb%E6pa P{٦MqfCqI>_O%$෌eEiu1Yfjy&cƍM-da]ѳfʙQ۹6Z>ScLGf3.zHG rjY3drIVM[̘DfSL׻θrqC@Zi7.!fd֍U"ӓVW`g uWqƚQNAd|K)!`7{3HF1yӵinۗv֍ @] Zt5R)ue":D5-CVOa8M|]!PfnNt fvkśjUWN#,IU pKa=0J(d¸p?#~>5C1<͐NN>{Xqnx6Ɗ,S^Td.(fsXL,2Kc&MAq%dnVxє95N1mA.xvRߥ1}Wl%q0PκEtT[EcZRA^sUmy:4-wɲPAjV6~2YސΣ/7nԦM1dj(n0vS[2SUwCtS9.IHѻ CPh^r#5%6ձXß1PLQf]ΜCr hKmD^#,p]3˦AhnqQYVrGîF4cvVQV9kq=5p#"ͻ]BB\p(I! 1$2m}5&ţ< M,εZ2e21m}e.\aحlmYHϦ f.}i?-aޘɒ!N Dڤaۇ)fuAۆUa4{ Sp >Prםf,&UjhtYdQȄ! C(yBmp[Kp[[?`T[ÖWN!1r㻻l*_30ͅ\;\Id+CA.R%ҋ>soKrlYN6hxv6}r,-P!G>:J"iݨcL,.#oc&T6FkdfyM`ۂ-.ESч4>״]A2)Z/WeJU#i$V/6Cj7Ure501R`fÄ䛃 .q\)#,,iV0kQ]YAxhrh$sLQ-#,+!uL'8pٛl\6usri^fӕwhCQ;yi&5j!$hU=r8h#V)Aeȁk,^j׺#, 0 &.@9D#giYqJI}05{-Dl|<r$/m#5R?ZT%[J\*އƭO8_.YC"SȊqITF5aKZSNQ^{bƻXդ09B8vEJ X,P߾hp,i(ee!K\-nˤא^SQ&/$a$ɵ2aj9ӭQGI1c<"!t`^H^Xj*H)(£ >KA4M&*]#,M9#,f`<A9Wi W` ;9 7黒GctZh":)#,&y0jq0XmQPmk+ Fxnlh.ivS9TD2n(ixqNg9&wWscW!HT2(h@D}g܁'TROtVB6bӝyB'~"tv?gtI 0GA)R"l#58{Af@0\y/41-HcLhc:\-u׶md]aejf(3$ׅ6oqc[;&gXCRϜk㌪CC`йM%EP|e g?go.ߺE%B>Bg|l +=J DL(QQ0"0TdG60C0ۇ5߻wk;#C^J<*L5j#,q?tM!h⒊(=;ǘ_TѪ0Le+ `)W'j?-ԏBW_Oj . {yC@N˺ҜIĹ=œ;KϜ6?T$* ح=^ZYuG~#,a&تvQQ7kwf;w]+cbk:qwQfۼӋ(hTrMr@ 7#5IиN[D3oYأ!e4$?=SX(w#5AL B P 4}Ox@wD>vNOXCΡT'j#5DRJI0I100`>Qw9I_8HAJ4K>uG!i<lV&AJjE:oM#DLlI$xwnwx4聁)Py+m6ƀ+dԃT#UjlĪi~DYc4~E)X#qDF8js'.bta#,0l&暬سK!EP~kImm*)AZQDNVViAˆ(HՅV(:1&0czz: #\čID)2P ɱ±4w(ӌmS2)`@xĽc#,ۜ6XWŁ3"Ct9 ɟJSB mEBEؚѤ gOt\#,L(~GsfMBanƯ&nF+UaG;QZF63iǖ:Á෽HYev_ c}b#,oF3u 1Yk$l8k(brt1=7 4Tԫ`dCjGٚZBԵf½d:rd^Y S8'u|Y-m<2jb00Ļ8ۄ_冗ckʰ sC6d|6RnC4r0xw5t]\p"v4;n/ 4*H;={Nb ʣ1)OzۂX|hhl]C jl#58I(3=W16]'gLVA̒~ŝUDAsJ/j-Fz1ZmBz#,J(Ƙy7Q1Ry윏<5u>G@OGK s;<T$(Oa2բ@@"o$ѶPI' %jZ;y=4q1%!!ũh'LŌ;}Վ6H1JzvYӮ8IS7+s]n]\u- g\]vUx#5˷Nu{dٺǷIWvM"e*ȬB $8)"S?/O[FacUdJi}g'EG\nP|6b7  LJ#," >mp'РoOsTyo!9`oJ&3 S22-dÇd;TtbBG_i;.~SN}e?Mp'#hl.D(4[smU<-F6IL;qm%C6~p:qU \UCw#k1y^ bu #50O#5JPA#5 Z9>.jh#CI.tЦF2.K5MTݷ5 ˩mF c v{:|ss͓{0BW0àGP"Y~ȅWwO1SP5#5P0J0RVz\^45SBShutٲTƣ*kQ/i53alJR)Vimo&gK}.ڔ=dem$S*U~2][URbzkK)h̕MdifDxZ{ P#5!B 0jR&Qj:+nkRs]Hbm.]W]I%;pUH%1k*ds-iѤ-!lWc[ B#,P$R8'{L7{Lz5Qz50嘮AD^rQJE4%Yڻ`XK0#,HPYCAR;Lt@Cl#5t0fmZSh5J ] 2*ʐHҦ)QLATlcRJS2dYFmɐ4PQ%lKJd![2[c@ѤCQ$Ai !eF"MkB/ZcC!m(1 !ԫAMJ&;DP> SKMɻzaǞ{De^nD&Gc6>Go{3 L ;HLjF#⳹ʆ@X1>'R}!!۾=Jj{8%[ y N'zp( z#ٞg2{/ .׃t>OCT6b0dGdx,ҽթ&wH/#,pIGneMr΄}.#,9ز ͗GgL;>ͶL7' P*5bvsȏM&蚮OHybq2GS٤,Y) ӝ3>cU>$:H#,v,4.Z[~B(l\6v}WNIa \CSRBؽjB'?"D}XDDchtȥ$`TK9j^rV3C2&BcZ#,Re.6"|4Mc@S#,3Y`uh"mrZN r()(4ڌT0`Ӄc %ʜ:@6~t'C& 'Ӥ#5b!t$lbi}Xf֥P|MgeM&ꞛI9C6SIs6Ayw髉K]KЌ >iHo/E|G3.2?1*{M_m),wނdm4/[SWvÔi $Ipѭ(셙b6sKs#nt ߭-A-3IxTQFS~Ȑ.(~-jVQ-D{28+PL5ia61#5KDojA@#,Ay)AKtˉ%#8ADTǟeUUUza#,=d3}͏6VK.e;yɰ惁1gyԝB,!BDY 9[zC0$uJd:0 mwsIXэH;J ]lC֋t* Zp8HFBv1Ot;Eas@ "Q/LikنAHFHmHfH1qEF<ʫ76"9C)%M6ƚ gD:e6`&q>\=`rcuy#:`""ti^5fWœ]7h pNh&蝹fp'Ȩg绖rf]tJxW:&\A)(Nr0Ȫ()urPhl-GNi%hR)Y6$]A?|%x65*W&BJH o mCZF,b>4Ȯ$Yp1(hL2D@O:1>6#,+y;)Q>@#5ji% > :1+;L#5)6c^QXNSmD44 yNyt`T2_՛B7 F.; K;Dm&" @0!<'9|b#{)PZgTF@'`R`WNWkVv{TtQ "KH@IB=MsѕD׹UίTrcfAʃQ9[n5h[b|nFnͭo8?zSL t&ݸfJР~wONa܈HDʼ"Jo.':QE*%0R`diyzG_!~?]g l}=!bJd_75HH0 @g`2Cge'{!:"yW 8+]+~Oga\A;`T9Oz{\@P@ @]p^[#Ddn4~ݍk ! v(O 6M_rd@ƓU?w[`6Y,…O"1D:jҽە׶xƱ{Jf#ě#,h%Z1")7QT"Cf0Hk jUQ,cJ#. 8CvU$2"4݁So&QnUй!ę LR;qbHokXdj7%#,#5GD6!VdFX6$M/KiÆL+3ybbⴥn#M#596l. ݍL' rJ[2![#ۦ2Qcsns[oonz!m&ph#,E&#,D9J,$5`i0DFFQV(˔e&N4{x#5El1Al~ZEJRE) :eOlRO8|>dL%Y88aA6)M:1I$#,_t*LI?{}UOv ?J%H_F!Rb!$ I#5d^KۦRiQMo% %2R H ]@9BHˊJ>x#, fHbvMFBr}QO_7#,Jk͎L)"J1#QNkir@e#,i,fw2gD ,p[EFϼ?Le;)G-#,) #,XmQT)l7N4̴(™ e Tv:eNCixI-Lܪ$Sx)1 q"ߞp]I:Ū (#,P?U!ZR@-}H1l LGpۡiqrnb(\&iW 51^;&|v) ~#,OY^Y@:2>@(Q^#5 8)C?3j>w?-u7q]|^:7N}#5]zsfC 6~q̮fO$2|T>d/:h?|#5CFU*-HͶVZjVm)2IlJ!ddfNF'>'%u$ֱJ )R)Oka~&~oOi4=f$$>@ۉEvERfg#, 6T#,3YS lL܄o 1H"j0pyL@I|C|{gҟ>]-$"RI$  !$ύ/UT,V I'HFZu7ʳIQӔFD@Ƴ%CQ8{.Gu9t9}[b A`!! $!~UA3ibJ6P<]Ia93,]Ll`a̺(#5$՝fir΅hC#,{->6$y-p1^e{W]f] Ρ{7]6^ކ~o;Md0_h(qO1F,(b)&BfѬjlu)vb2e%VU6#5JMAf-&330̪iD#,L$A/3~*Rd4vRtT;#5ML4P* JJd w:``_c`PCTi?J L$muظw1%0mDA~WADŽuПX@gg0(VbVFXS>p;$#5yđM2Л@:6[r6ӻ"E9 "O<ʨ{ /NiDKF7>9brOW{TC^<>!7Aɲi I7a ,5!VnBl`#s#, LvOb~d#56~hCI&꜍Ét]NMt:}1\#5O*gZECQ$Ir-p8tvL [vQ>#cM ;Fԛ;eKݫl_j#I%#,̍ωN\`|`n"C:s1L{Ct-TG7+"2`&V0Y/^^νEΩ @؂@C/~h3v `9@{4(.'Ȁ#,!(: >nߨgc*$4|'M9=~#58{=f9 TW?=P9{|t "È)ߞfpyjȩ@zz'3~J|8MȴN"(&Tbd2ń8܍>[>YR\S.J$X}&Y9Z|>lp*,l|)5FJqlЈFc !a.q7 ن@/1O5bfa /;_!Sv_%*Y]3-suպusG#,rl 9  cٝjv$hcfq1p?䮷"𙻋#5TX~lgPg;xNSB1 hCrYNa#,eC0(Y6gɸ!%z%/|jCO!U@Dɺy}1ST0US#, 4"m<68҇C9H0f$<IJDg;B"Gb]+g!t %UCC.;QnlQNC7Oahs"qXy6]. 2,".A6Ne~sh'8N Kc= v}@{Y>%Yyyx7ǧva#5bP^޾A{Dvp#[XsT WpW$$#,e1cI?BȴD F@DMǴgbg83oN\.UKei!$#52ثAhƇnιzWJ&h(ZXڐ$jB(+\<ębDb2f398+"%SPѸݑKQq-![Q"mؙbJa?1:r/͘#e#,)e `4E6* ?=؎w=!6UPŢǐ:8a?1$zmC5;geG猣9pǗ@X0DoRhH>xQ5Ǚ.Jy1nI@ha s!jl~-fPu&[8|f<2qX0.C@t2Fb;$Bg\ِDMv}ҝn#5l,~Zp]ҵgqǿRώ}N}CN=!=b6sޛK{0khii kP{ -#5R∁5JPIkQR4~όK|˄@p>DB%l,x=ϯa[n>,l'$ɊTC 1ALnJL1"FSIFd၂b!TL*3D'at1*ä:Axg3(SiI=Q12k 'ûCs_LNtevfHdR*U9/!T&E+j%u(u_`NB+>󻻶boC#,2EdV0W#(Ac}hR,J LȌ $XR[mi Q'B8QI! AJþW}S]$C=>ߊ-H,ÖfG ('S@&_uĹyjUL(\au-h>F$A}M^\iEFB mvv;0D=!m E/7w:=>qy4*;xxkk{3>r|mi9f,ō#,?0|/\>,#5-ܿY.@PF&Qâ=#,s}kTMA!(Toā?=4U91/uصa@"b͏!X#5o>~ʠeY#5Y9S|H}]e`RAn6,gd8f#,?nsm4x#l<Ėlj &0%cVa>g4x1 O&TF*y:3n9Ns<M$XQ<^+I !x[_(n8Lq D%zrN,0d˛u<ϲv#5||03wfM&'j~=KA- `vcOve/o-]:kGbM%^_~jP&)~?Ȱկ2JC|-Lt$x 2#5X#,!,5s-,re2oCbv69b~E)f} "5#5Is}6}/_;~QF`P_2V}ޛret4jr/ DtBDБ@AJJU Ri1%LBϿсؑ3;.~I{%E߅vlhnh7"m <;rO&ٛ>R{Oȸ٣_ ngפB/b4I#,{dٍ a>oϟ?gT!.,X^ZY<`S.#,yr>'U7i:!֍j` /S a* =|rGe`IZgKƁGC2јZ=89S`$4 jgQ_E__\_"}_͏)ufR>̑"!UzFX!'[8Ȕa0C HY]%4HÞ0ilgW.R eugƴ/h2qJ*PTn{;CұxF0Ԭ| gN]a 7:V !q`Ӎta?OdUf W_c<=L|6>hCm23vRAC# Q ?V!8ԃ2Y#5i%UrB3kDP4R%!i&&aV>.Tiܳm.-Fw($s|2E#"i14BDmCPЛU= Pda#0F#5m lddmw ܞCpB(ULq;]5%*VvkB())8P6^+f5R^tWZcPұe-"*MXJT͆LkdL:umۺщ07&8b.em !4(bT0cJ4LbA:700iXCc#5|Jd6XJ bHkSdf69 Fӊ845aC^ډMӬAeE?KiڑHpg]MS]dz;#5J&Ҭ&2hWyzMċ102BW6Р44=8`Bb4`Ğz#5i]<aI9u ՄZ( Pkc[xfE 30eGQzi҄cw!X#,i f[g϶*άS#,sS4;LkTyֱ86ÖS"iܤpVtm'B-ѺlaNQo%1P,~u2?!HMP 8>B𩈰] 1ke<Bdt"jfZR:gcDƥԫtP6KaDV4-4VK\Hh:g#,XJG<:솶>F8QQ_)Y?7r88ե `ƊČ"Z`RTb8}\(a0%L 1pq4B0 JUjPְi0~Uǿ%#57 /Xa8};rf#,PpW4"LBoR=~Лo,J&&w!B1Ŏ"nwݸӯ>Yybv9.QGwQf%%tqKa/w|~"!@ &;.6tʱ>Pۛ:IWztd9ߡwt#,~2;a.$2n˦0/,eRqSzӯXV@Gwg[1tfnqi在ѿ׏RާqkKaFc2Ɋ7vd*PIhfO(tc*fz)fZwӶ<#HRgh Jmn Z. Cbjb?g>t]Ud4e8rP͏$ 䙀ctO|#,ZD4 ]AQt6܃j6L#5W% "HS}wY9c|>O*Q"뗆g۠4T&" #5BRj_gEٌ&68`zrg 2rD7PW : d 8P#,d D#c&sZ WI4.Q (mI7`-MPI(1cq a3#5Um梆XFŻYF5`kl``%e?$5 T '"0IgH(A#,fFePtb m}/;R(x.b`(v1vl&'bÅd0"N0@8)UG@#,*+! w![ၗܠvv'@f`GZDvte $!<~@bRӦCT<LT%?sLߝ~a!20RL!~(J\Y31%SWbג;J7f,RlXr^;u\j]Jh !%!2 EB*șK3mFs]#?⚅t (9p`O=#a}9vçɪO=R@<@ԱbZ((@CBϏ_AN'd0k ܨl HY'_,+=D&9s"j@#5l@USJ5#,?쟟;>caT*XX uAGc4PI6# H~0*̊A-D4?~B/,2锯WxToj5D~W.IE's"UӘPŴ#ÿTLm%i1 z?+hC}dPR "bpK(A48:M`+!wkTCh2+R:+s>v+1{GH %"US l*n~3s"UX , (b XP>tCGÁ= TE1LJQTHWZcpD5` 4_0~OA#,#,E⏈#,36=F'R\|uŀj1"~CO|LKL.(ڦ0 !+o:(ᙔNQD5#,'T"y|=8{5? ^3Ӏ.%#55F#cb%Y)/Rѷ:Z%"iuMvjVuZEm6!f6^4UebCuPQjD xϹa4\$!')Cn*AiLq$Pܩ mA*4$°4 JP71HCf.-WN=A1ݨk0|&c0.: O+E\%1"bW)" F1#,7#@,< #5=gfv$Đ{}uIP#,vo(&__~L3&Uly8ТsaapN'MƊ]c#,##,aIZ7E14ecCsQmLXu%#qWCTi $֛a#5Ƅ6n9XNK.6RSw#ʲ7Cd;SBqaG~:I ĂBf8BD~CD)#,H H!LQ:z?&Q7_<>ikNtS2uXz$>,DT0? W)Cݸ('@,؟u^uRd v$JO FVZ3祱 ;*_uɋ9wQp;6 to 9%~$)&XWmnK绩3?>izZe89]ZaĈVtLi1!q8_C8A~$:!J>ƃ,B~0`ة=̐&$pgˏɆq$W>?.b5&.*ib#dGc6rdoW9#bz(KD`JݢIQ!iAP%'d,fqʵOF//9eE1̑#a 2]Z3ţeafe{̣횡4ԣ3ǖN<ߎ|mOh8Of5(H '! C dQM9ꙙ:7V\p~|cMVqFs5轼̝'j}2^Ǒ6 lVCf$AKBT]IhY&N=; zo|LUWQtw0t'v#,T Tꌓ , (w# 5ቷcc&ܩf:R~7 @ꘔ&G)2r^"0qExyKKZciC`p4*ڶ-.;wvd\5﮾(dl]`fɪEoeZǔ32\|<3qy<Ò SuYf5c#,Hl6T{&5ȣHIbZ2˯NܮJ>v bJ]<"\oR&{GG/aȅp`ׇA9)y q@⧟#-CI87#,xn+gLC G)aR!]iFzŷ[jAO²s{uKF[!!l[eMeŜZEM1;v*z0XW9U{Lˌ.G_VNo T4VgrĬIN=FՂ2>&e!vGQ#z#,A#5ΒxyKJDP\B "3xuo->?#5#ݿ̚~ 5AP~L1H>}~X]>$BqN#,y5=eɞU~EO'Qq~yF38S5$' ?1>j{d٘$n}_' IqE#YG21o@emx3c{I(+^#:ve=#>t\{Ak=KGyGNt4s?m۰Grr{Dpl(N]5dm!\,Fkw 3?~n~%i9Ht}^9 @:%V0AM%zٿg+b#"s0@v$* .@Gl1M4h6&lLBA!!޸kရq\xE,U#,IdEiD7k@LK"S(@) "h2#,24dQ"Y/xWL-1#_l\?+fBbY`0#,a0b[3B'JqT@đ =0tl 9S!<=#,9%K`5#ϥռL p=VU7qT<2OraCGmy\K.qy2P3?w2`@! B`#5E2@ ##,(\ "i43 Pb[]Tj-.nw IFYY%\%UDBQVlKLH|aD{b4j1 $1Aیi#fO詶F{S `THq)k#,:kV QF~.h8 5䵸o&3I\hì3u+b!SWcN]Il:hZlWJ(ZPf ڎ$H18⎩a[iS)CQ46T4G]Rc`;h9`cPB2FIaH41tFB 2ar2d-WL441f+Y-k(ޖsC52=[Vo%MKy!=I8bG-4\#,2D͹fz:5%P}Fe0/ ѣ1TU &.(R4p#,Z1okT#527*V4֊@v+֘DS8T)mʰuPN2)˩#5L:f]9}I,Yy˻x)ݵڪLPRJACY7Q"lrp6#v0ʊ:cK#(4Z?(!MF!6=.u4dHt#5QѣLqb&R0 Ra%(Ȓ&QʮFHk_0g)6GlgK+5'qa00Nf07GY;lRH1>i #Vd`!ɬ"Oqnn1b㞅ȸOeM)lȇ#t(pGSF&nc#i$02K*̂ CTl*O?UQJUB-jr Pam#,Hp&X!Aaá}%E1T̬JA,Q3?_%:l}TNoj'4(Ct9x~_9l$*w;>v3G7p>R@!B);XBSC壕Dp ?҅3xacis)HJ66$@FB;AլN2]kyWRU_{)%_@{^UQ1MZB1!ج\43M)O1Nz 7 56H%%Qʪ~'TDkS;$& "χ#5]ꠑqI;a J_#vct#,0L!`9}H.ƮS2(RgsE)Ӹ&w`mA!Jӥ5R'$l7.S*svG7{U?_8Q|vשDj7J~߭ax6g>"h~Xb!kF5Ilĭ.{Cz%rQz3^>n{\KNO{S_ext@TZ kB'ti*iMJ dn:0A)B:f;tN(!#5""ϬZ9E6ꡣFw(}Y'Я'Ejh˩#,GG T/J醊DԷ"ط-͢מ]뷈EA5zi(4lUب7J^4\7457{v潼!L#5Soj[oC;xPC'h)6SˏYY5?@+DL 5ۀ}[n. gvg~_ ?5Cy'D%.@#,0n:.K1,Yf#XF2}c )2$`Fk!&W`;{$WR(B*T?~s:P=/z2m@Q<: PUφ $ J0w㸟YwTWݎ\O@6U?,T4)1cXddmY)lLKClj#,+((pv5.1Alh*>2(h"61J6G^ZcmqDUtCQZFƂF 1JJ)D0,6Lp3i` 2%P]=B ĠL+~yX`QE A Dπ1 A CH0pgY_+=џNT`YUP I*!5YЏC!dI1cM8=$X ĺ:nuzwI=CJ*j^s^^W1ٱQ`frVT!2))#,LYkR%T=-8iT隅IeǒN6#5F=>ߦ|ao3'jV'X.a3ESw.&Yfr[bWq'7F!$4v6.$P4thV!GAROearH贽&tAcRu}Xxk!䐖s$MX<*O^:rӑjzzx^JLfrf(Ikyzs.qM@ֻ 1#,z#"9֣m6ZXWǽFWBcҺoOE <ݬzo!i|#5_\gyN LKHnU2dxu7}#/Cmna7Uk5~4N?/-cr9NOF,GDiZT)-o~&ͬ9:s;|2 GmX{|Ao;*87]YrPm#,C#5vH.M i7 rnwA{.}|t%ªaɡ(IaP`gpݨJ#,V5YЋ$<׼t~F8ĺVrGX:'Qq#jrJYFHbmHV@22ɱdZ=^žIszo-m#,d "UlyjgcYmNb߮\wB'FkxӤ-͋lu:{M=TM-,r#5@ʹ6掘lqeaM1pAxraWB򻩸Vۋ-Z#,u{ިx=dHv[XQ^ Lټ'vyIL/[МsI(B13dll~ cMD' FSfu6Ss("Ϲa,4`bd/JQ2i:Qi@7b\mteu5ǁ%Dh`L8fs}] t:ӌkxׄ!qmp]cyƓ;jpN5OL(JY&64MkI==#5"8p2@#,0&X02 \&$-#l. s߷6 tI0NjˁNTKMkdCjh S{xet *L&{S#,qׅזdx@(y-ݥ6M$c #,|uI6 ,`eêwt컉Bl"M*;+twp6CKz1ޛe5EX}LiPA\paJzw#,CW/붡6#QR+8GwGq#,B߭+{w% |zsgl=ګon߸xWs|\ص'y9QEXzBnt6͸禨;˿?) kI<ըhH!.|=jk-y::vf19:]5_)Mr[\ V4>V(0mi;f'iԾ57sQ.kf^[XV:[=[WwӼ)/yeQ~˓ߓۤ6߳4QngLY/5WGcq^/JxwIg/BzXPu:c#5DO|=3M+ L]azpA]&"g Q箛:m6Ș;GZHOXR!;`0fh2&Si6-HQ?9Ø2tRNN^Tfe٤xٟ֍TӢed{CQ;ίm 8ŵЅM1/Sr퉝0hKZT#,gh9]r\.z6=|ψܒNg׵]E#گGx"'_c^LيfTyGb:z|uA Ѱ?A39<o)N=6TX?]@R4iRB ~ppc/^^Y,9UܥݷFuw y9lʤ[u^J-m3дP#,)8Hl; ṽfu#,V:w6xhbCn!m]UДL1+\dJ ՃeM>F6ڮ8XJ#Y+ o] (hczbΑ` 'iGHXC(:H~Ȫem VpgXwz(v1Z |0$)Mi)̨0ΆkdZȵL{$&Rss:5,s0`дa 2rb$#5B$5]\+DR)&Vddv#, pƄEf#,fG*s&g#+ղSpYbq#,8 $r˷ə]X.I1p6/^mek ^֌7 kD9X桙1S&`ƒOdaSY C,Lnp9Y`D[M[X#,b,V2%݆:qBA3PcdC"Lr&D 2tfvsrZ1!tCCDiɤB(q 6nqK켈|g.< c]55\$ Â+WGBc  S݊!!+Bm0NSySZ5 pj#wLXN{J**-JI.`Pz+! L:"QJ5xV9]f MWf \.UREJ [ɶTphf&Q{0sY-FFb`޹nms 섙 ;RH55K*k[P3 Ź̲+?0rwRAE.%#5߼iϯωN"(qsSXØ2Ov>/mLgxsp階`[DQ;g9+[h9j'd-)Ó}+ϗ~Qszd 6$'<{@u_0wQHoCTE,`H(,mّ7cۏM85i>H_z4` %sբO0Ba4;}>~$Nq(@K(H LeC*R >[B);6/Iؾ@@ -#fZԥ&2Q"ĄSM($R!Պɭ&dR64cPhb[aWV1D! % 巟n-{$,X@=&:@##,4U]=HYR{EiIc|^hv0379[k`q4>^Y 9qnw Ӹeӂ 0]5446f⹹g,nhV]q_-ʧ]-$iҪN:B-C49C%,tYW!!Ilʹe]Bud@_8W1Ȉls7'%ĘVMXj:cD5 BD$$;\Qd 4GR}+[.ѨOy@6CN@J.mo$M&B87&^Mp zJ4*ho02u%PL7h>'Cuݝ]΄6ݤ/ Z5ظ_vbyg5}}{hn*HYp$)( #,*ʣ",t 0Q?VOd*w`IgBk&C*4 )a|Y4G'f. DS|8X)GwDOWJ^ pBlMpRbHbiNcK[p8 AG֪9t;yt9WDWL' ӻa)x.fN}AMO;;H48Di; 'CIk)g?pΦM9<$(ߩb1i~b|n\ :.x=H^0j>$$7Dz#,0b`>L !IѤ< J^ޙ-ye W;-#,1倞$+0#d˓FKkb8ֆ73j#G>l5dgr,Y!ĹH[6gY~gW[Ģ5Su$8z҄.ٳljC”脎M'f#0Z`S0N[3A TI@Dw#,v0!jD {4L1db)a`8ZFQA^i!H떵 k`1Ȅ^8z\udTo#,V2jSY7"d9I$ lbxƆCt"|II[!o7_:c8Ith:1HAAcIM/'w(Ԉ!$"2j[5pI;^asǙY\w)SROWg}U62qN0##,[9VلсU!M\cSrT$V\9g2C*I1ە:7OU+㢹 P] wbFb gKd۴AƎ$mΪSjќ6A)vp#,^Y:ďsgmM\84jPȏn@bѢ xr YNH.%1~iD&~f3lHhwk0,4tl(,f'޻zM&p`kn>#,F\ J=NNDpwqt# >moiL#,b'LBJ2Ca)V+b2/ xφ橌"L3D)2+*橩@dCxveӅ5ӦL'SI6)~|f&Q3;1d 2 VzY,[aY qDvоjá;e՜ӈ3<#5' [&(zxiu!w.T(Dmm{#5a^Ob_;kF#uV49yg3r^3Hpr pqōkΛKY7Rzxu_ $SN\ԄҬ5լp ooj0Jv4ꨇVF׼E90^Iݪ۴6o\,ГW3 ]wpȈxk`JQȚObM\ETxsq$%u1m/z^.\ͻ6ʰ.7aB+:#,Y`jqr<#WSS)bk#52ں*t{DWTz3S^uF0taf(,Hyf/GI!t}w%US(I Z@N?ü7kۏ $&#,~G%Y54p~L>N>M#M$2UҭKJ#,"Q`K Q:CBE9BM,#Fh#5ρӗ"""Qv>cմ;:72kAi,۳\?^{gmO(mƜ H`at٠8Fv7u$]!vMPRGTn,'32?;׸!aoފ,GqiaY5gbfj_LYd 3X#5|{xdЖ#,JHSNpw)ry3.lDMBHlB4ĤUB#,!I?!ś5#, Pg_qAWI(jTJlKZIlTkW5WF"Jp;4|xD)=̉dMkxK@#h:]-]7$I٤3X¯0 zI=)P-@NBhڰ&[Ǿd~kT3({H}ױ& |#a Ґ HSb3ë3CrY vhfѢdths몮d1#,ݨckݰV iÖ{B\.kMPP\+NJO.l}_@\-5hCy3k S(`a`T0XtA;h[7!1FMvl*}{򿟫ä5;8CR ^HD>q~2➓exlvzVQT9: AKn2>ԒGFVL$.9^`cnpj}?߻p(d.Z?EȄz,čT ’0&B`6#$O)=u}@}Ȥv#& s䅳k+b2*Sio++Kݬq Rwat¹`#,`~߹[pB^uT"L JY5&R@Қ1JPfVB|N<UV%/#5Qffrbā.s"ܳ|^ex2 3Ez'bӅDX*\*4Ik6[:B'BCyDB!+AYpb߬z\}?cX7H5KT\}i9>^(ˇ Lu[8PݚPxcS'&@w10̩B`sp^lvi.#,ZVcdǗ(Hc_пlq4vWQaTBFguB$0fWԌ7<A3W1+wO/??G>_[/z}Tݍ͇3Dl_'Px+ Ǐgr' 3ڡ%BV5^7~^_;H"x`rGl'S7}}z?]vBP}. 1\Ї2)8|AK RF4I$D&AmL׎>~y>!&GyDէBz&O|v??{.0F .Lb„k`lESw;_ 5+K5&Kti؟\ә)#57XYYe3(S45%9,e#5x'Ǹz<8d2"V']bS(7N#,%T`D t4fPʭmcT6TR='Jny4vծPlnCRu8Sz]eNRto)C2؜uqrHS9JjM^/5x> #5Iy8uu֞.PJH#,#ذן=/NIuxPݐ䔜\ H$a` Oq#,3y2~MUU~7&%q^th` ꦆmf,9yo@=BU! 0IY%1|(b(^ O<q #C.ʳ,&bn}˪OBھ3k՟p]*iq8k81~66PQo9}I]YYl %3._<ďDFa4vz@ۙdpʷFvi_,'͵2FriOd JDdC! #5(S!Gq$`//fŅ F<`!,2<3;8eG('u}<#5l9$7 A7TiDO>Ѽr"(Np&\?nw']) ## object.h (module 'core'): ns3::Object::AggregateIterator [class] @@ -178,12 +182,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -221,6 +225,7 @@ register_Ns3ObjectFactory_methods(root_module, root_module['ns3::ObjectFactory']) register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -1177,6 +1182,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1374,62 +1387,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1438,6 +1407,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -1478,6 +1449,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Object_methods(root_module, cls): @@ -1619,13 +1592,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1652,6 +1627,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', diff -Naur ns-3.19/src/bridge/bindings/modulegen__gcc_LP64.py ns-3.20/src/bridge/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/bridge/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.494636229 -0700 +++ ns-3.20/src/bridge/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.824996494 -0700 @@ -62,6 +62,8 @@ 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')) ## tag-buffer.h (module 'network'): ns3::TagBuffer [class] module.add_class('TagBuffer', import_from_module='ns.network') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -74,6 +76,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## 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] @@ -178,12 +182,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -221,6 +225,7 @@ register_Ns3ObjectFactory_methods(root_module, root_module['ns3::ObjectFactory']) register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -1177,6 +1182,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1374,62 +1387,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1438,6 +1407,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -1478,6 +1449,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Object_methods(root_module, cls): @@ -1619,13 +1592,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1652,6 +1627,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', diff -Naur ns-3.19/src/bridge/model/bridge-channel.cc ns-3.20/src/bridge/model/bridge-channel.cc --- ns-3.19/src/bridge/model/bridge-channel.cc 2014-06-17 10:34:00.496636214 -0700 +++ ns-3.20/src/bridge/model/bridge-channel.cc 2014-06-17 10:33:13.826996479 -0700 @@ -23,8 +23,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (BridgeChannel) - ; +NS_OBJECT_ENSURE_REGISTERED (BridgeChannel); TypeId BridgeChannel::GetTypeId (void) diff -Naur ns-3.19/src/bridge/model/bridge-net-device.cc ns-3.20/src/bridge/model/bridge-net-device.cc --- ns-3.19/src/bridge/model/bridge-net-device.cc 2014-06-17 10:34:00.497636206 -0700 +++ ns-3.20/src/bridge/model/bridge-net-device.cc 2014-06-17 10:33:13.827996471 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (BridgeNetDevice) - ; +NS_OBJECT_ENSURE_REGISTERED (BridgeNetDevice); TypeId diff -Naur ns-3.19/src/bridge/waf ns-3.20/src/bridge/waf --- ns-3.19/src/bridge/waf 2014-06-17 10:34:00.498636198 -0700 +++ ns-3.20/src/bridge/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../../waf "$@" diff -Naur ns-3.19/src/brite/helper/brite-topology-helper.cc ns-3.20/src/brite/helper/brite-topology-helper.cc --- ns-3.19/src/brite/helper/brite-topology-helper.cc 2014-06-17 10:34:00.503636160 -0700 +++ ns-3.20/src/brite/helper/brite-topology-helper.cc 2014-06-17 10:33:13.833996425 -0700 @@ -456,7 +456,7 @@ // Set the link delay // The brite value for delay is given in milliseconds m_britePointToPointHelper.SetChannelAttribute ("Delay", - TimeValue (MilliSeconds ((*it).delay))); + TimeValue (Seconds ((*it).delay/1000.0))); // The brite value for data rate is given in Mbps m_britePointToPointHelper.SetDeviceAttribute ("DataRate", diff -Naur ns-3.19/src/brite/test/brite-test-topology.cc ns-3.20/src/brite/test/brite-test-topology.cc --- ns-3.19/src/brite/test/brite-test-topology.cc 2014-06-17 10:34:00.504636152 -0700 +++ ns-3.20/src/brite/test/brite-test-topology.cc 2014-06-17 10:33:13.834996417 -0700 @@ -29,7 +29,7 @@ #include #include -namespace ns3 { +using namespace ns3; class BriteTopologyStructureTestCase : public TestCase { @@ -196,5 +196,3 @@ AddTestCase (new BriteTopologyFunctionTestCase, TestCase::QUICK); } } g_briteTestSuite; - -} // namespace ns3 diff -Naur ns-3.19/src/brite/wscript ns-3.20/src/brite/wscript --- ns-3.19/src/brite/wscript 2014-06-17 10:34:00.505636144 -0700 +++ ns-3.20/src/brite/wscript 2014-06-17 10:33:13.835996409 -0700 @@ -14,33 +14,39 @@ def configure(conf): conf.env['ENABLE_BRITE'] = False + lib_to_check = 'libbrite.so' if Options.options.with_brite: - if os.path.isdir(Options.options.with_brite): - conf.msg("Checking BRITE location", ("%s (given)" % Options.options.with_brite)) + conf.msg("Checking BRITE location", ("%s (given)" % Options.options.with_brite)) + brite_dir = Options.options.with_brite + if os.path.exists(os.path.join(brite_dir, lib_to_check)): conf.env['WITH_BRITE'] = os.path.abspath(Options.options.with_brite) else: - brite_dir = os.path.join('..','BRITE') - if os.path.isdir(brite_dir): - conf.msg("Checking for BRITE location", ("%s (guessed)" % brite_dir)) - conf.env['WITH_BRITE'] = os.path.abspath(brite_dir) - del brite_dir - if not conf.env['WITH_BRITE']: - conf.msg("Checking for BRITE location", False) - conf.report_optional_feature("brite", "BRITE Integration", False, - "BRITE not found (see option --with-brite)") - # Add this module to the list of modules that won't be built - # if they are enabled. - conf.env['MODULES_NOT_BUILT'].append('brite') - - return + conf.report_optional_feature("brite", "BRITE Integration", False, + "BRITE not found at requested location") + # Add this module to the list of modules that won't be built + # if they are enabled. + conf.env['MODULES_NOT_BUILT'].append('brite') + return else: - conf.report_optional_feature("brite", "BRITE Integration", False, 'BRITE not enabled (see option --with-brite)') - - # Add this module to the list of modules that won't be built - # if they are enabled. - conf.env['MODULES_NOT_BUILT'].append('brite') + # No user specified '--with-brite' option, try to guess + # bake.py uses ../../build, while ns-3-dev uses ../click + brite_dir = os.path.join('..','BRITE') + brite_bake_build_dir = os.path.join('..', '..', 'build') + brite_bake_lib_dir = os.path.join(brite_bake_build_dir, 'lib') + if os.path.exists(os.path.join(brite_dir, lib_to_check)): + conf.msg("Checking for BRITE location", ("%s (guessed)" % brite_dir)) + conf.env['WITH_BRITE'] = os.path.abspath(brite_dir) +# Below is not yet ready (bake does not install BRITE yet, just builds it) +# elif os.path.exists(os.path.join(brite_bake_lib_dir, lib_to_check)): +# conf.msg("Checking for BRITE location", ("%s (guessed)" % brite_bake_lib_dir)) +# conf.env['WITH_BRITE'] = os.path.abspath(brite_bake_lib_dir) + else: + conf.report_optional_feature("brite", "BRITE Integration", False, 'BRITE not enabled (see option --with-brite)') - return + # Add this module to the list of modules that won't be built + # if they are enabled. + conf.env['MODULES_NOT_BUILT'].append('brite') + return test_code = ''' #include "Brite.h" diff -Naur ns-3.19/src/buildings/bindings/modulegen__gcc_ILP32.py ns-3.20/src/buildings/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/buildings/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.508636121 -0700 +++ ns-3.20/src/buildings/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.838996386 -0700 @@ -72,6 +72,8 @@ 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')) ## tag-buffer.h (module 'network'): ns3::TagBuffer [class] module.add_class('TagBuffer', import_from_module='ns.network') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -88,6 +90,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## 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] @@ -268,17 +272,17 @@ 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']) - typehandlers.add_type_alias('ns3::Vector3D', 'ns3::Vector') - typehandlers.add_type_alias('ns3::Vector3D*', 'ns3::Vector*') - typehandlers.add_type_alias('ns3::Vector3D&', 'ns3::Vector&') + typehandlers.add_type_alias(u'ns3::Vector3D', u'ns3::Vector') + typehandlers.add_type_alias(u'ns3::Vector3D*', u'ns3::Vector*') + typehandlers.add_type_alias(u'ns3::Vector3D&', u'ns3::Vector&') module.add_typedef(root_module['ns3::Vector3D'], 'Vector') - typehandlers.add_type_alias('ns3::Vector3DValue', 'ns3::VectorValue') - typehandlers.add_type_alias('ns3::Vector3DValue*', 'ns3::VectorValue*') - typehandlers.add_type_alias('ns3::Vector3DValue&', 'ns3::VectorValue&') + typehandlers.add_type_alias(u'ns3::Vector3DValue', u'ns3::VectorValue') + typehandlers.add_type_alias(u'ns3::Vector3DValue*', u'ns3::VectorValue*') + typehandlers.add_type_alias(u'ns3::Vector3DValue&', u'ns3::VectorValue&') module.add_typedef(root_module['ns3::Vector3DValue'], 'VectorValue') - typehandlers.add_type_alias('ns3::Vector3DChecker', 'ns3::VectorChecker') - typehandlers.add_type_alias('ns3::Vector3DChecker*', 'ns3::VectorChecker*') - typehandlers.add_type_alias('ns3::Vector3DChecker&', 'ns3::VectorChecker&') + typehandlers.add_type_alias(u'ns3::Vector3DChecker', u'ns3::VectorChecker') + typehandlers.add_type_alias(u'ns3::Vector3DChecker*', u'ns3::VectorChecker*') + typehandlers.add_type_alias(u'ns3::Vector3DChecker&', u'ns3::VectorChecker&') module.add_typedef(root_module['ns3::Vector3DChecker'], 'VectorChecker') ## Register a nested module for the namespace FatalImpl @@ -302,12 +306,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -348,6 +352,7 @@ register_Ns3ObjectFactory_methods(root_module, root_module['ns3::ObjectFactory']) register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -1480,6 +1485,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1707,62 +1720,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1771,6 +1740,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -1811,6 +1782,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Object_methods(root_module, cls): @@ -2324,13 +2297,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2357,6 +2332,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -3398,12 +3378,12 @@ cls.add_method('SetSystemLoss', 'void', [param('double', 'systemLoss')]) - ## propagation-loss-model.h (module 'propagation'): void ns3::FriisPropagationLossModel::SetMinDistance(double minDistance) [member function] - cls.add_method('SetMinDistance', + ## propagation-loss-model.h (module 'propagation'): void ns3::FriisPropagationLossModel::SetMinLoss(double minLoss) [member function] + cls.add_method('SetMinLoss', 'void', - [param('double', 'minDistance')]) - ## propagation-loss-model.h (module 'propagation'): double ns3::FriisPropagationLossModel::GetMinDistance() const [member function] - cls.add_method('GetMinDistance', + [param('double', 'minLoss')]) + ## propagation-loss-model.h (module 'propagation'): double ns3::FriisPropagationLossModel::GetMinLoss() const [member function] + cls.add_method('GetMinLoss', 'double', [], is_const=True) diff -Naur ns-3.19/src/buildings/bindings/modulegen__gcc_LP64.py ns-3.20/src/buildings/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/buildings/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.511636098 -0700 +++ ns-3.20/src/buildings/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.841996363 -0700 @@ -72,6 +72,8 @@ 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')) ## tag-buffer.h (module 'network'): ns3::TagBuffer [class] module.add_class('TagBuffer', import_from_module='ns.network') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -88,6 +90,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## 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] @@ -268,17 +272,17 @@ 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']) - typehandlers.add_type_alias('ns3::Vector3D', 'ns3::Vector') - typehandlers.add_type_alias('ns3::Vector3D*', 'ns3::Vector*') - typehandlers.add_type_alias('ns3::Vector3D&', 'ns3::Vector&') + typehandlers.add_type_alias(u'ns3::Vector3D', u'ns3::Vector') + typehandlers.add_type_alias(u'ns3::Vector3D*', u'ns3::Vector*') + typehandlers.add_type_alias(u'ns3::Vector3D&', u'ns3::Vector&') module.add_typedef(root_module['ns3::Vector3D'], 'Vector') - typehandlers.add_type_alias('ns3::Vector3DValue', 'ns3::VectorValue') - typehandlers.add_type_alias('ns3::Vector3DValue*', 'ns3::VectorValue*') - typehandlers.add_type_alias('ns3::Vector3DValue&', 'ns3::VectorValue&') + typehandlers.add_type_alias(u'ns3::Vector3DValue', u'ns3::VectorValue') + typehandlers.add_type_alias(u'ns3::Vector3DValue*', u'ns3::VectorValue*') + typehandlers.add_type_alias(u'ns3::Vector3DValue&', u'ns3::VectorValue&') module.add_typedef(root_module['ns3::Vector3DValue'], 'VectorValue') - typehandlers.add_type_alias('ns3::Vector3DChecker', 'ns3::VectorChecker') - typehandlers.add_type_alias('ns3::Vector3DChecker*', 'ns3::VectorChecker*') - typehandlers.add_type_alias('ns3::Vector3DChecker&', 'ns3::VectorChecker&') + typehandlers.add_type_alias(u'ns3::Vector3DChecker', u'ns3::VectorChecker') + typehandlers.add_type_alias(u'ns3::Vector3DChecker*', u'ns3::VectorChecker*') + typehandlers.add_type_alias(u'ns3::Vector3DChecker&', u'ns3::VectorChecker&') module.add_typedef(root_module['ns3::Vector3DChecker'], 'VectorChecker') ## Register a nested module for the namespace FatalImpl @@ -302,12 +306,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -348,6 +352,7 @@ register_Ns3ObjectFactory_methods(root_module, root_module['ns3::ObjectFactory']) register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -1480,6 +1485,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1707,62 +1720,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1771,6 +1740,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -1811,6 +1782,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Object_methods(root_module, cls): @@ -2324,13 +2297,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2357,6 +2332,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -3398,12 +3378,12 @@ cls.add_method('SetSystemLoss', 'void', [param('double', 'systemLoss')]) - ## propagation-loss-model.h (module 'propagation'): void ns3::FriisPropagationLossModel::SetMinDistance(double minDistance) [member function] - cls.add_method('SetMinDistance', + ## propagation-loss-model.h (module 'propagation'): void ns3::FriisPropagationLossModel::SetMinLoss(double minLoss) [member function] + cls.add_method('SetMinLoss', 'void', - [param('double', 'minDistance')]) - ## propagation-loss-model.h (module 'propagation'): double ns3::FriisPropagationLossModel::GetMinDistance() const [member function] - cls.add_method('GetMinDistance', + [param('double', 'minLoss')]) + ## propagation-loss-model.h (module 'propagation'): double ns3::FriisPropagationLossModel::GetMinLoss() const [member function] + cls.add_method('GetMinLoss', 'double', [], is_const=True) diff -Naur ns-3.19/src/buildings/helper/building-allocator.cc ns-3.20/src/buildings/helper/building-allocator.cc --- ns-3.19/src/buildings/helper/building-allocator.cc 2014-06-17 10:34:00.516636059 -0700 +++ ns-3.20/src/buildings/helper/building-allocator.cc 2014-06-17 10:33:13.846996324 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (GridBuildingAllocator) - ; +NS_OBJECT_ENSURE_REGISTERED (GridBuildingAllocator); GridBuildingAllocator::GridBuildingAllocator () : m_current (0) diff -Naur ns-3.19/src/buildings/helper/building-position-allocator.cc ns-3.20/src/buildings/helper/building-position-allocator.cc --- ns-3.19/src/buildings/helper/building-position-allocator.cc 2014-06-17 10:34:00.518636044 -0700 +++ ns-3.20/src/buildings/helper/building-position-allocator.cc 2014-06-17 10:33:13.847996317 -0700 @@ -35,10 +35,9 @@ NS_LOG_COMPONENT_DEFINE ("BuildingPositionAllocator"); -namespace ns3 { +using namespace ns3; -NS_OBJECT_ENSURE_REGISTERED (RandomBuildingPositionAllocator) - ; +NS_OBJECT_ENSURE_REGISTERED (RandomBuildingPositionAllocator); RandomBuildingPositionAllocator::RandomBuildingPositionAllocator () @@ -105,8 +104,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (RandomRoomPositionAllocator) - ; +NS_OBJECT_ENSURE_REGISTERED (RandomRoomPositionAllocator); RandomRoomPositionAllocator::RandomRoomPositionAllocator () @@ -194,8 +192,7 @@ -NS_OBJECT_ENSURE_REGISTERED (SameRoomPositionAllocator) - ; +NS_OBJECT_ENSURE_REGISTERED (SameRoomPositionAllocator); SameRoomPositionAllocator::SameRoomPositionAllocator () { @@ -285,8 +282,7 @@ return 1; } -NS_OBJECT_ENSURE_REGISTERED (FixedRoomPositionAllocator) - ; +NS_OBJECT_ENSURE_REGISTERED (FixedRoomPositionAllocator); FixedRoomPositionAllocator::FixedRoomPositionAllocator ( @@ -348,6 +344,3 @@ m_rand->SetStream (stream); return 1; } - - -} // namespace ns3 diff -Naur ns-3.19/src/buildings/model/building.cc ns-3.20/src/buildings/model/building.cc --- ns-3.19/src/buildings/model/building.cc 2014-06-17 10:34:00.520636028 -0700 +++ ns-3.20/src/buildings/model/building.cc 2014-06-17 10:33:13.850996293 -0700 @@ -34,8 +34,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Building) - ; +NS_OBJECT_ENSURE_REGISTERED (Building); TypeId Building::GetTypeId (void) diff -Naur ns-3.19/src/buildings/model/building-list.cc ns-3.20/src/buildings/model/building-list.cc --- ns-3.19/src/buildings/model/building-list.cc 2014-06-17 10:34:00.520636028 -0700 +++ ns-3.20/src/buildings/model/building-list.cc 2014-06-17 10:33:13.849996301 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("BuildingList") - ; +NS_LOG_COMPONENT_DEFINE ("BuildingList"); /** * \brief private implementation detail of the BuildingList API. @@ -58,8 +57,7 @@ std::vector > m_buildings; }; -NS_OBJECT_ENSURE_REGISTERED (BuildingListPriv) - ; +NS_OBJECT_ENSURE_REGISTERED (BuildingListPriv); TypeId BuildingListPriv::GetTypeId (void) diff -Naur ns-3.19/src/buildings/model/buildings-propagation-loss-model.cc ns-3.20/src/buildings/model/buildings-propagation-loss-model.cc --- ns-3.19/src/buildings/model/buildings-propagation-loss-model.cc 2014-06-17 10:34:00.521636021 -0700 +++ ns-3.20/src/buildings/model/buildings-propagation-loss-model.cc 2014-06-17 10:33:13.851996286 -0700 @@ -35,8 +35,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (BuildingsPropagationLossModel) - ; +NS_OBJECT_ENSURE_REGISTERED (BuildingsPropagationLossModel); BuildingsPropagationLossModel::ShadowingLoss::ShadowingLoss () { diff -Naur ns-3.19/src/buildings/model/hybrid-buildings-propagation-loss-model.cc ns-3.20/src/buildings/model/hybrid-buildings-propagation-loss-model.cc --- ns-3.19/src/buildings/model/hybrid-buildings-propagation-loss-model.cc 2014-06-17 10:34:00.522636013 -0700 +++ ns-3.20/src/buildings/model/hybrid-buildings-propagation-loss-model.cc 2014-06-17 10:33:13.851996286 -0700 @@ -41,8 +41,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (HybridBuildingsPropagationLossModel) - ; +NS_OBJECT_ENSURE_REGISTERED (HybridBuildingsPropagationLossModel); diff -Naur ns-3.19/src/buildings/model/itu-r-1238-propagation-loss-model.cc ns-3.20/src/buildings/model/itu-r-1238-propagation-loss-model.cc --- ns-3.19/src/buildings/model/itu-r-1238-propagation-loss-model.cc 2014-06-17 10:34:00.523636005 -0700 +++ ns-3.20/src/buildings/model/itu-r-1238-propagation-loss-model.cc 2014-06-17 10:33:13.852996278 -0700 @@ -32,8 +32,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ItuR1238PropagationLossModel) - ; +NS_OBJECT_ENSURE_REGISTERED (ItuR1238PropagationLossModel); TypeId diff -Naur ns-3.19/src/buildings/model/mobility-building-info.cc ns-3.20/src/buildings/model/mobility-building-info.cc --- ns-3.19/src/buildings/model/mobility-building-info.cc 2014-06-17 10:34:00.524635997 -0700 +++ ns-3.20/src/buildings/model/mobility-building-info.cc 2014-06-17 10:33:13.853996270 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (MobilityBuildingInfo) - ; +NS_OBJECT_ENSURE_REGISTERED (MobilityBuildingInfo); TypeId MobilityBuildingInfo::GetTypeId (void) diff -Naur ns-3.19/src/buildings/model/oh-buildings-propagation-loss-model.cc ns-3.20/src/buildings/model/oh-buildings-propagation-loss-model.cc --- ns-3.19/src/buildings/model/oh-buildings-propagation-loss-model.cc 2014-06-17 10:34:00.524635997 -0700 +++ ns-3.20/src/buildings/model/oh-buildings-propagation-loss-model.cc 2014-06-17 10:33:13.853996270 -0700 @@ -35,8 +35,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (OhBuildingsPropagationLossModel) - ; +NS_OBJECT_ENSURE_REGISTERED (OhBuildingsPropagationLossModel); diff -Naur ns-3.19/src/buildings/test/building-position-allocator-test.cc ns-3.20/src/buildings/test/building-position-allocator-test.cc --- ns-3.19/src/buildings/test/building-position-allocator-test.cc 2014-06-17 10:34:00.525635990 -0700 +++ ns-3.20/src/buildings/test/building-position-allocator-test.cc 2014-06-17 10:33:13.854996262 -0700 @@ -34,8 +34,7 @@ NS_LOG_COMPONENT_DEFINE ("BuildingPositionAllocatorTest"); -namespace ns3 { - +using namespace ns3; struct Room @@ -242,6 +241,3 @@ } static BuildingPositionAllocatorTestSuite buildingsPositionAllocatorTestSuiteInstance; - -} // namespace ns3 - diff -Naur ns-3.19/src/buildings/test/buildings-helper-test.cc ns-3.20/src/buildings/test/buildings-helper-test.cc --- ns-3.19/src/buildings/test/buildings-helper-test.cc 2014-06-17 10:34:00.526635982 -0700 +++ ns-3.20/src/buildings/test/buildings-helper-test.cc 2014-06-17 10:33:13.855996255 -0700 @@ -31,7 +31,7 @@ NS_LOG_COMPONENT_DEFINE ("BuildingsHelperTest"); -namespace ns3 { +using namespace ns3; struct PositionInBuilding @@ -325,6 +325,3 @@ } static BuildingsHelperTestSuite buildingsHelperAntennaTestSuiteInstance; - -} // namespace ns3 - diff -Naur ns-3.19/src/buildings/test/buildings-pathloss-test.cc ns-3.20/src/buildings/test/buildings-pathloss-test.cc --- ns-3.19/src/buildings/test/buildings-pathloss-test.cc 2014-06-17 10:34:00.526635982 -0700 +++ ns-3.20/src/buildings/test/buildings-pathloss-test.cc 2014-06-17 10:33:13.855996255 -0700 @@ -36,7 +36,7 @@ NS_LOG_COMPONENT_DEFINE ("BuildingsPathlossTest"); -namespace ns3 { +using namespace ns3; /** @@ -271,7 +271,3 @@ BuildingsHelper::MakeConsistent (mm); return mm; } - - - -} // namespace ns3 diff -Naur ns-3.19/src/buildings/test/buildings-pathloss-test.h ns-3.20/src/buildings/test/buildings-pathloss-test.h --- ns-3.19/src/buildings/test/buildings-pathloss-test.h 2014-06-17 10:34:00.527635974 -0700 +++ ns-3.20/src/buildings/test/buildings-pathloss-test.h 2014-06-17 10:33:13.856996247 -0700 @@ -25,7 +25,7 @@ #include -namespace ns3 { +using namespace ns3; /** * Test 1.1 pathloss calculation @@ -58,6 +58,3 @@ #endif /* BUILDING_PATHLOSS_TEST_H */ - - -} // namespace ns3 diff -Naur ns-3.19/src/buildings/test/buildings-shadowing-test.cc ns-3.20/src/buildings/test/buildings-shadowing-test.cc --- ns-3.19/src/buildings/test/buildings-shadowing-test.cc 2014-06-17 10:34:00.527635974 -0700 +++ ns-3.20/src/buildings/test/buildings-shadowing-test.cc 2014-06-17 10:33:13.856996247 -0700 @@ -36,7 +36,7 @@ NS_LOG_COMPONENT_DEFINE ("BuildingsShadowingTest"); -namespace ns3 { +using namespace ns3; @@ -228,8 +228,3 @@ BuildingsHelper::MakeConsistent (mm); return mm; } - - - - -} // namespace ns3 diff -Naur ns-3.19/src/buildings/test/buildings-shadowing-test.h ns-3.20/src/buildings/test/buildings-shadowing-test.h --- ns-3.19/src/buildings/test/buildings-shadowing-test.h 2014-06-17 10:34:00.528635967 -0700 +++ ns-3.20/src/buildings/test/buildings-shadowing-test.h 2014-06-17 10:33:13.857996239 -0700 @@ -25,7 +25,7 @@ -namespace ns3 { +using namespace ns3; /** * Test shadowing calculation @@ -55,5 +55,3 @@ }; #endif /*BUILDINGS_SHADOWING_TEST_H*/ - -} // namespace ns3 diff -Naur ns-3.19/src/click/bindings/modulegen__gcc_ILP32.py ns-3.20/src/click/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/click/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.533635928 -0700 +++ ns-3.20/src/click/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.861996209 -0700 @@ -46,8 +46,6 @@ 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') - ## event-id.h (module 'core'): ns3::EventId [class] - module.add_class('EventId', import_from_module='ns.core') ## hash.h (module 'core'): ns3::Hasher [class] module.add_class('Hasher', import_from_module='ns.core') ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress [class] @@ -58,34 +56,6 @@ module.add_class('InetSocketAddress', import_from_module='ns.network') ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] root_module['ns3::InetSocketAddress'].implicitly_converts_to(root_module['ns3::Address']) - ## int-to-type.h (module 'core'): ns3::IntToType<0> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['0']) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 0 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<1> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['1']) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 1 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<2> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['2']) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 2 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<3> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['3']) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 3 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<4> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['4']) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 4 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<5> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['5']) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 5 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<6> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['6']) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 6 >'], 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] @@ -100,12 +70,6 @@ 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-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress [class] - module.add_class('Ipv6InterfaceAddress', import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e [enumeration] - module.add_enum('State_e', ['TENTATIVE', 'DEPRECATED', 'PREFERRED', 'PERMANENT', 'HOMEADDRESS', 'TENTATIVE_OPTIMISTIC', 'INVALID'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e [enumeration] - module.add_enum('Scope_e', ['HOST', 'LINKLOCAL', 'GLOBAL'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix [class] module.add_class('Ipv6Prefix', import_from_module='ns.network') ## log.h (module 'core'): ns3::LogComponent [class] @@ -114,8 +78,6 @@ 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] @@ -136,22 +98,12 @@ module.add_enum('TagData_e', ['MAX_SIZE'], outer_class=root_module['ns3::PacketTagList::TagData'], import_from_module='ns.network') ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount [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-wall-clock-ms.h (module 'core'): ns3::SystemWallClockMs [class] module.add_class('SystemWallClockMs', 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') - ## timer.h (module 'core'): ns3::Timer [class] - module.add_class('Timer', import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] - module.add_enum('DestroyPolicy', ['CANCEL_ON_DESTROY', 'REMOVE_ON_DESTROY', 'CHECK_ON_DESTROY'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::State [enumeration] - module.add_enum('State', ['RUNNING', 'EXPIRED', 'SUSPENDED'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer-impl.h (module 'core'): ns3::TimerImpl [class] - module.add_class('TimerImpl', allow_subclassing=True, import_from_module='ns.core') ## 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] @@ -162,8 +114,6 @@ 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']) ## header.h (module 'network'): ns3::Header [class] @@ -174,10 +124,6 @@ module.add_enum('DscpType', ['DscpDefault', 'DSCP_CS1', 'DSCP_AF11', 'DSCP_AF12', 'DSCP_AF13', 'DSCP_CS2', 'DSCP_AF21', 'DSCP_AF22', 'DSCP_AF23', 'DSCP_CS3', 'DSCP_AF31', 'DSCP_AF32', 'DSCP_AF33', 'DSCP_CS4', 'DSCP_AF41', 'DSCP_AF42', 'DSCP_AF43', 'DSCP_CS5', 'DSCP_EF', 'DSCP_CS6', 'DSCP_CS7'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType [enumeration] module.add_enum('EcnType', ['ECN_NotECT', 'ECN_ECT1', 'ECN_ECT0', 'ECN_CE'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header [class] - module.add_class('Ipv6Header', import_from_module='ns.internet', parent=root_module['ns3::Header']) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::NextHeader_e [enumeration] - module.add_enum('NextHeader_e', ['IPV6_EXT_HOP_BY_HOP', 'IPV6_IPV4', 'IPV6_TCP', 'IPV6_UDP', 'IPV6_IPV6', 'IPV6_EXT_ROUTING', 'IPV6_EXT_FRAGMENTATION', 'IPV6_EXT_CONFIDENTIALITY', 'IPV6_EXT_AUTHENTIFICATION', 'IPV6_ICMPV6', 'IPV6_EXT_END', 'IPV6_EXT_DESTINATION', 'IPV6_SCTP', 'IPV6_EXT_MOBILITY', 'IPV6_UDP_LITE'], outer_class=root_module['ns3::Ipv6Header'], import_from_module='ns.internet') ## 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] @@ -190,8 +136,6 @@ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeValue', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::CallbackImplBase', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] - module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::EventImpl', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Hash::Implementation', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] @@ -224,12 +168,6 @@ module.add_class('SocketIpv6TclassTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## socket.h (module 'network'): ns3::SocketSetDontFragmentTag [class] module.add_class('SocketSetDontFragmentTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) - ## 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 >']) ## trailer.h (module 'network'): ns3::Trailer [class] @@ -248,12 +186,6 @@ module.add_class('CallbackValue', import_from_module='ns.core', 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']) - ## 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 >']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -278,8 +210,6 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -290,16 +220,10 @@ 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 >']) - ## 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 >']) ## 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 >']) - ## 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] @@ -376,27 +300,17 @@ 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_Ns3EventId_methods(root_module, root_module['ns3::EventId']) register_Ns3Hasher_methods(root_module, root_module['ns3::Hasher']) register_Ns3Inet6SocketAddress_methods(root_module, root_module['ns3::Inet6SocketAddress']) register_Ns3InetSocketAddress_methods(root_module, root_module['ns3::InetSocketAddress']) - register_Ns3IntToType__0_methods(root_module, root_module['ns3::IntToType< 0 >']) - register_Ns3IntToType__1_methods(root_module, root_module['ns3::IntToType< 1 >']) - register_Ns3IntToType__2_methods(root_module, root_module['ns3::IntToType< 2 >']) - register_Ns3IntToType__3_methods(root_module, root_module['ns3::IntToType< 3 >']) - register_Ns3IntToType__4_methods(root_module, root_module['ns3::IntToType< 4 >']) - register_Ns3IntToType__5_methods(root_module, root_module['ns3::IntToType< 5 >']) - register_Ns3IntToType__6_methods(root_module, root_module['ns3::IntToType< 6 >']) register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address']) register_Ns3Ipv4InterfaceAddress_methods(root_module, root_module['ns3::Ipv4InterfaceAddress']) register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address']) - register_Ns3Ipv6InterfaceAddress_methods(root_module, root_module['ns3::Ipv6InterfaceAddress']) register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix']) register_Ns3LogComponent_methods(root_module, root_module['ns3::LogComponent']) 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']) @@ -405,28 +319,22 @@ register_Ns3PacketTagList_methods(root_module, root_module['ns3::PacketTagList']) register_Ns3PacketTagListTagData_methods(root_module, root_module['ns3::PacketTagList::TagData']) 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_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) - register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) - register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) 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_Ns3Header_methods(root_module, root_module['ns3::Header']) register_Ns3Ipv4Header_methods(root_module, root_module['ns3::Ipv4Header']) - register_Ns3Ipv6Header_methods(root_module, root_module['ns3::Ipv6Header']) register_Ns3Object_methods(root_module, root_module['ns3::Object']) register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter >']) - register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3Ipv4MulticastRoute_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4MulticastRoute__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3Ipv4Route_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4Route__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter >']) @@ -441,7 +349,6 @@ register_Ns3SocketIpv6HopLimitTag_methods(root_module, root_module['ns3::SocketIpv6HopLimitTag']) register_Ns3SocketIpv6TclassTag_methods(root_module, root_module['ns3::SocketIpv6TclassTag']) register_Ns3SocketSetDontFragmentTag_methods(root_module, root_module['ns3::SocketSetDontFragmentTag']) - 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']) @@ -451,8 +358,6 @@ register_Ns3CallbackImplBase_methods(root_module, root_module['ns3::CallbackImplBase']) register_Ns3CallbackValue_methods(root_module, root_module['ns3::CallbackValue']) register_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue']) - register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -465,16 +370,12 @@ register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3NetDevice_methods(root_module, root_module['ns3::NetDevice']) register_Ns3NixVector_methods(root_module, root_module['ns3::NixVector']) - 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_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']) @@ -965,51 +866,6 @@ is_static=True, visibility='protected') 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 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_Ns3Hasher_methods(root_module, cls): ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Hasher const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hasher const &', 'arg0')]) @@ -1125,55 +981,6 @@ [param('uint16_t', 'port')]) return -def register_Ns3IntToType__0_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType(ns3::IntToType<0> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 0 > const &', 'arg0')]) - return - -def register_Ns3IntToType__1_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType(ns3::IntToType<1> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 1 > const &', 'arg0')]) - return - -def register_Ns3IntToType__2_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType(ns3::IntToType<2> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 2 > const &', 'arg0')]) - return - -def register_Ns3IntToType__3_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType(ns3::IntToType<3> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 3 > const &', 'arg0')]) - return - -def register_Ns3IntToType__4_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType(ns3::IntToType<4> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 4 > const &', 'arg0')]) - return - -def register_Ns3IntToType__5_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType(ns3::IntToType<5> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 5 > const &', 'arg0')]) - return - -def register_Ns3IntToType__6_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType(ns3::IntToType<6> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 6 > const &', 'arg0')]) - return - def register_Ns3Ipv4Address_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1510,10 +1317,11 @@ 'bool', [param('ns3::Ipv6Address const &', 'other')], is_const=True) - ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsIpv4MappedAddress() [member function] + ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsIpv4MappedAddress() const [member function] cls.add_method('IsIpv4MappedAddress', 'bool', - []) + [], + is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocal() const [member function] cls.add_method('IsLinkLocal', 'bool', @@ -1604,61 +1412,6 @@ [param('uint8_t *', 'address')]) return -def register_Ns3Ipv6InterfaceAddress_methods(root_module, cls): - cls.add_binary_comparison_operator('!=') - cls.add_output_stream_operator() - cls.add_binary_comparison_operator('==') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress() [constructor] - cls.add_constructor([]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address, ns3::Ipv6Prefix prefix) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'prefix')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6InterfaceAddress const & o) [copy constructor] - cls.add_constructor([param('ns3::Ipv6InterfaceAddress const &', 'o')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6InterfaceAddress::GetAddress() const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): uint32_t ns3::Ipv6InterfaceAddress::GetNsDadUid() const [member function] - cls.add_method('GetNsDadUid', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Prefix ns3::Ipv6InterfaceAddress::GetPrefix() const [member function] - cls.add_method('GetPrefix', - 'ns3::Ipv6Prefix', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e ns3::Ipv6InterfaceAddress::GetScope() const [member function] - cls.add_method('GetScope', - 'ns3::Ipv6InterfaceAddress::Scope_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e ns3::Ipv6InterfaceAddress::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Ipv6InterfaceAddress::State_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] - cls.add_method('SetAddress', - 'void', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetNsDadUid(uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('uint32_t', 'uid')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetScope(ns3::Ipv6InterfaceAddress::Scope_e scope) [member function] - cls.add_method('SetScope', - 'void', - [param('ns3::Ipv6InterfaceAddress::Scope_e', 'scope')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetState(ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - return - def register_Ns3Ipv6Prefix_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() @@ -1720,8 +1473,8 @@ def register_Ns3LogComponent_methods(root_module, cls): ## log.h (module 'core'): ns3::LogComponent::LogComponent(ns3::LogComponent const & arg0) [copy constructor] cls.add_constructor([param('ns3::LogComponent const &', 'arg0')]) - ## log.h (module 'core'): ns3::LogComponent::LogComponent(char const * name) [constructor] - cls.add_constructor([param('char const *', 'name')]) + ## log.h (module 'core'): ns3::LogComponent::LogComponent(std::string const & name) [constructor] + cls.add_constructor([param('std::string const &', 'name')]) ## log.h (module 'core'): void ns3::LogComponent::Disable(ns3::LogLevel level) [member function] cls.add_method('Disable', 'void', @@ -1730,10 +1483,10 @@ cls.add_method('Enable', 'void', [param('ns3::LogLevel', 'level')]) - ## log.h (module 'core'): void ns3::LogComponent::EnvVarCheck(char const * name) [member function] + ## log.h (module 'core'): void ns3::LogComponent::EnvVarCheck(std::string const & name) [member function] cls.add_method('EnvVarCheck', 'void', - [param('char const *', 'name')]) + [param('std::string const &', 'name')]) ## log.h (module 'core'): std::string ns3::LogComponent::GetLevelLabel(ns3::LogLevel const level) const [member function] cls.add_method('GetLevelLabel', 'std::string', @@ -1829,42 +1582,6 @@ 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::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')]) @@ -2068,86 +1785,6 @@ 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::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 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_Ns3SystemWallClockMs_methods(root_module, cls): ## system-wall-clock-ms.h (module 'core'): ns3::SystemWallClockMs::SystemWallClockMs(ns3::SystemWallClockMs const & arg0) [copy constructor] cls.add_constructor([param('ns3::SystemWallClockMs const &', 'arg0')]) @@ -2273,90 +1910,6 @@ [param('uint8_t', 'v')]) return -def register_Ns3Timer_methods(root_module, cls): - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Timer const &', 'arg0')]) - ## timer.h (module 'core'): ns3::Timer::Timer() [constructor] - cls.add_constructor([]) - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer::DestroyPolicy destroyPolicy) [constructor] - cls.add_constructor([param('ns3::Timer::DestroyPolicy', 'destroyPolicy')]) - ## timer.h (module 'core'): void ns3::Timer::Cancel() [member function] - cls.add_method('Cancel', - 'void', - []) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelay() const [member function] - cls.add_method('GetDelay', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelayLeft() const [member function] - cls.add_method('GetDelayLeft', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Timer::State ns3::Timer::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Timer::State', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsExpired() const [member function] - cls.add_method('IsExpired', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsRunning() const [member function] - cls.add_method('IsRunning', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsSuspended() const [member function] - cls.add_method('IsSuspended', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): void ns3::Timer::Remove() [member function] - cls.add_method('Remove', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Resume() [member function] - cls.add_method('Resume', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule() [member function] - cls.add_method('Schedule', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule(ns3::Time delay) [member function] - cls.add_method('Schedule', - 'void', - [param('ns3::Time', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::SetDelay(ns3::Time const & delay) [member function] - cls.add_method('SetDelay', - 'void', - [param('ns3::Time const &', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::Suspend() [member function] - cls.add_method('Suspend', - 'void', - []) - return - -def register_Ns3TimerImpl_methods(root_module, cls): - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl() [constructor] - cls.add_constructor([]) - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl(ns3::TimerImpl const & arg0) [copy constructor] - cls.add_constructor([param('ns3::TimerImpl const &', 'arg0')]) - ## timer-impl.h (module 'core'): void ns3::TimerImpl::Invoke() [member function] - cls.add_method('Invoke', - 'void', - [], - is_pure_virtual=True, is_virtual=True) - ## timer-impl.h (module 'core'): ns3::EventId ns3::TimerImpl::Schedule(ns3::Time const & delay) [member function] - cls.add_method('Schedule', - 'ns3::EventId', - [param('ns3::Time const &', 'delay')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2553,113 +2106,6 @@ 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([]) @@ -2887,106 +2333,6 @@ [param('uint8_t', 'ttl')]) return -def register_Ns3Ipv6Header_methods(root_module, cls): - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header(ns3::Ipv6Header const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Header const &', 'arg0')]) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header() [constructor] - cls.add_constructor([]) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::Deserialize(ns3::Buffer::Iterator start) [member function] - cls.add_method('Deserialize', - 'uint32_t', - [param('ns3::Buffer::Iterator', 'start')], - is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetDestinationAddress() const [member function] - cls.add_method('GetDestinationAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetFlowLabel() const [member function] - cls.add_method('GetFlowLabel', - 'uint32_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetHopLimit() const [member function] - cls.add_method('GetHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): ns3::TypeId ns3::Ipv6Header::GetInstanceTypeId() const [member function] - cls.add_method('GetInstanceTypeId', - 'ns3::TypeId', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetNextHeader() const [member function] - cls.add_method('GetNextHeader', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint16_t ns3::Ipv6Header::GetPayloadLength() const [member function] - cls.add_method('GetPayloadLength', - 'uint16_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetSerializedSize() const [member function] - cls.add_method('GetSerializedSize', - 'uint32_t', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetSourceAddress() const [member function] - cls.add_method('GetSourceAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetTrafficClass() const [member function] - cls.add_method('GetTrafficClass', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): static ns3::TypeId ns3::Ipv6Header::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Print(std::ostream & os) const [member function] - cls.add_method('Print', - 'void', - [param('std::ostream &', 'os')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Serialize(ns3::Buffer::Iterator start) const [member function] - cls.add_method('Serialize', - 'void', - [param('ns3::Buffer::Iterator', 'start')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetDestinationAddress(ns3::Ipv6Address dst) [member function] - cls.add_method('SetDestinationAddress', - 'void', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetFlowLabel(uint32_t flow) [member function] - cls.add_method('SetFlowLabel', - 'void', - [param('uint32_t', 'flow')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetHopLimit(uint8_t limit) [member function] - cls.add_method('SetHopLimit', - 'void', - [param('uint8_t', 'limit')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetNextHeader(uint8_t next) [member function] - cls.add_method('SetNextHeader', - 'void', - [param('uint8_t', 'next')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetPayloadLength(uint16_t len) [member function] - cls.add_method('SetPayloadLength', - 'void', - [param('uint16_t', 'len')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetSourceAddress(ns3::Ipv6Address src) [member function] - cls.add_method('SetSourceAddress', - 'void', - [param('ns3::Ipv6Address', 'src')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetTrafficClass(uint8_t traffic) [member function] - cls.add_method('SetTrafficClass', - 'void', - [param('uint8_t', 'traffic')]) - return - def register_Ns3Object_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::Object() [constructor] cls.add_constructor([]) @@ -3101,18 +2447,6 @@ 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 >::SimpleRefCount() [constructor] - cls.add_constructor([]) - ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] - cls.add_method('Cleanup', - 'void', - [], - is_static=True) - return - def register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] cls.add_constructor([]) @@ -3808,177 +3142,6 @@ is_const=True, is_virtual=True) 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 ns3::Time ns3::Time::Max() [member function] - cls.add_method('Max', - 'ns3::Time', - [], - is_static=True) - ## nstime.h (module 'core'): static ns3::Time ns3::Time::Min() [member function] - cls.add_method('Min', - 'ns3::Time', - [], - is_static=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'): static bool ns3::Time::StaticInit() [member function] - cls.add_method('StaticInit', - 'bool', - [], - 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')]) @@ -4199,87 +3362,6 @@ is_const=True, visibility='private', 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_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -4565,10 +3647,10 @@ cls.add_method('Send', 'void', [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Address', 'dest')]) - ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetArpCache(ns3::Ptr arg0) [member function] + ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetArpCache(ns3::Ptr arpCache) [member function] cls.add_method('SetArpCache', 'void', - [param('ns3::Ptr< ns3::ArpCache >', 'arg0')]) + [param('ns3::Ptr< ns3::ArpCache >', 'arpCache')]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetDevice(ns3::Ptr device) [member function] cls.add_method('SetDevice', 'void', @@ -4835,151 +3917,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor] cls.add_constructor([]) @@ -5196,46 +4133,6 @@ is_const=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::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 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 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')]) @@ -5434,39 +4331,6 @@ [param('ns3::Ptr< ns3::NixVector >', '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::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 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 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([]) diff -Naur ns-3.19/src/click/bindings/modulegen__gcc_LP64.py ns-3.20/src/click/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/click/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.536635905 -0700 +++ ns-3.20/src/click/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.864996186 -0700 @@ -46,8 +46,6 @@ 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') - ## event-id.h (module 'core'): ns3::EventId [class] - module.add_class('EventId', import_from_module='ns.core') ## hash.h (module 'core'): ns3::Hasher [class] module.add_class('Hasher', import_from_module='ns.core') ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress [class] @@ -58,34 +56,6 @@ module.add_class('InetSocketAddress', import_from_module='ns.network') ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] root_module['ns3::InetSocketAddress'].implicitly_converts_to(root_module['ns3::Address']) - ## int-to-type.h (module 'core'): ns3::IntToType<0> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['0']) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 0 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<1> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['1']) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 1 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<2> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['2']) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 2 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<3> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['3']) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 3 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<4> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['4']) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 4 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<5> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['5']) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 5 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<6> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['6']) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 6 >'], 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] @@ -100,12 +70,6 @@ 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-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress [class] - module.add_class('Ipv6InterfaceAddress', import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e [enumeration] - module.add_enum('State_e', ['TENTATIVE', 'DEPRECATED', 'PREFERRED', 'PERMANENT', 'HOMEADDRESS', 'TENTATIVE_OPTIMISTIC', 'INVALID'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e [enumeration] - module.add_enum('Scope_e', ['HOST', 'LINKLOCAL', 'GLOBAL'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix [class] module.add_class('Ipv6Prefix', import_from_module='ns.network') ## log.h (module 'core'): ns3::LogComponent [class] @@ -114,8 +78,6 @@ 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] @@ -136,22 +98,12 @@ module.add_enum('TagData_e', ['MAX_SIZE'], outer_class=root_module['ns3::PacketTagList::TagData'], import_from_module='ns.network') ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount [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-wall-clock-ms.h (module 'core'): ns3::SystemWallClockMs [class] module.add_class('SystemWallClockMs', 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') - ## timer.h (module 'core'): ns3::Timer [class] - module.add_class('Timer', import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] - module.add_enum('DestroyPolicy', ['CANCEL_ON_DESTROY', 'REMOVE_ON_DESTROY', 'CHECK_ON_DESTROY'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::State [enumeration] - module.add_enum('State', ['RUNNING', 'EXPIRED', 'SUSPENDED'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer-impl.h (module 'core'): ns3::TimerImpl [class] - module.add_class('TimerImpl', allow_subclassing=True, import_from_module='ns.core') ## 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] @@ -162,8 +114,6 @@ 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']) ## header.h (module 'network'): ns3::Header [class] @@ -174,10 +124,6 @@ module.add_enum('DscpType', ['DscpDefault', 'DSCP_CS1', 'DSCP_AF11', 'DSCP_AF12', 'DSCP_AF13', 'DSCP_CS2', 'DSCP_AF21', 'DSCP_AF22', 'DSCP_AF23', 'DSCP_CS3', 'DSCP_AF31', 'DSCP_AF32', 'DSCP_AF33', 'DSCP_CS4', 'DSCP_AF41', 'DSCP_AF42', 'DSCP_AF43', 'DSCP_CS5', 'DSCP_EF', 'DSCP_CS6', 'DSCP_CS7'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType [enumeration] module.add_enum('EcnType', ['ECN_NotECT', 'ECN_ECT1', 'ECN_ECT0', 'ECN_CE'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header [class] - module.add_class('Ipv6Header', import_from_module='ns.internet', parent=root_module['ns3::Header']) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::NextHeader_e [enumeration] - module.add_enum('NextHeader_e', ['IPV6_EXT_HOP_BY_HOP', 'IPV6_IPV4', 'IPV6_TCP', 'IPV6_UDP', 'IPV6_IPV6', 'IPV6_EXT_ROUTING', 'IPV6_EXT_FRAGMENTATION', 'IPV6_EXT_CONFIDENTIALITY', 'IPV6_EXT_AUTHENTIFICATION', 'IPV6_ICMPV6', 'IPV6_EXT_END', 'IPV6_EXT_DESTINATION', 'IPV6_SCTP', 'IPV6_EXT_MOBILITY', 'IPV6_UDP_LITE'], outer_class=root_module['ns3::Ipv6Header'], import_from_module='ns.internet') ## 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] @@ -190,8 +136,6 @@ module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeValue', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::CallbackImplBase', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] - module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::EventImpl', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Hash::Implementation', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] @@ -224,12 +168,6 @@ module.add_class('SocketIpv6TclassTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## socket.h (module 'network'): ns3::SocketSetDontFragmentTag [class] module.add_class('SocketSetDontFragmentTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) - ## 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 >']) ## trailer.h (module 'network'): ns3::Trailer [class] @@ -248,12 +186,6 @@ module.add_class('CallbackValue', import_from_module='ns.core', 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']) - ## 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 >']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -278,8 +210,6 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -290,16 +220,10 @@ 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 >']) - ## 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 >']) ## 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 >']) - ## 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] @@ -376,27 +300,17 @@ 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_Ns3EventId_methods(root_module, root_module['ns3::EventId']) register_Ns3Hasher_methods(root_module, root_module['ns3::Hasher']) register_Ns3Inet6SocketAddress_methods(root_module, root_module['ns3::Inet6SocketAddress']) register_Ns3InetSocketAddress_methods(root_module, root_module['ns3::InetSocketAddress']) - register_Ns3IntToType__0_methods(root_module, root_module['ns3::IntToType< 0 >']) - register_Ns3IntToType__1_methods(root_module, root_module['ns3::IntToType< 1 >']) - register_Ns3IntToType__2_methods(root_module, root_module['ns3::IntToType< 2 >']) - register_Ns3IntToType__3_methods(root_module, root_module['ns3::IntToType< 3 >']) - register_Ns3IntToType__4_methods(root_module, root_module['ns3::IntToType< 4 >']) - register_Ns3IntToType__5_methods(root_module, root_module['ns3::IntToType< 5 >']) - register_Ns3IntToType__6_methods(root_module, root_module['ns3::IntToType< 6 >']) register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address']) register_Ns3Ipv4InterfaceAddress_methods(root_module, root_module['ns3::Ipv4InterfaceAddress']) register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address']) - register_Ns3Ipv6InterfaceAddress_methods(root_module, root_module['ns3::Ipv6InterfaceAddress']) register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix']) register_Ns3LogComponent_methods(root_module, root_module['ns3::LogComponent']) 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']) @@ -405,28 +319,22 @@ register_Ns3PacketTagList_methods(root_module, root_module['ns3::PacketTagList']) register_Ns3PacketTagListTagData_methods(root_module, root_module['ns3::PacketTagList::TagData']) 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_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) - register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) - register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) 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_Ns3Header_methods(root_module, root_module['ns3::Header']) register_Ns3Ipv4Header_methods(root_module, root_module['ns3::Ipv4Header']) - register_Ns3Ipv6Header_methods(root_module, root_module['ns3::Ipv6Header']) register_Ns3Object_methods(root_module, root_module['ns3::Object']) register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter >']) - register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3Ipv4MulticastRoute_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4MulticastRoute__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter >']) register_Ns3SimpleRefCount__Ns3Ipv4Route_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4Route__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter >']) @@ -441,7 +349,6 @@ register_Ns3SocketIpv6HopLimitTag_methods(root_module, root_module['ns3::SocketIpv6HopLimitTag']) register_Ns3SocketIpv6TclassTag_methods(root_module, root_module['ns3::SocketIpv6TclassTag']) register_Ns3SocketSetDontFragmentTag_methods(root_module, root_module['ns3::SocketSetDontFragmentTag']) - 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']) @@ -451,8 +358,6 @@ register_Ns3CallbackImplBase_methods(root_module, root_module['ns3::CallbackImplBase']) register_Ns3CallbackValue_methods(root_module, root_module['ns3::CallbackValue']) register_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue']) - register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -465,16 +370,12 @@ register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3NetDevice_methods(root_module, root_module['ns3::NetDevice']) register_Ns3NixVector_methods(root_module, root_module['ns3::NixVector']) - 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_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']) @@ -965,51 +866,6 @@ is_static=True, visibility='protected') 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 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_Ns3Hasher_methods(root_module, cls): ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Hasher const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hasher const &', 'arg0')]) @@ -1125,55 +981,6 @@ [param('uint16_t', 'port')]) return -def register_Ns3IntToType__0_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType(ns3::IntToType<0> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 0 > const &', 'arg0')]) - return - -def register_Ns3IntToType__1_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType(ns3::IntToType<1> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 1 > const &', 'arg0')]) - return - -def register_Ns3IntToType__2_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType(ns3::IntToType<2> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 2 > const &', 'arg0')]) - return - -def register_Ns3IntToType__3_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType(ns3::IntToType<3> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 3 > const &', 'arg0')]) - return - -def register_Ns3IntToType__4_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType(ns3::IntToType<4> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 4 > const &', 'arg0')]) - return - -def register_Ns3IntToType__5_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType(ns3::IntToType<5> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 5 > const &', 'arg0')]) - return - -def register_Ns3IntToType__6_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType(ns3::IntToType<6> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 6 > const &', 'arg0')]) - return - def register_Ns3Ipv4Address_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1510,10 +1317,11 @@ 'bool', [param('ns3::Ipv6Address const &', 'other')], is_const=True) - ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsIpv4MappedAddress() [member function] + ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsIpv4MappedAddress() const [member function] cls.add_method('IsIpv4MappedAddress', 'bool', - []) + [], + is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocal() const [member function] cls.add_method('IsLinkLocal', 'bool', @@ -1604,61 +1412,6 @@ [param('uint8_t *', 'address')]) return -def register_Ns3Ipv6InterfaceAddress_methods(root_module, cls): - cls.add_binary_comparison_operator('!=') - cls.add_output_stream_operator() - cls.add_binary_comparison_operator('==') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress() [constructor] - cls.add_constructor([]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address, ns3::Ipv6Prefix prefix) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'prefix')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6InterfaceAddress const & o) [copy constructor] - cls.add_constructor([param('ns3::Ipv6InterfaceAddress const &', 'o')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6InterfaceAddress::GetAddress() const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): uint32_t ns3::Ipv6InterfaceAddress::GetNsDadUid() const [member function] - cls.add_method('GetNsDadUid', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Prefix ns3::Ipv6InterfaceAddress::GetPrefix() const [member function] - cls.add_method('GetPrefix', - 'ns3::Ipv6Prefix', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e ns3::Ipv6InterfaceAddress::GetScope() const [member function] - cls.add_method('GetScope', - 'ns3::Ipv6InterfaceAddress::Scope_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e ns3::Ipv6InterfaceAddress::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Ipv6InterfaceAddress::State_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] - cls.add_method('SetAddress', - 'void', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetNsDadUid(uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('uint32_t', 'uid')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetScope(ns3::Ipv6InterfaceAddress::Scope_e scope) [member function] - cls.add_method('SetScope', - 'void', - [param('ns3::Ipv6InterfaceAddress::Scope_e', 'scope')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetState(ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - return - def register_Ns3Ipv6Prefix_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() @@ -1720,8 +1473,8 @@ def register_Ns3LogComponent_methods(root_module, cls): ## log.h (module 'core'): ns3::LogComponent::LogComponent(ns3::LogComponent const & arg0) [copy constructor] cls.add_constructor([param('ns3::LogComponent const &', 'arg0')]) - ## log.h (module 'core'): ns3::LogComponent::LogComponent(char const * name) [constructor] - cls.add_constructor([param('char const *', 'name')]) + ## log.h (module 'core'): ns3::LogComponent::LogComponent(std::string const & name) [constructor] + cls.add_constructor([param('std::string const &', 'name')]) ## log.h (module 'core'): void ns3::LogComponent::Disable(ns3::LogLevel level) [member function] cls.add_method('Disable', 'void', @@ -1730,10 +1483,10 @@ cls.add_method('Enable', 'void', [param('ns3::LogLevel', 'level')]) - ## log.h (module 'core'): void ns3::LogComponent::EnvVarCheck(char const * name) [member function] + ## log.h (module 'core'): void ns3::LogComponent::EnvVarCheck(std::string const & name) [member function] cls.add_method('EnvVarCheck', 'void', - [param('char const *', 'name')]) + [param('std::string const &', 'name')]) ## log.h (module 'core'): std::string ns3::LogComponent::GetLevelLabel(ns3::LogLevel const level) const [member function] cls.add_method('GetLevelLabel', 'std::string', @@ -1829,42 +1582,6 @@ 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::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')]) @@ -2068,86 +1785,6 @@ 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::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 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_Ns3SystemWallClockMs_methods(root_module, cls): ## system-wall-clock-ms.h (module 'core'): ns3::SystemWallClockMs::SystemWallClockMs(ns3::SystemWallClockMs const & arg0) [copy constructor] cls.add_constructor([param('ns3::SystemWallClockMs const &', 'arg0')]) @@ -2273,90 +1910,6 @@ [param('uint8_t', 'v')]) return -def register_Ns3Timer_methods(root_module, cls): - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Timer const &', 'arg0')]) - ## timer.h (module 'core'): ns3::Timer::Timer() [constructor] - cls.add_constructor([]) - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer::DestroyPolicy destroyPolicy) [constructor] - cls.add_constructor([param('ns3::Timer::DestroyPolicy', 'destroyPolicy')]) - ## timer.h (module 'core'): void ns3::Timer::Cancel() [member function] - cls.add_method('Cancel', - 'void', - []) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelay() const [member function] - cls.add_method('GetDelay', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelayLeft() const [member function] - cls.add_method('GetDelayLeft', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Timer::State ns3::Timer::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Timer::State', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsExpired() const [member function] - cls.add_method('IsExpired', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsRunning() const [member function] - cls.add_method('IsRunning', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsSuspended() const [member function] - cls.add_method('IsSuspended', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): void ns3::Timer::Remove() [member function] - cls.add_method('Remove', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Resume() [member function] - cls.add_method('Resume', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule() [member function] - cls.add_method('Schedule', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule(ns3::Time delay) [member function] - cls.add_method('Schedule', - 'void', - [param('ns3::Time', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::SetDelay(ns3::Time const & delay) [member function] - cls.add_method('SetDelay', - 'void', - [param('ns3::Time const &', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::Suspend() [member function] - cls.add_method('Suspend', - 'void', - []) - return - -def register_Ns3TimerImpl_methods(root_module, cls): - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl() [constructor] - cls.add_constructor([]) - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl(ns3::TimerImpl const & arg0) [copy constructor] - cls.add_constructor([param('ns3::TimerImpl const &', 'arg0')]) - ## timer-impl.h (module 'core'): void ns3::TimerImpl::Invoke() [member function] - cls.add_method('Invoke', - 'void', - [], - is_pure_virtual=True, is_virtual=True) - ## timer-impl.h (module 'core'): ns3::EventId ns3::TimerImpl::Schedule(ns3::Time const & delay) [member function] - cls.add_method('Schedule', - 'ns3::EventId', - [param('ns3::Time const &', 'delay')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2553,113 +2106,6 @@ 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([]) @@ -2887,106 +2333,6 @@ [param('uint8_t', 'ttl')]) return -def register_Ns3Ipv6Header_methods(root_module, cls): - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header(ns3::Ipv6Header const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Header const &', 'arg0')]) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header() [constructor] - cls.add_constructor([]) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::Deserialize(ns3::Buffer::Iterator start) [member function] - cls.add_method('Deserialize', - 'uint32_t', - [param('ns3::Buffer::Iterator', 'start')], - is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetDestinationAddress() const [member function] - cls.add_method('GetDestinationAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetFlowLabel() const [member function] - cls.add_method('GetFlowLabel', - 'uint32_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetHopLimit() const [member function] - cls.add_method('GetHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): ns3::TypeId ns3::Ipv6Header::GetInstanceTypeId() const [member function] - cls.add_method('GetInstanceTypeId', - 'ns3::TypeId', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetNextHeader() const [member function] - cls.add_method('GetNextHeader', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint16_t ns3::Ipv6Header::GetPayloadLength() const [member function] - cls.add_method('GetPayloadLength', - 'uint16_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetSerializedSize() const [member function] - cls.add_method('GetSerializedSize', - 'uint32_t', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetSourceAddress() const [member function] - cls.add_method('GetSourceAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetTrafficClass() const [member function] - cls.add_method('GetTrafficClass', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): static ns3::TypeId ns3::Ipv6Header::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Print(std::ostream & os) const [member function] - cls.add_method('Print', - 'void', - [param('std::ostream &', 'os')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Serialize(ns3::Buffer::Iterator start) const [member function] - cls.add_method('Serialize', - 'void', - [param('ns3::Buffer::Iterator', 'start')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetDestinationAddress(ns3::Ipv6Address dst) [member function] - cls.add_method('SetDestinationAddress', - 'void', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetFlowLabel(uint32_t flow) [member function] - cls.add_method('SetFlowLabel', - 'void', - [param('uint32_t', 'flow')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetHopLimit(uint8_t limit) [member function] - cls.add_method('SetHopLimit', - 'void', - [param('uint8_t', 'limit')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetNextHeader(uint8_t next) [member function] - cls.add_method('SetNextHeader', - 'void', - [param('uint8_t', 'next')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetPayloadLength(uint16_t len) [member function] - cls.add_method('SetPayloadLength', - 'void', - [param('uint16_t', 'len')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetSourceAddress(ns3::Ipv6Address src) [member function] - cls.add_method('SetSourceAddress', - 'void', - [param('ns3::Ipv6Address', 'src')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetTrafficClass(uint8_t traffic) [member function] - cls.add_method('SetTrafficClass', - 'void', - [param('uint8_t', 'traffic')]) - return - def register_Ns3Object_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::Object() [constructor] cls.add_constructor([]) @@ -3101,18 +2447,6 @@ 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 >::SimpleRefCount() [constructor] - cls.add_constructor([]) - ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] - cls.add_method('Cleanup', - 'void', - [], - is_static=True) - return - def register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] cls.add_constructor([]) @@ -3808,177 +3142,6 @@ is_const=True, is_virtual=True) 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 ns3::Time ns3::Time::Max() [member function] - cls.add_method('Max', - 'ns3::Time', - [], - is_static=True) - ## nstime.h (module 'core'): static ns3::Time ns3::Time::Min() [member function] - cls.add_method('Min', - 'ns3::Time', - [], - is_static=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'): static bool ns3::Time::StaticInit() [member function] - cls.add_method('StaticInit', - 'bool', - [], - 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')]) @@ -4199,87 +3362,6 @@ is_const=True, visibility='private', 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_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -4565,10 +3647,10 @@ cls.add_method('Send', 'void', [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Address', 'dest')]) - ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetArpCache(ns3::Ptr arg0) [member function] + ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetArpCache(ns3::Ptr arpCache) [member function] cls.add_method('SetArpCache', 'void', - [param('ns3::Ptr< ns3::ArpCache >', 'arg0')]) + [param('ns3::Ptr< ns3::ArpCache >', 'arpCache')]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetDevice(ns3::Ptr device) [member function] cls.add_method('SetDevice', 'void', @@ -4835,151 +3917,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor] cls.add_constructor([]) @@ -5196,46 +4133,6 @@ is_const=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::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 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 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')]) @@ -5434,39 +4331,6 @@ [param('ns3::Ptr< ns3::NixVector >', '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::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 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 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([]) diff -Naur ns-3.19/src/click/model/ipv4-click-routing.cc ns-3.20/src/click/model/ipv4-click-routing.cc --- ns-3.19/src/click/model/ipv4-click-routing.cc 2014-06-17 10:34:00.543635851 -0700 +++ ns-3.20/src/click/model/ipv4-click-routing.cc 2014-06-17 10:33:13.871996131 -0700 @@ -45,8 +45,7 @@ #define INTERFACE_ID_FIRST 1 #define INTERFACE_ID_FIRST_DROP 33 -NS_OBJECT_ENSURE_REGISTERED (Ipv4ClickRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4ClickRouting); std::map < simclick_node_t *, Ptr > Ipv4ClickRouting::m_clickInstanceFromSimNode; diff -Naur ns-3.19/src/click/model/ipv4-click-routing.h ns-3.20/src/click/model/ipv4-click-routing.h --- ns-3.19/src/click/model/ipv4-click-routing.h 2014-06-17 10:34:00.544635843 -0700 +++ ns-3.20/src/click/model/ipv4-click-routing.h 2014-06-17 10:33:13.872996124 -0700 @@ -37,6 +37,10 @@ #include #include +class ClickTrivialTest; +class ClickIfidFromNameTest; +class ClickIpMacAddressFromNameTest; + namespace ns3 { /** @@ -56,9 +60,9 @@ #ifdef NS3_CLICK public: // Allow test cases to access private members - friend class ClickTrivialTest; - friend class ClickIfidFromNameTest; - friend class ClickIpMacAddressFromNameTest; + friend class ::ClickTrivialTest; + friend class ::ClickIfidFromNameTest; + friend class ::ClickIpMacAddressFromNameTest; static TypeId GetTypeId (void); diff -Naur ns-3.19/src/click/model/ipv4-l3-click-protocol.cc ns-3.20/src/click/model/ipv4-l3-click-protocol.cc --- ns-3.19/src/click/model/ipv4-l3-click-protocol.cc 2014-06-17 10:34:00.544635843 -0700 +++ ns-3.20/src/click/model/ipv4-l3-click-protocol.cc 2014-06-17 10:33:13.873996116 -0700 @@ -44,8 +44,7 @@ const uint16_t Ipv4L3ClickProtocol::PROT_NUMBER = 0x0800; -NS_OBJECT_ENSURE_REGISTERED (Ipv4L3ClickProtocol) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4L3ClickProtocol); TypeId Ipv4L3ClickProtocol::GetTypeId (void) diff -Naur ns-3.19/src/click/test/ipv4-click-routing-test.cc ns-3.20/src/click/test/ipv4-click-routing-test.cc --- ns-3.19/src/click/test/ipv4-click-routing-test.cc 2014-06-17 10:34:00.546635828 -0700 +++ ns-3.20/src/click/test/ipv4-click-routing-test.cc 2014-06-17 10:33:13.874996108 -0700 @@ -30,7 +30,7 @@ #include -namespace ns3 { +using namespace ns3; static void AddClickInternetStack (Ptr node) @@ -203,6 +203,4 @@ } } g_ipv4ClickRoutingTestSuite; -} // namespace ns3 - #endif // NS3_CLICK diff -Naur ns-3.19/src/click/waf ns-3.20/src/click/waf --- ns-3.19/src/click/waf 2014-06-17 10:34:00.546635828 -0700 +++ ns-3.20/src/click/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../../waf "$@" diff -Naur ns-3.19/src/config-store/bindings/modulegen__gcc_ILP32.py ns-3.20/src/config-store/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/config-store/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.548635812 -0700 +++ ns-3.20/src/config-store/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.876996093 -0700 @@ -102,12 +102,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function diff -Naur ns-3.19/src/config-store/bindings/modulegen__gcc_LP64.py ns-3.20/src/config-store/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/config-store/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.549635804 -0700 +++ ns-3.20/src/config-store/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.877996085 -0700 @@ -102,12 +102,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function diff -Naur ns-3.19/src/config-store/examples/config-store-save.cc ns-3.20/src/config-store/examples/config-store-save.cc --- ns-3.19/src/config-store/examples/config-store-save.cc 2014-06-17 10:34:00.550635797 -0700 +++ ns-3.20/src/config-store/examples/config-store-save.cc 2014-06-17 10:33:13.878996077 -0700 @@ -22,8 +22,7 @@ int16_t m_int16; }; -NS_OBJECT_ENSURE_REGISTERED (ConfigExample) - ; +NS_OBJECT_ENSURE_REGISTERED (ConfigExample); // Assign a new default value to A::TestInt16 (-5) // Configure a TestInt16 value for a special instance of A (to -3) diff -Naur ns-3.19/src/config-store/model/config-store.cc ns-3.20/src/config-store/model/config-store.cc --- ns-3.19/src/config-store/model/config-store.cc 2014-06-17 10:34:00.552635781 -0700 +++ ns-3.20/src/config-store/model/config-store.cc 2014-06-17 10:33:13.880996062 -0700 @@ -23,8 +23,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ConfigStore) - ; +NS_OBJECT_ENSURE_REGISTERED (ConfigStore); TypeId ConfigStore::GetTypeId (void) diff -Naur ns-3.19/src/config-store/model/gtk-config-store.cc ns-3.20/src/config-store/model/gtk-config-store.cc --- ns-3.19/src/config-store/model/gtk-config-store.cc 2014-06-17 10:34:00.554635766 -0700 +++ ns-3.20/src/config-store/model/gtk-config-store.cc 2014-06-17 10:33:13.882996046 -0700 @@ -26,8 +26,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("GtkconfigStore") - ; +NS_LOG_COMPONENT_DEFINE ("GtkconfigStore"); GtkConfigStore::GtkConfigStore () diff -Naur ns-3.19/src/core/bindings/core.py ns-3.20/src/core/bindings/core.py --- ns-3.19/src/core/bindings/core.py 2014-06-17 10:34:00.558635735 -0700 +++ ns-3.20/src/core/bindings/core.py 2014-06-17 10:33:13.886996016 -0700 @@ -1,10 +1,10 @@ - +from __future__ import absolute_import # "from _core import *" doesn't work here because symbols starting # with underscore would not be imported. But they are needed because # other modules depend on them... -import _core +from . import _core g = globals() -for k,v in _core.__dict__.iteritems(): +for k,v in _core.__dict__.items(): g[k] = v del g, k, v, _core diff -Naur ns-3.19/src/core/bindings/modulegen_customizations.py ns-3.20/src/core/bindings/modulegen_customizations.py --- ns-3.19/src/core/bindings/modulegen_customizations.py 2014-06-17 10:34:00.567635665 -0700 +++ ns-3.20/src/core/bindings/modulegen_customizations.py 2014-06-17 10:33:13.895995946 -0700 @@ -13,77 +13,6 @@ from pybindgen.typehandlers.base import CodeGenerationError -# class SmartPointerTransformation(typehandlers.TypeTransformation): -# """ -# This class provides a "type transformation" that tends to support -# NS-3 smart pointers. Parameters such as "Ptr foo" are -# transformed into something like Parameter.new("Foo*", "foo", -# transfer_ownership=False). Return values such as Ptr are -# transformed into ReturnValue.new("Foo*", -# caller_owns_return=False). Since the underlying objects have -# reference counting, PyBindGen does the right thing. -# """ -# def __init__(self): -# super(SmartPointerTransformation, self).__init__() -# self.rx = re.compile(r'(ns3::|::ns3::|)Ptr<([^>]+)>\s*$') - -# def _get_untransformed_type_traits(self, name): -# m = self.rx.match(name) -# is_const = False -# if m is None: -# return None, False -# else: -# name1 = m.group(2).strip() -# if name1.startswith('const '): -# name1 = name1[len('const '):] -# is_const = True -# if name1.endswith(' const'): -# name1 = name1[:-len(' const')] -# is_const = True -# new_name = name1+' *' - -# if new_name.startswith('::'): -# new_name = new_name[2:] -# return new_name, is_const - -# def get_untransformed_name(self, name): -# new_name, dummy_is_const = self._get_untransformed_type_traits(name) -# return new_name - -# def create_type_handler(self, type_handler, *args, **kwargs): -# if issubclass(type_handler, Parameter): -# kwargs['transfer_ownership'] = False -# elif issubclass(type_handler, ReturnValue): -# kwargs['caller_owns_return'] = False -# else: -# raise AssertionError - -# ## fix the ctype, add ns3:: namespace -# orig_ctype, is_const = self._get_untransformed_type_traits(args[0]) -# if is_const: -# correct_ctype = 'ns3::Ptr< %s const >' % orig_ctype[:-2] -# else: -# correct_ctype = 'ns3::Ptr< %s >' % orig_ctype[:-2] -# args = tuple([correct_ctype] + list(args[1:])) - -# handler = type_handler(*args, **kwargs) -# handler.set_tranformation(self, orig_ctype) -# return handler - -# def untransform(self, type_handler, declarations, code_block, expression): -# return 'const_cast<%s> (ns3::PeekPointer (%s))' % (type_handler.untransformed_ctype, expression) - -# def transform(self, type_handler, declarations, code_block, expression): -# assert type_handler.untransformed_ctype[-1] == '*' -# return 'ns3::Ptr< %s > (%s)' % (type_handler.untransformed_ctype[:-1], expression) - -# ## register the type transformation -# transf = SmartPointerTransformation() -# typehandlers.return_type_matcher.register_transformation(transf) -# typehandlers.param_type_matcher.register_transformation(transf) -# del transf - - class ArgvParam(Parameter): """ Converts a python list-of-strings argument to a pair of 'int argc, @@ -123,11 +52,21 @@ ''' % vars()) #wrapper.before_call.write_error_check('item == NULL') wrapper.before_call.write_error_check( - '!PyString_Check(item)', + '\n' + '#if PY_VERSION_HEX >= 0x03000000\n' + '!PyUnicode_Check(item)\n' + '#else\n' + '!PyString_Check(item)\n' + '#endif\n', failure_cleanup=('PyErr_SetString(PyExc_TypeError, ' '"argument %s must be a list of strings");') % self.name) wrapper.before_call.write_code( - '%s[%s] = PyString_AsString(item);' % (name, idx)) + '#if PY_VERSION_HEX >= 0x03000000\n' + '{var}[{idx}] = PyUnicode_AsUTF8(item);\n' + '#else\n' + '{var}[{idx}] = PyString_AsString(item);\n' + '#endif\n' + .format(var=name, idx=idx)) wrapper.before_call.sink.unindent() wrapper.before_call.write_code('}') wrapper.before_call.write_code('%s = PyList_Size(%s);' % (argc_var, py_name)) @@ -136,165 +75,6 @@ wrapper.call_params.append(name) -# class CallbackImplProxyMethod(typehandlers.ReverseWrapperBase): -# """ -# Class that generates a proxy virtual method that calls a similarly named python method. -# """ - -# def __init__(self, return_value, parameters): -# super(CallbackImplProxyMethod, self).__init__(return_value, parameters) - -# def generate_python_call(self): -# """code to call the python method""" -# build_params = self.build_params.get_parameters(force_tuple_creation=True) -# if build_params[0][0] == '"': -# build_params[0] = '(char *) ' + build_params[0] -# args = self.before_call.declare_variable('PyObject*', 'args') -# self.before_call.write_code('%s = Py_BuildValue(%s);' -# % (args, ', '.join(build_params))) -# self.before_call.add_cleanup_code('Py_DECREF(%s);' % args) -# self.before_call.write_code('py_retval = PyObject_CallObject(m_callback, %s);' % args) -# self.before_call.write_error_check('py_retval == NULL') -# self.before_call.add_cleanup_code('Py_DECREF(py_retval);') - - - - -# def generate_callback_classes(out, callbacks): -# for callback_impl_num, template_parameters in enumerate(callbacks): -# sink = MemoryCodeSink() -# cls_name = "ns3::Callback< %s >" % ', '.join(template_parameters) -# #print >> sys.stderr, "***** trying to register callback: %r" % cls_name -# class_name = "PythonCallbackImpl%i" % callback_impl_num -# sink.writeln(''' -# class %s : public ns3::CallbackImpl<%s> -# { -# public: -# PyObject *m_callback; -# %s(PyObject *callback) -# { -# Py_INCREF(callback); -# m_callback = callback; -# } -# virtual ~%s() -# { -# Py_DECREF(m_callback); -# m_callback = NULL; -# } - -# virtual bool IsEqual(ns3::Ptr other_base) const -# { -# const %s *other = dynamic_cast (ns3::PeekPointer (other_base)); -# if (other != NULL) -# return (other->m_callback == m_callback); -# else -# return false; -# } - -# ''' % (class_name, ', '.join(template_parameters), class_name, class_name, class_name, class_name)) -# sink.indent() -# callback_return = template_parameters[0] -# return_ctype = ctypeparser.parse_type(callback_return) -# if ('const' in return_ctype.remove_modifiers()): -# kwargs = {'is_const': True} -# else: -# kwargs = {} -# try: -# return_type = ReturnValue.new(str(return_ctype), **kwargs) -# except (typehandlers.TypeLookupError, typehandlers.TypeConfigurationError), ex: -# warnings.warn("***** Unable to register callback; Return value '%s' error (used in %s): %r" -# % (callback_return, cls_name, ex), -# Warning) -# continue - -# arguments = [] -# ok = True -# callback_parameters = [arg for arg in template_parameters[1:] if arg != 'ns3::empty'] -# for arg_num, arg_type in enumerate(callback_parameters): -# arg_name = 'arg%i' % (arg_num+1) - -# param_ctype = ctypeparser.parse_type(arg_type) -# if ('const' in param_ctype.remove_modifiers()): -# kwargs = {'is_const': True} -# else: -# kwargs = {} -# try: -# arguments.append(Parameter.new(str(param_ctype), arg_name, **kwargs)) -# except (typehandlers.TypeLookupError, typehandlers.TypeConfigurationError), ex: -# warnings.warn("***** Unable to register callback; parameter '%s %s' error (used in %s): %r" -# % (arg_type, arg_name, cls_name, ex), -# Warning) -# ok = False -# if not ok: -# continue - -# wrapper = CallbackImplProxyMethod(return_type, arguments) -# wrapper.generate(sink, 'operator()', decl_modifiers=[]) - -# sink.unindent() -# sink.writeln('};\n') -# sink.flush_to(out) - -# class PythonCallbackParameter(Parameter): -# "Class handlers" -# CTYPES = [cls_name] -# #print >> sys.stderr, "***** registering callback handler: %r" % ctypeparser.normalize_type_string(cls_name) -# DIRECTIONS = [Parameter.DIRECTION_IN] -# PYTHON_CALLBACK_IMPL_NAME = class_name -# TEMPLATE_ARGS = template_parameters - -# def convert_python_to_c(self, wrapper): -# "parses python args to get C++ value" -# assert isinstance(wrapper, typehandlers.ForwardWrapperBase) - -# if self.default_value is None: -# py_callback = wrapper.declarations.declare_variable('PyObject*', self.name) -# wrapper.parse_params.add_parameter('O', ['&'+py_callback], self.name) -# wrapper.before_call.write_error_check( -# '!PyCallable_Check(%s)' % py_callback, -# 'PyErr_SetString(PyExc_TypeError, "parameter \'%s\' must be callbale");' % self.name) -# callback_impl = wrapper.declarations.declare_variable( -# 'ns3::Ptr<%s>' % self.PYTHON_CALLBACK_IMPL_NAME, -# '%s_cb_impl' % self.name) -# wrapper.before_call.write_code("%s = ns3::Create<%s> (%s);" -# % (callback_impl, self.PYTHON_CALLBACK_IMPL_NAME, py_callback)) -# wrapper.call_params.append( -# 'ns3::Callback<%s> (%s)' % (', '.join(self.TEMPLATE_ARGS), callback_impl)) -# else: -# py_callback = wrapper.declarations.declare_variable('PyObject*', self.name, 'NULL') -# wrapper.parse_params.add_parameter('O', ['&'+py_callback], self.name, optional=True) -# value = wrapper.declarations.declare_variable( -# 'ns3::Callback<%s>' % ', '.join(self.TEMPLATE_ARGS), -# self.name+'_value', -# self.default_value) - -# wrapper.before_call.write_code("if (%s) {" % (py_callback,)) -# wrapper.before_call.indent() - -# wrapper.before_call.write_error_check( -# '!PyCallable_Check(%s)' % py_callback, -# 'PyErr_SetString(PyExc_TypeError, "parameter \'%s\' must be callbale");' % self.name) - -# wrapper.before_call.write_code("%s = ns3::Callback<%s> (ns3::Create<%s> (%s));" -# % (value, ', '.join(self.TEMPLATE_ARGS), -# self.PYTHON_CALLBACK_IMPL_NAME, py_callback)) - -# wrapper.before_call.unindent() -# wrapper.before_call.write_code("}") # closes: if (py_callback) { - -# wrapper.call_params.append(value) - - -# def convert_c_to_python(self, wrapper): -# raise typehandlers.NotSupportedError("Reverse wrappers for ns3::Callback<...> types " -# "(python using callbacks defined in C++) not implemented.") - - -# def write_preamble(out): -# pybindgen.write_preamble(out) -# out.writeln("#include \"ns3/everything.h\"") - - def Simulator_customizations(module): Simulator = module['ns3::Simulator'] @@ -327,76 +107,6 @@ flags=["METH_VARARGS", "METH_KEYWORDS"]) -# def Object_customizations(module): -# ## --------------------------------------------------------------------- -# ## Here we generate custom constructor code for all classes that -# ## derive from ns3::Object. The custom constructors are needed in -# ## order to support kwargs only and to translate kwargs into ns3 -# ## attributes, etc. -# ## --------------------------------------------------------------------- -# Object = module['ns3::Object'] - - -# ## add a GetTypeId method to all generatd helper classes -# def helper_class_hook(helper_class): -# decl = """ -# static ns3::TypeId GetTypeId (void) -# { -# static ns3::TypeId tid = ns3::TypeId ("%s") -# .SetParent< %s > () -# ; -# return tid; -# }""" % (helper_class.name, helper_class.class_.full_name) - -# helper_class.add_custom_method(decl) -# helper_class.add_post_generation_code( -# "NS_OBJECT_ENSURE_REGISTERED (%s);" % helper_class.name) -# Object.add_helper_class_hook(helper_class_hook) - -# def ns3_object_instance_creation_function(cpp_class, code_block, lvalue, -# parameters, construct_type_name): -# assert lvalue -# assert not lvalue.startswith('None') -# if cpp_class.cannot_be_constructed: -# raise CodeGenerationError("%s cannot be constructed (%s)" -# % cpp_class.full_name) -# if cpp_class.incomplete_type: -# raise CodeGenerationError("%s cannot be constructed (incomplete type)" -# % cpp_class.full_name) -# code_block.write_code("%s = new %s(%s);" % (lvalue, construct_type_name, parameters)) -# code_block.write_code("%s->Ref ();" % (lvalue)) - -# def ns3_object_post_instance_creation_function(cpp_class, code_block, lvalue, -# parameters, construct_type_name): -# code_block.write_code("ns3::CompleteConstruct(%s);" % (lvalue, )) - -# Object.set_instance_creation_function(ns3_object_instance_creation_function) -# Object.set_post_instance_creation_function(ns3_object_post_instance_creation_function) - - -# def Attribute_customizations(module): -# # Fix up for the "const AttributeValue &v = EmptyAttribute()" -# # case, as used extensively by helper classes. - -# # Here's why we need to do this: pybindgen.gccxmlscanner, when -# # scanning parameter default values, is only provided with the -# # value as a simple C expression string. (py)gccxml does not -# # report the type of the default value. - -# # As a workaround, here we iterate over all parameters of all -# # methods of all classes and tell pybindgen what is the type of -# # the default value for attributes. - -# for cls in module.classes: -# for meth in cls.get_all_methods(): -# for param in meth.parameters: -# if isinstance(param, cppclass.CppClassRefParameter): -# if param.cpp_class.name == 'AttributeValue' \ -# and param.default_value is not None \ -# and param.default_value_type is None: -# param.default_value_type = 'ns3::EmptyAttributeValue' - - def TypeId_customizations(module): TypeId = module['ns3::TypeId'] TypeId.add_custom_method_wrapper("LookupByNameFailSafe", "_wrap_TypeId_LookupByNameFailSafe", diff -Naur ns-3.19/src/core/bindings/modulegen__gcc_ILP32.py ns-3.20/src/core/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/core/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.563635696 -0700 +++ ns-3.20/src/core/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.891995977 -0700 @@ -78,6 +78,8 @@ module.add_class('ObjectDeleter') ## object-factory.h (module 'core'): ns3::ObjectFactory [class] module.add_class('ObjectFactory') + ## log.h (module 'core'): ns3::ParameterLogger [class] + module.add_class('ParameterLogger') ## random-variable.h (module 'core'): ns3::RandomVariable [class] module.add_class('RandomVariable') ## random-variable-stream-helper.h (module 'core'): ns3::RandomVariableStreamHelper [class] @@ -98,6 +100,8 @@ module.add_class('SystemMutex') ## system-wall-clock-ms.h (module 'core'): ns3::SystemWallClockMs [class] module.add_class('SystemWallClockMs') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -134,6 +138,8 @@ module.add_class('empty') ## int64x64-double.h (module 'core'): ns3::int64x64_t [class] module.add_class('int64x64_t') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t']) ## random-variable.h (module 'core'): ns3::ConstantVariable [class] module.add_class('ConstantVariable', parent=root_module['ns3::RandomVariable']) ## random-variable.h (module 'core'): ns3::DeterministicVariable [class] @@ -316,35 +322,35 @@ module.add_class('Vector3DChecker', parent=root_module['ns3::AttributeChecker']) ## vector.h (module 'core'): ns3::Vector3DValue [class] module.add_class('Vector3DValue', parent=root_module['ns3::AttributeValue']) - typehandlers.add_type_alias('ns3::RngSeedManager', 'ns3::SeedManager') - typehandlers.add_type_alias('ns3::RngSeedManager*', 'ns3::SeedManager*') - typehandlers.add_type_alias('ns3::RngSeedManager&', 'ns3::SeedManager&') + typehandlers.add_type_alias(u'ns3::RngSeedManager', u'ns3::SeedManager') + typehandlers.add_type_alias(u'ns3::RngSeedManager*', u'ns3::SeedManager*') + typehandlers.add_type_alias(u'ns3::RngSeedManager&', u'ns3::SeedManager&') module.add_typedef(root_module['ns3::RngSeedManager'], 'SeedManager') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue', 'ns3::ObjectVectorValue') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue*', 'ns3::ObjectVectorValue*') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue&', 'ns3::ObjectVectorValue&') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue', u'ns3::ObjectVectorValue') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue*', u'ns3::ObjectVectorValue*') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue&', u'ns3::ObjectVectorValue&') module.add_typedef(root_module['ns3::ObjectPtrContainerValue'], 'ObjectVectorValue') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *', 'ns3::LogTimePrinter') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) **', 'ns3::LogTimePrinter*') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *&', 'ns3::LogTimePrinter&') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *', 'ns3::LogNodePrinter') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) **', 'ns3::LogNodePrinter*') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *&', 'ns3::LogNodePrinter&') - typehandlers.add_type_alias('ns3::Vector3D', 'ns3::Vector') - typehandlers.add_type_alias('ns3::Vector3D*', 'ns3::Vector*') - typehandlers.add_type_alias('ns3::Vector3D&', 'ns3::Vector&') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *', u'ns3::LogTimePrinter') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) **', u'ns3::LogTimePrinter*') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *&', u'ns3::LogTimePrinter&') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *', u'ns3::LogNodePrinter') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) **', u'ns3::LogNodePrinter*') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *&', u'ns3::LogNodePrinter&') + typehandlers.add_type_alias(u'ns3::Vector3D', u'ns3::Vector') + typehandlers.add_type_alias(u'ns3::Vector3D*', u'ns3::Vector*') + typehandlers.add_type_alias(u'ns3::Vector3D&', u'ns3::Vector&') module.add_typedef(root_module['ns3::Vector3D'], 'Vector') - typehandlers.add_type_alias('ns3::Vector3DValue', 'ns3::VectorValue') - typehandlers.add_type_alias('ns3::Vector3DValue*', 'ns3::VectorValue*') - typehandlers.add_type_alias('ns3::Vector3DValue&', 'ns3::VectorValue&') + typehandlers.add_type_alias(u'ns3::Vector3DValue', u'ns3::VectorValue') + typehandlers.add_type_alias(u'ns3::Vector3DValue*', u'ns3::VectorValue*') + typehandlers.add_type_alias(u'ns3::Vector3DValue&', u'ns3::VectorValue&') module.add_typedef(root_module['ns3::Vector3DValue'], 'VectorValue') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue', 'ns3::ObjectMapValue') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue*', 'ns3::ObjectMapValue*') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue&', 'ns3::ObjectMapValue&') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue', u'ns3::ObjectMapValue') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue*', u'ns3::ObjectMapValue*') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue&', u'ns3::ObjectMapValue&') module.add_typedef(root_module['ns3::ObjectPtrContainerValue'], 'ObjectMapValue') - typehandlers.add_type_alias('ns3::Vector3DChecker', 'ns3::VectorChecker') - typehandlers.add_type_alias('ns3::Vector3DChecker*', 'ns3::VectorChecker*') - typehandlers.add_type_alias('ns3::Vector3DChecker&', 'ns3::VectorChecker&') + typehandlers.add_type_alias(u'ns3::Vector3DChecker', u'ns3::VectorChecker') + typehandlers.add_type_alias(u'ns3::Vector3DChecker*', u'ns3::VectorChecker*') + typehandlers.add_type_alias(u'ns3::Vector3DChecker&', u'ns3::VectorChecker&') module.add_typedef(root_module['ns3::Vector3DChecker'], 'VectorChecker') ## Register a nested module for the namespace CommandLineHelper @@ -392,8 +398,8 @@ ## config.h (module 'core'): ns3::Config::MatchContainer [class] module.add_class('MatchContainer') - module.add_container('std::vector< ns3::Ptr< ns3::Object > >', 'ns3::Ptr< ns3::Object >', container_type='vector') - module.add_container('std::vector< std::string >', 'std::string', container_type='vector') + module.add_container('std::vector< ns3::Ptr< ns3::Object > >', 'ns3::Ptr< ns3::Object >', container_type=u'vector') + module.add_container('std::vector< std::string >', 'std::string', container_type=u'vector') def register_types_ns3_FatalImpl(module): root_module = module.get_root() @@ -404,12 +410,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -432,7 +438,7 @@ def register_types_ns3_SystemPath(module): root_module = module.get_root() - module.add_container('std::list< std::string >', 'std::string', container_type='list') + module.add_container('std::list< std::string >', 'std::string', container_type=u'list') def register_types_ns3_internal(module): root_module = module.get_root() @@ -460,6 +466,7 @@ 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_Ns3ParameterLogger_methods(root_module, root_module['ns3::ParameterLogger']) register_Ns3RandomVariable_methods(root_module, root_module['ns3::RandomVariable']) register_Ns3RandomVariableStreamHelper_methods(root_module, root_module['ns3::RandomVariableStreamHelper']) register_Ns3RngSeedManager_methods(root_module, root_module['ns3::RngSeedManager']) @@ -470,6 +477,7 @@ register_Ns3SystemCondition_methods(root_module, root_module['ns3::SystemCondition']) register_Ns3SystemMutex_methods(root_module, root_module['ns3::SystemMutex']) register_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TriangularVariable_methods(root_module, root_module['ns3::TriangularVariable']) @@ -641,6 +649,7 @@ return def register_Ns3CommandLine_methods(root_module, cls): + cls.add_output_stream_operator() ## command-line.h (module 'core'): ns3::CommandLine::CommandLine() [constructor] cls.add_constructor([]) ## command-line.h (module 'core'): ns3::CommandLine::CommandLine(ns3::CommandLine const & cmd) [copy constructor] @@ -878,29 +887,25 @@ def register_Ns3LogComponent_methods(root_module, cls): ## log.h (module 'core'): ns3::LogComponent::LogComponent(ns3::LogComponent const & arg0) [copy constructor] cls.add_constructor([param('ns3::LogComponent const &', 'arg0')]) - ## log.h (module 'core'): ns3::LogComponent::LogComponent(std::string const & name) [constructor] - cls.add_constructor([param('std::string const &', 'name')]) - ## log.h (module 'core'): void ns3::LogComponent::Disable(ns3::LogLevel level) [member function] + ## log.h (module 'core'): ns3::LogComponent::LogComponent(std::string const & name, ns3::LogLevel const mask=::ns3::LOG_NONE) [constructor] + cls.add_constructor([param('std::string const &', 'name'), param('ns3::LogLevel const', 'mask', default_value='::ns3::LOG_NONE')]) + ## log.h (module 'core'): void ns3::LogComponent::Disable(ns3::LogLevel const level) [member function] cls.add_method('Disable', 'void', - [param('ns3::LogLevel', 'level')]) - ## log.h (module 'core'): void ns3::LogComponent::Enable(ns3::LogLevel level) [member function] + [param('ns3::LogLevel const', 'level')]) + ## log.h (module 'core'): void ns3::LogComponent::Enable(ns3::LogLevel const level) [member function] cls.add_method('Enable', 'void', - [param('ns3::LogLevel', 'level')]) - ## log.h (module 'core'): void ns3::LogComponent::EnvVarCheck(std::string const & name) [member function] - cls.add_method('EnvVarCheck', - 'void', - [param('std::string const &', 'name')]) - ## log.h (module 'core'): std::string ns3::LogComponent::GetLevelLabel(ns3::LogLevel const level) const [member function] + [param('ns3::LogLevel const', 'level')]) + ## log.h (module 'core'): static std::string ns3::LogComponent::GetLevelLabel(ns3::LogLevel const level) [member function] cls.add_method('GetLevelLabel', 'std::string', [param('ns3::LogLevel const', 'level')], - is_const=True) - ## log.h (module 'core'): bool ns3::LogComponent::IsEnabled(ns3::LogLevel level) const [member function] + is_static=True) + ## log.h (module 'core'): bool ns3::LogComponent::IsEnabled(ns3::LogLevel const level) const [member function] cls.add_method('IsEnabled', 'bool', - [param('ns3::LogLevel', 'level')], + [param('ns3::LogLevel const', 'level')], is_const=True) ## log.h (module 'core'): bool ns3::LogComponent::IsNoneEnabled() const [member function] cls.add_method('IsNoneEnabled', @@ -912,6 +917,10 @@ 'char const *', [], is_const=True) + ## log.h (module 'core'): void ns3::LogComponent::SetMask(ns3::LogLevel const level) [member function] + cls.add_method('SetMask', + 'void', + [param('ns3::LogLevel const', 'level')]) return def register_Ns3Names_methods(root_module, cls): @@ -1075,6 +1084,13 @@ [param('std::string', 'tid')]) return +def register_Ns3ParameterLogger_methods(root_module, cls): + ## log.h (module 'core'): ns3::ParameterLogger::ParameterLogger(ns3::ParameterLogger const & arg0) [copy constructor] + cls.add_constructor([param('ns3::ParameterLogger const &', 'arg0')]) + ## log.h (module 'core'): ns3::ParameterLogger::ParameterLogger(std::ostream & os) [constructor] + cls.add_constructor([param('std::ostream &', 'os')]) + return + def register_Ns3RandomVariable_methods(root_module, cls): cls.add_output_stream_operator() ## random-variable.h (module 'core'): ns3::RandomVariable::RandomVariable() [constructor] @@ -1325,6 +1341,14 @@ []) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -1709,62 +1733,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1773,6 +1753,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -1813,6 +1795,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3ConstantVariable_methods(root_module, cls): @@ -1945,7 +1929,7 @@ cls.add_method('GetObject', 'ns3::Ptr< ns3::Object >', [param('ns3::TypeId', 'tid')], - is_const=True, template_parameters=['ns3::Object'], custom_template_method_name='GetObject') + is_const=True, template_parameters=['ns3::Object'], custom_template_method_name=u'GetObject') ## object.h (module 'core'): static ns3::TypeId ns3::Object::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', @@ -2501,13 +2485,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2534,6 +2520,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', diff -Naur ns-3.19/src/core/bindings/modulegen__gcc_LP64.py ns-3.20/src/core/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/core/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.566635673 -0700 +++ ns-3.20/src/core/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.894995954 -0700 @@ -78,6 +78,8 @@ module.add_class('ObjectDeleter') ## object-factory.h (module 'core'): ns3::ObjectFactory [class] module.add_class('ObjectFactory') + ## log.h (module 'core'): ns3::ParameterLogger [class] + module.add_class('ParameterLogger') ## random-variable.h (module 'core'): ns3::RandomVariable [class] module.add_class('RandomVariable') ## random-variable-stream-helper.h (module 'core'): ns3::RandomVariableStreamHelper [class] @@ -98,6 +100,8 @@ module.add_class('SystemMutex') ## system-wall-clock-ms.h (module 'core'): ns3::SystemWallClockMs [class] module.add_class('SystemWallClockMs') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -134,6 +138,8 @@ module.add_class('empty') ## int64x64-double.h (module 'core'): ns3::int64x64_t [class] module.add_class('int64x64_t') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t']) ## random-variable.h (module 'core'): ns3::ConstantVariable [class] module.add_class('ConstantVariable', parent=root_module['ns3::RandomVariable']) ## random-variable.h (module 'core'): ns3::DeterministicVariable [class] @@ -316,35 +322,35 @@ module.add_class('Vector3DChecker', parent=root_module['ns3::AttributeChecker']) ## vector.h (module 'core'): ns3::Vector3DValue [class] module.add_class('Vector3DValue', parent=root_module['ns3::AttributeValue']) - typehandlers.add_type_alias('ns3::RngSeedManager', 'ns3::SeedManager') - typehandlers.add_type_alias('ns3::RngSeedManager*', 'ns3::SeedManager*') - typehandlers.add_type_alias('ns3::RngSeedManager&', 'ns3::SeedManager&') + typehandlers.add_type_alias(u'ns3::RngSeedManager', u'ns3::SeedManager') + typehandlers.add_type_alias(u'ns3::RngSeedManager*', u'ns3::SeedManager*') + typehandlers.add_type_alias(u'ns3::RngSeedManager&', u'ns3::SeedManager&') module.add_typedef(root_module['ns3::RngSeedManager'], 'SeedManager') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue', 'ns3::ObjectVectorValue') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue*', 'ns3::ObjectVectorValue*') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue&', 'ns3::ObjectVectorValue&') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue', u'ns3::ObjectVectorValue') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue*', u'ns3::ObjectVectorValue*') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue&', u'ns3::ObjectVectorValue&') module.add_typedef(root_module['ns3::ObjectPtrContainerValue'], 'ObjectVectorValue') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *', 'ns3::LogTimePrinter') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) **', 'ns3::LogTimePrinter*') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *&', 'ns3::LogTimePrinter&') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *', 'ns3::LogNodePrinter') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) **', 'ns3::LogNodePrinter*') - typehandlers.add_type_alias('void ( * ) ( std::ostream & ) *&', 'ns3::LogNodePrinter&') - typehandlers.add_type_alias('ns3::Vector3D', 'ns3::Vector') - typehandlers.add_type_alias('ns3::Vector3D*', 'ns3::Vector*') - typehandlers.add_type_alias('ns3::Vector3D&', 'ns3::Vector&') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *', u'ns3::LogTimePrinter') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) **', u'ns3::LogTimePrinter*') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *&', u'ns3::LogTimePrinter&') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *', u'ns3::LogNodePrinter') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) **', u'ns3::LogNodePrinter*') + typehandlers.add_type_alias(u'void ( * ) ( std::ostream & ) *&', u'ns3::LogNodePrinter&') + typehandlers.add_type_alias(u'ns3::Vector3D', u'ns3::Vector') + typehandlers.add_type_alias(u'ns3::Vector3D*', u'ns3::Vector*') + typehandlers.add_type_alias(u'ns3::Vector3D&', u'ns3::Vector&') module.add_typedef(root_module['ns3::Vector3D'], 'Vector') - typehandlers.add_type_alias('ns3::Vector3DValue', 'ns3::VectorValue') - typehandlers.add_type_alias('ns3::Vector3DValue*', 'ns3::VectorValue*') - typehandlers.add_type_alias('ns3::Vector3DValue&', 'ns3::VectorValue&') + typehandlers.add_type_alias(u'ns3::Vector3DValue', u'ns3::VectorValue') + typehandlers.add_type_alias(u'ns3::Vector3DValue*', u'ns3::VectorValue*') + typehandlers.add_type_alias(u'ns3::Vector3DValue&', u'ns3::VectorValue&') module.add_typedef(root_module['ns3::Vector3DValue'], 'VectorValue') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue', 'ns3::ObjectMapValue') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue*', 'ns3::ObjectMapValue*') - typehandlers.add_type_alias('ns3::ObjectPtrContainerValue&', 'ns3::ObjectMapValue&') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue', u'ns3::ObjectMapValue') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue*', u'ns3::ObjectMapValue*') + typehandlers.add_type_alias(u'ns3::ObjectPtrContainerValue&', u'ns3::ObjectMapValue&') module.add_typedef(root_module['ns3::ObjectPtrContainerValue'], 'ObjectMapValue') - typehandlers.add_type_alias('ns3::Vector3DChecker', 'ns3::VectorChecker') - typehandlers.add_type_alias('ns3::Vector3DChecker*', 'ns3::VectorChecker*') - typehandlers.add_type_alias('ns3::Vector3DChecker&', 'ns3::VectorChecker&') + typehandlers.add_type_alias(u'ns3::Vector3DChecker', u'ns3::VectorChecker') + typehandlers.add_type_alias(u'ns3::Vector3DChecker*', u'ns3::VectorChecker*') + typehandlers.add_type_alias(u'ns3::Vector3DChecker&', u'ns3::VectorChecker&') module.add_typedef(root_module['ns3::Vector3DChecker'], 'VectorChecker') ## Register a nested module for the namespace CommandLineHelper @@ -392,8 +398,8 @@ ## config.h (module 'core'): ns3::Config::MatchContainer [class] module.add_class('MatchContainer') - module.add_container('std::vector< ns3::Ptr< ns3::Object > >', 'ns3::Ptr< ns3::Object >', container_type='vector') - module.add_container('std::vector< std::string >', 'std::string', container_type='vector') + module.add_container('std::vector< ns3::Ptr< ns3::Object > >', 'ns3::Ptr< ns3::Object >', container_type=u'vector') + module.add_container('std::vector< std::string >', 'std::string', container_type=u'vector') def register_types_ns3_FatalImpl(module): root_module = module.get_root() @@ -404,12 +410,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -432,7 +438,7 @@ def register_types_ns3_SystemPath(module): root_module = module.get_root() - module.add_container('std::list< std::string >', 'std::string', container_type='list') + module.add_container('std::list< std::string >', 'std::string', container_type=u'list') def register_types_ns3_internal(module): root_module = module.get_root() @@ -460,6 +466,7 @@ 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_Ns3ParameterLogger_methods(root_module, root_module['ns3::ParameterLogger']) register_Ns3RandomVariable_methods(root_module, root_module['ns3::RandomVariable']) register_Ns3RandomVariableStreamHelper_methods(root_module, root_module['ns3::RandomVariableStreamHelper']) register_Ns3RngSeedManager_methods(root_module, root_module['ns3::RngSeedManager']) @@ -470,6 +477,7 @@ register_Ns3SystemCondition_methods(root_module, root_module['ns3::SystemCondition']) register_Ns3SystemMutex_methods(root_module, root_module['ns3::SystemMutex']) register_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TriangularVariable_methods(root_module, root_module['ns3::TriangularVariable']) @@ -641,6 +649,7 @@ return def register_Ns3CommandLine_methods(root_module, cls): + cls.add_output_stream_operator() ## command-line.h (module 'core'): ns3::CommandLine::CommandLine() [constructor] cls.add_constructor([]) ## command-line.h (module 'core'): ns3::CommandLine::CommandLine(ns3::CommandLine const & cmd) [copy constructor] @@ -878,29 +887,25 @@ def register_Ns3LogComponent_methods(root_module, cls): ## log.h (module 'core'): ns3::LogComponent::LogComponent(ns3::LogComponent const & arg0) [copy constructor] cls.add_constructor([param('ns3::LogComponent const &', 'arg0')]) - ## log.h (module 'core'): ns3::LogComponent::LogComponent(std::string const & name) [constructor] - cls.add_constructor([param('std::string const &', 'name')]) - ## log.h (module 'core'): void ns3::LogComponent::Disable(ns3::LogLevel level) [member function] + ## log.h (module 'core'): ns3::LogComponent::LogComponent(std::string const & name, ns3::LogLevel const mask=::ns3::LOG_NONE) [constructor] + cls.add_constructor([param('std::string const &', 'name'), param('ns3::LogLevel const', 'mask', default_value='::ns3::LOG_NONE')]) + ## log.h (module 'core'): void ns3::LogComponent::Disable(ns3::LogLevel const level) [member function] cls.add_method('Disable', 'void', - [param('ns3::LogLevel', 'level')]) - ## log.h (module 'core'): void ns3::LogComponent::Enable(ns3::LogLevel level) [member function] + [param('ns3::LogLevel const', 'level')]) + ## log.h (module 'core'): void ns3::LogComponent::Enable(ns3::LogLevel const level) [member function] cls.add_method('Enable', 'void', - [param('ns3::LogLevel', 'level')]) - ## log.h (module 'core'): void ns3::LogComponent::EnvVarCheck(std::string const & name) [member function] - cls.add_method('EnvVarCheck', - 'void', - [param('std::string const &', 'name')]) - ## log.h (module 'core'): std::string ns3::LogComponent::GetLevelLabel(ns3::LogLevel const level) const [member function] + [param('ns3::LogLevel const', 'level')]) + ## log.h (module 'core'): static std::string ns3::LogComponent::GetLevelLabel(ns3::LogLevel const level) [member function] cls.add_method('GetLevelLabel', 'std::string', [param('ns3::LogLevel const', 'level')], - is_const=True) - ## log.h (module 'core'): bool ns3::LogComponent::IsEnabled(ns3::LogLevel level) const [member function] + is_static=True) + ## log.h (module 'core'): bool ns3::LogComponent::IsEnabled(ns3::LogLevel const level) const [member function] cls.add_method('IsEnabled', 'bool', - [param('ns3::LogLevel', 'level')], + [param('ns3::LogLevel const', 'level')], is_const=True) ## log.h (module 'core'): bool ns3::LogComponent::IsNoneEnabled() const [member function] cls.add_method('IsNoneEnabled', @@ -912,6 +917,10 @@ 'char const *', [], is_const=True) + ## log.h (module 'core'): void ns3::LogComponent::SetMask(ns3::LogLevel const level) [member function] + cls.add_method('SetMask', + 'void', + [param('ns3::LogLevel const', 'level')]) return def register_Ns3Names_methods(root_module, cls): @@ -1075,6 +1084,13 @@ [param('std::string', 'tid')]) return +def register_Ns3ParameterLogger_methods(root_module, cls): + ## log.h (module 'core'): ns3::ParameterLogger::ParameterLogger(ns3::ParameterLogger const & arg0) [copy constructor] + cls.add_constructor([param('ns3::ParameterLogger const &', 'arg0')]) + ## log.h (module 'core'): ns3::ParameterLogger::ParameterLogger(std::ostream & os) [constructor] + cls.add_constructor([param('std::ostream &', 'os')]) + return + def register_Ns3RandomVariable_methods(root_module, cls): cls.add_output_stream_operator() ## random-variable.h (module 'core'): ns3::RandomVariable::RandomVariable() [constructor] @@ -1325,6 +1341,14 @@ []) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -1709,62 +1733,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -1773,6 +1753,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -1813,6 +1795,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3ConstantVariable_methods(root_module, cls): @@ -1945,7 +1929,7 @@ cls.add_method('GetObject', 'ns3::Ptr< ns3::Object >', [param('ns3::TypeId', 'tid')], - is_const=True, template_parameters=['ns3::Object'], custom_template_method_name='GetObject') + is_const=True, template_parameters=['ns3::Object'], custom_template_method_name=u'GetObject') ## object.h (module 'core'): static ns3::TypeId ns3::Object::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', @@ -2501,13 +2485,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2534,6 +2520,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', diff -Naur ns-3.19/src/core/bindings/module_helpers.cc ns-3.20/src/core/bindings/module_helpers.cc --- ns-3.19/src/core/bindings/module_helpers.cc 2014-06-17 10:34:00.559635727 -0700 +++ ns-3.20/src/core/bindings/module_helpers.cc 2014-06-17 10:33:13.887996008 -0700 @@ -2,6 +2,10 @@ #include "ns3/ref-count-base.h" #include +#if PY_VERSION_HEX >= 0x03000000 +# define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask +# define PyString_FromStringAndSize PyUnicode_FromStringAndSize +#endif namespace { diff -Naur ns-3.19/src/core/model/abort.h ns-3.20/src/core/model/abort.h --- ns-3.19/src/core/model/abort.h 2014-06-17 10:34:00.574635611 -0700 +++ ns-3.20/src/core/model/abort.h 2014-06-17 10:33:13.902995892 -0700 @@ -24,7 +24,8 @@ #include "fatal-error.h" /** - * \ingroup debugging + * \ingroup fatal + * * \brief Abnormal program termination * * \param msg message to output when this macro is hit. @@ -48,7 +49,8 @@ /** - * \ingroup debugging + * \ingroup fatal + * * \brief Abnormal program termination if cond is true. * * \param cond condition to be evaluated. @@ -76,7 +78,8 @@ } while (false) /** - * \ingroup debugging + * \ingroup fatal + * * \brief Abnormal program termination if cond is true. * * \param cond condition to be evaluated. @@ -105,7 +108,8 @@ } while (false) /** - * \ingroup debugging + * \ingroup fatal + * * \brief Abnormal program termination if cond is false. * * \param cond condition to be evaluated. @@ -118,7 +122,8 @@ NS_ABORT_IF (!(cond)) /** - * \ingroup debugging + * \ingroup fatal + * * \brief Abnormal program termination if cond is false. * * \param cond condition to be evaluated. diff -Naur ns-3.19/src/core/model/assert.h ns-3.20/src/core/model/assert.h --- ns-3.19/src/core/model/assert.h 2014-06-17 10:34:00.574635611 -0700 +++ ns-3.20/src/core/model/assert.h 2014-06-17 10:33:13.902995892 -0700 @@ -21,21 +21,11 @@ #ifndef NS_ASSERT_H #define NS_ASSERT_H -#ifdef NS3_ASSERT_ENABLE - -#include - -#include "fatal-error.h" - -/** - * \ingroup core - * \defgroup debugging Debugging - */ /** * \ingroup debugging - * \defgroup assert Assert + * \defgroup assert Assertions * - * \brief assert functions and macros + * \brief Assert functions and macros * * The assert macros are used to verify * at runtime that a certain condition is true. If it is @@ -53,13 +43,20 @@ * builds, use NS_ABORT_UNLESS and NS_ABORT_MSG_UNLESS. */ +#ifdef NS3_ASSERT_ENABLE + +#include + +#include "fatal-error.h" + /** * \ingroup assert - * \param condition condition to verify. * * At runtime, in debugging builds, if this condition is not * true, the program prints the source file, line number and * unverified condition and halts by calling std::terminate + * + * \param condition condition to verify. */ #define NS_ASSERT(condition) \ do \ @@ -76,12 +73,13 @@ /** * \ingroup assert - * \param condition condition to verify. - * \param message message to output * * At runtime, in debugging builds, if this condition is not * true, the program prints the message to output and * halts by calling std::terminate. + * + * \param condition condition to verify. + * \param message message to output */ #define NS_ASSERT_MSG(condition, message) \ do \ diff -Naur ns-3.19/src/core/model/attribute-accessor-helper.h ns-3.20/src/core/model/attribute-accessor-helper.h --- ns-3.19/src/core/model/attribute-accessor-helper.h 2014-06-17 10:34:00.574635611 -0700 +++ ns-3.20/src/core/model/attribute-accessor-helper.h 2014-06-17 10:33:13.902995892 -0700 @@ -28,6 +28,7 @@ * \ingroup AttributeHelper */ template +inline Ptr MakeAccessorHelper (T1 a1); @@ -35,6 +36,7 @@ * \ingroup AttributeHelper */ template +inline Ptr MakeAccessorHelper (T1 a1, T2 a2); @@ -94,6 +96,7 @@ }; template +inline Ptr DoMakeAccessorHelperOne (U T::*memberVariable) { @@ -132,6 +135,7 @@ } template +inline Ptr DoMakeAccessorHelperOne (U (T::*getter)(void) const) { @@ -163,6 +167,7 @@ template +inline Ptr DoMakeAccessorHelperOne (void (T::*setter)(U)) { @@ -199,6 +204,7 @@ } template +inline Ptr DoMakeAccessorHelperTwo (void (T::*setter)(U), V (T::*getter)(void) const) @@ -240,6 +246,7 @@ } template +inline Ptr DoMakeAccessorHelperTwo (V (T::*getter)(void) const, void (T::*setter)(U)) @@ -248,6 +255,7 @@ } template +inline Ptr DoMakeAccessorHelperTwo (bool (T::*setter)(U), V (T::*getter)(void) const) @@ -289,6 +297,7 @@ } template +inline Ptr DoMakeAccessorHelperTwo (bool (T::*getter)(void) const, void (T::*setter)(U)) @@ -297,6 +306,7 @@ } template +inline Ptr MakeAccessorHelper (T1 a1) { @@ -304,6 +314,7 @@ } template +inline Ptr MakeAccessorHelper (T1 a1, T2 a2) { diff -Naur ns-3.19/src/core/model/attribute-construction-list.cc ns-3.20/src/core/model/attribute-construction-list.cc --- ns-3.19/src/core/model/attribute-construction-list.cc 2014-06-17 10:34:00.575635604 -0700 +++ ns-3.20/src/core/model/attribute-construction-list.cc 2014-06-17 10:33:13.903995884 -0700 @@ -22,8 +22,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE("AttributeConstructionList") - ; +NS_LOG_COMPONENT_DEFINE("AttributeConstructionList"); AttributeConstructionList::AttributeConstructionList () { diff -Naur ns-3.19/src/core/model/attribute-helper.h ns-3.20/src/core/model/attribute-helper.h --- ns-3.19/src/core/model/attribute-helper.h 2014-06-17 10:34:00.575635604 -0700 +++ ns-3.20/src/core/model/attribute-helper.h 2014-06-17 10:33:13.903995884 -0700 @@ -37,10 +37,10 @@ * the user class can then effectively be made an attribute. * * There are two kinds of helper macros: - * 1) The simple macros. - * - ATTRIBUTE_HELPER_HEADER(type) - * - ATTRIBUTE_HELPER_CPP - * 2) The more complex macros. + * -# The simple macros. + * - ATTRIBUTE_HELPER_HEADER(type) + * - ATTRIBUTE_HELPER_CPP(type) + * -# The more complex macros. * * The simple macros are implemented in terms of the complex * macros and should generally be preferred over the complex macros. @@ -98,125 +98,180 @@ /** * \ingroup attributehelper + * + * Define the attribute accessor functions \c MakeTypeAccessor + * for class \pname{type}. + * * \param type the name of the class * * This macro defines and generates the code for the implementation - * of the \c MakeAccessor template functions. This macro is typically + * of the \c MakeTypeAccessor template functions. This macro is typically * invoked in a class header to allow users of this class to view and * use the template functions defined here. This macro is implemented * through the helper templates functions ns3::MakeAccessorHelper<>. */ #define ATTRIBUTE_ACCESSOR_DEFINE(type) \ template \ - Ptr Make ## type ## Accessor (T1 a1) \ + Ptr Make ## type ## Accessor (T1 a1) \ { \ - return MakeAccessorHelper (a1); \ + return MakeAccessorHelper (a1); \ } \ template \ - Ptr Make ## type ## Accessor (T1 a1, T2 a2) \ + Ptr Make ## type ## Accessor (T1 a1, T2 a2) \ { \ - return MakeAccessorHelper (a1, a2); \ + return MakeAccessorHelper (a1, a2); \ } /** * \ingroup attributehelper - * \internal + * + * Declare the attribute value class \pname{name}Value + * for underlying class \pname{type}. + * + * \param type The underlying type name + * \param name The token to use in defining the accessor name. + * + * This macro declares the class \c TypeValue associated with class \c type. + * This macro is typically invoked in the class header file. + * + * This can be used directly for things like plain old data, + * such as \c std::string, to create the attribute value class + * StringValue. */ #define ATTRIBUTE_VALUE_DEFINE_WITH_NAME(type,name) \ - class name ## Value : public AttributeValue \ + class name ## Value : public AttributeValue \ { \ -public: \ - name ## Value (); \ - name ## Value (const type &value); \ + public: \ + name ## Value (); \ + name ## Value (const type &value); \ void Set (const type &value); \ type Get (void) const; \ template \ - bool GetAccessor (T &value) const { \ + bool GetAccessor (T &value) const { \ value = T (m_value); \ return true; \ } \ virtual Ptr Copy (void) const; \ - virtual std::string SerializeToString (Ptr checker) const; \ - virtual bool DeserializeFromString (std::string value, Ptr checker); \ -private: \ + virtual std::string \ + SerializeToString (Ptr checker) const; \ + virtual bool \ + DeserializeFromString (std::string value, \ + Ptr checker); \ + private: \ type m_value; \ }; /** * \ingroup attributehelper - * \param type the name of the class. * - * This macro defines the class \c typeValue associated to class \c type. + * Declare the attribute value class \pname{Name}Value + * for the class \pname{Name} + * + * \param Name the name of the class. + * + * This macro declares the class \c NameValue associated to class \c Name. * This macro is typically invoked in the class header file. */ -#define ATTRIBUTE_VALUE_DEFINE(type) \ - ATTRIBUTE_VALUE_DEFINE_WITH_NAME (type,type) +#define ATTRIBUTE_VALUE_DEFINE(Name) \ + ATTRIBUTE_VALUE_DEFINE_WITH_NAME (Name,Name) /** * \ingroup attributehelper + * + * Define the conversion operators class \pname{type} and + * Attribute instances. + * * \param type the name of the class * * This macro defines the conversion operators for class \c type to and * from instances of type Attribute. * Typically invoked in the class header file. + * + * \internal + * This appears to be unused. */ #define ATTRIBUTE_CONVERTER_DEFINE(type) /** * \ingroup attributehelper + * + * Declare the AttributeChecker class \pname{type}Checker + * and the \c MakeTypeChecker function for class \pname{type}. + * * \param type the name of the class * - * This macro defines the \c typeChecker class and the associated - * \c MakeChecker function. - * Typically invoked in the class header file.. - */ -#define ATTRIBUTE_CHECKER_DEFINE(type) \ - class type ## Checker : public AttributeChecker {}; \ - Ptr Make ## type ## Checker (void); \ + * This macro declares the \pname{type}Checker class and the associated + * \c MakeTypeChecker function. + * + * (Note that the \pname{type}Checker class needs no implementation + * since it just inherits all its implementation from AttributeChecker.) + * + * Typically invoked in the class header file. + */ +#define ATTRIBUTE_CHECKER_DEFINE(type) \ + class type ## Checker : public AttributeChecker {}; \ + Ptr Make ## type ## Checker (void) /** * \ingroup attributehelper - * \internal + * + * Define the class methods belonging to + * the attribute value class \pname{name}Value + * of the underlying class \pname{type}. + * + * \param type The underlying type name + * \param name The token to use in defining the accessor name. + * + * This macro implements the \pname{type}Value class methods + * (including the \pname{type}Value::SerializeToString + * and \pname{type}Value::DeserializeFromString methods). + * + * Typically invoked in the source file. */ #define ATTRIBUTE_VALUE_IMPLEMENT_WITH_NAME(type,name) \ - name ## Value::name ## Value () \ + name ## Value::name ## Value () \ : m_value () {} \ - name ## Value::name ## Value (const type &value) \ - : m_value (value) {} \ - void name ## Value::Set (const type &v) { \ + name ## Value::name ## Value (const type &value) \ + : m_value (value) {} \ + void name ## Value::Set (const type &v) { \ m_value = v; \ } \ - type name ## Value::Get (void) const { \ + type name ## Value::Get (void) const { \ return m_value; \ } \ Ptr \ - name ## Value::Copy (void) const { \ - return ns3::Create (*this); \ + name ## Value::Copy (void) const { \ + return ns3::Create (*this); \ + } \ + std::string name ## Value::SerializeToString \ + (Ptr checker) const { \ + std::ostringstream oss; \ + oss << m_value; \ + return oss.str (); \ } \ - std::string \ - name ## Value::SerializeToString (Ptr checker) const { \ - std::ostringstream oss; \ - oss << m_value; \ - return oss.str (); \ - } \ - bool \ - name ## Value::DeserializeFromString (std::string value, Ptr checker) { \ - std::istringstream iss; \ - iss.str (value); \ - iss >> m_value; \ - return !iss.bad () && !iss.fail (); \ + bool name ## Value::DeserializeFromString \ + (std::string value, Ptr checker) { \ + std::istringstream iss; \ + iss.str (value); \ + iss >> m_value; \ + return !iss.bad () && !iss.fail (); \ } /** * \ingroup attributehelper + * + * Define the class methods belonging to + * attribute value class \pname{type}Value for class \pname{type}. + * * \param type the name of the class. * - * This macro implements the \c typeValue class (including the - * \c typeValue::SerializeToString and \c typeValue::DeserializeFromString - * methods). + * This macro implements the \pname{type}Value class methods + * (including the \pname{type}Value::SerializeToString + * and \pname{type}Value::DeserializeFromString methods). + * * Typically invoked in the source file. */ #define ATTRIBUTE_VALUE_IMPLEMENT(type) \ @@ -225,31 +280,58 @@ /** * \ingroup attributehelper + * + * Define the \c MakeTypeChecker function for class \pname{type}. + * * \param type the name of the class * - * This macro implements the \c MakeChecker function. + * This macro implements the \c MakeTypeChecker function. + * * Typically invoked in the source file.. */ #define ATTRIBUTE_CHECKER_IMPLEMENT(type) \ - Ptr Make ## type ## Checker (void) \ - { \ - return MakeSimpleAttributeChecker (# type "Value", # type); \ + Ptr Make ## type ## Checker (void) { \ + return MakeSimpleAttributeChecker \ + (# type "Value", # type); \ } \ /** * \ingroup attributehelper - * \internal + * + * Define the \c MakeTypeChecker function for class \pname{type}. + * + * \param type the name of the class. + * \param name the string name of the underlying type. + * + * This macro implements the \c MakeTypeChecker function + * for class \pname{type}. + * + * Typically invoked in the source file.. */ -#define ATTRIBUTE_CHECKER_IMPLEMENT_WITH_NAME(type,name) \ - Ptr Make ## type ## Checker (void) \ - { \ - return MakeSimpleAttributeChecker (# type "Value", name); \ +#define ATTRIBUTE_CHECKER_IMPLEMENT_WITH_NAME(type,name) \ + Ptr Make ## type ## Checker (void) { \ + return MakeSimpleAttributeChecker \ + (# type "Value", name); \ } \ /** * \ingroup attributehelper + * + * Declare the attribute value, accessor and checkers for class \pname{type} + * * \param type the name of the class * + * This macro declares: + * + * - The attribute value class \pname{type}Value, + * + * - The attribute accessor functions \c MakeTypeAccessor, + * + * - The AttributeChecker class \pname{type}Checker + * and the \c MakeTypeChecker function, + * + * for class \pname{type}. + * * This macro should be invoked outside of the class * declaration in its public header. */ @@ -260,8 +342,19 @@ /** * \ingroup attributehelper + * + * Define the attribute value, accessor and checkers for class \pname{type} + * * \param type the name of the class * + * This macro implements + * + * - The \pname{type}Value class methods, + * + * - The \c MakeTypeChecker function, + * + * for class \pname{type}. + * * This macro should be invoked from the class implementation file. */ #define ATTRIBUTE_HELPER_CPP(type) \ diff -Naur ns-3.19/src/core/model/breakpoint.h ns-3.20/src/core/model/breakpoint.h --- ns-3.19/src/core/model/breakpoint.h 2014-06-17 10:34:00.577635588 -0700 +++ ns-3.20/src/core/model/breakpoint.h 2014-06-17 10:33:13.905995869 -0700 @@ -36,10 +36,17 @@ /** * \ingroup debugging + * \defgroup breakpoint Breakpoints + * + * \brief Trigger a debugger breakpoint. + */ + +/** + * \ingroup breakpoint * * Inserts a breakpoint instruction (or equivalent system call) into - * the code for selected machines. When an NS_ASSERT cannot verify its condition, - * this macro is used. Falls back to calling + * the code for selected machines. When an NS_ASSERT cannot verify + * its condition, this macro is used. Falls back to calling * AssertBreakpoint() for architectures where breakpoint assembly * instructions are not supported. */ @@ -57,7 +64,7 @@ #endif /** - * \ingroup debugging + * \ingroup breakpoint * * \brief fallback breakpoint function * diff -Naur ns-3.19/src/core/model/cairo-wideint.c ns-3.20/src/core/model/cairo-wideint.c --- ns-3.19/src/core/model/cairo-wideint.c 2014-06-17 10:34:00.578635580 -0700 +++ ns-3.20/src/core/model/cairo-wideint.c 2014-06-17 10:33:13.906995861 -0700 @@ -32,6 +32,8 @@ #if HAVE_UINT64_T +const char * cairo_impl64 = "uint64_t"; + #define _cairo_uint32s_to_uint64(h,l) ((uint64_t) (h) << 32 | (l)) cairo_uquorem64_t @@ -46,6 +48,8 @@ #else +const char * cairo_impl64 = "uint32_t"; + cairo_uint64_t _cairo_uint32_to_uint64 (uint32_t i) { @@ -312,6 +316,8 @@ #if HAVE_UINT128_T +const char * cairo_impl128 = "uint128_t"; + cairo_uquorem128_t _cairo_uint128_divrem (cairo_uint128_t num, cairo_uint128_t den) { @@ -324,6 +330,8 @@ #else +const char * cairo_impl128 = "cairo_uint64_t"; + cairo_uint128_t _cairo_uint32_to_uint128 (uint32_t i) { @@ -610,16 +618,16 @@ return qr; } -cairo_int128_t -_cairo_int128_negate (cairo_int128_t a) +cairo_uint128_t +_cairo_uint128_negate (cairo_uint128_t a) { a.lo = _cairo_uint64_not (a.lo); a.hi = _cairo_uint64_not (a.hi); return _cairo_uint128_add (a, _cairo_uint32_to_uint128 (1)); } -cairo_int128_t -_cairo_int128_not (cairo_int128_t a) +cairo_uint128_t +_cairo_uint128_not (cairo_uint128_t a) { a.lo = _cairo_uint64_not (a.lo); a.hi = _cairo_uint64_not (a.hi); @@ -659,7 +667,7 @@ * dividend and 64 bit divisor. If the quotient doesn't fit into 32 * bits then the returned remainder is equal to the divisor, and the * quotient is the largest representable 64 bit integer. It is an - * error to call this function with the high 32 bits of @num being + * error to call this function with the high 32 bits of `num' being * non-zero. */ cairo_uquorem64_t _cairo_uint_96by64_32x64_divrem (cairo_uint128_t num, diff -Naur ns-3.19/src/core/model/cairo-wideint-private.h ns-3.20/src/core/model/cairo-wideint-private.h --- ns-3.19/src/core/model/cairo-wideint-private.h 2014-06-17 10:34:00.578635580 -0700 +++ ns-3.20/src/core/model/cairo-wideint-private.h 2014-06-17 10:33:13.906995861 -0700 @@ -32,9 +32,14 @@ #ifndef CAIRO_WIDEINT_H #define CAIRO_WIDEINT_H +// Adapt to ns-3 environment #include "ns3/core-config.h" #define cairo_private #define HAVE_UINT64_T 1 +// Implementation tags added below and in cairo-wideint.c: +// extern const char * cairo_impl64; +// extern const char * cairo_impl128; + /*for compatibility with MacOS and Cygwin*/ #ifndef HAVE_STDINT_H @@ -90,6 +95,8 @@ #if !HAVE_UINT64_T +extern const char * cairo_impl64; + typedef struct _cairo_uint64 { uint32_t lo, hi; } cairo_uint64_t, cairo_int64_t; @@ -129,6 +136,8 @@ #else +extern const char * cairo_impl64; + typedef uint64_t cairo_uint64_t; typedef int64_t cairo_int64_t; @@ -209,6 +218,8 @@ #if !HAVE_UINT128_T +extern const char * cairo_impl128; + typedef struct cairo_uint128 { cairo_uint64_t lo, hi; } cairo_uint128_t, cairo_int128_t; @@ -252,6 +263,8 @@ #else /* !HAVE_UINT128_T */ +extern const char * cairo_impl128; + typedef uint128_t cairo_uint128_t; typedef int128_t cairo_int128_t; diff -Naur ns-3.19/src/core/model/calendar-scheduler.cc ns-3.20/src/core/model/calendar-scheduler.cc --- ns-3.19/src/core/model/calendar-scheduler.cc 2014-06-17 10:34:00.579635573 -0700 +++ ns-3.20/src/core/model/calendar-scheduler.cc 2014-06-17 10:33:13.907995853 -0700 @@ -28,11 +28,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("CalendarScheduler") - ; +NS_LOG_COMPONENT_DEFINE ("CalendarScheduler"); -NS_OBJECT_ENSURE_REGISTERED (CalendarScheduler) - ; +NS_OBJECT_ENSURE_REGISTERED (CalendarScheduler); TypeId CalendarScheduler::GetTypeId (void) diff -Naur ns-3.19/src/core/model/callback.h ns-3.20/src/core/model/callback.h --- ns-3.19/src/core/model/callback.h 2014-06-17 10:34:00.580635565 -0700 +++ ns-3.20/src/core/model/callback.h 2014-06-17 10:33:13.908995846 -0700 @@ -35,6 +35,10 @@ /** * \ingroup core * \defgroup callback Callbacks + * \brief Wrap functions, objects, and arguments into self contained callbacks. + * + * Wrapped callbacks are at the heart of scheduling events in the + * simulator. */ /** * \ingroup callback @@ -68,7 +72,7 @@ /** * \ingroup callback * \defgroup callbackimpl Callback Implementation - * CallbackImpl classes + * Callback implementation classes */ /** * \ingroup callbackimpl @@ -1658,12 +1662,14 @@ class CallbackValue : public AttributeValue { public: + /** Constructor */ CallbackValue (); /** * Copy constructor * \param base Callback to copy */ - CallbackValue (const CallbackBase &base); + CallbackValue (const CallbackBase &base); + /** Destructor */ virtual ~CallbackValue (); /** \param base the Callbackbase to use */ void Set (CallbackBase base); @@ -1695,10 +1701,8 @@ CallbackBase m_value; //!< the CallbackBase }; -/** Attribute helpers @{ */ ATTRIBUTE_ACCESSOR_DEFINE (Callback); ATTRIBUTE_CHECKER_DEFINE (Callback); -/**@}*/ } // namespace ns3 diff -Naur ns-3.19/src/core/model/command-line.cc ns-3.20/src/core/model/command-line.cc --- ns-3.19/src/core/model/command-line.cc 2014-06-17 10:34:00.581635557 -0700 +++ ns-3.20/src/core/model/command-line.cc 2014-06-17 10:33:13.909995838 -0700 @@ -457,4 +457,11 @@ } } +std::ostream & +operator << (std::ostream & os, const CommandLine & cmd) +{ + cmd.PrintHelp (os); + return os; +} + } // namespace ns3 diff -Naur ns-3.19/src/core/model/command-line.h ns-3.20/src/core/model/command-line.h --- ns-3.19/src/core/model/command-line.h 2014-06-17 10:34:00.581635557 -0700 +++ ns-3.20/src/core/model/command-line.h 2014-06-17 10:33:13.910995830 -0700 @@ -91,7 +91,7 @@ * --SchedulerType=HeapScheduler * \endcode * - * A simple example is in \c src/core/example/command-line-example.cc + * A simple example is in `src/core/example/ command-line-example.cc` * The heart of that example is this code: * * \code @@ -110,7 +110,7 @@ * cmd.Parse (argc, argv); * \endcode * after which it prints the values of each variable. (The \c SetCbArg function - * is not shown.) + * is not shown here; see `src/core/example/ command-line-example.cc`) * * Here is the output from a few runs of that program: * @@ -148,6 +148,31 @@ * --PrintAttributes=[typeid]: Print all attributes of typeid. * --PrintHelp: Print this help message. * \endcode + * + * Having parsed the arguments, some programs will need to perform + * some additional validation of the received values. A common issue at this + * point is to discover that the supplied arguments are incomplete or + * incompatible. Suggested best practice is to supply an error message + * and the complete usage message. For example, + * + * \code + * int value1; + * int value2; + * + * CommandLine cmd; + * cmd.Usage ("..."); + * cmd.AddValue ("value1", "first value", value1); + * cmd.AddValue ("value2", "second value", value1); + * + * cmd.Parse (argc, argv); + * + * if (value1 * value2 < 0) + * { + * std::cerr << "value1 and value2 must have the same sign!" << std::endl; + * std::cerr << cmd; + * exit (-1); + * } + * \endcode */ class CommandLine { @@ -328,12 +353,14 @@ /** * Handler for \c \-\-PrintAttributes: print the attributes for a given type. * + * \param os the output stream. * \param type the TypeId whose Attributes should be displayed */ void PrintAttributes (std::ostream &os, const std::string &type) const; /** * Handler for \c \-\-PrintGroup: print all types belonging to a given group. * + * \param os the output stream. * \param group the name of the TypeId group to display */ void PrintGroup (std::ostream &os, const std::string &group) const; @@ -463,6 +490,23 @@ return !iss.bad () && !iss.fail (); } +/** + * Overloaded operator << to print program usage + * (shortcut for CommandLine::PrintHelper) + * + * \see CommandLine::PrintHelper + * + * Example usage: + * \code + * CommandLine cmd; + * cmd.Parse (argc, argv); + * ... + * + * std::cerr << cmd; + * \endcode + */ +std::ostream & operator << (std::ostream & os, const CommandLine & cmd); + } // namespace ns3 #endif /* COMMAND_LINE_H */ diff -Naur ns-3.19/src/core/model/default-simulator-impl.cc ns-3.20/src/core/model/default-simulator-impl.cc --- ns-3.19/src/core/model/default-simulator-impl.cc 2014-06-17 10:34:00.584635534 -0700 +++ ns-3.20/src/core/model/default-simulator-impl.cc 2014-06-17 10:33:13.912995815 -0700 @@ -38,8 +38,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (DefaultSimulatorImpl) - ; +NS_OBJECT_ENSURE_REGISTERED (DefaultSimulatorImpl); TypeId DefaultSimulatorImpl::GetTypeId (void) diff -Naur ns-3.19/src/core/model/fatal-error.h ns-3.20/src/core/model/fatal-error.h --- ns-3.19/src/core/model/fatal-error.h 2014-06-17 10:34:00.587635511 -0700 +++ ns-3.20/src/core/model/fatal-error.h 2014-06-17 10:33:13.915995792 -0700 @@ -28,7 +28,29 @@ #include "fatal-impl.h" /** - * \ingroup debugging + * \ingroup core + * \defgroup fatal Fatal Error Handlers + * + * \brief Functions to help clean up when a fatal error + * is encountered. + * + * The functions in this group are used to perform + * limited clean up, like flushing active streams, when + * fatal errors are encountered (through assertion fail, + * calls to NS_ABORT_* or calls to NS_FATAL_ERROR). + * + * Currently, other than flushing active ostreams, these + * functions does not interfere with outside memory. There + * is still a residual risk that invalid ostream + * pointers may be present, and may corrupt the memory + * on the attempt to execute the flush() function. + */ + + +/** + * \ingroup fatal + * \private + * * \brief fatal error handling * * When this macro is hit at runtime, details of filename @@ -52,7 +74,8 @@ while (false) /** - * \ingroup debugging + * \ingroup fatal + * * \brief fatal error handling * * \param msg message to output when this macro is hit. diff -Naur ns-3.19/src/core/model/fatal-impl.h ns-3.20/src/core/model/fatal-impl.h --- ns-3.19/src/core/model/fatal-impl.h 2014-06-17 10:34:00.588635503 -0700 +++ ns-3.20/src/core/model/fatal-impl.h 2014-06-17 10:33:13.916995784 -0700 @@ -23,30 +23,11 @@ #include -/** - * \ingroup debugging - * \defgroup fatalHandler Fatal Error Handler - * - * \brief Functions to help clean up when fatal error - * is encountered. - * - * The functions in this group are used to perform - * limited clean up, like flushing active streams, when - * fatal error are encountered (through assertion fail, - * calls to NS_ABORT_* and calls to NS_FATAL_ERROR. - * - * Currently, other than flushing active ostreams, these - * functions does not interfere with outside memory. There - * is still a residual risk that may be invalid ostream - * pointers may be present, and may corrupt the memory - * on the attempt to execute the flush() function. - */ - namespace ns3 { namespace FatalImpl { /** - * \ingroup fatalHandler + * \ingroup fatal * \param stream The stream to be flushed on abnormal exit. * * \brief Register a stream to be flushed on abnormal exit. @@ -60,7 +41,7 @@ void RegisterStream (std::ostream* stream); /** - * \ingroup fatalHandler + * \ingroup fatal * \param stream The stream to be unregistered. * * \brief Unregister a stream for flushing on abnormal exit. @@ -74,7 +55,7 @@ void UnregisterStream (std::ostream* stream); /** - * \ingroup fatalHandler + * \ingroup fatal * * \brief Flush all currently registered streams. * diff -Naur ns-3.19/src/core/model/global-value.cc ns-3.20/src/core/model/global-value.cc --- ns-3.19/src/core/model/global-value.cc 2014-06-17 10:34:00.588635503 -0700 +++ ns-3.20/src/core/model/global-value.cc 2014-06-17 10:33:13.917995777 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("GlobalValue") - ; +NS_LOG_COMPONENT_DEFINE ("GlobalValue"); GlobalValue::GlobalValue (std::string name, std::string help, const AttributeValue &initialValue, diff -Naur ns-3.19/src/core/model/global-value.h ns-3.20/src/core/model/global-value.h --- ns-3.19/src/core/model/global-value.h 2014-06-17 10:34:00.589635496 -0700 +++ ns-3.20/src/core/model/global-value.h 2014-06-17 10:33:13.917995777 -0700 @@ -25,6 +25,7 @@ #include "ptr.h" #include "attribute.h" +class GlobalValueTestCase; namespace ns3 { @@ -141,7 +142,7 @@ private: - friend class GlobalValueTestCase; + friend class ::GlobalValueTestCase; static Vector *GetVector (void); void InitializeFromEnv (void); diff -Naur ns-3.19/src/core/model/hash.cc ns-3.20/src/core/model/hash.cc --- ns-3.19/src/core/model/hash.cc 2014-06-17 10:34:00.592635472 -0700 +++ ns-3.20/src/core/model/hash.cc 2014-06-17 10:33:13.920995753 -0700 @@ -24,8 +24,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Hash") - ; +NS_LOG_COMPONENT_DEFINE ("Hash"); Hasher::Hasher () { diff -Naur ns-3.19/src/core/model/hash-fnv.cc ns-3.20/src/core/model/hash-fnv.cc --- ns-3.19/src/core/model/hash-fnv.cc 2014-06-17 10:34:00.589635496 -0700 +++ ns-3.20/src/core/model/hash-fnv.cc 2014-06-17 10:33:13.918995769 -0700 @@ -38,8 +38,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Hash-Fnv") - ; +NS_LOG_COMPONENT_DEFINE ("Hash-Fnv"); namespace Hash { diff -Naur ns-3.19/src/core/model/hash-function.cc ns-3.20/src/core/model/hash-function.cc --- ns-3.19/src/core/model/hash-function.cc 2014-06-17 10:34:00.590635488 -0700 +++ ns-3.20/src/core/model/hash-function.cc 2014-06-17 10:33:13.918995769 -0700 @@ -24,8 +24,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("HashFunction") - ; +NS_LOG_COMPONENT_DEFINE ("HashFunction"); namespace Hash { diff -Naur ns-3.19/src/core/model/hash.h ns-3.20/src/core/model/hash.h --- ns-3.19/src/core/model/hash.h 2014-06-17 10:34:00.592635472 -0700 +++ ns-3.20/src/core/model/hash.h 2014-06-17 10:33:13.921995745 -0700 @@ -35,6 +35,8 @@ /** * \ingroup core * \defgroup hash Hash Functions + * + * \brief Generic Hash function interface */ /** * \ingroup hash @@ -70,7 +72,7 @@ * offer \c unsigned. * * Longer hashes require returning a byte buffer of some sort, - * but our \ref buffer class seems a bit overkill for this case. + * but our \ref Buffer class seems a bit overkill for this case. * */ class Hasher diff -Naur ns-3.19/src/core/model/hash-murmur3.cc ns-3.20/src/core/model/hash-murmur3.cc --- ns-3.19/src/core/model/hash-murmur3.cc 2014-06-17 10:34:00.591635480 -0700 +++ ns-3.20/src/core/model/hash-murmur3.cc 2014-06-17 10:33:13.919995761 -0700 @@ -36,8 +36,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Hash-Murmur3") - ; +NS_LOG_COMPONENT_DEFINE ("Hash-Murmur3"); namespace Hash { diff -Naur ns-3.19/src/core/model/heap-scheduler.cc ns-3.20/src/core/model/heap-scheduler.cc --- ns-3.19/src/core/model/heap-scheduler.cc 2014-06-17 10:34:00.592635472 -0700 +++ ns-3.20/src/core/model/heap-scheduler.cc 2014-06-17 10:33:13.921995745 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (HeapScheduler) - ; +NS_OBJECT_ENSURE_REGISTERED (HeapScheduler); TypeId HeapScheduler::GetTypeId (void) diff -Naur ns-3.19/src/core/model/int64x64-128.cc ns-3.20/src/core/model/int64x64-128.cc --- ns-3.19/src/core/model/int64x64-128.cc 2014-06-17 10:34:00.593635465 -0700 +++ ns-3.20/src/core/model/int64x64-128.cc 2014-06-17 10:33:13.922995738 -0700 @@ -11,40 +11,40 @@ namespace ns3 { -#define OUTPUT_SIGN(sa,sb,ua,ub) \ - ({ bool negA, negB; \ - negA = sa < 0; \ - negB = sb < 0; \ - ua = negA ? -sa : sa; \ - ub = negB ? -sb : sb; \ - (negA && !negB) || (!negA && negB); }) - - -#define MASK_LO ((((int128_t)1)<<64)-1) -#define MASK_HI (~MASK_LO) +static inline +bool +output_sign (const int128_t sa, + const int128_t sb, + uint128_t & ua, + uint128_t & ub) +{ + bool negA = sa < 0; + bool negB = sb < 0; + ua = negA ? -sa : sa; + ub = negB ? -sb : sb; + return (negA && !negB) || (!negA && negB); +} void -int64x64_t::Mul (int64x64_t const &o) +int64x64_t::Mul (const int64x64_t & o) { - bool negResult; uint128_t a, b; - negResult = OUTPUT_SIGN (_v, o._v, a, b); - int128_t result = Umul (a, b); - // add the sign to the result - result = negResult ? -result : result; - _v = result; + bool negative = output_sign (_v, o._v, a, b); + uint128_t result = Umul (a, b); + _v = negative ? -result : result; } uint128_t -int64x64_t::Umul (uint128_t a, uint128_t b) +int64x64_t::Umul (const uint128_t a, const uint128_t b) { - uint128_t aL = a & MASK_LO; - uint128_t bL = b & MASK_LO; - uint128_t aH = (a >> 64) & MASK_LO; - uint128_t bH = (b >> 64) & MASK_LO; + uint128_t aL = a & HP_MASK_LO; + uint128_t bL = b & HP_MASK_LO; + uint128_t aH = (a >> 64) & HP_MASK_LO; + uint128_t bH = (b >> 64) & HP_MASK_LO; uint128_t result; - uint128_t hiPart,loPart,midPart; + uint128_t hiPart, loPart, midPart; + uint128_t res1, res2; // Multiplying (a.h 2^64 + a.l) x (b.h 2^64 + b.l) = // 2^128 a.h b.h + 2^64*(a.h b.l+b.h a.l) + a.l b.l @@ -53,53 +53,107 @@ loPart = aL * bL; // compute the middle part 2^64*(a.h b.l+b.h a.l) midPart = aL * bH + aH * bL; - // truncate the low part - result = (loPart >> 64) + (midPart & MASK_LO); // compute the high part 2^128 a.h b.h hiPart = aH * bH; - // truncate the high part and only use the low part - result |= ((hiPart & MASK_LO) << 64) + (midPart & MASK_HI); // if the high part is not zero, put a warning - NS_ABORT_MSG_IF ((hiPart & MASK_HI) != 0, + NS_ABORT_MSG_IF ((hiPart & HP_MASK_HI) != 0, "High precision 128 bits multiplication error: multiplication overflow."); + + // Adding 64-bit terms to get 128-bit results, with carries + res1 = loPart >> 64; + res2 = midPart & HP_MASK_LO; + result = res1 + res2; + + res1 = midPart >> 64; + res2 = hiPart & HP_MASK_LO; + res1 += res2; + res1 <<= 64; + + result += res1; + return result; } + void -int64x64_t::Div (int64x64_t const &o) +int64x64_t::Div (const int64x64_t & o) { - bool negResult; uint128_t a, b; - negResult = OUTPUT_SIGN (_v, o._v, a, b); - int128_t result = Divu (a, b); - result = negResult ? -result : result; - _v = result; + bool negative = output_sign (_v, o._v, a, b); + int128_t result = Udiv (a, b); + _v = negative ? -result : result; } uint128_t -int64x64_t::Divu (uint128_t a, uint128_t b) +int64x64_t::Udiv (const uint128_t a, const uint128_t b) { - uint128_t quo = a / b; - uint128_t rem = (a % b); - uint128_t result = quo << 64; + + uint128_t rem = a; + uint128_t den = b; + uint128_t quo = rem / den; + rem = rem % den; + uint128_t result = quo; + // Now, manage the remainder - uint128_t tmp = rem >> 64; - uint128_t div; - if (tmp == 0) + const uint64_t DIGITS = 64; // Number of fraction digits (bits) we need + const uint128_t ZERO = 0; + + NS_ASSERT_MSG (rem < den, + "Remainder not less than divisor"); + + uint64_t digis = 0; // Number of digits we have already + uint64_t shift = 0; // Number we are going to get this round + + // Skip trailing zeros in divisor + while ( (shift < DIGITS) && !(den & 0x1)) + { + ++shift; + den >>= 1; + } + + while ( (digis < DIGITS) && (rem != ZERO) ) { - rem = rem << 64; - div = b; + // Skip leading zeros in remainder + while ( (digis + shift < DIGITS) && + !(rem & HP128_MASK_HI_BIT)) + { + ++shift; + rem <<= 1; + } + + // Cast off denominator bits if: + // Need more digits and + // LSB is zero or + // rem < den + while ( (digis + shift < DIGITS) && + ( !(den & 0x1) || (rem < den) ) ) + { + ++shift; + den >>= 1; + } + + // Do the division + quo = rem / den; + rem = rem % den; + + // Add in the quotient as shift bits of the fraction + result <<= shift; + result += quo; + + digis += shift; + shift = 0; } - else + // Did we run out of remainder? + if (digis < DIGITS) { - div = b >> 64; + shift = DIGITS - digis; + result <<= shift; } - quo = rem / div; - result = result + quo; + return result; } void -int64x64_t::MulByInvert (const int64x64_t &o) +int64x64_t::MulByInvert (const int64x64_t & o) { bool negResult = _v < 0; uint128_t a = negResult ? -_v : _v; @@ -107,30 +161,32 @@ _v = negResult ? -result : result; } + uint128_t -int64x64_t::UmulByInvert (uint128_t a, uint128_t b) +int64x64_t::UmulByInvert (const uint128_t a, const uint128_t b) { uint128_t result, ah, bh, al, bl; uint128_t hi, mid; ah = a >> 64; bh = b >> 64; - al = a & MASK_LO; - bl = b & MASK_LO; + al = a & HP_MASK_LO; + bl = b & HP_MASK_LO; hi = ah * bh; mid = ah * bl + al * bh; mid >>= 64; result = hi + mid; return result; } + int64x64_t -int64x64_t::Invert (uint64_t v) +int64x64_t::Invert (const uint64_t v) { NS_ASSERT (v > 1); uint128_t a; a = 1; a <<= 64; int64x64_t result; - result._v = Divu (a, v); + result._v = Udiv (a, v); int64x64_t tmp = int64x64_t (v, false); tmp.MulByInvert (result); if (tmp.GetHigh () != 1) diff -Naur ns-3.19/src/core/model/int64x64-128.h ns-3.20/src/core/model/int64x64-128.h --- ns-3.19/src/core/model/int64x64-128.h 2014-06-17 10:34:00.594635457 -0700 +++ ns-3.20/src/core/model/int64x64-128.h 2014-06-17 10:33:13.922995738 -0700 @@ -2,212 +2,404 @@ #if !defined(INT64X64_128_H) && defined (INT64X64_USE_128) && !defined(PYTHON_SCAN) #define INT64X64_128_H -#include "ns3/core-config.h" #include -#include +#include // pow #if defined(HAVE___UINT128_T) && !defined(HAVE_UINT128_T) typedef __uint128_t uint128_t; typedef __int128_t int128_t; #endif -namespace ns3 { -#define HP128_MAX_64 18446744073709551615.0 -#define HP128_MASK_LO ((((int128_t)1)<<64)-1) +namespace ns3 { +/** + * \internal + * The implementation documented here is based on native 128-bit integers. + */ class int64x64_t { + /// uint128_t high bit (sign bit) + static const uint128_t HP128_MASK_HI_BIT = (((int128_t)1)<<127); + /// Mask for fraction part + static const uint64_t HP_MASK_LO = 0xffffffffffffffffULL; + /// Mask for sign + integer part + static const uint64_t HP_MASK_HI = ~HP_MASK_LO; + /** + * Floating point value of HP_MASK_LO + 1 + * We really want: + * \code + * static const long double HP_MAX_64 = std:pow (2.0L, 64); + * \endcode + * but we can't call functions in const definitions, + * We could make this a static and initialize in int64x64-128.cc or + * int64x64.cc, but this requires handling static initialization order + * when most of the implementation is inline. Instead, we resort to + * this define. + */ +#define HP_MAX_64 (std::pow (2.0L, 64)) + public: + /** + * Type tag for the underlying implementation. + * + * A few testcases are are sensitive to implementation, + * specifically the double implementation. To handle this, + * we expose the underlying implementation type here. + */ + enum impl_type { + int128_impl, //!< Native int128_t implementation. + cairo_impl, //!< cairo wideint implementation + ld_impl, //!< long double implementation + }; + + /// Type tag for this implementation. + static const enum impl_type implementation = int128_impl; + + /// Default constructor inline int64x64_t () - : _v (0) - {} - inline int64x64_t (double value) - { - bool is_negative = value < 0; - value = is_negative ? -value : value; - double hi = std::floor (value); - double lo = (value - hi) * HP128_MAX_64; - _v = (int128_t)hi; - _v <<= 64; - _v += (int128_t)lo; - _v = is_negative ? -_v : _v; - } - inline int64x64_t (int v) + : _v (0) {} + /**@{*/ + /** + * Construct from a floating point value. + * + * \param [in] value floating value to represent + */ + inline int64x64_t (const double value) + { + const int64x64_t tmp ((long double)value); + _v = tmp._v; + } + inline int64x64_t (const long double value) + { + const bool negative = value < 0; + const long double v = negative ? -value : value; + + long double fhi; + long double flo = std::modf (v, &fhi); + // Add 0.5 to round, which improves the last count + // This breaks these tests: + // TestSuite devices-mesh-dot11s-regression + // TestSuite devices-mesh-flame-regression + // TestSuite routing-aodv-regression + // TestSuite routing-olsr-regression + // Setting round = 0; breaks: + // TestSuite int64x64 + const long double round = 0.5; + flo = flo * HP_MAX_64 + round; + int128_t hi = fhi; + const uint64_t lo = flo; + if (flo >= HP_MAX_64) + { + // conversion to uint64 rolled over + ++hi; + } + _v = hi << 64; + _v |= lo; + _v = negative ? -_v : _v; + } + /**@}*/ + + /**@{*/ + /** + * Construct from an integral type. + * + * \param [in] v integer value to represent + */ + inline int64x64_t (const int v) : _v (v) { _v <<= 64; } - inline int64x64_t (long int v) + inline int64x64_t (const long int v) : _v (v) { _v <<= 64; } - inline int64x64_t (long long int v) + inline int64x64_t (const long long int v) : _v (v) { _v <<= 64; } - inline int64x64_t (unsigned int v) + inline int64x64_t (const unsigned int v) : _v (v) { _v <<= 64; } - inline int64x64_t (unsigned long int v) + inline int64x64_t (const unsigned long int v) : _v (v) { _v <<= 64; } - inline int64x64_t (unsigned long long int v) + inline int64x64_t (const unsigned long long int v) : _v (v) { _v <<= 64; } - explicit inline int64x64_t (int64_t hi, uint64_t lo) - { - bool is_negative = hi<0; - _v = is_negative ? -hi : hi; - _v <<= 64; - _v += lo; - _v = is_negative ? -_v : _v; - } - - inline int64x64_t (const int64x64_t &o) + /**@}*/ + /** + * Construct from explicit high and low values. + * + * \param [in] hi Integer portion. + * \param [in] lo Fractional portion, already scaled to HP_MAX_64. + */ + explicit inline int64x64_t (const int64_t hi, const uint64_t lo) + { + _v = (int128_t)hi << 64; + _v |= lo; + } + + /** + * Copy constructor. + * + * \param [in] o Value to copy. + */ + inline int64x64_t (const int64x64_t & o) : _v (o._v) {} - inline int64x64_t &operator = (const int64x64_t &o) + /** + * Assignment. + * + * \param [in] o Value to assign to this int64x64_t. + */ + inline int64x64_t & operator = (const int64x64_t & o) { _v = o._v; return *this; } + /** + * Get this value as a double. + * + * \return This value in floating form. + */ inline double GetDouble (void) const { - bool is_negative = _v < 0; - uint128_t value = is_negative ? -_v : _v; - uint64_t hi = value >> 64; - uint64_t lo = value; - double flo = lo; - flo /= HP128_MAX_64; - double retval = hi; + const bool negative = _v < 0; + const uint128_t value = negative ? -_v : _v; + const long double fhi = value >> 64; + const long double flo = (value & HP_MASK_LO) / HP_MAX_64; + long double retval = fhi; retval += flo; - retval = is_negative ? -retval : retval; + retval = negative ? -retval : retval; return retval; } + /** + * Get the integer portion. + * + * \return The integer portion of this value. + */ inline int64_t GetHigh (void) const { - bool negative = _v < 0; - int128_t v = negative ? -_v : _v; - v >>= 64; - int64_t retval = v; - return negative ? -retval : retval; + const int128_t retval = _v >> 64; + return retval; } + /** + * Get the fractional portion of this value, unscaled. + * + * \return The fractional portion, unscaled, as an integer. + */ inline uint64_t GetLow (void) const { - bool negative = _v < 0; - int128_t v = negative ? -_v : _v; - int128_t low = v & HP128_MASK_LO; - uint64_t retval = low; + const uint128_t retval = _v & HP_MASK_LO; return retval; } -#undef HP128_MAX_64 -#undef HP128_MASK_LO - void MulByInvert (const int64x64_t &o); - - static int64x64_t Invert (uint64_t v); + /** + * Multiply this value by a Q0.128 value, presumably representing an inverse, + * completing a division operation. + * + * \param [in] o The inverse operand. + * + * \see Invert + */ + void MulByInvert (const int64x64_t & o); + + /** + * Compute the inverse of an integer value. + * + * Ordinary division by an integer would be limited to 64 bits of precsion. + * Instead, we multiply by the 128-bit inverse of the divisor. + * This function computes the inverse to 128-bit precision. + * MulByInvert() then completes the division. + * + * (Really this should be a separate type representing Q0.128.) + * + * \param [in] v The value to compute the inverse of. + * \return A Q0.128 representation of the inverse. + */ + static int64x64_t Invert (const uint64_t v); private: - friend bool operator == (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator != (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator <= (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator >= (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator < (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator > (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator += (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator -= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator *= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator /= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator + (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator - (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator * (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator / (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator + (const int64x64_t &lhs); - friend int64x64_t operator - (const int64x64_t &lhs); - friend int64x64_t operator ! (const int64x64_t &lhs); - void Mul (const int64x64_t &o); - void Div (const int64x64_t &o); - static uint128_t UmulByInvert (uint128_t a, uint128_t b); - static uint128_t Umul (uint128_t a, uint128_t b); - static uint128_t Divu (uint128_t a, uint128_t b); - inline int64x64_t (int128_t v) + friend bool operator == (const int64x64_t & lhs, const int64x64_t & rhs); + + friend bool operator < (const int64x64_t & lhs, const int64x64_t & rhs); + friend bool operator > (const int64x64_t & lhs, const int64x64_t & rhs); + + friend int64x64_t & operator += ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator -= ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator *= ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator /= ( int64x64_t & lhs, const int64x64_t & rhs); + + friend int64x64_t operator - (const int64x64_t & lhs); + friend int64x64_t operator ! (const int64x64_t & lhs); + + /** + * Implement `*=`. + * + * \param [in] o The other factor. + */ + void Mul (const int64x64_t & o); + /** + * Implement `/=`. + * + * \param [in] o The divisor. + */ + void Div (const int64x64_t & o); + /** + * Unsigned multiplication of Q64.64 values. + * + * Mathematically this should produce a Q128.128 value; + * we keep the central 128 bits, representing the Q64.64 result. + * We assert on integer overflow beyond the 64-bit integer portion. + * + * \param [in] a First factor. + * \param [in] b Second factor. + * \return The Q64.64 product. + * + * \internal + * + * It might be tempting to just use \pname{a} `*` \pname{b} + * and be done with it, but it's not that simple. With \pname{a} + * and \pname{b} as 128-bit integers, \pname{a} `*` \pname{b} + * mathematically produces a 256-bit result, which the computer + * truncates to the lowest 128 bits. In our case, where \pname{a} + * and \pname{b} are interpreted as Q64.64 fixed point numbers, + * the multiplication mathematically produces a Q128.128 fixed point number. + * We want the middle 128 bits from the result, truncating both the + * high and low 64 bits. To achieve this, we carry out the multiplication + * explicitly with 64-bit operands and 128-bit intermediate results. + */ + static uint128_t Umul (const uint128_t a, const uint128_t b); + /** + * Unsigned division of Q64.64 values. + * + * \param [in] a Numerator. + * \param [in] b Denominator. + * \return The Q64.64 representation of `a / b` + */ + static uint128_t Udiv (const uint128_t a, const uint128_t b); + /** + * Unsigned multiplication of Q64.64 and Q0.128 values. + * + * \param [in] a The numerator, a Q64.64 value. + * \param [in] b The inverse of the denominator, a Q0.128 value + * \return The product `a * b`, representing the ration `a / b^-1` + * + * \see Invert + */ + static uint128_t UmulByInvert (const uint128_t a, const uint128_t b); + + /** + * Construct from an integral type. + * + * \param [in] v integer value to represent + */ + inline int64x64_t (const int128_t v) : _v (v) {} - int128_t _v; -}; + int128_t _v; //!< The Q64.64 value. -inline bool operator == (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs._v == rhs._v; -} +}; // class int64x64_t -inline bool operator != (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs._v != rhs._v; -} -inline bool operator < (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs._v < rhs._v; -} -inline bool operator <= (const int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Equality operator. + */ +inline bool operator == (const int64x64_t & lhs, const int64x64_t & rhs) { - return lhs._v <= rhs._v; + return lhs._v == rhs._v; } - -inline bool operator >= (const int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Less than operator + */ +inline bool operator < (const int64x64_t & lhs, const int64x64_t & rhs) { - return lhs._v >= rhs._v; + return lhs._v < rhs._v; } -inline bool operator > (const int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Greater operator + */ +inline bool operator > (const int64x64_t & lhs, const int64x64_t & rhs) { return lhs._v > rhs._v; } -inline int64x64_t &operator += (int64x64_t &lhs, const int64x64_t &rhs) + +/** + * \ingroup highprec + * Compound addition operator + */ +inline int64x64_t & operator += (int64x64_t & lhs, const int64x64_t & rhs) { lhs._v += rhs._v; return lhs; } -inline int64x64_t &operator -= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound subtraction operator + */ +inline int64x64_t & operator -= (int64x64_t & lhs, const int64x64_t & rhs) { lhs._v -= rhs._v; return lhs; } -inline int64x64_t &operator *= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound multiplication operator + */ +inline int64x64_t & operator *= (int64x64_t & lhs, const int64x64_t & rhs) { lhs.Mul (rhs); return lhs; } -inline int64x64_t &operator /= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound division operator + */ +inline int64x64_t & operator /= (int64x64_t & lhs, const int64x64_t & rhs) { lhs.Div (rhs); return lhs; } -inline int64x64_t operator + (const int64x64_t &lhs) +/** + * \ingroup highprec + * Unary plus operator + */ +inline int64x64_t operator + (const int64x64_t & lhs) { return lhs; } - -inline int64x64_t operator - (const int64x64_t &lhs) +/** + * \ingroup highprec + * Unary negation operator (change sign operator) + */ +inline int64x64_t operator - (const int64x64_t & lhs) { return int64x64_t (-lhs._v); } - -inline int64x64_t operator ! (const int64x64_t &lhs) +/** + * \ingroup highprec + * Logical not operator + */ +inline int64x64_t operator ! (const int64x64_t & lhs) { return int64x64_t (!lhs._v); } + } // namespace ns3 #endif /* INT64X64_128_H */ diff -Naur ns-3.19/src/core/model/int64x64-cairo.cc ns-3.20/src/core/model/int64x64-cairo.cc --- ns-3.19/src/core/model/int64x64-cairo.cc 2014-06-17 10:34:00.594635457 -0700 +++ ns-3.20/src/core/model/int64x64-cairo.cc 2014-06-17 10:33:13.923995730 -0700 @@ -17,13 +17,13 @@ * * Author: Mathieu Lacage */ -#include "int64x64-cairo.h" #include "test.h" #include "abort.h" #include "assert.h" #include "log.h" #include #include +#include "int64x64-cairo.h" // Note: Logging in this file is largely avoided due to the // number of calls that are made to these functions and the possibility @@ -31,38 +31,45 @@ NS_LOG_COMPONENT_DEFINE ("int64x64-cairo"); +// Include directly to allow optimizations within this compilation unit. +extern "C" { +#include "cairo-wideint.c" +} + + namespace ns3 { -#define OUTPUT_SIGN(sa,sb,ua,ub) \ - ({ bool negA, negB; \ - negA = _cairo_int128_negative (sa); \ - negB = _cairo_int128_negative (sb); \ - ua = _cairo_int128_to_uint128 (sa); \ - ub = _cairo_int128_to_uint128 (sb); \ - ua = negA ? _cairo_uint128_negate (ua) : ua; \ - ub = negB ? _cairo_uint128_negate (ub) : ub; \ - (negA && !negB) || (!negA && negB); }) +static inline +bool +output_sign (const cairo_int128_t sa, + const cairo_int128_t sb, + cairo_uint128_t & ua, + cairo_uint128_t & ub) +{ + bool negA = _cairo_int128_negative (sa); + bool negB = _cairo_int128_negative (sb); + ua = _cairo_int128_to_uint128 (sa); + ub = _cairo_int128_to_uint128 (sb); + ua = negA ? _cairo_uint128_negate (ua) : ua; + ub = negB ? _cairo_uint128_negate (ub) : ub; + return (negA && !negB) || (!negA && negB); +} void -int64x64_t::Mul (int64x64_t const &o) +int64x64_t::Mul (const int64x64_t & o) { - cairo_uint128_t a, b, result; - bool sign = OUTPUT_SIGN (_v, o._v, a, b); - result = Umul (a, b); + cairo_uint128_t a, b; + bool sign = output_sign (_v, o._v, a, b); + cairo_uint128_t result = Umul (a, b); _v = sign ? _cairo_uint128_negate (result) : result; } -/** - * this function multiplies two 128 bits fractions considering - * the high 64 bits as the integer part and the low 64 bits - * as the fractional part. It takes into account the sign - * of the operands to produce a signed 128 bits result. - */ cairo_uint128_t -int64x64_t::Umul (cairo_uint128_t a, cairo_uint128_t b) +int64x64_t::Umul (const cairo_uint128_t a, const cairo_uint128_t b) { cairo_uint128_t result; - cairo_uint128_t hiPart,loPart,midPart; + cairo_uint128_t hiPart, loPart, midPart; + cairo_uint128_t res1, res2; // Multiplying (a.h 2^64 + a.l) x (b.h 2^64 + b.l) = // 2^128 a.h b.h + 2^64*(a.h b.l+b.h a.l) + a.l b.l @@ -72,62 +79,114 @@ // compute the middle part 2^64*(a.h b.l+b.h a.l) midPart = _cairo_uint128_add (_cairo_uint64x64_128_mul (a.lo, b.hi), _cairo_uint64x64_128_mul (a.hi, b.lo)); - // truncate the low part - result.lo = _cairo_uint64_add (loPart.hi,midPart.lo); // compute the high part 2^128 a.h b.h hiPart = _cairo_uint64x64_128_mul (a.hi, b.hi); - // truncate the high part and only use the low part - result.hi = _cairo_uint64_add (hiPart.lo,midPart.hi); // if the high part is not zero, put a warning NS_ABORT_MSG_IF (hiPart.hi != 0, "High precision 128 bits multiplication error: multiplication overflow."); + + // Adding 64-bit terms to get 128-bit results, with carries + res1 = _cairo_uint64_to_uint128 (loPart.hi); + res2 = _cairo_uint64_to_uint128 (midPart.lo); + result = _cairo_uint128_add (res1, res2); + + res1 = _cairo_uint64_to_uint128 (midPart.hi); + res2 = _cairo_uint64_to_uint128 (hiPart.lo); + res1 = _cairo_uint128_add (res1, res2); + res1 = _cairo_uint128_lsl (res1, 64); + + result = _cairo_uint128_add (result, res1); + return result; } void -int64x64_t::Div (int64x64_t const &o) +int64x64_t::Div (const int64x64_t & o) { - cairo_uint128_t a, b, result; - bool sign = OUTPUT_SIGN (_v, o._v, a, b); - result = Udiv (a, b); + cairo_uint128_t a, b; + bool sign = output_sign (_v, o._v, a, b); + cairo_uint128_t result = Udiv (a, b); _v = sign ? _cairo_uint128_negate (result) : result; } cairo_uint128_t -int64x64_t::Udiv (cairo_uint128_t a, cairo_uint128_t b) +int64x64_t::Udiv (const cairo_uint128_t a, const cairo_uint128_t b) { + cairo_uint128_t den = b; cairo_uquorem128_t qr = _cairo_uint128_divrem (a, b); - cairo_uint128_t result = _cairo_uint128_lsl (qr.quo, 64); + cairo_uint128_t result = qr.quo; + cairo_uint128_t rem = qr.rem; + // Now, manage the remainder - cairo_uint128_t tmp = _cairo_uint128_rsl (qr.rem, 64); - cairo_uint128_t zero = _cairo_uint64_to_uint128 (0); - cairo_uint128_t rem, div; - if (_cairo_uint128_eq (tmp, zero)) + const uint64_t DIGITS = 64; // Number of fraction digits (bits) we need + const cairo_uint128_t ZERO = _cairo_uint32_to_uint128 ((uint32_t)0); + + NS_ASSERT_MSG (_cairo_uint128_lt (rem, den), + "Remainder not less than divisor"); + + uint64_t digis = 0; // Number of digits we have already + uint64_t shift = 0; // Number we are going to get this round + + // Skip trailing zeros in divisor + while ( (shift < DIGITS) && !(den.lo & 0x1)) { - rem = _cairo_uint128_lsl (qr.rem, 64); - div = b; + ++shift; + den = _cairo_uint128_rsl (den, 1); } - else + + while ( (digis < DIGITS) && !(_cairo_uint128_eq(rem, ZERO)) ) { + // Skip leading zeros in remainder + while ( (digis + shift < DIGITS) && + !(rem.hi & HPCAIRO_MASK_HI_BIT) ) + { + ++shift; + rem = _cairo_int128_lsl (rem, 1); + } + + // Cast off denominator bits if: + // Need more digits and + // LSB is zero or + // rem < den + while ( (digis + shift < DIGITS) && + ( !(den.lo & 0x1) || _cairo_uint128_lt (rem, den) ) ) + { + ++shift; + den = _cairo_uint128_rsl (den, 1); + } + + // Do the division + qr = _cairo_uint128_divrem (rem, den); + + // Add in the quotient as shift bits of the fraction + result = _cairo_uint128_lsl (result, shift); + result = _cairo_uint128_add (result, qr.quo); rem = qr.rem; - div = _cairo_uint128_rsl (b, 64); + digis += shift; + shift = 0; } - qr = _cairo_uint128_divrem (rem, div); - result = _cairo_uint128_add (result, qr.quo); + // Did we run out of remainder? + if (digis < DIGITS) + { + shift = DIGITS - digis; + result = _cairo_uint128_lsl (result, shift); + } + return result; } void -int64x64_t::MulByInvert (const int64x64_t &o) +int64x64_t::MulByInvert (const int64x64_t & o) { - bool negResult = _cairo_int128_negative (_v); - cairo_uint128_t a = negResult ? _cairo_int128_negate (_v) : _v; + bool sign = _cairo_int128_negative (_v); + cairo_uint128_t a = sign ? _cairo_int128_negate (_v) : _v; cairo_uint128_t result = UmulByInvert (a, o._v); - _v = negResult ? _cairo_int128_negate (result) : result; + _v = sign ? _cairo_int128_negate (result) : result; } + cairo_uint128_t -int64x64_t::UmulByInvert (cairo_uint128_t a, cairo_uint128_t b) +int64x64_t::UmulByInvert (const cairo_uint128_t a, const cairo_uint128_t b) { cairo_uint128_t result; cairo_uint128_t hi, mid; @@ -139,8 +198,9 @@ result = _cairo_uint128_add (hi,mid); return result; } + int64x64_t -int64x64_t::Invert (uint64_t v) +int64x64_t::Invert (const uint64_t v) { NS_ASSERT (v > 1); cairo_uint128_t a, factor; @@ -162,8 +222,3 @@ } // namespace ns3 - -// include directly to allow optimizations within the compilation unit. -extern "C" { -#include "cairo-wideint.c" -} diff -Naur ns-3.19/src/core/model/int64x64-cairo.h ns-3.20/src/core/model/int64x64-cairo.h --- ns-3.19/src/core/model/int64x64-cairo.h 2014-06-17 10:34:00.594635457 -0700 +++ ns-3.20/src/core/model/int64x64-cairo.h 2014-06-17 10:33:13.924995722 -0700 @@ -2,254 +2,393 @@ #if !defined(INT64X64_CAIRO_H) && defined (INT64X64_USE_CAIRO) && !defined(PYTHON_SCAN) #define INT64X64_CAIRO_H -#include -#include +#include // pow #include "cairo-wideint-private.h" -#ifdef __i386__ -// this assembly code does not appear to work right yet. -#define noInt64x64_CAIRO_ASM 1 -#endif namespace ns3 { +/** + * \internal + * The implementation documented here uses cairo 128-bit integers. + */ class int64x64_t { + /// High bit of fractional part + static const uint64_t HPCAIRO_MASK_HI_BIT = (((uint64_t)1)<<63); + /// Mask for fraction part + static const uint64_t HP_MASK_LO = 0xffffffffffffffffULL; + /** + * Floating point value of HP_MASK_LO + 1 + * We really want: + * \code + * static const long double HP_MAX_64 = std:pow (2.0L, 64); + * \endcode + * but we can't call functions in const definitions, + * We could make this a static and initialize in int64x64-cairo.cc or + * int64x64.cc, but this requires handling static initialization order + * when most of the implementation is inline. Instead, we resort to + * this define. + */ +#define HP_MAX_64 (std::pow (2.0L, 64)) + public: + /** + * Type tag for the underlying implementation. + * + * A few testcases are sensitive to implementation, + * specifically the double implementation. To handle this, + * we expose the underlying implementation type here. + */ + enum impl_type { + int128_impl, //!< Native int128_t implementation. + cairo_impl, //!< cairo wideint implementation + ld_impl, //!< long double implementation + }; + + /// Type tag for this implementation. + static const enum impl_type implementation = cairo_impl; + + /// Default constructor inline int64x64_t () { _v.hi = 0; _v.lo = 0; } - inline int64x64_t (double value) - { -#define HPCAIRO_MAX_64 18446744073709551615.0 - double fhi = std::floor (value); - int64_t hi = lround (fhi); - uint64_t lo = (uint64_t)((value - fhi) * HPCAIRO_MAX_64); + /**@{*/ + /** + * Construct from a floating point value. + * + * \param [in] value floating value to represent + */ + inline int64x64_t (const double value) + { + const int64x64_t tmp ((long double)value); + _v = tmp._v; + } + inline int64x64_t (const long double value) + { + const bool negative = value < 0; + const long double v = negative ? -value : value; + + long double fhi; + long double flo = std::modf (v, &fhi); + // Add 0.5 to round, which improves the last count + // This breaks these tests: + // TestSuite devices-mesh-dot11s-regression + // TestSuite devices-mesh-flame-regression + // TestSuite routing-aodv-regression + // TestSuite routing-olsr-regression + // Setting round = 0; breaks: + // TestSuite int64x64 + const long double round = 0.5; + flo = flo * HP_MAX_64 + round; + cairo_int64_t hi = fhi; + const cairo_uint64_t lo = flo; + if (flo >= HP_MAX_64) + { + // conversion to uint64 rolled over + ++hi; + } _v.hi = hi; _v.lo = lo; -#undef HPCAIRO_MAX_64 + _v = negative ? _cairo_int128_negate (_v) : _v; } - inline int64x64_t (int v) + /**@}*/ + + /**@{*/ + /** + * Construct from an integral type. + * + * \param [in] v integer value to represent + */ + inline int64x64_t (const int v) { _v.hi = v; _v.lo = 0; } - inline int64x64_t (long int v) + inline int64x64_t (const long int v) { _v.hi = v; _v.lo = 0; } - inline int64x64_t (long long int v) + inline int64x64_t (const long long int v) { _v.hi = v; _v.lo = 0; } - inline int64x64_t (unsigned int v) + inline int64x64_t (const unsigned int v) { _v.hi = v; _v.lo = 0; } - inline int64x64_t (unsigned long int v) + inline int64x64_t (const unsigned long int v) { _v.hi = v; _v.lo = 0; } - inline int64x64_t (unsigned long long int v) + inline int64x64_t (const unsigned long long int v) { _v.hi = v; _v.lo = 0; } - inline int64x64_t (int64_t hi, uint64_t lo) + /**@}*/ + /** + * Construct from explicit high and low values. + * + * \param [in] hi Integer portion. + * \param [in] lo Fractional portion, already scaled to HP_MAX_64. + */ + explicit inline int64x64_t (const int64_t hi, const uint64_t lo) { _v.hi = hi; _v.lo = lo; } - inline int64x64_t (const int64x64_t &o) + /** + * Copy constructor. + * + * \param [in] o Value to copy. + */ + inline int64x64_t (const int64x64_t & o) : _v (o._v) {} - inline int64x64_t &operator = (const int64x64_t &o) + /** + * Assignment. + * + * \param [in] o Value to assign to this int64x64_t. + */ + inline int64x64_t & operator = (const int64x64_t & o) { _v = o._v; return *this; } + /** + * Get this value as a double. + * + * \return This value in floating form. + */ inline double GetDouble (void) const { -#define HPCAIRO_MAX_64 18446744073709551615.0 - bool is_negative = IsNegative (); - cairo_int128_t value = is_negative ? _cairo_int128_negate (_v) : _v; - double flo = value.lo; - flo /= HPCAIRO_MAX_64; - double retval = value.hi; + const bool negative = _cairo_int128_negative (_v); + const cairo_int128_t value = negative ? _cairo_int128_negate (_v) : _v; + const long double fhi = value.hi; + const long double flo = value.lo / HP_MAX_64; + long double retval = fhi; retval += flo; - retval = is_negative ? -retval : retval; + retval = negative ? -retval : retval; return retval; -#undef HPCAIRO_MAX_64 } + /** + * Get the integer portion. + * + * \return The integer portion of this value. + */ inline int64_t GetHigh (void) const { return (int64_t)_v.hi; } + /** + * Get the fractional portion of this value, unscaled. + * + * \return The fractional portion, unscaled, as an integer. + */ inline uint64_t GetLow (void) const { return _v.lo; } - void MulByInvert (const int64x64_t &o); - - static int64x64_t Invert (uint64_t v); + /** + * Multiply this value by a Q0.128 value, presumably representing an inverse, + * completing a division operation. + * + * \param [in] o The inverse operand. + * + * \see Invert + */ + void MulByInvert (const int64x64_t & o); + + /** + * Compute the inverse of an integer value. + * + * Ordinary division by an integer would be limited to 64 bits of precsion. + * Instead, we multiply by the 128-bit inverse of the divisor. + * This function computes the inverse to 128-bit precision. + * MulByInvert() then completes the division. + * + * (Really this should be a separate type representing Q0.128.) + * + * \param [in] v The value to compute the inverse of. + * \return A Q0.128 representation of the inverse. + */ + static int64x64_t Invert (const uint64_t v); private: - friend bool operator == (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator != (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator <= (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator >= (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator < (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator > (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator += (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator -= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator *= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator /= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator + (const int64x64_t &lhs); - friend int64x64_t operator - (const int64x64_t &lhs); - friend int64x64_t operator ! (const int64x64_t &lhs); - void Mul (const int64x64_t &o); - void Div (const int64x64_t &o); - static cairo_uint128_t Umul (cairo_uint128_t a, cairo_uint128_t b); - static cairo_uint128_t Udiv (cairo_uint128_t a, cairo_uint128_t b); - static cairo_uint128_t UmulByInvert (cairo_uint128_t a, cairo_uint128_t b); - inline bool IsNegative (void) const - { - int64_t hi = _v.hi; - return hi < 0; - } - inline void Negate (void) - { - _v.lo = ~_v.lo; - _v.hi = ~_v.hi; - if (++_v.lo == 0) - { - ++_v.hi; - } - } - inline int Compare (const int64x64_t &o) const - { - int status; - int64x64_t tmp = *this; - tmp -= o; - status = (((int64_t)(tmp)._v.hi) < 0) ? -1 : - (((tmp)._v.hi == 0 && (tmp)._v.lo == 0)) ? 0 : 1; - return status; - } - cairo_int128_t _v; -}; - -inline bool operator == (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs._v.hi == rhs._v.hi && lhs._v.lo == lhs._v.lo; -} + friend bool operator == (const int64x64_t & lhs, const int64x64_t & rhs); -inline bool operator != (const int64x64_t &lhs, const int64x64_t &rhs) + friend bool operator < (const int64x64_t & lhs, const int64x64_t & rhs); + friend bool operator > (const int64x64_t & lhs, const int64x64_t & rhs); + + friend int64x64_t & operator += ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator -= ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator *= ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator /= ( int64x64_t & lhs, const int64x64_t & rhs); + + friend int64x64_t operator - (const int64x64_t & lhs); + friend int64x64_t operator ! (const int64x64_t & lhs); + + /** + * Implement `*=`. + * + * \param [in] o The other factor. + */ + void Mul (const int64x64_t & o); + /** + * Implement `/=`. + * + * \param [in] o The divisor. + */ + void Div (const int64x64_t & o); + /** + * Unsigned multiplication of Q64.64 values. + * + * Mathematically this should produce a Q128.128 value; + * we keep the central 128 bits, representing the Q64.64 result. + * We assert on integer overflow beyond the 64-bit integer portion. + * + * \param [in] a First factor. + * \param [in] b Second factor. + * \return The Q64.64 product. + * + * \internal + * + * It might be tempting to just use \pname{a} `*` \pname{b} + * and be done with it, but it's not that simple. With \pname{a} + * and \pname{b} as 128-bit integers, \pname{a} `*` \pname{b} + * mathematically produces a 256-bit result, which the computer + * truncates to the lowest 128 bits. In our case, where \pname{a} + * and \pname{b} are interpreted as Q64.64 fixed point numbers, + * the multiplication mathematically produces a Q128.128 fixed point number. + * We want the middle 128 bits from the result, truncating both the + * high and low 64 bits. To achieve this, we carry out the multiplication + * explicitly with 64-bit operands and 128-bit intermediate results. + */ + static cairo_uint128_t Umul (const cairo_uint128_t a, const cairo_uint128_t b); + /** + * Unsigned division of Q64.64 values. + * + * \param [in] a Numerator. + * \param [in] b Denominator. + * \return The Q64.64 representation of `a / b` + */ + static cairo_uint128_t Udiv (const cairo_uint128_t a, const cairo_uint128_t b); + /** + * Unsigned multiplication of Q64.64 and Q0.128 values. + * + * \param [in] a The numerator, a Q64.64 value. + * \param [in] b The inverse of the denominator, a Q0.128 value + * \return The product `a * b`, representing the ration `a / b^-1` + * + * \see Invert + */ + static cairo_uint128_t UmulByInvert (const cairo_uint128_t a, const cairo_uint128_t b); + + cairo_int128_t _v; //!< The Q64.64 value. + +}; // class int64x64_t + + +/** + * \ingroup highprec + * Equality operator. + */ +inline bool operator == (const int64x64_t & lhs, const int64x64_t & rhs) +{ + return _cairo_int128_eq (lhs._v, rhs._v); +} +/** + * \ingroup highprec + * Less than operator + */ +inline bool operator < (const int64x64_t & lhs, const int64x64_t & rhs) +{ + return _cairo_int128_lt (lhs._v, rhs._v); +} +/** + * \ingroup highprec + * Greater operator + */ +inline bool operator > (const int64x64_t & lhs, const int64x64_t & rhs) +{ + return _cairo_int128_gt (lhs._v, rhs._v); +} + +/** + * \ingroup highprec + * Compound addition operator + */ +inline int64x64_t & operator += (int64x64_t & lhs, const int64x64_t & rhs) { - return !(lhs == rhs); -} - -inline bool operator < (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs.Compare (rhs) < 0; -} -inline bool operator <= (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs.Compare (rhs) <= 0; -} - -inline bool operator >= (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs.Compare (rhs) >= 0; -} -inline bool operator > (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs.Compare (rhs) > 0; -} -inline int64x64_t &operator += (int64x64_t &lhs, const int64x64_t &rhs) -{ -#if Int64x64_CAIRO_ASM - asm ("mov 0(%1),%%eax\n\t" - "add %%eax,0(%0)\n\t" - "mov 4(%1),%%eax\n\t" - "adc %%eax,4(%0)\n\t" - "mov 8(%1),%%eax\n\t" - "adc %%eax,8(%0)\n\t" - "mov 12(%1),%%eax\n\t" - "adc %%eax,12(%0)\n\t" - : - : "r" (&lhs._v), "r" (&rhs._v) - : "%eax", "cc"); -#else - lhs._v.hi += rhs._v.hi; - lhs._v.lo += rhs._v.lo; - if (lhs._v.lo < rhs._v.lo) - { - lhs._v.hi++; - } -#endif + lhs._v = _cairo_int128_add( lhs._v, rhs._v ); return lhs; } -inline int64x64_t &operator -= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound subtraction operator + */ +inline int64x64_t & operator -= (int64x64_t & lhs, const int64x64_t & rhs) { -#if Int64x64_CAIRO_ASM - asm ("mov 0(%1),%%eax\n\t" - "sub %%eax,0(%0)\n\t" - "mov 4(%1),%%eax\n\t" - "sbb %%eax,4(%0)\n\t" - "mov 8(%1),%%eax\n\t" - "sbb %%eax,8(%0)\n\t" - "mov 12(%1),%%eax\n\t" - "sbb %%eax,12(%0)\n\t" - : - : "r" (&lhs._v), "r" (&rhs._v) - : "%eax", "cc"); -#else - lhs._v.hi -= rhs._v.hi; - lhs._v.lo -= rhs._v.lo; - if (lhs._v.lo > rhs._v.lo) - { - lhs._v.hi--; - } -#endif + lhs._v = _cairo_int128_sub( lhs._v, rhs._v ); return lhs; } -inline int64x64_t &operator *= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound multiplication operator + */ +inline int64x64_t & operator *= (int64x64_t & lhs, const int64x64_t & rhs) { lhs.Mul (rhs); return lhs; } -inline int64x64_t &operator /= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound division operator + */ +inline int64x64_t & operator /= (int64x64_t & lhs, const int64x64_t & rhs) { lhs.Div (rhs); return lhs; } -inline int64x64_t operator + (const int64x64_t &lhs) +/** + * \ingroup highprec + * Unary plus operator + */ +inline int64x64_t operator + (const int64x64_t & lhs) { return lhs; } - -inline int64x64_t operator - (const int64x64_t &lhs) +/** + * \ingroup highprec + * Unary negation operator (change sign operator) + */ +inline int64x64_t operator - (const int64x64_t & lhs) { int64x64_t tmp = lhs; - tmp.Negate (); + tmp._v = _cairo_int128_negate (tmp._v); return tmp; } - -inline int64x64_t operator ! (const int64x64_t &lhs) +/** + * \ingroup highprec + * Logical not operator + */ +inline int64x64_t operator ! (const int64x64_t & lhs) { - return (lhs._v.hi == 0 && lhs._v.lo == 0) ? int64x64_t (1, 0) : int64x64_t (); + return (lhs == int64x64_t ()) ? int64x64_t (1, 0) : int64x64_t (); } + } // namespace ns3 #endif /* INT64X64_CAIRO_H */ diff -Naur ns-3.19/src/core/model/int64x64.cc ns-3.20/src/core/model/int64x64.cc --- ns-3.19/src/core/model/int64x64.cc 2014-06-17 10:34:00.595635449 -0700 +++ ns-3.20/src/core/model/int64x64.cc 2014-06-17 10:33:13.925995715 -0700 @@ -14,77 +14,159 @@ namespace ns3 { -static uint8_t MostSignificantDigit (uint64_t value) -{ - uint8_t n = 0; - do - { - n++; - value /= 10; - } while (value != 0); - return n; -} - -static uint64_t PowerOfTen (uint8_t n) -{ - uint64_t retval = 1; - while (n > 0) - { - retval *= 10; - n--; - } - return retval; -} - +/** + * \internal + * This algorithm is exact to the precision requested, up to the full + * 64 decimal digits required to exactly represent a 64-bit fraction. + * + * Proper rounding turns out to be surprisingly hard. + * In `y.xxxx5|6`, where the `|` marks follows the last output digit, + * rounding the `5|6` to `6|` is straightforward. However, + * rounding `y.xxx99|6` should result in `y.xx100|`. Notice the + * effect of rounding percolates to higher digits. + * We accumulate the output digits in a string, then carry out + * the rounding in the string directly. + */ std::ostream &operator << (std::ostream &os, const int64x64_t &value) { - int64_t hi = value.GetHigh (); + const bool negative = (value < 0); + const int64x64_t absVal = (negative ? -value : value); + + int64_t hi = absVal.GetHigh (); // Save stream format flags + const std::streamsize precision = os.precision (); std::ios_base::fmtflags ff = os.flags (); + const bool floatfield = os.flags () & std::ios_base::floatfield; + os << std::setw (1) << std::noshowpos; + + os << std::right << (negative ? "-" : "+"); + + std::ostringstream oss; + oss << hi << "."; // collect the digits here so we can round properly + - { /// \internal - /// See \bugid{1737}: gcc libstc++ 4.2 bug - if (hi == 0) - { - os << '+'; - } - else - { - os << std::showpos; - } - } + int64x64_t low(0, absVal.GetLow ()); + int places = 0; // Number of decimal places printed so far + bool more = true; // Should we print more digits? + +#define HEXHILOW(hi, lo) \ + std::hex << std::setfill ('0') << std::right << " (0x" \ + << std::setw (16) << hi << " " \ + << std::setw (16) << lo \ + << std::dec << std::setfill (' ') << std::left << ")" + + + NS_LOG_LOGIC (std::endl + << (floatfield ? " f" : " ") + << "[" << precision << "] " << hi << ". " + << HEXHILOW (hi, low.GetLow ()) + ); + + int64_t digit; + do + { + low *= 10; + digit = low.GetHigh (); + NS_ASSERT_MSG ( (0 <= digit) && (digit <= 9), + "digit " << digit << " out of range [0,9] " + << " streaming out " + << HEXHILOW (value.GetHigh (), value.GetLow ()) ); + low -= digit; + + oss << std::setw (1) << digit; + + ++places; + if (floatfield) + { + more = places < precision; + } + else // default + { + // Full resolution is 20 decimal digits + more = low.GetLow () && (places < 20); + } + + NS_LOG_LOGIC ((more ? "+" : " ") + << (floatfield ? "f" : " ") + << "[" << places << "] " << digit + << HEXHILOW (low.GetHigh (), low.GetLow ()) + << std::dec << std::setfill (' ' ) << std::left); + + } while (more); + + // Check if we need to round the last printed digit, + // based on the first unprinted digit + std::string digits = oss.str (); + low *= 10; + int64_t nextDigit = low.GetHigh (); + if ( (nextDigit > 5) || ((nextDigit == 5) && (digit % 2 == 1)) ) + { + // Walk backwards with the carry + bool carry = true; + for (std::string::reverse_iterator rit = digits.rbegin (); + rit != digits.rend (); + ++rit) + { + if (*rit == '.') // Skip over the decimal point + { + continue ; + } + + ++(*rit); // Add the carry + if (*rit <= '9') // Relies on character order... + { + carry = false; + break ; // Carry complete + } + else + { + *rit = '0'; // Continue carry to next higher digit + } + } + if (carry) // If we still have a carry... + { + digits.insert (digits.begin (), '1'); + } + } + os << digits; - os << hi << "."; os.flags (ff); // Restore stream flags - - uint64_t low = value.GetLow (); - uint8_t msd = MostSignificantDigit (~((uint64_t)0)); - do - { - msd--; - uint64_t pow = PowerOfTen (msd); - uint8_t digit = low / pow; - NS_ASSERT (digit < 10); - os << (uint16_t) digit; - low -= digit * pow; - } while (msd > 0 && low > 0); return os; } -static uint64_t ReadDigits (std::string str) +static uint64_t ReadHiDigits (std::string str) { const char *buf = str.c_str (); uint64_t retval = 0; while (*buf != 0) { retval *= 10; - retval += *buf - 0x30; + retval += *buf - '0'; buf++; } return retval; } +static uint64_t ReadLoDigits (std::string str) +{ + int64x64_t low; + const int64x64_t round (0, 5); // Round last place in division + + for (std::string::const_reverse_iterator rit = str.rbegin (); + rit != str.rend (); + ++rit) + { + int digit = *rit - '0'; + NS_ASSERT_MSG ( (0 <= digit) && (digit <= 9), + "digit " << digit << " out of range [0,9]" + << " streaming in low digits \"" << str << "\""); + low = (low + digit + round) / 10; + } + + return low.GetLow (); +} + std::istream &operator >> (std::istream &is, int64x64_t &value) { std::string str; @@ -121,16 +203,23 @@ next = str.find (".", cur); if (next != std::string::npos) { - hi = ReadDigits (str.substr (cur, next-cur)); - lo = ReadDigits (str.substr (next+1, str.size ()-(next+1))); + hi = ReadHiDigits (str.substr (cur, next-cur)); + lo = ReadLoDigits (str.substr (next+1, str.size ()-(next+1))); + } + else if (cur != std::string::npos) + { + hi = ReadHiDigits (str.substr (cur, str.size ()-cur)); + lo = 0; } else { - hi = ReadDigits (str.substr (cur, str.size ()-cur)); + hi = 0; lo = 0; } - hi = negative ? -hi : hi; + value = int64x64_t (hi, lo); + value = negative ? -value : value; + return is; } diff -Naur ns-3.19/src/core/model/int64x64-double.h ns-3.20/src/core/model/int64x64-double.h --- ns-3.19/src/core/model/int64x64-double.h 2014-06-17 10:34:00.595635449 -0700 +++ ns-3.20/src/core/model/int64x64-double.h 2014-06-17 10:33:13.924995722 -0700 @@ -2,18 +2,73 @@ #if !defined(INT64X64_DOUBLE_H) && (defined (INT64X64_USE_DOUBLE) || defined(PYTHON_SCAN)) #define INT64X64_DOUBLE_H -#include -#include +#include +#include // pow +#include // pair + namespace ns3 { +/** + * \internal + * The implementation documented here uses native long double. + */ class int64x64_t { + /// Mask for fraction part + static const uint64_t HP_MASK_LO = 0xffffffffffffffffULL; + /** + * Floating point value of HP_MASK_LO + 1 + * We really want: + * \code + * static const long double HP_MAX_64 = std:pow (2.0L, 64); + * \endcode + * but we can't call functions in const definitions, + * We could make this a static and initialize in int64x64-double.cc or + * int64x64.cc, but this requires handling static initialization order + * when most of the implementation is inline. Instead, we resort to + * this define. + */ +#define HP_MAX_64 (std::pow (2.0L, 64)) + public: + /** + * Type tag for the underlying implementation. + * + * A few testcases are are sensitive to implementation, + * specifically the double implementation. To handle this, + * we expose the underlying implementation type here. + */ + enum impl_type { + int128_impl, //!< Native int128_t implementation. + cairo_impl, //!< cairo wideint implementation + ld_impl, //!< long double implementation + }; + + /// Type tag for this implementation. + static const enum impl_type implementation = ld_impl; + + /// Default constructor inline int64x64_t () : _v (0) {} + /**@{*/ + /** + * Construct from a floating point value. + * + * \param [in] v floating value to represent + */ inline int64x64_t (double v) : _v (v) {} + inline int64x64_t (long double v) + : _v (v) {} + /**@}*/ + + /**@{*/ + /** + * Construct from an integral type. + * + * \param [in] v integer value to represent + */ inline int64x64_t (int v) : _v (v) {} inline int64x64_t (long int v) @@ -26,135 +81,244 @@ : _v (v) {} inline int64x64_t (unsigned long long int v) : _v (v) {} - inline int64x64_t (int64_t hi, uint64_t lo) - : _v (hi) { /** \todo add in lo? */} + /**@}*/ + /** + * Construct from explicit high and low values. + * + * \param [in] hi Integer portion. + * \param [in] lo Fractional portion, already scaled to HP_MAX_64. + */ + explicit inline int64x64_t (int64_t hi, uint64_t lo) + { + const bool negative = hi < 0; + const long double fhi = negative ? -hi : hi; + const long double flo = lo / HP_MAX_64; + _v = negative ? - fhi : fhi; + _v += flo; + // _v = negative ? -_v : _v; + } - inline int64x64_t (const int64x64_t &o) + /** + * Copy constructor. + * + * \param [in] o Value to copy. + */ + inline int64x64_t (const int64x64_t & o) : _v (o._v) {} - inline int64x64_t &operator = (const int64x64_t &o) + /** + * Assignment. + * + * \param [in] o Value to assign to this int64x64_t. + */ + inline int64x64_t & operator = (const int64x64_t & o) { _v = o._v; return *this; } + /** + * Get this value as a double. + * + * \return This value in floating form. + */ inline double GetDouble (void) const { - return _v; + return (double)_v; } +private: + /** + * Get the high and low portions of this value. + * + * \return a pair of the high and low words + */ + std::pair GetHighLow (void) const + { + const bool negative = _v < 0; + const long double v = negative ? -_v : _v; + + long double fhi; + long double flo = std::modf (v, &fhi); + // Add 0.5 to round, which improves the last count + // This breaks these tests: + // TestSuite devices-mesh-dot11s-regression + // TestSuite devices-mesh-flame-regression + // TestSuite routing-aodv-regression + // TestSuite routing-olsr-regression + // Setting round = 0; breaks: + // TestSuite int64x64 + const long double round = 0.5; + flo = flo * HP_MAX_64 + round; + int64_t hi = fhi; + uint64_t lo = flo; + if (flo >= HP_MAX_64) + { + // conversion to uint64 rolled over + ++hi; + } + if (negative) + { + lo = ~lo; + hi = ~hi; + if (++lo == 0) + { + ++hi; + } + } + return std::make_pair (hi, lo); + } +public: + /** + * Get the integer portion. + * + * \return The integer portion of this value. + */ inline int64_t GetHigh (void) const { - return (int64_t)std::floor (_v); + return GetHighLow ().first; } + /** + * Get the fractional portion of this value, unscaled. + * + * \return The fractional portion, unscaled, as an integer. + */ inline uint64_t GetLow (void) const { - /// \todo Generate lo? - return 0; + return GetHighLow ().second; } - inline void MulByInvert (const int64x64_t &o) + /** + * Multiply this value by a Q0.128 value, presumably representing an inverse, + * completing a division operation. + * + * \param [in] o The inverse operand. + * + * \note There is no difference between Q64.64 and Q0.128 in this implementation, + * so this function is a simple multiply. + */ + inline void MulByInvert (const int64x64_t & o) { _v *= o._v; } + /** + * Compute the inverse of an integer value. + * + * \param [in] v The value to compute the inverse of. + * \return The inverse. + */ static inline int64x64_t Invert (uint64_t v) { - double d = v; - return int64x64_t (1/d); + int64x64_t tmp ((long double)1 / v); + return tmp; } private: - friend bool operator == (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator != (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator <= (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator >= (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator < (const int64x64_t &lhs, const int64x64_t &rhs); - friend bool operator > (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator += (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator -= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator *= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t &operator /= (int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator + (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator - (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator * (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator / (const int64x64_t &lhs, const int64x64_t &rhs); - friend int64x64_t operator + (const int64x64_t &lhs); - friend int64x64_t operator - (const int64x64_t &lhs); - friend int64x64_t operator ! (const int64x64_t &lhs); + friend bool operator == (const int64x64_t & lhs, const int64x64_t & rhs); - double _v; -}; + friend bool operator < (const int64x64_t & lhs, const int64x64_t & rhs); + friend bool operator > (const int64x64_t & lhs, const int64x64_t & rhs); + + friend int64x64_t & operator += ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator -= ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator *= ( int64x64_t & lhs, const int64x64_t & rhs); + friend int64x64_t & operator /= ( int64x64_t & lhs, const int64x64_t & rhs); -inline bool operator == (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs._v == rhs._v; -} + friend int64x64_t operator - (const int64x64_t & lhs); + friend int64x64_t operator ! (const int64x64_t & lhs); -inline bool operator != (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs._v != rhs._v; -} + long double _v; //!< The Q64.64 value. + +}; // class int64x64_t -inline bool operator <= (const int64x64_t &lhs, const int64x64_t &rhs) -{ - return lhs._v <= rhs._v; -} -inline bool operator >= (const int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Equality operator. + */ +inline bool operator == (const int64x64_t & lhs, const int64x64_t & rhs) { - return lhs._v >= rhs._v; + return lhs._v == rhs._v; } -inline bool operator < (const int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Less than operator + */ +inline bool operator < (const int64x64_t & lhs, const int64x64_t & rhs) { return lhs._v < rhs._v; } -inline bool operator > (const int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Greater operator + */ +inline bool operator > (const int64x64_t & lhs, const int64x64_t & rhs) { return lhs._v > rhs._v; } -inline int64x64_t &operator += (int64x64_t &lhs, const int64x64_t &rhs) + +/** + * \ingroup highprec + * Compound addition operator + */ +inline int64x64_t & operator += (int64x64_t & lhs, const int64x64_t & rhs) { - double tmp = lhs._v; - tmp += rhs._v; - lhs = int64x64_t (tmp); + lhs._v += rhs._v; return lhs; } -inline int64x64_t &operator -= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound subtraction operator + */ +inline int64x64_t & operator -= (int64x64_t & lhs, const int64x64_t & rhs) { - double tmp = lhs._v; - tmp -= rhs._v; - lhs = int64x64_t (tmp); + lhs._v -= rhs._v; return lhs; } -inline int64x64_t &operator *= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound multiplication operator + */ +inline int64x64_t & operator *= (int64x64_t & lhs, const int64x64_t & rhs) { - double tmp = lhs._v; - tmp *= rhs._v; - lhs = int64x64_t (tmp); + lhs._v *= rhs._v; return lhs; } -inline int64x64_t &operator /= (int64x64_t &lhs, const int64x64_t &rhs) +/** + * \ingroup highprec + * Compound division operator + */ +inline int64x64_t & operator /= (int64x64_t & lhs, const int64x64_t & rhs) { - double tmp = lhs._v; - tmp /= rhs._v; - lhs = int64x64_t (tmp); + lhs._v /= rhs._v; return lhs; } -inline int64x64_t operator + (const int64x64_t &lhs) +/** + * \ingroup highprec + * Unary plus operator + */ +inline int64x64_t operator + (const int64x64_t & lhs) { return lhs; } - -inline int64x64_t operator - (const int64x64_t &lhs) +/** + * \ingroup highprec + * Unary negation operator (change sign operator) + */ +inline int64x64_t operator - (const int64x64_t & lhs) { return int64x64_t (-lhs._v); } - -inline int64x64_t operator ! (const int64x64_t &lhs) +/** + * \ingroup highprec + * Logical not operator + */ +inline int64x64_t operator ! (const int64x64_t & lhs) { return int64x64_t (!lhs._v); } + } // namespace ns3 #endif /* INT64X64_DOUBLE_H */ diff -Naur ns-3.19/src/core/model/int64x64.h ns-3.20/src/core/model/int64x64.h --- ns-3.19/src/core/model/int64x64.h 2014-06-17 10:34:00.596635442 -0700 +++ ns-3.20/src/core/model/int64x64.h 2014-06-17 10:33:13.925995715 -0700 @@ -3,95 +3,204 @@ #include "ns3/core-config.h" -#if defined (INT64X64_USE_DOUBLE) || defined (PYTHON_SCAN) -#include "int64x64-double.h" -#elif defined (INT64X64_USE_CAIRO) -#include "int64x64-cairo.h" -#elif defined (INT64X64_USE_128) +// Order is important here, as it determines which implementation +// will generate doxygen API docs. This order mimics the +// selection logic in wscript, so we generate docs from the +// implementation actually chosen by the configuration. +#if defined (INT64X64_USE_128) && !defined (PYTHON_SCAN) #include "int64x64-128.h" +#elif defined (INT64X64_USE_CAIRO) && !defined (PYTHON_SCAN) +#include "int64x64-cairo.h" +#elif defined (INT64X64_USE_DOUBLE) || defined (PYTHON_SCAN) +#include "int64x64-double.h" #endif #include namespace ns3 { -#define INT64X64_OP_ARITH_TYPE(op,type) \ - inline int64x64_t operator op (const int64x64_t &lhs, const type rhs) \ - { \ - int64x64_t tmp = lhs; \ - tmp op ## = int64x64_t (rhs); \ - return tmp; \ - } \ - inline int64x64_t operator op (const type lhs, const int64x64_t &rhs) \ - { \ - int64x64_t tmp = int64x64_t (lhs); \ - tmp op ## = rhs; \ - return tmp; \ - } - -#define INT64X64_OP_ARITH(op) \ - inline int64x64_t operator op (const int64x64_t &lhs, const int64x64_t &rhs) \ - { \ - int64x64_t tmp = lhs; \ - tmp op ## = rhs; \ - return tmp; \ - } \ - INT64X64_OP_ARITH_TYPE (op,double) \ - INT64X64_OP_ARITH_TYPE (op,signed char) \ - INT64X64_OP_ARITH_TYPE (op,signed short) \ - INT64X64_OP_ARITH_TYPE (op,signed int) \ - INT64X64_OP_ARITH_TYPE (op,signed long int) \ - INT64X64_OP_ARITH_TYPE (op,signed long long int) \ - INT64X64_OP_ARITH_TYPE (op,unsigned char) \ - INT64X64_OP_ARITH_TYPE (op,unsigned short) \ - INT64X64_OP_ARITH_TYPE (op,unsigned int) \ - INT64X64_OP_ARITH_TYPE (op,unsigned long int) \ - INT64X64_OP_ARITH_TYPE (op,unsigned long long int) - -#define INT64X64_OP_CMP_TYPE(op,type) \ - inline bool operator op (const int64x64_t &lhs, const type &rhs) \ - { \ - return lhs op int64x64_t (rhs); \ - } \ - inline bool operator op (const type &lhs, const int64x64_t &rhs) \ - { \ - return int64x64_t (lhs) op rhs; \ - } - -#define INT64X64_OP_CMP(op) \ - INT64X64_OP_CMP_TYPE (op,double) \ - INT64X64_OP_CMP_TYPE (op,signed int) \ - INT64X64_OP_CMP_TYPE (op,signed long int) \ - INT64X64_OP_CMP_TYPE (op,signed long long int) \ - INT64X64_OP_CMP_TYPE (op,unsigned int) \ - INT64X64_OP_CMP_TYPE (op,unsigned long int) \ - INT64X64_OP_CMP_TYPE (op,unsigned long long int) - - -INT64X64_OP_ARITH (+) -INT64X64_OP_ARITH (-) -INT64X64_OP_ARITH (*) -INT64X64_OP_ARITH (/) -INT64X64_OP_CMP (==) -INT64X64_OP_CMP (!=) -INT64X64_OP_CMP (<) -INT64X64_OP_CMP (<=) -INT64X64_OP_CMP (>) -INT64X64_OP_CMP (>=) - +/** + * \ingroup core + * \defgroup highprec High Precision Q64.64 + * + * Functions and class for high precision Q64.64 fixed point arithmetic. + */ + +/** + * \ingroup highprec + * \class int64x64_t + * + * High precision numerical type, implementing Q64.64 fixed precision. + * + * A Q64.64 fixed precision number consists of: + * + * Bits | Function + * ---- | -------- + * 1 | Sign bit + * 63 | Integer portion + * 64 | Fractional portion + * + * The `high` word consists of the sign bit and integer value; + * the `low` word is the fractional part, unscaled. + * + * All standard arithmetic operations are supported: + * + * Category | Operators + * ----------- | --------- + * Computation | `+`, `+=`, `-`, `-=`, `*`, `*=`, `/`, `/=` + * Comparison | `==`, `!=`, `<`, `<=`, `>`, `>=` + * Unary | `+`, `-`, `!` + */ + + +/** + * \ingroup core + * \defgroup highprec High Precision Q64.64 + * + * Functions and class for high precision Q64.64 fixed point arithmetic. + */ + +/** + * \ingroup highprec + * \class int64x64_t + * + * High precision numerical type, implementing Q64.64 fixed precision. + * + * A Q64.64 fixed precision number consists of: + * + * Bits | Function + * ---- | -------- + * 1 | Sign bit + * 63 | Integer portion + * 64 | Fractional portion + * + * The `high` word consists of the sign bit and integer value; + * the `low` word is the fractional part, unscaled. + * + * All standard arithmetic operations are supported: + * + * Category | Operators + * ----------- | --------- + * Computation | `+`, `+=`, `-`, `-=`, `*`, `*=`, `/`, `/=` + * Comparison | `==`, `!=`, `<`, `<=`, `>`, `>=` + * Unary | `+`, `-`, `!` + */ + + +/** + * \ingroup highprec + * Addition operator. + */ +inline +int64x64_t operator + (const int64x64_t & lhs, const int64x64_t & rhs) +{ + int64x64_t tmp = lhs; + tmp += rhs; + return tmp; +} +/** + * \ingroup highprec + * Subtraction operator. + */ +inline +int64x64_t operator - (const int64x64_t & lhs, const int64x64_t & rhs) +{ + int64x64_t tmp = lhs; + tmp -= rhs; + return tmp; +} +/** + * \ingroup highprec + * Multiplication operator. + */ +inline +int64x64_t operator * (const int64x64_t & lhs, const int64x64_t & rhs) +{ + int64x64_t tmp = lhs; + tmp *= rhs; + return tmp; +} +/** + * \ingroup highprec + * Division operator. + */ +inline +int64x64_t operator / (const int64x64_t & lhs, const int64x64_t & rhs) +{ + int64x64_t tmp = lhs; + tmp /= rhs; + return tmp; +} +/** + * \ingroup highprec + * Inequality operator + */ +inline bool operator != (const int64x64_t & lhs, const int64x64_t & rhs) +{ + return !(lhs == rhs); +} +/** + * \ingroup highprec + * Less or equal operator + */ +inline bool operator <= (const int64x64_t & lhs, const int64x64_t & rhs) +{ + return !(lhs > rhs); +} +/** + * \ingroup highprec + * Greater or equal operator + */ +inline bool operator >= (const int64x64_t & lhs, const int64x64_t & rhs) +{ + return !(lhs < rhs); +} +/** + * \ingroup highprec + * Output streamer for int64x64_t + * + * Values are printed with the following format flags + * (independent of the the stream flags): + * - `showpos` + * - `left` + * + * The stream `width` is ignored. If `floatfield` is set, + * `precision` decimal places are printed. If `floatfield` is not set, + * all digits of the fractional part are printed, up to the + * representation limit of 20 digits; trailing zeros are omitted. + */ std::ostream &operator << (std::ostream &os, const int64x64_t &val); +/** + * \ingroup highprec + * Input streamer for int64x64_t + */ std::istream &operator >> (std::istream &is, int64x64_t &val); +/** + * \ingroup highprec + * Absolute value. + */ inline int64x64_t Abs (const int64x64_t &value) { return (value < 0) ? -value : value; } +/** + * \ingroup highprec + * Minimum. + * + * \return The smaller of the arguments. + */ inline int64x64_t Min (const int64x64_t &a, const int64x64_t &b) { return (a < b) ? a : b; } - +/** + * \ingroup highprec + * Maximum. + * + * \return The larger of the arguments. + */ inline int64x64_t Max (const int64x64_t &a, const int64x64_t &b) { return (a > b) ? a : b; diff -Naur ns-3.19/src/core/model/list-scheduler.cc ns-3.20/src/core/model/list-scheduler.cc --- ns-3.19/src/core/model/list-scheduler.cc 2014-06-17 10:34:00.596635442 -0700 +++ ns-3.20/src/core/model/list-scheduler.cc 2014-06-17 10:33:13.926995707 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ListScheduler) - ; +NS_OBJECT_ENSURE_REGISTERED (ListScheduler); TypeId ListScheduler::GetTypeId (void) diff -Naur ns-3.19/src/core/model/log.cc ns-3.20/src/core/model/log.cc --- ns-3.19/src/core/model/log.cc 2014-06-17 10:34:00.597635434 -0700 +++ ns-3.20/src/core/model/log.cc 2014-06-17 10:33:13.928995691 -0700 @@ -36,8 +36,8 @@ namespace ns3 { -LogTimePrinter g_logTimePrinter = 0; -LogNodePrinter g_logNodePrinter = 0; +static LogTimePrinter g_logTimePrinter = 0; +static LogNodePrinter g_logNodePrinter = 0; typedef std::map ComponentList; typedef std::map::iterator ComponentListI; @@ -84,10 +84,11 @@ } -LogComponent::LogComponent (const std::string & name) - : m_levels (0), m_name (name) +LogComponent::LogComponent (const std::string & name, + const enum LogLevel mask /* = 0 */) + : m_levels (0), m_mask (mask), m_name (name) { - EnvVarCheck (name); + EnvVarCheck (); ComponentList *components = GetComponentList (); for (ComponentListI i = components->begin (); @@ -103,7 +104,7 @@ } void -LogComponent::EnvVarCheck (const std::string & name) +LogComponent::EnvVarCheck (void) { #ifdef HAVE_GETENV char *envVar = getenv ("NS_LOG"); @@ -112,7 +113,6 @@ return; } std::string env = envVar; - std::string myName = name; std::string::size_type cur = 0; std::string::size_type next = 0; @@ -125,7 +125,7 @@ if (equal == std::string::npos) { component = tmp; - if (component == myName || component == "*" || component == "***") + if (component == m_name || component == "*" || component == "***") { int level = LOG_LEVEL_ALL | LOG_PREFIX_ALL; Enable ((enum LogLevel)level); @@ -135,7 +135,7 @@ else { component = tmp.substr (0, equal); - if (component == myName || component == "*") + if (component == m_name || component == "*") { int level = 0; std::string::size_type cur_lev; @@ -242,7 +242,7 @@ bool -LogComponent::IsEnabled (enum LogLevel level) const +LogComponent::IsEnabled (const enum LogLevel level) const { // LogComponentEnableEnvVar (); return (level & m_levels) ? 1 : 0; @@ -254,14 +254,20 @@ return m_levels == 0; } +void +LogComponent::SetMask (const enum LogLevel level) +{ + m_mask |= level; +} + void -LogComponent::Enable (enum LogLevel level) +LogComponent::Enable (const enum LogLevel level) { - m_levels |= level; + m_levels |= (level & ~m_mask); } void -LogComponent::Disable (enum LogLevel level) +LogComponent::Disable (const enum LogLevel level) { m_levels &= ~level; } @@ -272,8 +278,9 @@ return m_name.c_str (); } +/* static */ std::string -LogComponent::GetLevelLabel(const enum LogLevel level) const +LogComponent::GetLevelLabel(const enum LogLevel level) { if (level == LOG_ERROR) { @@ -580,8 +587,7 @@ ParameterLogger::ParameterLogger (std::ostream &os) - : std::basic_ostream (os.rdbuf ()), //!< \bugid{1792} - m_itemNumber (0), + : m_first (true), m_os (os) { } diff -Naur ns-3.19/src/core/model/log.h ns-3.20/src/core/model/log.h --- ns-3.19/src/core/model/log.h 2014-06-17 10:34:00.598635426 -0700 +++ ns-3.20/src/core/model/log.h 2014-06-17 10:33:13.928995691 -0700 @@ -26,11 +26,15 @@ #include #include +#include "log-macros-enabled.h" +#include "log-macros-disabled.h" + namespace ns3 { /** * \ingroup debugging * \defgroup logging Logging + * * \brief Logging functions and macros * * LOG functionality: macros which allow developers to @@ -59,85 +63,90 @@ * Use NS_LOG_FUNCTION_NOARGS() only in static functions. */ - /** * \ingroup logging * * Logging severity classes and levels. */ enum LogLevel { - LOG_NONE = 0x00000000, // no logging + LOG_NONE = 0x00000000, //!< no logging - LOG_ERROR = 0x00000001, // serious error messages only + LOG_ERROR = 0x00000001, //!< serious error messages only LOG_LEVEL_ERROR = 0x00000001, - LOG_WARN = 0x00000002, // warning messages + LOG_WARN = 0x00000002, //!< warning messages LOG_LEVEL_WARN = 0x00000003, - LOG_DEBUG = 0x00000004, // rare ad-hoc debug messages + LOG_DEBUG = 0x00000004, //!< rare ad-hoc debug messages LOG_LEVEL_DEBUG = 0x00000007, - LOG_INFO = 0x00000008, // informational messages (e.g., banners) + LOG_INFO = 0x00000008, //!< informational messages (e.g., banners) LOG_LEVEL_INFO = 0x0000000f, - LOG_FUNCTION = 0x00000010, // function tracing + LOG_FUNCTION = 0x00000010, //!< function tracing LOG_LEVEL_FUNCTION = 0x0000001f, - LOG_LOGIC = 0x00000020, // control flow tracing within functions + LOG_LOGIC = 0x00000020, //!< control flow tracing within functions LOG_LEVEL_LOGIC = 0x0000003f, - LOG_ALL = 0x0fffffff, // print everything + LOG_ALL = 0x0fffffff, //!< print everything LOG_LEVEL_ALL = LOG_ALL, - LOG_PREFIX_FUNC = 0x80000000, // prefix all trace prints with function - LOG_PREFIX_TIME = 0x40000000, // prefix all trace prints with simulation time - LOG_PREFIX_NODE = 0x20000000, // prefix all trace prints with simulation node - LOG_PREFIX_LEVEL = 0x10000000, // prefix all trace prints with log level (severity) - LOG_PREFIX_ALL = 0xf0000000 // all prefixes + LOG_PREFIX_FUNC = 0x80000000, //!< prefix all trace prints with function + LOG_PREFIX_TIME = 0x40000000, //!< prefix all trace prints with simulation time + LOG_PREFIX_NODE = 0x20000000, //!< prefix all trace prints with simulation node + LOG_PREFIX_LEVEL = 0x10000000, //!< prefix all trace prints with log level (severity) + LOG_PREFIX_ALL = 0xf0000000 //!< all prefixes }; /** - * \param name a log component name - * \param level a logging level * \ingroup logging * * Enable the logging output associated with that log component. + * * The logging output can be later disabled with a call * to ns3::LogComponentDisable. * * Same as running your program with the NS_LOG environment * variable set as NS_LOG='name=level' + * + * \param name a log component name + * \param level a logging level */ void LogComponentEnable (char const *name, enum LogLevel level); /** - * \param level a logging level * \ingroup logging * * Enable the logging output for all registered log components. * * Same as running your program with the NS_LOG environment * variable set as NS_LOG='*=level' + * + * \param level a logging level */ void LogComponentEnableAll (enum LogLevel level); /** - * \param name a log component name - * \param level a logging level * \ingroup logging * * Disable the logging output associated with that log component. + * * The logging output can be later re-enabled with a call * to ns3::LogComponentEnable. + * + * \param name a log component name + * \param level a logging level */ void LogComponentDisable (char const *name, enum LogLevel level); /** - * \param level a logging level * \ingroup logging * * Disable all logging for all components. + * + * \param level a logging level */ void LogComponentDisableAll (enum LogLevel level); @@ -146,7 +155,6 @@ /** * \ingroup logging - * \param name a string * * Define a Log component with a specific name. * @@ -157,143 +165,60 @@ * ns3::LogComponentDisable functions or with the NS_LOG * environment variable. * - * To create a log component Foo, at the top of foo.cc: - * - * \code - * NS_LOG_COMPONENT_DEFINE ("Foo") - * ; - * \endcode - * - * Note the closing ';' is not on the same line; this prevents - * Doxygen from spuriously warning that the macro invocation is undocumented. - + * \param name a string */ #define NS_LOG_COMPONENT_DEFINE(name) \ static ns3::LogComponent g_log = ns3::LogComponent (name) /** * \ingroup logging - * Append the simulation time to a log message. - */ -#define NS_LOG_APPEND_TIME_PREFIX \ - if (g_log.IsEnabled (ns3::LOG_PREFIX_TIME)) \ - { \ - ns3::LogTimePrinter printer = ns3::LogGetTimePrinter (); \ - if (printer != 0) \ - { \ - (*printer)(std::clog); \ - std::clog << " "; \ - } \ - } - -/** - * \ingroup logging - * Append the simulation node id to a log message. - */ -#define NS_LOG_APPEND_NODE_PREFIX \ - if (g_log.IsEnabled (ns3::LOG_PREFIX_NODE)) \ - { \ - ns3::LogNodePrinter printer = ns3::LogGetNodePrinter (); \ - if (printer != 0) \ - { \ - (*printer)(std::clog); \ - std::clog << " "; \ - } \ - } - -/** - * \ingroup logging - * Append the function name to a log message. - */ -#define NS_LOG_APPEND_FUNC_PREFIX \ - if (g_log.IsEnabled (ns3::LOG_PREFIX_FUNC)) \ - { \ - std::clog << g_log.Name () << ":" << \ - __FUNCTION__ << "(): "; \ - } \ - -/** - * \ingroup logging - * Append the log severity level to a log message. - */ -#define NS_LOG_APPEND_LEVEL_PREFIX(level) \ - if (g_log.IsEnabled (ns3::LOG_PREFIX_LEVEL)) \ - { \ - std::clog << "[" << g_log.GetLevelLabel (level) << "] "; \ - } \ - - -#ifndef NS_LOG_APPEND_CONTEXT -#define NS_LOG_APPEND_CONTEXT -#endif /* NS_LOG_APPEND_CONTEXT */ - - - -#ifdef NS3_LOG_ENABLE - - - -/** - * \ingroup logging - * \param level the log level - * \param msg the message to log * - * This macro allows you to log an arbitrary message at a specific - * log level. The log message is expected to be a C++ ostream - * message such as "my string" << aNumber << "my oth stream". - * - * Typical usage looks like: - * \code - * NS_LOG (LOG_DEBUG, "a number="< ParameterLogger& operator<< (T param) { - switch (m_itemNumber) + if (m_first) { - case 0: // first parameter m_os << param; - break; - default: // parameter following a previous parameter + m_first = false; + } + else + { m_os << ", " << param; - break; } - m_itemNumber++; return *this; } }; diff -Naur ns-3.19/src/core/model/log-macros-disabled.h ns-3.20/src/core/model/log-macros-disabled.h --- ns-3.19/src/core/model/log-macros-disabled.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/core/model/log-macros-disabled.h 2014-06-17 10:33:13.927995699 -0700 @@ -0,0 +1,50 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Andrey Mazo + * + * 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: Andrey Mazo + */ + +#ifndef NS3_LOG_MACROS_DISABLED_H +#define NS3_LOG_MACROS_DISABLED_H + +#ifndef NS3_LOG_ENABLE + +#define NS_LOG_NOOP_INTERNAL(msg) \ + do \ + { \ + if (false) \ + { \ + std::clog << msg; \ + } \ + } \ + while (false) + +#define NS_LOG(level, msg) \ + NS_LOG_NOOP_INTERNAL (msg) + +#define NS_LOG_FUNCTION_NOARGS() + +#define NS_LOG_FUNCTION(parameters) \ + NS_LOG_NOOP_INTERNAL (parameters) + +#define NS_LOG_UNCOND(msg) \ + NS_LOG_NOOP_INTERNAL (msg) + + +#endif /* !NS3_LOG_ENABLE */ + +#endif /* NS3_LOG_MACROS_DISABLED_H */ diff -Naur ns-3.19/src/core/model/log-macros-enabled.h ns-3.20/src/core/model/log-macros-enabled.h --- ns-3.19/src/core/model/log-macros-enabled.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/core/model/log-macros-enabled.h 2014-06-17 10:33:13.927995699 -0700 @@ -0,0 +1,224 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2006,2007 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: Mathieu Lacage + */ + +#ifndef NS3_LOG_MACROS_ENABLED_H +#define NS3_LOG_MACROS_ENABLED_H + +#ifdef NS3_LOG_ENABLE + + +/** + * \ingroup logging + * Append the simulation time to a log message. + * \internal + * Logging implementation macro; should not be called directly. + */ +#define NS_LOG_APPEND_TIME_PREFIX \ + if (g_log.IsEnabled (ns3::LOG_PREFIX_TIME)) \ + { \ + ns3::LogTimePrinter printer = ns3::LogGetTimePrinter (); \ + if (printer != 0) \ + { \ + (*printer)(std::clog); \ + std::clog << " "; \ + } \ + } + +/** + * \ingroup logging + * Append the simulation node id to a log message. + * \internal + * Logging implementation macro; should not be called directly. + */ +#define NS_LOG_APPEND_NODE_PREFIX \ + if (g_log.IsEnabled (ns3::LOG_PREFIX_NODE)) \ + { \ + ns3::LogNodePrinter printer = ns3::LogGetNodePrinter (); \ + if (printer != 0) \ + { \ + (*printer)(std::clog); \ + std::clog << " "; \ + } \ + } + +/** + * \ingroup logging + * Append the function name to a log message. + * \internal + * Logging implementation macro; should not be called directly. + */ +#define NS_LOG_APPEND_FUNC_PREFIX \ + if (g_log.IsEnabled (ns3::LOG_PREFIX_FUNC)) \ + { \ + std::clog << g_log.Name () << ":" << \ + __FUNCTION__ << "(): "; \ + } \ + +/** + * \ingroup logging + * Append the log severity level to a log message. + * \internal + * Logging implementation macro; should not be called directly. + */ +#define NS_LOG_APPEND_LEVEL_PREFIX(level) \ + if (g_log.IsEnabled (ns3::LOG_PREFIX_LEVEL)) \ + { \ + std::clog << "[" << g_log.GetLevelLabel (level) << "] "; \ + } \ + + +#ifndef NS_LOG_APPEND_CONTEXT +/** + * \ingroup logging + * Append the node id to a log message. + * + * This is implemented locally in `.cc` files because + * the the relevant variable is only known there. + * + * Preferred format is something like (assuming the node id is + * accessible from `var`: + * \code + * if (var) + * { + * std::clog << "[node " << var->GetObject ()->GetId () << "] "; + * } + * \endcode + * + * \internal + * Logging implementation macro; should not be called directly. + * + */ +#define NS_LOG_APPEND_CONTEXT +#endif /* NS_LOG_APPEND_CONTEXT */ + + +/** + * \ingroup logging + * + * This macro allows you to log an arbitrary message at a specific + * log level. + * + * The log message is expected to be a C++ ostream + * message such as "my string" << aNumber << "my oth stream". + * + * Typical usage looks like: + * \code + * NS_LOG (LOG_DEBUG, "a number="< o` */ - inline int Compare (const Time &o) const + inline int Compare (const Time & o) const { return (m_data < o.m_data) ? -1 : (m_data == o.m_data) ? 0 : 1; } @@ -445,7 +443,7 @@ { return To (timeUnit).GetDouble (); } - static inline Time From (const int64x64_t &from, enum Unit timeUnit) + static inline Time From (const int64x64_t & from, enum Unit timeUnit) { struct Information *info = PeekInformation (timeUnit); // DO NOT REMOVE this temporary variable. It's here @@ -479,7 +477,7 @@ { return int64x64_t (m_data); } - explicit inline Time (const int64x64_t &value) + explicit inline Time (const int64x64_t & value) : m_data (value.GetHigh ()) { if (g_markingTimes) @@ -487,11 +485,25 @@ Mark (this); } } - inline static Time From (const int64x64_t &value) + inline static Time From (const int64x64_t & value) { return Time (value); } + /** + * Attach a unit to a Time, to facilitate output in a specific unit. + * + * For example, + * \code + * Time t (3.14e9); // Pi seconds + * std::cout << t.As (Time::MS) << std::endl; + * \endcode + * will print ``+3140.0ms`` + * + * \param unit [in] The unit to use. + */ + TimeWithUnit As (const enum Unit unit) const; + private: /** * How to convert between other units and the current unit @@ -516,11 +528,11 @@ static inline struct Resolution *PeekResolution (void) { static struct Time::Resolution resolution = SetDefaultNsResolution (); - return &resolution; + return & resolution; } static inline struct Information *PeekInformation (enum Unit timeUnit) { - return &(PeekResolution ()->info[timeUnit]); + return & (PeekResolution ()->info[timeUnit]); } static struct Resolution SetDefaultNsResolution (void); @@ -531,7 +543,7 @@ * Record all instances of Time, so we can rescale them when * the resolution changes. * - * \intern + * \internal * * We use a std::set so we can remove the record easily when * ~Time() is called. @@ -543,7 +555,7 @@ * [Stack Overflow](http://stackoverflow.com/questions/5526019/compile-errors-stdset-with-const-members) * says otherwise, quoting the standard: * - * > §23.1/3 states that std::set key types must be assignable + * > & sect;23.1/3 states that std::set key types must be assignable * > and copy constructable; clearly a const type will not be assignable. */ typedef std::set< Time * > MarkedTimes; @@ -551,7 +563,7 @@ * Record of outstanding Time objects which will need conversion * when the resolution is set. * - * \intern + * \internal * * Use a classic static variable so we can check in Time ctors * without a function call. @@ -576,7 +588,7 @@ /** * Remove all MarkedTimes. * - * \intern + * \internal * Has to be visible to the Simulator class, hence the friending. */ static void ClearMarkedTimes (); @@ -593,19 +605,23 @@ */ static void ConvertTimes (const enum Unit unit); - friend bool operator == (const Time &lhs, const Time &rhs); - friend bool operator != (const Time &lhs, const Time &rhs); - friend bool operator <= (const Time &lhs, const Time &rhs); - friend bool operator >= (const Time &lhs, const Time &rhs); - friend bool operator < (const Time &lhs, const Time &rhs); - friend bool operator > (const Time &lhs, const Time &rhs); - friend Time operator + (const Time &lhs, const Time &rhs); - friend Time operator - (const Time &lhs, const Time &rhs); - friend Time &operator += (Time &lhs, const Time &rhs); - friend Time &operator -= (Time &lhs, const Time &rhs); - friend Time Abs (const Time &time); - friend Time Max (const Time &ta, const Time &tb); - friend Time Min (const Time &ta, const Time &tb); + friend bool operator == (const Time & lhs, const Time & rhs); + friend bool operator != (const Time & lhs, const Time & rhs); + friend bool operator <= (const Time & lhs, const Time & rhs); + friend bool operator >= (const Time & lhs, const Time & rhs); + friend bool operator < (const Time & lhs, const Time & rhs); + friend bool operator > (const Time & lhs, const Time & rhs); + friend Time operator + (const Time & lhs, const Time & rhs); + friend Time operator - (const Time & lhs, const Time & rhs); + friend Time operator * (const Time & lhs, const int64_t & rhs); + friend Time operator * (const int64_t & lhs, const Time & rhs); + friend int64_t operator / (const Time & lhs, const Time & rhs); + friend Time operator / (const Time & lhs, const int64_t & rhs); + friend Time & operator += (Time & lhs, const Time & rhs); + friend Time & operator -= (Time & lhs, const Time & rhs); + friend Time Abs (const Time & time); + friend Time Max (const Time & ta, const Time & tb); + friend Time Min (const Time & ta, const Time & tb); int64_t m_data; //!< Virtual time value, in the current unit. @@ -613,105 +629,136 @@ }; // class Time -// Force static initialization of Time +/// Force static initialization of Time static bool NS_UNUSED_GLOBAL (g_TimeStaticInit) = Time::StaticInit (); inline bool -operator == (const Time &lhs, const Time &rhs) +operator == (const Time & lhs, const Time & rhs) { return lhs.m_data == rhs.m_data; } inline bool -operator != (const Time &lhs, const Time &rhs) +operator != (const Time & lhs, const Time & rhs) { return lhs.m_data != rhs.m_data; } inline bool -operator <= (const Time &lhs, const Time &rhs) +operator <= (const Time & lhs, const Time & rhs) { return lhs.m_data <= rhs.m_data; } inline bool -operator >= (const Time &lhs, const Time &rhs) +operator >= (const Time & lhs, const Time & rhs) { return lhs.m_data >= rhs.m_data; } inline bool -operator < (const Time &lhs, const Time &rhs) +operator < (const Time & lhs, const Time & rhs) { return lhs.m_data < rhs.m_data; } inline bool -operator > (const Time &lhs, const Time &rhs) +operator > (const Time & lhs, const Time & rhs) { return lhs.m_data > rhs.m_data; } -inline Time operator + (const Time &lhs, const Time &rhs) +inline Time operator + (const Time & lhs, const Time & rhs) { return Time (lhs.m_data + rhs.m_data); } -inline Time operator - (const Time &lhs, const Time &rhs) +inline Time operator - (const Time & lhs, const Time & rhs) { return Time (lhs.m_data - rhs.m_data); } -inline Time &operator += (Time &lhs, const Time &rhs) +inline Time +operator * (const Time & lhs, const int64_t & rhs) +{ + Time res = lhs; + res.m_data *= rhs; + return res; +} +inline Time +operator * (const int64_t & lhs, const Time & rhs) +{ + Time res = rhs; + res.m_data *= lhs; + return res; +} +inline int64_t +operator / (const Time & lhs, const Time & rhs) +{ + int64_t res = lhs.m_data / rhs.m_data; + return res; +} +inline Time +operator / (const Time & lhs, const int64_t & rhs) +{ + Time res = lhs; + res.m_data /= rhs; + return res; +} +inline Time & operator += (Time & lhs, const Time & rhs) { lhs.m_data += rhs.m_data; return lhs; } -inline Time &operator -= (Time &lhs, const Time &rhs) +inline Time & operator -= (Time & lhs, const Time & rhs) { lhs.m_data -= rhs.m_data; return lhs; } /** - * \anchor ns3-Time-Abs - * \relates ns3::TimeUnit - * Absolute value function for Time - * \param time the input value - * \returns the absolute value of the input value. - */ -inline Time Abs (const Time &time) -{ - return Time ((time.m_data < 0) ? -time.m_data : time.m_data); -} -/** - * \anchor ns3-Time-Max - * \relates ns3::TimeUnit + * Max function for Time. * \param ta the first value * \param tb the seconds value * \returns the max of the two input values. */ -inline Time Max (const Time &ta, const Time &tb) +inline Time Max (const Time & ta, const Time & tb) { return Time ((ta.m_data < tb.m_data) ? tb : ta); } /** + * Min function for Time. * \param ta the first value * \param tb the seconds value * \returns the min of the two input values. */ -inline Time Min (const Time &ta, const Time &tb) +inline Time Min (const Time & ta, const Time & tb) { return Time ((ta.m_data > tb.m_data) ? tb : ta); } +/** + * Absolute value function for Time + * \param time the input value + * \returns the absolute value of the input value. + */ +inline Time Abs (const Time & time) +{ + return Time ((time.m_data < 0) ? -time.m_data : time.m_data); +} /** * \brief Time output streamer. * - * Generates output such as "3.96ns" - * \relates ns3::Time + * Generates output such as "3.96ns". Times are printed with the + * following format flags (independent of the stream flags): + * - `showpos` + * - `fixed` + * - `left` + * The stream `width` and `precision` are ignored; Time output always + * includes ".0". + * \relates Time */ -std::ostream& operator<< (std::ostream& os, const Time & time); +std::ostream & operator<< (std::ostream & os, const Time & time); /** * \brief Time input streamer * * Uses the Time::Time (const std::string &) constructor - * \relates ns3::Time + * \relates Time */ -std::istream& operator>> (std::istream& is, Time & time); +std::istream & operator>> (std::istream & is, Time & time); /** * \brief create ns3::Time instances in units of seconds. @@ -722,7 +769,7 @@ * Simulator::Schedule (Seconds (5.0), ...); * \endcode * \param seconds seconds value - * \relates ns3::Time + * \relates Time */ inline Time Seconds (double seconds) { @@ -738,7 +785,7 @@ * Simulator::Schedule (MilliSeconds (5), ...); * \endcode * \param ms milliseconds value - * \relates ns3::Time + * \relates Time */ inline Time MilliSeconds (uint64_t ms) { @@ -753,7 +800,7 @@ * Simulator::Schedule (MicroSeconds (5), ...); * \endcode * \param us microseconds value - * \relates ns3::Time + * \relates Time */ inline Time MicroSeconds (uint64_t us) { @@ -768,7 +815,7 @@ * Simulator::Schedule (NanoSeconds (5), ...); * \endcode * \param ns nanoseconds value - * \relates ns3::Time + * \relates Time */ inline Time NanoSeconds (uint64_t ns) { @@ -783,7 +830,7 @@ * Simulator::Schedule (PicoSeconds (5), ...); * \endcode * \param ps picoseconds value - * \relates ns3::Time + * \relates Time */ inline Time PicoSeconds (uint64_t ps) { @@ -798,7 +845,7 @@ * Simulator::Schedule (FemtoSeconds (5), ...); * \endcode * \param fs femtoseconds value - * \relates ns3::Time + * \relates Time */ inline Time FemtoSeconds (uint64_t fs) { @@ -813,7 +860,7 @@ * Simulator::Schedule (Minutes (5.0), ...); * \endcode * \param minutes mintues value - * \relates ns3::Time + * \relates Time */ inline Time Minutes (double minutes) { @@ -828,7 +875,7 @@ * Simulator::Schedule (Hours (5.0), ...); * \endcode * \param hours hours value - * \relates ns3::Time + * \relates Time */ inline Time Hours (double hours) { @@ -843,7 +890,7 @@ * Simulator::Schedule (Days (5.0), ...); * \endcode * \param days days value - * \relates ns3::Time + * \relates Time */ inline Time Days (double days) { @@ -858,7 +905,7 @@ * Simulator::Schedule (Years (5.0), ...); * \endcode * \param years years value - * \relates ns3::Time + * \relates Time */ inline Time Years (double years) { @@ -867,7 +914,7 @@ /** * \see Seconds(double) - * \relates ns3::Time + * \relates Time */ inline Time Seconds (int64x64_t seconds) { @@ -875,7 +922,7 @@ } /** * \see MilliSeconds(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time MilliSeconds (int64x64_t ms) { @@ -883,7 +930,7 @@ } /** * \see MicroSeconds(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time MicroSeconds (int64x64_t us) { @@ -891,7 +938,7 @@ } /** * \see NanoSeconds(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time NanoSeconds (int64x64_t ns) { @@ -899,7 +946,7 @@ } /** * \see PicoSeconds(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time PicoSeconds (int64x64_t ps) { @@ -907,7 +954,7 @@ } /** * \see FemtoSeconds(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time FemtoSeconds (int64x64_t fs) { @@ -915,7 +962,7 @@ } /** * \see Minutes(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time Minutes (int64x64_t minutes) { @@ -923,7 +970,7 @@ } /** * \see Minutes(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time Hours (int64x64_t hours) { @@ -931,7 +978,7 @@ } /** * \see Minutes(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time Days (int64x64_t days) { @@ -939,7 +986,7 @@ } /** * \see Minutes(uint64_t) - * \relates ns3::Time + * \relates Time */ inline Time Years (int64x64_t years) { @@ -991,6 +1038,32 @@ return MakeTimeChecker (min, Time::Max ()); } +/** + * \ingroup time + * \brief A Time with attached unit, to facilitate output in that unit. + */ +class TimeWithUnit +{ +public: + /** + * Attach a unit to a Time + * + * \param [in] time The time. + * \param [in] unit The unit to use for output + */ + TimeWithUnit (const Time time, const Time::Unit unit) + : m_time (time), + m_unit (unit) + { }; + +private: + Time m_time; //!< The time + Time::Unit m_unit; //!< The unit to use in output + + /// Output streamer + friend std::ostream & operator << (std::ostream & os, const TimeWithUnit & time); + +}; // class TimeWithUnit } // namespace ns3 diff -Naur ns-3.19/src/core/model/object-base.cc ns-3.20/src/core/model/object-base.cc --- ns-3.19/src/core/model/object-base.cc 2014-06-17 10:34:00.602635395 -0700 +++ ns-3.20/src/core/model/object-base.cc 2014-06-17 10:33:13.933995653 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ObjectBase) - ; +NS_OBJECT_ENSURE_REGISTERED (ObjectBase); static TypeId GetObjectIid (void) @@ -76,13 +75,29 @@ struct TypeId::AttributeInformation info = tid.GetAttribute(i); NS_LOG_DEBUG ("try to construct \""<< tid.GetName ()<<"::"<< info.name <<"\""); + // is this attribute stored in this AttributeConstructionList instance ? + Ptr value = attributes.Find(info.checker); + // See if this attribute should not be set here in the + // constructor. if (!(info.flags & TypeId::ATTR_CONSTRUCT)) { - continue; + // Handle this attribute if it should not be + // set here. + if (value == 0) + { + // Skip this attribute if it's not in the + // AttributeConstructionList. + continue; + } + else + { + // This is an error because this attribute is not + // settable in its constructor but is present in + // the AttributeConstructionList. + NS_FATAL_ERROR ("Attribute name="< value = attributes.Find(info.checker); if (value != 0) { // We have a matching attribute value. diff -Naur ns-3.19/src/core/model/object-base.h ns-3.20/src/core/model/object-base.h --- ns-3.19/src/core/model/object-base.h 2014-06-17 10:34:00.602635395 -0700 +++ ns-3.20/src/core/model/object-base.h 2014-06-17 10:33:13.933995653 -0700 @@ -26,23 +26,14 @@ #include /** + * \ingroup object * \brief Register the class in the ns-3 factory. * * This macro should be invoked once for every class which * defines a new GetTypeId method. * - * Given a class Foo, the .cc implementation should begin - * - * \code - * NS_OBJECT_ENSURE_REGISTERED (Foo) - * ; - * \endcode - * * If the class is in a namespace, then the macro call should also be * in the namespace. - * - * Note the closing ';' is not on the same line; this prevents - * Doxygen from spuriously warning that the macro invocation is undocumented. */ #define NS_OBJECT_ENSURE_REGISTERED(type) \ static struct X ## type ## RegistrationClass \ diff -Naur ns-3.19/src/core/model/object.cc ns-3.20/src/core/model/object.cc --- ns-3.19/src/core/model/object.cc 2014-06-17 10:34:00.605635372 -0700 +++ ns-3.20/src/core/model/object.cc 2014-06-17 10:33:13.936995630 -0700 @@ -41,8 +41,7 @@ * The Object implementation *********************************************************************/ -NS_OBJECT_ENSURE_REGISTERED (Object) - ; +NS_OBJECT_ENSURE_REGISTERED (Object); Object::AggregateIterator::AggregateIterator () : m_object (0), diff -Naur ns-3.19/src/core/model/object-factory.cc ns-3.20/src/core/model/object-factory.cc --- ns-3.19/src/core/model/object-factory.cc 2014-06-17 10:34:00.603635387 -0700 +++ ns-3.20/src/core/model/object-factory.cc 2014-06-17 10:33:13.933995653 -0700 @@ -23,8 +23,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE("ObjectFactory") - ; +NS_LOG_COMPONENT_DEFINE("ObjectFactory"); ObjectFactory::ObjectFactory () { diff -Naur ns-3.19/src/core/model/object.h ns-3.20/src/core/model/object.h --- ns-3.19/src/core/model/object.h 2014-06-17 10:34:00.606635364 -0700 +++ ns-3.20/src/core/model/object.h 2014-06-17 10:33:13.936995630 -0700 @@ -46,6 +46,7 @@ /** * \ingroup core * \defgroup object Object + * \brief Base classes which provides memory management and object aggregation. */ /** * \ingroup object diff -Naur ns-3.19/src/core/model/ptr.h ns-3.20/src/core/model/ptr.h --- ns-3.19/src/core/model/ptr.h 2014-06-17 10:34:00.607635357 -0700 +++ ns-3.20/src/core/model/ptr.h 2014-06-17 10:33:13.937995622 -0700 @@ -30,6 +30,7 @@ /** * \ingroup core * \defgroup ptr Smart Pointer + * \brief Heap memory management. */ /** * \ingroup ptr diff -Naur ns-3.19/src/core/model/random-variable.cc ns-3.20/src/core/model/random-variable.cc --- ns-3.19/src/core/model/random-variable.cc 2014-06-17 10:34:00.610635334 -0700 +++ ns-3.20/src/core/model/random-variable.cc 2014-06-17 10:33:13.940995599 -0700 @@ -44,8 +44,7 @@ // ----------------------------------------------------------------------------- // RandomVariableBase methods -NS_LOG_COMPONENT_DEFINE ("RandomVariable") - ; +NS_LOG_COMPONENT_DEFINE ("RandomVariable"); /** \ingroup legacyrandom */ class RandomVariableBase @@ -1362,7 +1361,7 @@ * \brief Constructor * * Creates a generator that returns successive elements of the d array - * on successive calls to ::Value(). Note that the d pointer is copied + * on successive calls to GetValue(). Note that the d pointer is copied * for use by the generator (shallow-copy), not its contents, so the * contents of the array d points to have to remain unchanged for the use * of DeterministicVariableImpl to be meaningful. @@ -1861,7 +1860,7 @@ ZipfVariableImpl (long n, double alpha); /** - * \A zipf variable with N=1 and alpha=0 + * A zipf variable with N=1 and alpha=0 */ ZipfVariableImpl (); @@ -1953,7 +1952,7 @@ ZetaVariableImpl (double alpha); /** - * \A zipf variable with alpha=1.1 + * A zipf variable with alpha=1.1 */ ZetaVariableImpl (); diff -Naur ns-3.19/src/core/model/random-variable-stream.cc ns-3.20/src/core/model/random-variable-stream.cc --- ns-3.19/src/core/model/random-variable-stream.cc 2014-06-17 10:34:00.608635349 -0700 +++ ns-3.20/src/core/model/random-variable-stream.cc 2014-06-17 10:33:13.938995614 -0700 @@ -40,8 +40,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (RandomVariableStream) - ; +NS_OBJECT_ENSURE_REGISTERED (RandomVariableStream); TypeId RandomVariableStream::GetTypeId (void) @@ -131,8 +130,7 @@ return m_rng; } -NS_OBJECT_ENSURE_REGISTERED(UniformRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(UniformRandomVariable); TypeId UniformRandomVariable::GetTypeId (void) @@ -202,8 +200,7 @@ return (uint32_t)GetValue (m_min, m_max + 1); } -NS_OBJECT_ENSURE_REGISTERED(ConstantRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(ConstantRandomVariable); TypeId ConstantRandomVariable::GetTypeId (void) @@ -257,8 +254,7 @@ return (uint32_t)GetValue (m_constant); } -NS_OBJECT_ENSURE_REGISTERED(SequentialRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(SequentialRandomVariable); TypeId SequentialRandomVariable::GetTypeId (void) @@ -357,8 +353,7 @@ return (uint32_t)GetValue (); } -NS_OBJECT_ENSURE_REGISTERED(ExponentialRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(ExponentialRandomVariable); TypeId ExponentialRandomVariable::GetTypeId (void) @@ -439,8 +434,7 @@ return (uint32_t)GetValue (m_mean, m_bound); } -NS_OBJECT_ENSURE_REGISTERED(ParetoRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(ParetoRandomVariable); TypeId ParetoRandomVariable::GetTypeId (void) @@ -535,8 +529,7 @@ return (uint32_t)GetValue (m_mean, m_shape, m_bound); } -NS_OBJECT_ENSURE_REGISTERED(WeibullRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(WeibullRandomVariable); TypeId WeibullRandomVariable::GetTypeId (void) @@ -629,8 +622,7 @@ return (uint32_t)GetValue (m_scale, m_shape, m_bound); } -NS_OBJECT_ENSURE_REGISTERED(NormalRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(NormalRandomVariable); const double NormalRandomVariable::INFINITE_VALUE = 1e307; @@ -749,8 +741,7 @@ return (uint32_t)GetValue (m_mean, m_variance, m_bound); } -NS_OBJECT_ENSURE_REGISTERED(LogNormalRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(LogNormalRandomVariable); TypeId LogNormalRandomVariable::GetTypeId (void) @@ -869,8 +860,7 @@ return (uint32_t)GetValue (m_mu, m_sigma); } -NS_OBJECT_ENSURE_REGISTERED(GammaRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(GammaRandomVariable); TypeId GammaRandomVariable::GetTypeId (void) @@ -1045,8 +1035,7 @@ } } -NS_OBJECT_ENSURE_REGISTERED(ErlangRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(ErlangRandomVariable); TypeId ErlangRandomVariable::GetTypeId (void) @@ -1157,8 +1146,7 @@ } } -NS_OBJECT_ENSURE_REGISTERED(TriangularRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(TriangularRandomVariable); TypeId TriangularRandomVariable::GetTypeId (void) @@ -1252,8 +1240,7 @@ return (uint32_t)GetValue (m_mean, m_min, m_max); } -NS_OBJECT_ENSURE_REGISTERED(ZipfRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(ZipfRandomVariable); TypeId ZipfRandomVariable::GetTypeId (void) @@ -1343,8 +1330,7 @@ return (uint32_t)GetValue (m_n, m_alpha); } -NS_OBJECT_ENSURE_REGISTERED(ZetaRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(ZetaRandomVariable); TypeId ZetaRandomVariable::GetTypeId (void) @@ -1427,8 +1413,7 @@ return (uint32_t)GetValue (m_alpha); } -NS_OBJECT_ENSURE_REGISTERED(DeterministicRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(DeterministicRandomVariable); TypeId DeterministicRandomVariable::GetTypeId (void) @@ -1500,8 +1485,7 @@ return (uint32_t)GetValue (); } -NS_OBJECT_ENSURE_REGISTERED(EmpiricalRandomVariable) - ; +NS_OBJECT_ENSURE_REGISTERED(EmpiricalRandomVariable); // ValueCDF methods EmpiricalRandomVariable::ValueCDF::ValueCDF () diff -Naur ns-3.19/src/core/model/realtime-simulator-impl.cc ns-3.20/src/core/model/realtime-simulator-impl.cc --- ns-3.19/src/core/model/realtime-simulator-impl.cc 2014-06-17 10:34:00.611635326 -0700 +++ ns-3.20/src/core/model/realtime-simulator-impl.cc 2014-06-17 10:33:13.942995584 -0700 @@ -43,8 +43,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (RealtimeSimulatorImpl) - ; +NS_OBJECT_ENSURE_REGISTERED (RealtimeSimulatorImpl); TypeId RealtimeSimulatorImpl::GetTypeId (void) diff -Naur ns-3.19/src/core/model/scheduler.cc ns-3.20/src/core/model/scheduler.cc --- ns-3.19/src/core/model/scheduler.cc 2014-06-17 10:34:00.614635302 -0700 +++ ns-3.20/src/core/model/scheduler.cc 2014-06-17 10:33:13.944995568 -0700 @@ -26,8 +26,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Scheduler) - ; +NS_OBJECT_ENSURE_REGISTERED (Scheduler); Scheduler::~Scheduler () { diff -Naur ns-3.19/src/core/model/scheduler.h ns-3.20/src/core/model/scheduler.h --- ns-3.19/src/core/model/scheduler.h 2014-06-17 10:34:00.614635302 -0700 +++ ns-3.20/src/core/model/scheduler.h 2014-06-17 10:33:13.945995560 -0700 @@ -31,6 +31,7 @@ /** * \ingroup core * \defgroup scheduler Scheduler and Events + * \brief Manage the event list by creating and scheduling events. */ /** * \ingroup scheduler diff -Naur ns-3.19/src/core/model/simulator.cc ns-3.20/src/core/model/simulator.cc --- ns-3.19/src/core/model/simulator.cc 2014-06-17 10:34:00.616635287 -0700 +++ ns-3.20/src/core/model/simulator.cc 2014-06-17 10:33:13.947995545 -0700 @@ -45,15 +45,15 @@ namespace ns3 { -GlobalValue g_simTypeImpl = GlobalValue ("SimulatorImplementationType", - "The object class to use as the simulator implementation", - StringValue ("ns3::DefaultSimulatorImpl"), - MakeStringChecker ()); +static GlobalValue g_simTypeImpl = GlobalValue ("SimulatorImplementationType", + "The object class to use as the simulator implementation", + StringValue ("ns3::DefaultSimulatorImpl"), + MakeStringChecker ()); -GlobalValue g_schedTypeImpl = GlobalValue ("SchedulerType", - "The object class to use as the scheduler implementation", - TypeIdValue (MapScheduler::GetTypeId ()), - MakeTypeIdChecker ()); +static GlobalValue g_schedTypeImpl = GlobalValue ("SchedulerType", + "The object class to use as the scheduler implementation", + TypeIdValue (MapScheduler::GetTypeId ()), + MakeTypeIdChecker ()); static void TimePrinter (std::ostream &os) diff -Naur ns-3.19/src/core/model/simulator.h ns-3.20/src/core/model/simulator.h --- ns-3.19/src/core/model/simulator.h 2014-06-17 10:34:00.616635287 -0700 +++ ns-3.20/src/core/model/simulator.h 2014-06-17 10:33:13.947995545 -0700 @@ -40,6 +40,7 @@ /** * \ingroup core * \defgroup simulator Simulator + * \brief Control the virtual time and the execution of simulation events. */ /** * \ingroup simulator diff -Naur ns-3.19/src/core/model/string.h ns-3.20/src/core/model/string.h --- ns-3.19/src/core/model/string.h 2014-06-17 10:34:00.617635279 -0700 +++ ns-3.20/src/core/model/string.h 2014-06-17 10:33:13.948995537 -0700 @@ -15,7 +15,6 @@ * This class can be used to hold variables of type string, * that is, either char * or std::string. */ - ATTRIBUTE_VALUE_DEFINE_WITH_NAME (std::string, String); ATTRIBUTE_ACCESSOR_DEFINE (String); ATTRIBUTE_CHECKER_DEFINE (String); diff -Naur ns-3.19/src/core/model/synchronizer.cc ns-3.20/src/core/model/synchronizer.cc --- ns-3.19/src/core/model/synchronizer.cc 2014-06-17 10:34:00.618635272 -0700 +++ ns-3.20/src/core/model/synchronizer.cc 2014-06-17 10:33:13.948995537 -0700 @@ -23,8 +23,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Synchronizer) - ; +NS_OBJECT_ENSURE_REGISTERED (Synchronizer); TypeId Synchronizer::GetTypeId (void) diff -Naur ns-3.19/src/core/model/test.cc ns-3.20/src/core/model/test.cc --- ns-3.19/src/core/model/test.cc 2014-06-17 10:34:00.621635249 -0700 +++ ns-3.20/src/core/model/test.cc 2014-06-17 10:33:13.952995506 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Test") - ; +NS_LOG_COMPONENT_DEFINE ("Test"); bool TestDoubleIsEqual (const double x1, const double x2, const double epsilon) @@ -73,6 +72,18 @@ std::string file; int32_t line; }; +std::ostream & operator << (std::ostream & os, const TestCaseFailure & failure) +{ + os << " test=\"" << failure.cond + << "\" actual=\"" << failure.actual + << "\" limit=\"" << failure.limit + << "\" in=\"" << failure.file + << ":" << failure.line + << "\" " << failure.message; + + return os; +} + struct TestCase::Result { Result (); @@ -244,6 +255,12 @@ NS_LOG_FUNCTION (this); return m_name; } +TestCase * +TestCase::GetParent () const +{ + return m_parent; +} + void TestCase::ReportTestFailure (std::string cond, std::string actual, std::string limit, std::string message, @@ -592,10 +609,7 @@ { for (uint32_t i = 0; i < test->m_result->failure.size (); i++) { - TestCaseFailure failure = test->m_result->failure[i]; - *os << Indent (level) << " got=\"" << failure.cond << "\" expected=\"" - << failure.actual << "\" in=\"" << failure.file << ":" << failure.line - << "\" " << failure.message << std::endl; + *os << Indent (level) << test->m_result->failure[i] << std::endl; } for (uint32_t i = 0; i < test->m_children.size (); i++) { diff -Naur ns-3.19/src/core/model/test.h ns-3.20/src/core/model/test.h --- ns-3.19/src/core/model/test.h 2014-06-17 10:34:00.622635241 -0700 +++ ns-3.20/src/core/model/test.h 2014-06-17 10:33:13.953995499 -0700 @@ -31,6 +31,12 @@ #include "system-wall-clock-ms.h" #include "deprecated.h" +/** + * \ingroup core + * \defgroup testing Testing + * \brief Tools to define and execute unit tests. + */ + // // Note on below macros: // @@ -42,9 +48,9 @@ // /** + * \ingroup testing + * \brief Check if we should assert on errors, and do so * \internal - * - * Check if we should assert on errors, and do so */ #define ASSERT_ON_FAILURE \ do { \ @@ -55,9 +61,9 @@ } while (false) /** + * \ingroup testing + * \brief If we shouldn't continue on errors, return * \internal - * - * If we shouldn't continue on errors, return */ #define CONTINUE_ON_FAILURE \ do { \ @@ -68,9 +74,9 @@ } while (false) /** + * \ingroup testing + * \brief If we shouldn't continue on errors, return test status * \internal - * - * If we shouldn't continue on errors, return test status */ #define CONTINUE_ON_FAILURE_RETURNS_BOOL \ do { \ @@ -87,6 +93,9 @@ // =========================================================================== /** + * \ingroup testing + * \brief Test that an actual and expected (limit) value are equal and report + * and abort if not. * \internal */ #define NS_TEST_ASSERT_MSG_EQ_INTERNAL(actual, limit, msg, file, line) \ @@ -109,6 +118,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual and expected (limit) value are equal and report * and abort if not. * @@ -138,6 +149,9 @@ NS_TEST_ASSERT_MSG_EQ_INTERNAL (actual, limit, msg, __FILE__, __LINE__) /** + * \ingroup testing + * \brief Test that an actual and expected (limit) value are equal and report + * and abort if not. * \internal */ #define NS_TEST_ASSERT_MSG_EQ_RETURNS_BOOL_INTERNAL(actual, limit, msg, file, line) \ @@ -160,6 +174,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual and expected (limit) value are equal and report * and abort if not. * @@ -192,10 +208,13 @@ NS_TEST_ASSERT_MSG_EQ_RETURNS_BOOL_INTERNAL (actual, limit, msg, __FILE__, __LINE__) /** - * \internal + * \ingroup testing + * \brief Test that an actual and expected (limit) value are equal and report + * if not. * * Required to avoid use of return statement which allows use in methods * (esp. callbacks) returning void. + * \internal */ #define NS_TEST_EXPECT_MSG_EQ_INTERNAL(actual, limit, msg, file, line) \ do { \ @@ -216,6 +235,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual and expected (limit) value are equal and report * if not. * @@ -250,6 +271,9 @@ // =========================================================================== /** + * \ingroup testing + * \brief Test that actual and expected (limit) values are equal to plus + * or minus some tolerance and report and abort if not. * \internal */ #define NS_TEST_ASSERT_MSG_EQ_TOL_INTERNAL(actual, limit, tol, msg, file, line) \ @@ -276,18 +300,21 @@ } while (false) /** - * \brief Test that actual and expected (limit) values are equal to plus or minus - * some tolerance and report and abort if not. + * \ingroup testing + * + * \brief Test that actual and expected (limit) values are equal to plus + * or minus some tolerance and report and abort if not. * * Check to see if the expected (limit) value is equal to the actual value found * in a test case to some tolerance. This is not the same thing as asking if * two floating point are equal to within some epsilon, but is useful for that - * case. This assertion is geared toward more of a measurement problem. Consider - * measuring a physical rod of some kind that you have ordered. You need to - * determine if it is "good." You won't measure the rod to an arbitrary precision - * of sixteen significant figures, you will measure the rod to determine if its - * length is within the tolerances you provided. For example, 12.00 inches plus - * or minus .005 inch may be just fine. + * case. This assertion is geared toward more of a measurement problem. + * Consider measuring a physical rod of some kind that you have ordered. + * You need to determine if it is "good." You want to measure the rod + * to an arbitrary precision of sixteen significant figures, you will + * measure the rod to determine if its length is within the tolerances + * you provided. For example, 12.00 inches plus or minus .005 inch + * may be just fine. * * In ns-3, you might want to measure a signal to noise ratio and check to see * if the answer is what you expect. If you naively measure (double)1128.93 and @@ -297,18 +324,20 @@ * probably quickly find that is not what you want either. It may turn out to * be the case that when you measured an snr that printed as 1128.93, what was * actually measured was something more like 1128.9287653857625442 for example. - * Given that the double epsilon is on the order of 0.0000000000000009, you would - * need to provide sixteen significant figures of expected value for this kind of - * test to pass even with a typical test for floating point "approximate equality." - * That is clearly not required or desired. You really want to be able to provide - * 1128.93 along with a tolerance just like you provided 12 inches +- 0.005 inch - * above. + * Given that the double epsilon is on the order of 0.0000000000000009, + * you would need to provide sixteen significant figures of expected value + * for this kind of test to pass even with a typical test for floating point + * "approximate equality." That is clearly not required or desired. + * You really want to be able to provide 1128.93 along with a tolerance + * just like you provided 12 inches +- 0.005 inch above. * * This assertion is designed for real measurements by taking into account * measurement tolerances. By doing so it also automatically compensates for * floating point rounding errors. If you really want to check floating point - * equality down to the numeric_limits::epsilon () range, consider using - * ns3::TestDoubleIsEqual(). + * equality down to the numeric_limits::epsilon () range, consider + * using ns3::TestDoubleIsEqual(). + * + * \note Mixing signed and unsigned types can lead to misleading results. * * The message is interpreted as a stream, for example: * @@ -327,6 +356,9 @@ NS_TEST_ASSERT_MSG_EQ_TOL_INTERNAL (actual, limit, tol, msg, __FILE__, __LINE__) /** + * \ingroup testing + * \brief Test that actual and expected (limit) values are equal to plus + * or minus some tolerance and report and abort if not. * \internal */ #define NS_TEST_ASSERT_MSG_EQ_TOL_RETURNS_BOOL_INTERNAL(actual, limit, tol, msg, file, line) \ @@ -353,18 +385,21 @@ } while (false) /** - * \brief Test that actual and expected (limit) values are equal to plus or minus - * some tolerance and report and abort if not. + * \ingroup testing + * + * \brief Test that actual and expected (limit) values are equal to plus + * or minus some tolerance and report and abort if not. * * Check to see if the expected (limit) value is equal to the actual value found * in a test case to some tolerance. This is not the same thing as asking if * two floating point are equal to within some epsilon, but is useful for that - * case. This assertion is geared toward more of a measurement problem. Consider - * measuring a physical rod of some kind that you have ordered. You need to - * determine if it is "good." You won't measure the rod to an arbitrary precision - * of sixteen significant figures, you will measure the rod to determine if its - * length is within the tolerances you provided. For example, 12.00 inches plus - * or minus .005 inch may be just fine. + * case. This assertion is geared toward more of a measurement problem. + * Consider measuring a physical rod of some kind that you have ordered. + * You need to determine if it is "good." You want to measure the rod + * to an arbitrary precision of sixteen significant figures, you will + * measure the rod to determine if its length is within the tolerances + * you provided. For example, 12.00 inches plus or minus .005 inch + * may be just fine. * * In ns-3, you might want to measure a signal to noise ratio and check to see * if the answer is what you expect. If you naively measure (double)1128.93 and @@ -374,18 +409,20 @@ * probably quickly find that is not what you want either. It may turn out to * be the case that when you measured an snr that printed as 1128.93, what was * actually measured was something more like 1128.9287653857625442 for example. - * Given that the double epsilon is on the order of 0.0000000000000009, you would - * need to provide sixteen significant figures of expected value for this kind of - * test to pass even with a typical test for floating point "approximate equality." - * That is clearly not required or desired. You really want to be able to provide - * 1128.93 along with a tolerance just like you provided 12 inches +- 0.005 inch - * above. + * Given that the double epsilon is on the order of 0.0000000000000009, + * you would need to provide sixteen significant figures of expected value + * for this kind of test to pass even with a typical test for floating point + * "approximate equality." That is clearly not required or desired. + * You really want to be able to provide 1128.93 along with a tolerance + * just like you provided 12 inches +- 0.005 inch above. * * This assertion is designed for real measurements by taking into account * measurement tolerances. By doing so it also automatically compensates for * floating point rounding errors. If you really want to check floating point - * equality down to the numeric_limits::epsilon () range, consider using - * ns3::TestDoubleIsEqual(). + * equality down to the numeric_limits::epsilon () range, + * consider using ns3::TestDoubleIsEqual(). + * + * \note Mixing signed and unsigned types can lead to misleading results. * * The message is interpreted as a stream, for example: * @@ -407,10 +444,13 @@ NS_TEST_ASSERT_MSG_EQ_TOL_RETURNS_BOOL_INTERNAL (actual, limit, tol, msg, __FILE__, __LINE__) /** - * \internal + * \ingroup testing + * \brief Test that actual and expected (limit) values are equal to plus or minus + * some tolerance and report if not. * * Required to avoid use of return statement which allows use in methods * (esp. callbacks) returning void. + * \internal */ #define NS_TEST_EXPECT_MSG_EQ_TOL_INTERNAL(actual, limit, tol, msg, file, line) \ do { \ @@ -435,17 +475,20 @@ } while (false) /** - * \brief Test that actual and expected (limit) values are equal to plus or minus - * some tolerance and report if not. + * \ingroup testing + * + * \brief Test that actual and expected (limit) values are equal to plus + * or minus some tolerance and report if not. * * Check to see if the expected (limit) value is equal to the actual value found * in a test case to some tolerance. This is not the same thing as asking if * two floating point are equal to within some epsilon, but is useful for that - * case. This assertion is geared toward more of a measurement problem. Consider - * measuring a physical rod of some kind that you have ordered. You need to - * determine if it is "good." You won't measure the rod to an arbitrary precision - * of sixteen significant figures, you will measure the rod to determine if its - * length is within the tolerances you provided. For example, 12.00 inches plus + * case. This assertion is geared toward more of a measurement problem. + * Consider measuring a physical rod of some kind that you have ordered. + * You need to determine if it is "good." You want to measure the rod + * to an arbitrary precision of sixteen significant figures, + * you will measure the rod to determine if its length is within + * the tolerances you provided. For example, 12.00 inches plus * or minus .005 inch may be just fine. * * In ns-3, you might want to measure a signal to noise ratio and check to see @@ -456,18 +499,20 @@ * probably quickly find that is not what you want either. It may turn out to * be the case that when you measured an snr that printed as 1128.93, what was * actually measured was something more like 1128.9287653857625442 for example. - * Given that the double epsilon is on the order of 0.0000000000000009, you would - * need to provide sixteen significant figures of expected value for this kind of - * test to pass even with a typical test for floating point "approximate equality." - * That is clearly not required or desired. You really want to be able to provide - * 1128.93 along with a tolerance just like you provided 12 inches +- 0.005 inch - * above. + * Given that the double epsilon is on the order of 0.0000000000000009, + * you would need to provide sixteen significant figures of expected value + * for this kind of test to pass even with a typical test for floating point + * "approximate equality." That is clearly not required or desired. + * You really want to be able to provide 1128.93 along with a tolerance + * just like you provided 12 inches +- 0.005 inch above. * * This assertion is designed for real measurements by taking into account * measurement tolerances. By doing so it also automatically compensates for * floating point rounding errors. If you really want to check floating point - * equality down to the numeric_limits::epsilon () range, consider using - * ns3::TestDoubleIsEqual(). + * equality down to the numeric_limits::epsilon () range, + * consider using ns3::TestDoubleIsEqual(). + * + * \note Mixing signed and unsigned types can lead to misleading results. * * The message is interpreted as a stream, for example: * @@ -490,6 +535,9 @@ // =========================================================================== /** + * \ingroup testing + * \brief Test that an actual and expected (limit) value are not equal and + * report and abort if not. * \internal */ #define NS_TEST_ASSERT_MSG_NE_INTERNAL(actual, limit, msg, file, line) \ @@ -512,6 +560,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual and expected (limit) value are not equal and * report and abort if not. * @@ -540,6 +590,9 @@ NS_TEST_ASSERT_MSG_NE_INTERNAL (actual, limit, msg, __FILE__, __LINE__) /** + * \ingroup testing + * \brief Test that an actual and expected (limit) value are not equal and + * report and abort if not. * \internal */ #define NS_TEST_ASSERT_MSG_NE_RETURNS_BOOL_INTERNAL(actual, limit, msg, file, line) \ @@ -562,6 +615,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual and expected (limit) value are not equal and * report and abort if not. * @@ -593,10 +648,13 @@ NS_TEST_ASSERT_MSG_NE_RETURNS_BOOL_INTERNAL (actual, limit, msg, __FILE__, __LINE__) /** - * \internal + * \ingroup testing + * \brief Test that an actual and expected (limit) value are not equal and + * report if not. * * Required to avoid use of return statement which allows use in methods * (callbacks) returning void. + * \internal */ #define NS_TEST_EXPECT_MSG_NE_INTERNAL(actual, limit, msg, file, line) \ do { \ @@ -617,6 +675,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual and expected (limit) value are not equal and * report if not. * @@ -649,6 +709,9 @@ // =========================================================================== /** + * \ingroup testing + * \brief Test that an actual value is less than a limit and report and abort + * if not. * \internal */ #define NS_TEST_ASSERT_MSG_LT_INTERNAL(actual, limit, msg, file, line) \ @@ -671,6 +734,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual value is less than a limit and report and abort * if not. * @@ -689,10 +754,12 @@ NS_TEST_ASSERT_MSG_LT_INTERNAL (actual, limit, msg, __FILE__, __LINE__) /** - * \internal + * \ingroup testing + * \brief Test that an actual value is less than a limit and report if not. * * Required to avoid use of return statement which allows use in methods * (callbacks) returning void. + * \internal */ #define NS_TEST_EXPECT_MSG_LT_INTERNAL(actual, limit, msg, file, line) \ do { \ @@ -713,6 +780,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual value is less than a limit and report if not. * * Check to see if the actual value found in a test case is less than the @@ -734,6 +803,9 @@ // =========================================================================== /** + * \ingroup testing + * \brief Test that an actual value is greater than a limit and report and abort + * if not. * \internal */ #define NS_TEST_ASSERT_MSG_GT_INTERNAL(actual, limit, msg, file, line) \ @@ -756,6 +828,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual value is greater than a limit and report and abort * if not. * @@ -774,10 +848,12 @@ NS_TEST_ASSERT_MSG_GT_INTERNAL (actual, limit, msg, __FILE__, __LINE__) /** - * \internal + * \ingroup testing + * \brief Test that an actual value is greater than a limit and report if not. * * Required to avoid use of return statement which allows use in methods * (callbacks) returning void. + * \internal */ #define NS_TEST_EXPECT_MSG_GT_INTERNAL(actual, limit, msg, file, line) \ do { \ @@ -798,6 +874,8 @@ } while (false) /** + * \ingroup testing + * * \brief Test that an actual value is greater than a limit and report if not. * * Check to see if the actual value found in a test case is greater than the @@ -840,6 +918,8 @@ class TestRunnerImpl; /** + * \ingroup testing + * * \brief encapsulates test code * * To allow a new test to be run within the ns-3 test framework, users @@ -864,6 +944,11 @@ */ virtual ~TestCase (); + /** + * \return name of this test + */ + std::string GetName (void) const; + protected: /** * \param name the name of the new TestCase created @@ -917,47 +1002,43 @@ bool IsStatusSuccess (void) const; /** - * \return name of this test + * \return a pointer to the parent of this test */ - std::string GetName (void) const; - - // The methods below are used only by test macros and should not - // be used by normal users. + TestCase * GetParent () const; /** + * @{ * \internal - * + * The methods below are used only by test macros and should not + * be used by normal users. + */ + /** * Log the failure of this TestCase. */ void ReportTestFailure (std::string cond, std::string actual, std::string limit, std::string message, std::string file, int32_t line); /** - * \internal - * * \return should we assert on failure, per the TestSuite configuration */ bool MustAssertOnFailure (void) const; /** - * \internal - * * \return should we continue on failure, per the TestSuite configuration */ bool MustContinueOnFailure (void) const; /** - * \internal * \param filename the bare (no path) file name * \return the full path to filename in the data directory */ std::string CreateDataDirFilename (std::string filename); /** - * \internal * \param filename the bare (no path) file name * \return the full path to filename in the temporary directory. * If the TestRunner is invoked with "--update-data", this will be * the data directory instead. */ std::string CreateTempDirFilename (std::string filename); + /**@}*/ private: friend class TestRunnerImpl; @@ -983,26 +1064,23 @@ */ virtual void DoTeardown (void); - // forbid copying objects /** - * \internal * Private, to block copying */ TestCase (TestCase& tc); /** - * \internal * Private, to block copying */ TestCase& operator= (TestCase& tc); // methods called by TestRunnerImpl /** - * \internal * Actually run this TestCase + * + * \param runner The test runner implementation. */ void Run (TestRunnerImpl *runner); /** - * \internal * \return the failure status of this TestCase and all it's children */ bool IsFailed (void) const; @@ -1020,6 +1098,8 @@ }; /** + * \ingroup testing + * * \brief A suite of tests to run. */ class TestSuite : public TestCase @@ -1061,6 +1141,8 @@ }; /** + * \ingroup testing + * * \brief A runner to execute tests. */ class TestRunner @@ -1069,14 +1151,16 @@ /** * Run the requested suite of tests. * - * \param list of command line arguments - * \param argc number of elements in argv + * \param argc number of elements in \pname{argv} + * \param argv vector of command line arguments * \returns success status */ static int Run (int argc, char *argv[]); }; /** + * \ingroup testing + * * \brief A simple way to store test vectors (for stimulus or from responses) */ template diff -Naur ns-3.19/src/core/model/time.cc ns-3.20/src/core/model/time.cc --- ns-3.19/src/core/model/time.cc 2014-06-17 10:34:00.623635233 -0700 +++ ns-3.20/src/core/model/time.cc 2014-06-17 10:33:13.954995491 -0700 @@ -32,7 +32,7 @@ #include // showpos #include -NS_LOG_COMPONENT_DEFINE ("Time"); +NS_LOG_COMPONENT_DEFINE_MASK ("Time", ns3::LOG_PREFIX_TIME); namespace ns3 { @@ -41,6 +41,7 @@ Time::MarkedTimes * Time::g_markingTimes = 0; /** + * \internal * Get mutex for critical sections around modification of Time::g_markingTimes * * \relates Time @@ -379,65 +380,53 @@ } +TimeWithUnit +Time::As (const enum Unit unit) const +{ + return TimeWithUnit (*this, unit); +} + + std::ostream& operator<< (std::ostream& os, const Time & time) { + os << time.As (Time::GetResolution ()); + return os; +} + + +std::ostream & +operator << (std::ostream & os, const TimeWithUnit & timeU) +{ std::string unit; - Time::Unit res = Time::GetResolution (); - switch (res) + + switch (timeU.m_unit) { - case Time::S: - unit = "s"; - break; - case Time::MS: - unit = "ms"; - break; - case Time::US: - unit = "us"; - break; - case Time::NS: - unit = "ns"; - break; - case Time::PS: - unit = "ps"; - break; - case Time::FS: - unit = "fs"; - break; - case Time::MIN: - unit = "min"; - break; - case Time::H: - unit = "h"; - break; - case Time::D: - unit = "d"; - break; - case Time::Y: - unit = "y"; - break; + case Time::Y: unit = "y"; break; + case Time::D: unit = "d"; break; + case Time::H: unit = "h"; break; + case Time::MIN: unit = "min"; break; + case Time::S: unit = "s"; break; + case Time::MS: unit = "ms"; break; + case Time::US: unit = "us"; break; + case Time::NS: unit = "ns"; break; + case Time::PS: unit = "ps"; break; + case Time::FS: unit = "fs"; break; + case Time::LAST: + default: NS_ABORT_MSG ("can't be reached"); unit = "unreachable"; break; } - int64_t v = time.ToInteger (res); - std::ios_base::fmtflags ff = os.flags (); - { // See bug 1737: gcc libstc++ 4.2 bug - if (v == 0) - { - os << '+'; - } - else - { - os << std::showpos; - } - } - os << v << ".0" << unit; - os.flags (ff); // Restore stream flags + int64x64_t v = timeU.m_time.To (timeU.m_unit); + os << v << unit; + return os; } + + std::istream& operator>> (std::istream& is, Time & time) { std::string value; diff -Naur ns-3.19/src/core/model/traced-value.h ns-3.20/src/core/model/traced-value.h --- ns-3.19/src/core/model/traced-value.h 2014-06-17 10:34:00.626635210 -0700 +++ ns-3.20/src/core/model/traced-value.h 2014-06-17 10:33:13.957995468 -0700 @@ -34,6 +34,8 @@ /** * \ingroup core * \defgroup tracing Tracing + * \brief Publish/subscribe tools to collect and report changes to any + * values used by the various model components. */ /** diff -Naur ns-3.19/src/core/model/type-id.cc ns-3.20/src/core/model/type-id.cc --- ns-3.19/src/core/model/type-id.cc 2014-06-17 10:34:00.626635210 -0700 +++ ns-3.20/src/core/model/type-id.cc 2014-06-17 10:33:13.957995468 -0700 @@ -34,8 +34,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("TypeId") - ; +NS_LOG_COMPONENT_DEFINE ("TypeId"); // IidManager needs to be in ns3 namespace for NS_ASSERT and NS_LOG // to find g_log diff -Naur ns-3.19/src/core/model/unix-system-condition.cc ns-3.20/src/core/model/unix-system-condition.cc --- ns-3.19/src/core/model/unix-system-condition.cc 2014-06-17 10:34:00.630635179 -0700 +++ ns-3.20/src/core/model/unix-system-condition.cc 2014-06-17 10:33:13.961995437 -0700 @@ -30,7 +30,8 @@ namespace ns3 { class SystemConditionPrivate { -public: +public: + /// Conversion from ns to s. static const uint64_t NS_PER_SEC = (uint64_t)1000000000; SystemConditionPrivate (); diff -Naur ns-3.19/src/core/model/unix-system-mutex.cc ns-3.20/src/core/model/unix-system-mutex.cc --- ns-3.19/src/core/model/unix-system-mutex.cc 2014-06-17 10:34:00.630635179 -0700 +++ ns-3.20/src/core/model/unix-system-mutex.cc 2014-06-17 10:33:13.961995437 -0700 @@ -27,7 +27,7 @@ #include "log.h" -NS_LOG_COMPONENT_DEFINE ("SystemMutex"); +NS_LOG_COMPONENT_DEFINE_MASK ("SystemMutex", ns3::LOG_PREFIX_TIME); namespace ns3 { diff -Naur ns-3.19/src/core/model/valgrind.h ns-3.20/src/core/model/valgrind.h --- ns-3.19/src/core/model/valgrind.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/core/model/valgrind.h 2014-06-17 10:33:13.964995414 -0700 @@ -0,0 +1,5624 @@ +/* -*- c -*- + ---------------------------------------------------------------- + + Notice that the following BSD-style license applies to this one + file (valgrind.h) only. The rest of Valgrind is licensed under the + terms of the GNU General Public License, version 2, unless + otherwise indicated. See the COPYING file in the source + distribution for details. + + ---------------------------------------------------------------- + + This file is part of Valgrind, a dynamic binary instrumentation + framework. + + Copyright (C) 2000-2013 Julian Seward. All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + 2. The origin of this software must not be misrepresented; you must + not claim that you wrote the original software. If you use this + software in a product, an acknowledgment in the product + documentation would be appreciated but is not required. + + 3. Altered source versions must be plainly marked as such, and must + not be misrepresented as being the original software. + + 4. The name of the author may not be used to endorse or promote + products derived from this software without specific prior written + permission. + + THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS + OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY + DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE + GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + ---------------------------------------------------------------- + + Notice that the above BSD-style license applies to this one file + (valgrind.h) only. The entire rest of Valgrind is licensed under + the terms of the GNU General Public License, version 2. See the + COPYING file in the source distribution for details. + + ---------------------------------------------------------------- +*/ + + +/* This file is for inclusion into client (your!) code. + + You can use these macros to manipulate and query Valgrind's + execution inside your own programs. + + The resulting executables will still run without Valgrind, just a + little bit more slowly than they otherwise would, but otherwise + unchanged. When not running on valgrind, each client request + consumes very few (eg. 7) instructions, so the resulting performance + loss is negligible unless you plan to execute client requests + millions of times per second. Nevertheless, if that is still a + problem, you can compile with the NVALGRIND symbol defined (gcc + -DNVALGRIND) so that client requests are not even compiled in. */ + +#ifndef __VALGRIND_H +#define __VALGRIND_H + + +/* ------------------------------------------------------------------ */ +/* VERSION NUMBER OF VALGRIND */ +/* ------------------------------------------------------------------ */ + +/* Specify Valgrind's version number, so that user code can + conditionally compile based on our version number. Note that these + were introduced at version 3.6 and so do not exist in version 3.5 + or earlier. The recommended way to use them to check for "version + X.Y or later" is (eg) + +#if defined(__VALGRIND_MAJOR__) && defined(__VALGRIND_MINOR__) \ + && (__VALGRIND_MAJOR__ > 3 \ + || (__VALGRIND_MAJOR__ == 3 && __VALGRIND_MINOR__ >= 6)) +*/ +#define __VALGRIND_MAJOR__ 3 +#define __VALGRIND_MINOR__ 9 + + +#include + +/* Nb: this file might be included in a file compiled with -ansi. So + we can't use C++ style "//" comments nor the "asm" keyword (instead + use "__asm__"). */ + +/* Derive some tags indicating what the target platform is. Note + that in this file we're using the compiler's CPP symbols for + identifying architectures, which are different to the ones we use + within the rest of Valgrind. Note, __powerpc__ is active for both + 32 and 64-bit PPC, whereas __powerpc64__ is only active for the + latter (on Linux, that is). + + Misc note: how to find out what's predefined in gcc by default: + gcc -Wp,-dM somefile.c +*/ +#undef PLAT_x86_darwin +#undef PLAT_amd64_darwin +#undef PLAT_x86_win32 +#undef PLAT_amd64_win64 +#undef PLAT_x86_linux +#undef PLAT_amd64_linux +#undef PLAT_ppc32_linux +#undef PLAT_ppc64_linux +#undef PLAT_arm_linux +#undef PLAT_arm64_linux +#undef PLAT_s390x_linux +#undef PLAT_mips32_linux +#undef PLAT_mips64_linux + + +#if defined(__APPLE__) && defined(__i386__) +# define PLAT_x86_darwin 1 +#elif defined(__APPLE__) && defined(__x86_64__) +# define PLAT_amd64_darwin 1 +#elif defined(__MINGW32__) || defined(__CYGWIN32__) \ + || (defined(_WIN32) && defined(_M_IX86)) +# define PLAT_x86_win32 1 +#elif defined(__MINGW64__) || (defined(_WIN64) && defined(_M_X64)) +# define PLAT_amd64_win64 1 +#elif defined(__linux__) && defined(__i386__) +# define PLAT_x86_linux 1 +#elif defined(__linux__) && defined(__x86_64__) +# define PLAT_amd64_linux 1 +#elif defined(__linux__) && defined(__powerpc__) && !defined(__powerpc64__) +# define PLAT_ppc32_linux 1 +#elif defined(__linux__) && defined(__powerpc__) && defined(__powerpc64__) +# define PLAT_ppc64_linux 1 +#elif defined(__linux__) && defined(__arm__) && !defined(__aarch64__) +# define PLAT_arm_linux 1 +#elif defined(__linux__) && defined(__aarch64__) && !defined(__arm__) +# define PLAT_arm64_linux 1 +#elif defined(__linux__) && defined(__s390__) && defined(__s390x__) +# define PLAT_s390x_linux 1 +#elif defined(__linux__) && defined(__mips__) && (__mips==64) +# define PLAT_mips64_linux 1 +#elif defined(__linux__) && defined(__mips__) && (__mips!=64) +# define PLAT_mips32_linux 1 +#else +/* If we're not compiling for our target platform, don't generate + any inline asms. */ +# if !defined(NVALGRIND) +# define NVALGRIND 1 +# endif +#endif + + +/* ------------------------------------------------------------------ */ +/* ARCHITECTURE SPECIFICS for SPECIAL INSTRUCTIONS. There is nothing */ +/* in here of use to end-users -- skip to the next section. */ +/* ------------------------------------------------------------------ */ + +/* + * VALGRIND_DO_CLIENT_REQUEST(): a statement that invokes a Valgrind client + * request. Accepts both pointers and integers as arguments. + * + * VALGRIND_DO_CLIENT_REQUEST_STMT(): a statement that invokes a Valgrind + * client request that does not return a value. + + * VALGRIND_DO_CLIENT_REQUEST_EXPR(): a C expression that invokes a Valgrind + * client request and whose value equals the client request result. Accepts + * both pointers and integers as arguments. Note that such calls are not + * necessarily pure functions -- they may have side effects. + */ + +#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, \ + _zzq_request, _zzq_arg1, _zzq_arg2, \ + _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + do { (_zzq_rlval) = VALGRIND_DO_CLIENT_REQUEST_EXPR((_zzq_default), \ + (_zzq_request), (_zzq_arg1), (_zzq_arg2), \ + (_zzq_arg3), (_zzq_arg4), (_zzq_arg5)); } while (0) + +#define VALGRIND_DO_CLIENT_REQUEST_STMT(_zzq_request, _zzq_arg1, \ + _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + do { (void) VALGRIND_DO_CLIENT_REQUEST_EXPR(0, \ + (_zzq_request), (_zzq_arg1), (_zzq_arg2), \ + (_zzq_arg3), (_zzq_arg4), (_zzq_arg5)); } while (0) + +#if defined(NVALGRIND) + +/* Define NVALGRIND to completely remove the Valgrind magic sequence + from the compiled code (analogous to NDEBUG's effects on + assert()) */ +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + (_zzq_default) + +#else /* ! NVALGRIND */ + +/* The following defines the magic code sequences which the JITter + spots and handles magically. Don't look too closely at them as + they will rot your brain. + + The assembly code sequences for all architectures is in this one + file. This is because this file must be stand-alone, and we don't + want to have multiple files. + + For VALGRIND_DO_CLIENT_REQUEST, we must ensure that the default + value gets put in the return slot, so that everything works when + this is executed not under Valgrind. Args are passed in a memory + block, and so there's no intrinsic limit to the number that could + be passed, but it's currently five. + + The macro args are: + _zzq_rlval result lvalue + _zzq_default default value (result returned when running on real CPU) + _zzq_request request code + _zzq_arg1..5 request params + + The other two macros are used to support function wrapping, and are + a lot simpler. VALGRIND_GET_NR_CONTEXT returns the value of the + guest's NRADDR pseudo-register and whatever other information is + needed to safely run the call original from the wrapper: on + ppc64-linux, the R2 value at the divert point is also needed. This + information is abstracted into a user-visible type, OrigFn. + + VALGRIND_CALL_NOREDIR_* behaves the same as the following on the + guest, but guarantees that the branch instruction will not be + redirected: x86: call *%eax, amd64: call *%rax, ppc32/ppc64: + branch-and-link-to-r11. VALGRIND_CALL_NOREDIR is just text, not a + complete inline asm, since it needs to be combined with more magic + inline asm stuff to be useful. +*/ + +/* ------------------------- x86-{linux,darwin} ---------------- */ + +#if defined(PLAT_x86_linux) || defined(PLAT_x86_darwin) \ + || (defined(PLAT_x86_win32) && defined(__GNUC__)) + +typedef + struct { + unsigned int nraddr; /* where's the code? */ + } + OrigFn; + +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "roll $3, %%edi ; roll $13, %%edi\n\t" \ + "roll $29, %%edi ; roll $19, %%edi\n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + __extension__ \ + ({volatile unsigned int _zzq_args[6]; \ + volatile unsigned int _zzq_result; \ + _zzq_args[0] = (unsigned int)(_zzq_request); \ + _zzq_args[1] = (unsigned int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned int)(_zzq_arg5); \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %EDX = client_request ( %EAX ) */ \ + "xchgl %%ebx,%%ebx" \ + : "=d" (_zzq_result) \ + : "a" (&_zzq_args[0]), "0" (_zzq_default) \ + : "cc", "memory" \ + ); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + volatile unsigned int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %EAX = guest_NRADDR */ \ + "xchgl %%ecx,%%ecx" \ + : "=a" (__addr) \ + : \ + : "cc", "memory" \ + ); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_CALL_NOREDIR_EAX \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* call-noredir *%EAX */ \ + "xchgl %%edx,%%edx\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "xchgl %%edi,%%edi\n\t" \ + : : : "cc", "memory" \ + ); \ + } while (0) + +#endif /* PLAT_x86_linux || PLAT_x86_darwin || (PLAT_x86_win32 && __GNUC__) */ + +/* ------------------------- x86-Win32 ------------------------- */ + +#if defined(PLAT_x86_win32) && !defined(__GNUC__) + +typedef + struct { + unsigned int nraddr; /* where's the code? */ + } + OrigFn; + +#if defined(_MSC_VER) + +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + __asm rol edi, 3 __asm rol edi, 13 \ + __asm rol edi, 29 __asm rol edi, 19 + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + valgrind_do_client_request_expr((uintptr_t)(_zzq_default), \ + (uintptr_t)(_zzq_request), (uintptr_t)(_zzq_arg1), \ + (uintptr_t)(_zzq_arg2), (uintptr_t)(_zzq_arg3), \ + (uintptr_t)(_zzq_arg4), (uintptr_t)(_zzq_arg5)) + +static __inline uintptr_t +valgrind_do_client_request_expr(uintptr_t _zzq_default, uintptr_t _zzq_request, + uintptr_t _zzq_arg1, uintptr_t _zzq_arg2, + uintptr_t _zzq_arg3, uintptr_t _zzq_arg4, + uintptr_t _zzq_arg5) +{ + volatile uintptr_t _zzq_args[6]; + volatile unsigned int _zzq_result; + _zzq_args[0] = (uintptr_t)(_zzq_request); + _zzq_args[1] = (uintptr_t)(_zzq_arg1); + _zzq_args[2] = (uintptr_t)(_zzq_arg2); + _zzq_args[3] = (uintptr_t)(_zzq_arg3); + _zzq_args[4] = (uintptr_t)(_zzq_arg4); + _zzq_args[5] = (uintptr_t)(_zzq_arg5); + __asm { __asm lea eax, _zzq_args __asm mov edx, _zzq_default + __SPECIAL_INSTRUCTION_PREAMBLE + /* %EDX = client_request ( %EAX ) */ + __asm xchg ebx,ebx + __asm mov _zzq_result, edx + } + return _zzq_result; +} + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + volatile unsigned int __addr; \ + __asm { __SPECIAL_INSTRUCTION_PREAMBLE \ + /* %EAX = guest_NRADDR */ \ + __asm xchg ecx,ecx \ + __asm mov __addr, eax \ + } \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_CALL_NOREDIR_EAX ERROR + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm { __SPECIAL_INSTRUCTION_PREAMBLE \ + __asm xchg edi,edi \ + } \ + } while (0) + +#else +#error Unsupported compiler. +#endif + +#endif /* PLAT_x86_win32 */ + +/* ------------------------ amd64-{linux,darwin} --------------- */ + +#if defined(PLAT_amd64_linux) || defined(PLAT_amd64_darwin) + +typedef + struct { + unsigned long long int nraddr; /* where's the code? */ + } + OrigFn; + +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "rolq $3, %%rdi ; rolq $13, %%rdi\n\t" \ + "rolq $61, %%rdi ; rolq $51, %%rdi\n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + __extension__ \ + ({ volatile unsigned long long int _zzq_args[6]; \ + volatile unsigned long long int _zzq_result; \ + _zzq_args[0] = (unsigned long long int)(_zzq_request); \ + _zzq_args[1] = (unsigned long long int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned long long int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned long long int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned long long int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned long long int)(_zzq_arg5); \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %RDX = client_request ( %RAX ) */ \ + "xchgq %%rbx,%%rbx" \ + : "=d" (_zzq_result) \ + : "a" (&_zzq_args[0]), "0" (_zzq_default) \ + : "cc", "memory" \ + ); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + volatile unsigned long long int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %RAX = guest_NRADDR */ \ + "xchgq %%rcx,%%rcx" \ + : "=a" (__addr) \ + : \ + : "cc", "memory" \ + ); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_CALL_NOREDIR_RAX \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* call-noredir *%RAX */ \ + "xchgq %%rdx,%%rdx\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "xchgq %%rdi,%%rdi\n\t" \ + : : : "cc", "memory" \ + ); \ + } while (0) + +#endif /* PLAT_amd64_linux || PLAT_amd64_darwin */ + +/* ------------------------ ppc32-linux ------------------------ */ + +#if defined(PLAT_ppc32_linux) + +typedef + struct { + unsigned int nraddr; /* where's the code? */ + } + OrigFn; + +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "rlwinm 0,0,3,0,31 ; rlwinm 0,0,13,0,31\n\t" \ + "rlwinm 0,0,29,0,31 ; rlwinm 0,0,19,0,31\n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + \ + __extension__ \ + ({ unsigned int _zzq_args[6]; \ + unsigned int _zzq_result; \ + unsigned int* _zzq_ptr; \ + _zzq_args[0] = (unsigned int)(_zzq_request); \ + _zzq_args[1] = (unsigned int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned int)(_zzq_arg5); \ + _zzq_ptr = _zzq_args; \ + __asm__ volatile("mr 3,%1\n\t" /*default*/ \ + "mr 4,%2\n\t" /*ptr*/ \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* %R3 = client_request ( %R4 ) */ \ + "or 1,1,1\n\t" \ + "mr %0,3" /*result*/ \ + : "=b" (_zzq_result) \ + : "b" (_zzq_default), "b" (_zzq_ptr) \ + : "cc", "memory", "r3", "r4"); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + unsigned int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %R3 = guest_NRADDR */ \ + "or 2,2,2\n\t" \ + "mr %0,3" \ + : "=b" (__addr) \ + : \ + : "cc", "memory", "r3" \ + ); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* branch-and-link-to-noredir *%R11 */ \ + "or 3,3,3\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "or 5,5,5\n\t" \ + ); \ + } while (0) + +#endif /* PLAT_ppc32_linux */ + +/* ------------------------ ppc64-linux ------------------------ */ + +#if defined(PLAT_ppc64_linux) + +typedef + struct { + unsigned long long int nraddr; /* where's the code? */ + unsigned long long int r2; /* what tocptr do we need? */ + } + OrigFn; + +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "rotldi 0,0,3 ; rotldi 0,0,13\n\t" \ + "rotldi 0,0,61 ; rotldi 0,0,51\n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + \ + __extension__ \ + ({ unsigned long long int _zzq_args[6]; \ + unsigned long long int _zzq_result; \ + unsigned long long int* _zzq_ptr; \ + _zzq_args[0] = (unsigned long long int)(_zzq_request); \ + _zzq_args[1] = (unsigned long long int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned long long int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned long long int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned long long int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned long long int)(_zzq_arg5); \ + _zzq_ptr = _zzq_args; \ + __asm__ volatile("mr 3,%1\n\t" /*default*/ \ + "mr 4,%2\n\t" /*ptr*/ \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* %R3 = client_request ( %R4 ) */ \ + "or 1,1,1\n\t" \ + "mr %0,3" /*result*/ \ + : "=b" (_zzq_result) \ + : "b" (_zzq_default), "b" (_zzq_ptr) \ + : "cc", "memory", "r3", "r4"); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + unsigned long long int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %R3 = guest_NRADDR */ \ + "or 2,2,2\n\t" \ + "mr %0,3" \ + : "=b" (__addr) \ + : \ + : "cc", "memory", "r3" \ + ); \ + _zzq_orig->nraddr = __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %R3 = guest_NRADDR_GPR2 */ \ + "or 4,4,4\n\t" \ + "mr %0,3" \ + : "=b" (__addr) \ + : \ + : "cc", "memory", "r3" \ + ); \ + _zzq_orig->r2 = __addr; \ + } + +#define VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* branch-and-link-to-noredir *%R11 */ \ + "or 3,3,3\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "or 5,5,5\n\t" \ + ); \ + } while (0) + +#endif /* PLAT_ppc64_linux */ + +/* ------------------------- arm-linux ------------------------- */ + +#if defined(PLAT_arm_linux) + +typedef + struct { + unsigned int nraddr; /* where's the code? */ + } + OrigFn; + +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "mov r12, r12, ror #3 ; mov r12, r12, ror #13 \n\t" \ + "mov r12, r12, ror #29 ; mov r12, r12, ror #19 \n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + \ + __extension__ \ + ({volatile unsigned int _zzq_args[6]; \ + volatile unsigned int _zzq_result; \ + _zzq_args[0] = (unsigned int)(_zzq_request); \ + _zzq_args[1] = (unsigned int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned int)(_zzq_arg5); \ + __asm__ volatile("mov r3, %1\n\t" /*default*/ \ + "mov r4, %2\n\t" /*ptr*/ \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* R3 = client_request ( R4 ) */ \ + "orr r10, r10, r10\n\t" \ + "mov %0, r3" /*result*/ \ + : "=r" (_zzq_result) \ + : "r" (_zzq_default), "r" (&_zzq_args[0]) \ + : "cc","memory", "r3", "r4"); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + unsigned int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* R3 = guest_NRADDR */ \ + "orr r11, r11, r11\n\t" \ + "mov %0, r3" \ + : "=r" (__addr) \ + : \ + : "cc", "memory", "r3" \ + ); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* branch-and-link-to-noredir *%R4 */ \ + "orr r12, r12, r12\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "orr r9, r9, r9\n\t" \ + : : : "cc", "memory" \ + ); \ + } while (0) + +#endif /* PLAT_arm_linux */ + +/* ------------------------ arm64-linux ------------------------- */ + +#if defined(PLAT_arm64_linux) + +typedef + struct { + unsigned long long int nraddr; /* where's the code? */ + } + OrigFn; + +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "ror x12, x12, #3 ; ror x12, x12, #13 \n\t" \ + "ror x12, x12, #51 ; ror x12, x12, #61 \n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + \ + __extension__ \ + ({volatile unsigned long long int _zzq_args[6]; \ + volatile unsigned long long int _zzq_result; \ + _zzq_args[0] = (unsigned long long int)(_zzq_request); \ + _zzq_args[1] = (unsigned long long int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned long long int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned long long int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned long long int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned long long int)(_zzq_arg5); \ + __asm__ volatile("mov x3, %1\n\t" /*default*/ \ + "mov x4, %2\n\t" /*ptr*/ \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* X3 = client_request ( X4 ) */ \ + "orr x10, x10, x10\n\t" \ + "mov %0, x3" /*result*/ \ + : "=r" (_zzq_result) \ + : "r" (_zzq_default), "r" (&_zzq_args[0]) \ + : "cc","memory", "x3", "x4"); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + unsigned long long int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* X3 = guest_NRADDR */ \ + "orr x11, x11, x11\n\t" \ + "mov %0, x3" \ + : "=r" (__addr) \ + : \ + : "cc", "memory", "x3" \ + ); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_X8 \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* branch-and-link-to-noredir X8 */ \ + "orr x12, x12, x12\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "orr x9, x9, x9\n\t" \ + : : : "cc", "memory" \ + ); \ + } while (0) + +#endif /* PLAT_arm64_linux */ + +/* ------------------------ s390x-linux ------------------------ */ + +#if defined(PLAT_s390x_linux) + +typedef + struct { + unsigned long long int nraddr; /* where's the code? */ + } + OrigFn; + +/* __SPECIAL_INSTRUCTION_PREAMBLE will be used to identify Valgrind specific + * code. This detection is implemented in platform specific toIR.c + * (e.g. VEX/priv/guest_s390_decoder.c). + */ +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "lr 15,15\n\t" \ + "lr 1,1\n\t" \ + "lr 2,2\n\t" \ + "lr 3,3\n\t" + +#define __CLIENT_REQUEST_CODE "lr 2,2\n\t" +#define __GET_NR_CONTEXT_CODE "lr 3,3\n\t" +#define __CALL_NO_REDIR_CODE "lr 4,4\n\t" +#define __VEX_INJECT_IR_CODE "lr 5,5\n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + __extension__ \ + ({volatile unsigned long long int _zzq_args[6]; \ + volatile unsigned long long int _zzq_result; \ + _zzq_args[0] = (unsigned long long int)(_zzq_request); \ + _zzq_args[1] = (unsigned long long int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned long long int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned long long int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned long long int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned long long int)(_zzq_arg5); \ + __asm__ volatile(/* r2 = args */ \ + "lgr 2,%1\n\t" \ + /* r3 = default */ \ + "lgr 3,%2\n\t" \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + __CLIENT_REQUEST_CODE \ + /* results = r3 */ \ + "lgr %0, 3\n\t" \ + : "=d" (_zzq_result) \ + : "a" (&_zzq_args[0]), "0" (_zzq_default) \ + : "cc", "2", "3", "memory" \ + ); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + volatile unsigned long long int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + __GET_NR_CONTEXT_CODE \ + "lgr %0, 3\n\t" \ + : "=a" (__addr) \ + : \ + : "cc", "3", "memory" \ + ); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_CALL_NOREDIR_R1 \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + __CALL_NO_REDIR_CODE + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + __VEX_INJECT_IR_CODE); \ + } while (0) + +#endif /* PLAT_s390x_linux */ + +/* ------------------------- mips32-linux ---------------- */ + +#if defined(PLAT_mips32_linux) + +typedef + struct { + unsigned int nraddr; /* where's the code? */ + } + OrigFn; + +/* .word 0x342 + * .word 0x742 + * .word 0xC2 + * .word 0x4C2*/ +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "srl $0, $0, 13\n\t" \ + "srl $0, $0, 29\n\t" \ + "srl $0, $0, 3\n\t" \ + "srl $0, $0, 19\n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + __extension__ \ + ({ volatile unsigned int _zzq_args[6]; \ + volatile unsigned int _zzq_result; \ + _zzq_args[0] = (unsigned int)(_zzq_request); \ + _zzq_args[1] = (unsigned int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned int)(_zzq_arg5); \ + __asm__ volatile("move $11, %1\n\t" /*default*/ \ + "move $12, %2\n\t" /*ptr*/ \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* T3 = client_request ( T4 ) */ \ + "or $13, $13, $13\n\t" \ + "move %0, $11\n\t" /*result*/ \ + : "=r" (_zzq_result) \ + : "r" (_zzq_default), "r" (&_zzq_args[0]) \ + : "$11", "$12"); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + volatile unsigned int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* %t9 = guest_NRADDR */ \ + "or $14, $14, $14\n\t" \ + "move %0, $11" /*result*/ \ + : "=r" (__addr) \ + : \ + : "$11" \ + ); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_CALL_NOREDIR_T9 \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* call-noredir *%t9 */ \ + "or $15, $15, $15\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "or $11, $11, $11\n\t" \ + ); \ + } while (0) + + +#endif /* PLAT_mips32_linux */ + +/* ------------------------- mips64-linux ---------------- */ + +#if defined(PLAT_mips64_linux) + +typedef + struct { + unsigned long long nraddr; /* where's the code? */ + } + OrigFn; + +/* dsll $0,$0, 3 + * dsll $0,$0, 13 + * dsll $0,$0, 29 + * dsll $0,$0, 19*/ +#define __SPECIAL_INSTRUCTION_PREAMBLE \ + "dsll $0,$0, 3 ; dsll $0,$0,13\n\t" \ + "dsll $0,$0,29 ; dsll $0,$0,19\n\t" + +#define VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + _zzq_default, _zzq_request, \ + _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5) \ + __extension__ \ + ({ volatile unsigned long long int _zzq_args[6]; \ + volatile unsigned long long int _zzq_result; \ + _zzq_args[0] = (unsigned long long int)(_zzq_request); \ + _zzq_args[1] = (unsigned long long int)(_zzq_arg1); \ + _zzq_args[2] = (unsigned long long int)(_zzq_arg2); \ + _zzq_args[3] = (unsigned long long int)(_zzq_arg3); \ + _zzq_args[4] = (unsigned long long int)(_zzq_arg4); \ + _zzq_args[5] = (unsigned long long int)(_zzq_arg5); \ + __asm__ volatile("move $11, %1\n\t" /*default*/ \ + "move $12, %2\n\t" /*ptr*/ \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* $11 = client_request ( $12 ) */ \ + "or $13, $13, $13\n\t" \ + "move %0, $11\n\t" /*result*/ \ + : "=r" (_zzq_result) \ + : "r" (_zzq_default), "r" (&_zzq_args[0]) \ + : "$11", "$12"); \ + _zzq_result; \ + }) + +#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval) \ + { volatile OrigFn* _zzq_orig = &(_zzq_rlval); \ + volatile unsigned long long int __addr; \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + /* $11 = guest_NRADDR */ \ + "or $14, $14, $14\n\t" \ + "move %0, $11" /*result*/ \ + : "=r" (__addr) \ + : \ + : "$11"); \ + _zzq_orig->nraddr = __addr; \ + } + +#define VALGRIND_CALL_NOREDIR_T9 \ + __SPECIAL_INSTRUCTION_PREAMBLE \ + /* call-noredir $25 */ \ + "or $15, $15, $15\n\t" + +#define VALGRIND_VEX_INJECT_IR() \ + do { \ + __asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \ + "or $11, $11, $11\n\t" \ + ); \ + } while (0) + +#endif /* PLAT_mips64_linux */ + +/* Insert assembly code for other platforms here... */ + +#endif /* NVALGRIND */ + + +/* ------------------------------------------------------------------ */ +/* PLATFORM SPECIFICS for FUNCTION WRAPPING. This is all very */ +/* ugly. It's the least-worst tradeoff I can think of. */ +/* ------------------------------------------------------------------ */ + +/* This section defines magic (a.k.a appalling-hack) macros for doing + guaranteed-no-redirection macros, so as to get from function + wrappers to the functions they are wrapping. The whole point is to + construct standard call sequences, but to do the call itself with a + special no-redirect call pseudo-instruction that the JIT + understands and handles specially. This section is long and + repetitious, and I can't see a way to make it shorter. + + The naming scheme is as follows: + + CALL_FN_{W,v}_{v,W,WW,WWW,WWWW,5W,6W,7W,etc} + + 'W' stands for "word" and 'v' for "void". Hence there are + different macros for calling arity 0, 1, 2, 3, 4, etc, functions, + and for each, the possibility of returning a word-typed result, or + no result. +*/ + +/* Use these to write the name of your wrapper. NOTE: duplicates + VG_WRAP_FUNCTION_Z{U,Z} in pub_tool_redir.h. NOTE also: inserts + the default behaviour equivalance class tag "0000" into the name. + See pub_tool_redir.h for details -- normally you don't need to + think about this, though. */ + +/* Use an extra level of macroisation so as to ensure the soname/fnname + args are fully macro-expanded before pasting them together. */ +#define VG_CONCAT4(_aa,_bb,_cc,_dd) _aa##_bb##_cc##_dd + +#define I_WRAP_SONAME_FNNAME_ZU(soname,fnname) \ + VG_CONCAT4(_vgw00000ZU_,soname,_,fnname) + +#define I_WRAP_SONAME_FNNAME_ZZ(soname,fnname) \ + VG_CONCAT4(_vgw00000ZZ_,soname,_,fnname) + +/* Use this macro from within a wrapper function to collect the + context (address and possibly other info) of the original function. + Once you have that you can then use it in one of the CALL_FN_ + macros. The type of the argument _lval is OrigFn. */ +#define VALGRIND_GET_ORIG_FN(_lval) VALGRIND_GET_NR_CONTEXT(_lval) + +/* Also provide end-user facilities for function replacement, rather + than wrapping. A replacement function differs from a wrapper in + that it has no way to get hold of the original function being + called, and hence no way to call onwards to it. In a replacement + function, VALGRIND_GET_ORIG_FN always returns zero. */ + +#define I_REPLACE_SONAME_FNNAME_ZU(soname,fnname) \ + VG_CONCAT4(_vgr00000ZU_,soname,_,fnname) + +#define I_REPLACE_SONAME_FNNAME_ZZ(soname,fnname) \ + VG_CONCAT4(_vgr00000ZZ_,soname,_,fnname) + +/* Derivatives of the main macros below, for calling functions + returning void. */ + +#define CALL_FN_v_v(fnptr) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_v(_junk,fnptr); } while (0) + +#define CALL_FN_v_W(fnptr, arg1) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_W(_junk,fnptr,arg1); } while (0) + +#define CALL_FN_v_WW(fnptr, arg1,arg2) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_WW(_junk,fnptr,arg1,arg2); } while (0) + +#define CALL_FN_v_WWW(fnptr, arg1,arg2,arg3) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_WWW(_junk,fnptr,arg1,arg2,arg3); } while (0) + +#define CALL_FN_v_WWWW(fnptr, arg1,arg2,arg3,arg4) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_WWWW(_junk,fnptr,arg1,arg2,arg3,arg4); } while (0) + +#define CALL_FN_v_5W(fnptr, arg1,arg2,arg3,arg4,arg5) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_5W(_junk,fnptr,arg1,arg2,arg3,arg4,arg5); } while (0) + +#define CALL_FN_v_6W(fnptr, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_6W(_junk,fnptr,arg1,arg2,arg3,arg4,arg5,arg6); } while (0) + +#define CALL_FN_v_7W(fnptr, arg1,arg2,arg3,arg4,arg5,arg6,arg7) \ + do { volatile unsigned long _junk; \ + CALL_FN_W_7W(_junk,fnptr,arg1,arg2,arg3,arg4,arg5,arg6,arg7); } while (0) + +/* ------------------------- x86-{linux,darwin} ---------------- */ + +#if defined(PLAT_x86_linux) || defined(PLAT_x86_darwin) + +/* These regs are trashed by the hidden call. No need to mention eax + as gcc can already see that, plus causes gcc to bomb. */ +#define __CALLER_SAVED_REGS /*"eax"*/ "ecx", "edx" + +/* Macros to save and align the stack before making a function + call and restore it afterwards as gcc may not keep the stack + pointer aligned if it doesn't realise calls are being made + to other functions. */ + +#define VALGRIND_ALIGN_STACK \ + "movl %%esp,%%edi\n\t" \ + "andl $0xfffffff0,%%esp\n\t" +#define VALGRIND_RESTORE_STACK \ + "movl %%edi,%%esp\n\t" + +/* These CALL_FN_ macros assume that on x86-linux, sizeof(unsigned + long) == 4. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $12, %%esp\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $8, %%esp\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $4, %%esp\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1,arg2,arg3,arg4,arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[6]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $12, %%esp\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_6W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[7]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $8, %%esp\n\t" \ + "pushl 24(%%eax)\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[8]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $4, %%esp\n\t" \ + "pushl 28(%%eax)\n\t" \ + "pushl 24(%%eax)\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[9]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "pushl 32(%%eax)\n\t" \ + "pushl 28(%%eax)\n\t" \ + "pushl 24(%%eax)\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[10]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $12, %%esp\n\t" \ + "pushl 36(%%eax)\n\t" \ + "pushl 32(%%eax)\n\t" \ + "pushl 28(%%eax)\n\t" \ + "pushl 24(%%eax)\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[11]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $8, %%esp\n\t" \ + "pushl 40(%%eax)\n\t" \ + "pushl 36(%%eax)\n\t" \ + "pushl 32(%%eax)\n\t" \ + "pushl 28(%%eax)\n\t" \ + "pushl 24(%%eax)\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[12]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "subl $4, %%esp\n\t" \ + "pushl 44(%%eax)\n\t" \ + "pushl 40(%%eax)\n\t" \ + "pushl 36(%%eax)\n\t" \ + "pushl 32(%%eax)\n\t" \ + "pushl 28(%%eax)\n\t" \ + "pushl 24(%%eax)\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11,arg12) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[13]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + _argvec[12] = (unsigned long)(arg12); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "pushl 48(%%eax)\n\t" \ + "pushl 44(%%eax)\n\t" \ + "pushl 40(%%eax)\n\t" \ + "pushl 36(%%eax)\n\t" \ + "pushl 32(%%eax)\n\t" \ + "pushl 28(%%eax)\n\t" \ + "pushl 24(%%eax)\n\t" \ + "pushl 20(%%eax)\n\t" \ + "pushl 16(%%eax)\n\t" \ + "pushl 12(%%eax)\n\t" \ + "pushl 8(%%eax)\n\t" \ + "pushl 4(%%eax)\n\t" \ + "movl (%%eax), %%eax\n\t" /* target->%eax */ \ + VALGRIND_CALL_NOREDIR_EAX \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "edi" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_x86_linux || PLAT_x86_darwin */ + +/* ------------------------ amd64-{linux,darwin} --------------- */ + +#if defined(PLAT_amd64_linux) || defined(PLAT_amd64_darwin) + +/* ARGREGS: rdi rsi rdx rcx r8 r9 (the rest on stack in R-to-L order) */ + +/* These regs are trashed by the hidden call. */ +#define __CALLER_SAVED_REGS /*"rax",*/ "rcx", "rdx", "rsi", \ + "rdi", "r8", "r9", "r10", "r11" + +/* This is all pretty complex. It's so as to make stack unwinding + work reliably. See bug 243270. The basic problem is the sub and + add of 128 of %rsp in all of the following macros. If gcc believes + the CFA is in %rsp, then unwinding may fail, because what's at the + CFA is not what gcc "expected" when it constructs the CFIs for the + places where the macros are instantiated. + + But we can't just add a CFI annotation to increase the CFA offset + by 128, to match the sub of 128 from %rsp, because we don't know + whether gcc has chosen %rsp as the CFA at that point, or whether it + has chosen some other register (eg, %rbp). In the latter case, + adding a CFI annotation to change the CFA offset is simply wrong. + + So the solution is to get hold of the CFA using + __builtin_dwarf_cfa(), put it in a known register, and add a + CFI annotation to say what the register is. We choose %rbp for + this (perhaps perversely), because: + + (1) %rbp is already subject to unwinding. If a new register was + chosen then the unwinder would have to unwind it in all stack + traces, which is expensive, and + + (2) %rbp is already subject to precise exception updates in the + JIT. If a new register was chosen, we'd have to have precise + exceptions for it too, which reduces performance of the + generated code. + + However .. one extra complication. We can't just whack the result + of __builtin_dwarf_cfa() into %rbp and then add %rbp to the + list of trashed registers at the end of the inline assembly + fragments; gcc won't allow %rbp to appear in that list. Hence + instead we need to stash %rbp in %r15 for the duration of the asm, + and say that %r15 is trashed instead. gcc seems happy to go with + that. + + Oh .. and this all needs to be conditionalised so that it is + unchanged from before this commit, when compiled with older gccs + that don't support __builtin_dwarf_cfa. Furthermore, since + this header file is freestanding, it has to be independent of + config.h, and so the following conditionalisation cannot depend on + configure time checks. + + Although it's not clear from + 'defined(__GNUC__) && defined(__GCC_HAVE_DWARF2_CFI_ASM)', + this expression excludes Darwin. + .cfi directives in Darwin assembly appear to be completely + different and I haven't investigated how they work. + + For even more entertainment value, note we have to use the + completely undocumented __builtin_dwarf_cfa(), which appears to + really compute the CFA, whereas __builtin_frame_address(0) claims + to but actually doesn't. See + https://bugs.kde.org/show_bug.cgi?id=243270#c47 +*/ +#if defined(__GNUC__) && defined(__GCC_HAVE_DWARF2_CFI_ASM) +# define __FRAME_POINTER \ + ,"r"(__builtin_dwarf_cfa()) +# define VALGRIND_CFI_PROLOGUE \ + "movq %%rbp, %%r15\n\t" \ + "movq %2, %%rbp\n\t" \ + ".cfi_remember_state\n\t" \ + ".cfi_def_cfa rbp, 0\n\t" +# define VALGRIND_CFI_EPILOGUE \ + "movq %%r15, %%rbp\n\t" \ + ".cfi_restore_state\n\t" +#else +# define __FRAME_POINTER +# define VALGRIND_CFI_PROLOGUE +# define VALGRIND_CFI_EPILOGUE +#endif + +/* Macros to save and align the stack before making a function + call and restore it afterwards as gcc may not keep the stack + pointer aligned if it doesn't realise calls are being made + to other functions. */ + +#define VALGRIND_ALIGN_STACK \ + "movq %%rsp,%%r14\n\t" \ + "andq $0xfffffffffffffff0,%%rsp\n\t" +#define VALGRIND_RESTORE_STACK \ + "movq %%r14,%%rsp\n\t" + +/* These CALL_FN_ macros assume that on amd64-linux, sizeof(unsigned + long) == 8. */ + +/* NB 9 Sept 07. There is a nasty kludge here in all these CALL_FN_ + macros. In order not to trash the stack redzone, we need to drop + %rsp by 128 before the hidden call, and restore afterwards. The + nastyness is that it is only by luck that the stack still appears + to be unwindable during the hidden call - since then the behaviour + of any routine using this macro does not match what the CFI data + says. Sigh. + + Why is this important? Imagine that a wrapper has a stack + allocated local, and passes to the hidden call, a pointer to it. + Because gcc does not know about the hidden call, it may allocate + that local in the redzone. Unfortunately the hidden call may then + trash it before it comes to use it. So we must step clear of the + redzone, for the duration of the hidden call, to make it safe. + + Probably the same problem afflicts the other redzone-style ABIs too + (ppc64-linux); but for those, the stack is + self describing (none of this CFI nonsense) so at least messing + with the stack pointer doesn't give a danger of non-unwindable + stack. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1,arg2,arg3,arg4,arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[6]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_6W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[7]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "movq 48(%%rax), %%r9\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[8]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $136,%%rsp\n\t" \ + "pushq 56(%%rax)\n\t" \ + "movq 48(%%rax), %%r9\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[9]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "pushq 64(%%rax)\n\t" \ + "pushq 56(%%rax)\n\t" \ + "movq 48(%%rax), %%r9\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[10]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $136,%%rsp\n\t" \ + "pushq 72(%%rax)\n\t" \ + "pushq 64(%%rax)\n\t" \ + "pushq 56(%%rax)\n\t" \ + "movq 48(%%rax), %%r9\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[11]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "pushq 80(%%rax)\n\t" \ + "pushq 72(%%rax)\n\t" \ + "pushq 64(%%rax)\n\t" \ + "pushq 56(%%rax)\n\t" \ + "movq 48(%%rax), %%r9\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10,arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[12]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $136,%%rsp\n\t" \ + "pushq 88(%%rax)\n\t" \ + "pushq 80(%%rax)\n\t" \ + "pushq 72(%%rax)\n\t" \ + "pushq 64(%%rax)\n\t" \ + "pushq 56(%%rax)\n\t" \ + "movq 48(%%rax), %%r9\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10,arg11,arg12) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[13]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + _argvec[12] = (unsigned long)(arg12); \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + VALGRIND_ALIGN_STACK \ + "subq $128,%%rsp\n\t" \ + "pushq 96(%%rax)\n\t" \ + "pushq 88(%%rax)\n\t" \ + "pushq 80(%%rax)\n\t" \ + "pushq 72(%%rax)\n\t" \ + "pushq 64(%%rax)\n\t" \ + "pushq 56(%%rax)\n\t" \ + "movq 48(%%rax), %%r9\n\t" \ + "movq 40(%%rax), %%r8\n\t" \ + "movq 32(%%rax), %%rcx\n\t" \ + "movq 24(%%rax), %%rdx\n\t" \ + "movq 16(%%rax), %%rsi\n\t" \ + "movq 8(%%rax), %%rdi\n\t" \ + "movq (%%rax), %%rax\n\t" /* target->%rax */ \ + VALGRIND_CALL_NOREDIR_RAX \ + VALGRIND_RESTORE_STACK \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=a" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r14", "r15" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_amd64_linux || PLAT_amd64_darwin */ + +/* ------------------------ ppc32-linux ------------------------ */ + +#if defined(PLAT_ppc32_linux) + +/* This is useful for finding out about the on-stack stuff: + + extern int f9 ( int,int,int,int,int,int,int,int,int ); + extern int f10 ( int,int,int,int,int,int,int,int,int,int ); + extern int f11 ( int,int,int,int,int,int,int,int,int,int,int ); + extern int f12 ( int,int,int,int,int,int,int,int,int,int,int,int ); + + int g9 ( void ) { + return f9(11,22,33,44,55,66,77,88,99); + } + int g10 ( void ) { + return f10(11,22,33,44,55,66,77,88,99,110); + } + int g11 ( void ) { + return f11(11,22,33,44,55,66,77,88,99,110,121); + } + int g12 ( void ) { + return f12(11,22,33,44,55,66,77,88,99,110,121,132); + } +*/ + +/* ARGREGS: r3 r4 r5 r6 r7 r8 r9 r10 (the rest on stack somewhere) */ + +/* These regs are trashed by the hidden call. */ +#define __CALLER_SAVED_REGS \ + "lr", "ctr", "xer", \ + "cr0", "cr1", "cr2", "cr3", "cr4", "cr5", "cr6", "cr7", \ + "r0", "r2", "r3", "r4", "r5", "r6", "r7", "r8", "r9", "r10", \ + "r11", "r12", "r13" + +/* Macros to save and align the stack before making a function + call and restore it afterwards as gcc may not keep the stack + pointer aligned if it doesn't realise calls are being made + to other functions. */ + +#define VALGRIND_ALIGN_STACK \ + "mr 28,1\n\t" \ + "rlwinm 1,1,0,0,27\n\t" +#define VALGRIND_RESTORE_STACK \ + "mr 1,28\n\t" + +/* These CALL_FN_ macros assume that on ppc32-linux, + sizeof(unsigned long) == 4. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1,arg2,arg3,arg4,arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[6]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_6W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[7]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 8,24(11)\n\t" \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[8]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 8,24(11)\n\t" \ + "lwz 9,28(11)\n\t" \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[9]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 8,24(11)\n\t" \ + "lwz 9,28(11)\n\t" \ + "lwz 10,32(11)\n\t" /* arg8->r10 */ \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[10]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "addi 1,1,-16\n\t" \ + /* arg9 */ \ + "lwz 3,36(11)\n\t" \ + "stw 3,8(1)\n\t" \ + /* args1-8 */ \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 8,24(11)\n\t" \ + "lwz 9,28(11)\n\t" \ + "lwz 10,32(11)\n\t" /* arg8->r10 */ \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[11]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + _argvec[10] = (unsigned long)arg10; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "addi 1,1,-16\n\t" \ + /* arg10 */ \ + "lwz 3,40(11)\n\t" \ + "stw 3,12(1)\n\t" \ + /* arg9 */ \ + "lwz 3,36(11)\n\t" \ + "stw 3,8(1)\n\t" \ + /* args1-8 */ \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 8,24(11)\n\t" \ + "lwz 9,28(11)\n\t" \ + "lwz 10,32(11)\n\t" /* arg8->r10 */ \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10,arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[12]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + _argvec[10] = (unsigned long)arg10; \ + _argvec[11] = (unsigned long)arg11; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "addi 1,1,-32\n\t" \ + /* arg11 */ \ + "lwz 3,44(11)\n\t" \ + "stw 3,16(1)\n\t" \ + /* arg10 */ \ + "lwz 3,40(11)\n\t" \ + "stw 3,12(1)\n\t" \ + /* arg9 */ \ + "lwz 3,36(11)\n\t" \ + "stw 3,8(1)\n\t" \ + /* args1-8 */ \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 8,24(11)\n\t" \ + "lwz 9,28(11)\n\t" \ + "lwz 10,32(11)\n\t" /* arg8->r10 */ \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10,arg11,arg12) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[13]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + _argvec[10] = (unsigned long)arg10; \ + _argvec[11] = (unsigned long)arg11; \ + _argvec[12] = (unsigned long)arg12; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "addi 1,1,-32\n\t" \ + /* arg12 */ \ + "lwz 3,48(11)\n\t" \ + "stw 3,20(1)\n\t" \ + /* arg11 */ \ + "lwz 3,44(11)\n\t" \ + "stw 3,16(1)\n\t" \ + /* arg10 */ \ + "lwz 3,40(11)\n\t" \ + "stw 3,12(1)\n\t" \ + /* arg9 */ \ + "lwz 3,36(11)\n\t" \ + "stw 3,8(1)\n\t" \ + /* args1-8 */ \ + "lwz 3,4(11)\n\t" /* arg1->r3 */ \ + "lwz 4,8(11)\n\t" \ + "lwz 5,12(11)\n\t" \ + "lwz 6,16(11)\n\t" /* arg4->r6 */ \ + "lwz 7,20(11)\n\t" \ + "lwz 8,24(11)\n\t" \ + "lwz 9,28(11)\n\t" \ + "lwz 10,32(11)\n\t" /* arg8->r10 */ \ + "lwz 11,0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + VALGRIND_RESTORE_STACK \ + "mr %0,3" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_ppc32_linux */ + +/* ------------------------ ppc64-linux ------------------------ */ + +#if defined(PLAT_ppc64_linux) + +/* ARGREGS: r3 r4 r5 r6 r7 r8 r9 r10 (the rest on stack somewhere) */ + +/* These regs are trashed by the hidden call. */ +#define __CALLER_SAVED_REGS \ + "lr", "ctr", "xer", \ + "cr0", "cr1", "cr2", "cr3", "cr4", "cr5", "cr6", "cr7", \ + "r0", "r2", "r3", "r4", "r5", "r6", "r7", "r8", "r9", "r10", \ + "r11", "r12", "r13" + +/* Macros to save and align the stack before making a function + call and restore it afterwards as gcc may not keep the stack + pointer aligned if it doesn't realise calls are being made + to other functions. */ + +#define VALGRIND_ALIGN_STACK \ + "mr 28,1\n\t" \ + "rldicr 1,1,0,59\n\t" +#define VALGRIND_RESTORE_STACK \ + "mr 1,28\n\t" + +/* These CALL_FN_ macros assume that on ppc64-linux, sizeof(unsigned + long) == 8. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+0]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+1]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+2]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+3]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+4]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1,arg2,arg3,arg4,arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+5]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_6W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+6]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + _argvec[2+6] = (unsigned long)arg6; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 8, 48(11)\n\t" /* arg6->r8 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+7]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + _argvec[2+6] = (unsigned long)arg6; \ + _argvec[2+7] = (unsigned long)arg7; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 8, 48(11)\n\t" /* arg6->r8 */ \ + "ld 9, 56(11)\n\t" /* arg7->r9 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+8]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + _argvec[2+6] = (unsigned long)arg6; \ + _argvec[2+7] = (unsigned long)arg7; \ + _argvec[2+8] = (unsigned long)arg8; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 8, 48(11)\n\t" /* arg6->r8 */ \ + "ld 9, 56(11)\n\t" /* arg7->r9 */ \ + "ld 10, 64(11)\n\t" /* arg8->r10 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+9]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + _argvec[2+6] = (unsigned long)arg6; \ + _argvec[2+7] = (unsigned long)arg7; \ + _argvec[2+8] = (unsigned long)arg8; \ + _argvec[2+9] = (unsigned long)arg9; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "addi 1,1,-128\n\t" /* expand stack frame */ \ + /* arg9 */ \ + "ld 3,72(11)\n\t" \ + "std 3,112(1)\n\t" \ + /* args1-8 */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 8, 48(11)\n\t" /* arg6->r8 */ \ + "ld 9, 56(11)\n\t" /* arg7->r9 */ \ + "ld 10, 64(11)\n\t" /* arg8->r10 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+10]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + _argvec[2+6] = (unsigned long)arg6; \ + _argvec[2+7] = (unsigned long)arg7; \ + _argvec[2+8] = (unsigned long)arg8; \ + _argvec[2+9] = (unsigned long)arg9; \ + _argvec[2+10] = (unsigned long)arg10; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "addi 1,1,-128\n\t" /* expand stack frame */ \ + /* arg10 */ \ + "ld 3,80(11)\n\t" \ + "std 3,120(1)\n\t" \ + /* arg9 */ \ + "ld 3,72(11)\n\t" \ + "std 3,112(1)\n\t" \ + /* args1-8 */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 8, 48(11)\n\t" /* arg6->r8 */ \ + "ld 9, 56(11)\n\t" /* arg7->r9 */ \ + "ld 10, 64(11)\n\t" /* arg8->r10 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10,arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+11]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + _argvec[2+6] = (unsigned long)arg6; \ + _argvec[2+7] = (unsigned long)arg7; \ + _argvec[2+8] = (unsigned long)arg8; \ + _argvec[2+9] = (unsigned long)arg9; \ + _argvec[2+10] = (unsigned long)arg10; \ + _argvec[2+11] = (unsigned long)arg11; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "addi 1,1,-144\n\t" /* expand stack frame */ \ + /* arg11 */ \ + "ld 3,88(11)\n\t" \ + "std 3,128(1)\n\t" \ + /* arg10 */ \ + "ld 3,80(11)\n\t" \ + "std 3,120(1)\n\t" \ + /* arg9 */ \ + "ld 3,72(11)\n\t" \ + "std 3,112(1)\n\t" \ + /* args1-8 */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 8, 48(11)\n\t" /* arg6->r8 */ \ + "ld 9, 56(11)\n\t" /* arg7->r9 */ \ + "ld 10, 64(11)\n\t" /* arg8->r10 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10,arg11,arg12) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3+12]; \ + volatile unsigned long _res; \ + /* _argvec[0] holds current r2 across the call */ \ + _argvec[1] = (unsigned long)_orig.r2; \ + _argvec[2] = (unsigned long)_orig.nraddr; \ + _argvec[2+1] = (unsigned long)arg1; \ + _argvec[2+2] = (unsigned long)arg2; \ + _argvec[2+3] = (unsigned long)arg3; \ + _argvec[2+4] = (unsigned long)arg4; \ + _argvec[2+5] = (unsigned long)arg5; \ + _argvec[2+6] = (unsigned long)arg6; \ + _argvec[2+7] = (unsigned long)arg7; \ + _argvec[2+8] = (unsigned long)arg8; \ + _argvec[2+9] = (unsigned long)arg9; \ + _argvec[2+10] = (unsigned long)arg10; \ + _argvec[2+11] = (unsigned long)arg11; \ + _argvec[2+12] = (unsigned long)arg12; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "mr 11,%1\n\t" \ + "std 2,-16(11)\n\t" /* save tocptr */ \ + "ld 2,-8(11)\n\t" /* use nraddr's tocptr */ \ + "addi 1,1,-144\n\t" /* expand stack frame */ \ + /* arg12 */ \ + "ld 3,96(11)\n\t" \ + "std 3,136(1)\n\t" \ + /* arg11 */ \ + "ld 3,88(11)\n\t" \ + "std 3,128(1)\n\t" \ + /* arg10 */ \ + "ld 3,80(11)\n\t" \ + "std 3,120(1)\n\t" \ + /* arg9 */ \ + "ld 3,72(11)\n\t" \ + "std 3,112(1)\n\t" \ + /* args1-8 */ \ + "ld 3, 8(11)\n\t" /* arg1->r3 */ \ + "ld 4, 16(11)\n\t" /* arg2->r4 */ \ + "ld 5, 24(11)\n\t" /* arg3->r5 */ \ + "ld 6, 32(11)\n\t" /* arg4->r6 */ \ + "ld 7, 40(11)\n\t" /* arg5->r7 */ \ + "ld 8, 48(11)\n\t" /* arg6->r8 */ \ + "ld 9, 56(11)\n\t" /* arg7->r9 */ \ + "ld 10, 64(11)\n\t" /* arg8->r10 */ \ + "ld 11, 0(11)\n\t" /* target->r11 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R11 \ + "mr 11,%1\n\t" \ + "mr %0,3\n\t" \ + "ld 2,-16(11)\n\t" /* restore tocptr */ \ + VALGRIND_RESTORE_STACK \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[2]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r28" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_ppc64_linux */ + +/* ------------------------- arm-linux ------------------------- */ + +#if defined(PLAT_arm_linux) + +/* These regs are trashed by the hidden call. */ +#define __CALLER_SAVED_REGS "r0", "r1", "r2", "r3","r4","r14" + +/* Macros to save and align the stack before making a function + call and restore it afterwards as gcc may not keep the stack + pointer aligned if it doesn't realise calls are being made + to other functions. */ + +/* This is a bit tricky. We store the original stack pointer in r10 + as it is callee-saves. gcc doesn't allow the use of r11 for some + reason. Also, we can't directly "bic" the stack pointer in thumb + mode since r13 isn't an allowed register number in that context. + So use r4 as a temporary, since that is about to get trashed + anyway, just after each use of this macro. Side effect is we need + to be very careful about any future changes, since + VALGRIND_ALIGN_STACK simply assumes r4 is usable. */ +#define VALGRIND_ALIGN_STACK \ + "mov r10, sp\n\t" \ + "mov r4, sp\n\t" \ + "bic r4, r4, #7\n\t" \ + "mov sp, r4\n\t" +#define VALGRIND_RESTORE_STACK \ + "mov sp, r10\n\t" + +/* These CALL_FN_ macros assume that on arm-linux, sizeof(unsigned + long) == 4. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1,arg2,arg3,arg4,arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[6]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "sub sp, sp, #4 \n\t" \ + "ldr r0, [%1, #20] \n\t" \ + "push {r0} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_6W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[7]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #20] \n\t" \ + "ldr r1, [%1, #24] \n\t" \ + "push {r0, r1} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[8]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "sub sp, sp, #4 \n\t" \ + "ldr r0, [%1, #20] \n\t" \ + "ldr r1, [%1, #24] \n\t" \ + "ldr r2, [%1, #28] \n\t" \ + "push {r0, r1, r2} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[9]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #20] \n\t" \ + "ldr r1, [%1, #24] \n\t" \ + "ldr r2, [%1, #28] \n\t" \ + "ldr r3, [%1, #32] \n\t" \ + "push {r0, r1, r2, r3} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[10]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "sub sp, sp, #4 \n\t" \ + "ldr r0, [%1, #20] \n\t" \ + "ldr r1, [%1, #24] \n\t" \ + "ldr r2, [%1, #28] \n\t" \ + "ldr r3, [%1, #32] \n\t" \ + "ldr r4, [%1, #36] \n\t" \ + "push {r0, r1, r2, r3, r4} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[11]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #40] \n\t" \ + "push {r0} \n\t" \ + "ldr r0, [%1, #20] \n\t" \ + "ldr r1, [%1, #24] \n\t" \ + "ldr r2, [%1, #28] \n\t" \ + "ldr r3, [%1, #32] \n\t" \ + "ldr r4, [%1, #36] \n\t" \ + "push {r0, r1, r2, r3, r4} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[12]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "sub sp, sp, #4 \n\t" \ + "ldr r0, [%1, #40] \n\t" \ + "ldr r1, [%1, #44] \n\t" \ + "push {r0, r1} \n\t" \ + "ldr r0, [%1, #20] \n\t" \ + "ldr r1, [%1, #24] \n\t" \ + "ldr r2, [%1, #28] \n\t" \ + "ldr r3, [%1, #32] \n\t" \ + "ldr r4, [%1, #36] \n\t" \ + "push {r0, r1, r2, r3, r4} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11,arg12) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[13]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + _argvec[12] = (unsigned long)(arg12); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr r0, [%1, #40] \n\t" \ + "ldr r1, [%1, #44] \n\t" \ + "ldr r2, [%1, #48] \n\t" \ + "push {r0, r1, r2} \n\t" \ + "ldr r0, [%1, #20] \n\t" \ + "ldr r1, [%1, #24] \n\t" \ + "ldr r2, [%1, #28] \n\t" \ + "ldr r3, [%1, #32] \n\t" \ + "ldr r4, [%1, #36] \n\t" \ + "push {r0, r1, r2, r3, r4} \n\t" \ + "ldr r0, [%1, #4] \n\t" \ + "ldr r1, [%1, #8] \n\t" \ + "ldr r2, [%1, #12] \n\t" \ + "ldr r3, [%1, #16] \n\t" \ + "ldr r4, [%1] \n\t" /* target->r4 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_R4 \ + VALGRIND_RESTORE_STACK \ + "mov %0, r0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "r10" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_arm_linux */ + +/* ------------------------ arm64-linux ------------------------ */ + +#if defined(PLAT_arm64_linux) + +/* These regs are trashed by the hidden call. */ +#define __CALLER_SAVED_REGS \ + "x0", "x1", "x2", "x3","x4", "x5", "x6", "x7", "x8", "x9", \ + "x10", "x11", "x12", "x13", "x14", "x15", "x16", "x17", \ + "x18", "x19", "x20", "x30", \ + "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7", "v8", "v9", \ + "v10", "v11", "v12", "v13", "v14", "v15", "v16", "v17", \ + "v18", "v19", "v20", "v21", "v22", "v23", "v24", "v25", \ + "v26", "v27", "v28", "v29", "v30", "v31" + +/* x21 is callee-saved, so we can use it to save and restore SP around + the hidden call. */ +#define VALGRIND_ALIGN_STACK \ + "mov x21, sp\n\t" \ + "bic sp, x21, #15\n\t" +#define VALGRIND_RESTORE_STACK \ + "mov sp, x21\n\t" + +/* These CALL_FN_ macros assume that on arm64-linux, + sizeof(unsigned long) == 8. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr x8, [%1] \n\t" /* target->x8 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_X8 \ + VALGRIND_RESTORE_STACK \ + "mov %0, x0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "x21" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr x0, [%1, #8] \n\t" \ + "ldr x8, [%1] \n\t" /* target->x8 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_X8 \ + VALGRIND_RESTORE_STACK \ + "mov %0, x0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS, "x21" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr x0, [%1, #8] \n\t" \ + "ldr x1, [%1, #16] \n\t" \ + "ldr x8, [%1] \n\t" /* target->x8 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_X8 \ + VALGRIND_RESTORE_STACK \ + "mov %0, x0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS/*, "r10"*/ \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr x0, [%1, #8] \n\t" \ + "ldr x1, [%1, #16] \n\t" \ + "ldr x2, [%1, #24] \n\t" \ + "ldr x8, [%1] \n\t" /* target->x8 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_X8 \ + VALGRIND_RESTORE_STACK \ + "mov %0, x0\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS/*, "r10"*/ \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + __asm__ volatile( \ + VALGRIND_ALIGN_STACK \ + "ldr x0, [%1, #8] \n\t" \ + "ldr x1, [%1, #16] \n\t" \ + "ldr x2, [%1, #24] \n\t" \ + "ldr x3, [%1, #32] \n\t" \ + "ldr x8, [%1] \n\t" /* target->x8 */ \ + VALGRIND_BRANCH_AND_LINK_TO_NOREDIR_X8 \ + VALGRIND_RESTORE_STACK \ + "mov %0, x0" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS/*, "r10"*/ \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_arm64_linux */ + +/* ------------------------- s390x-linux ------------------------- */ + +#if defined(PLAT_s390x_linux) + +/* Similar workaround as amd64 (see above), but we use r11 as frame + pointer and save the old r11 in r7. r11 might be used for + argvec, therefore we copy argvec in r1 since r1 is clobbered + after the call anyway. */ +#if defined(__GNUC__) && defined(__GCC_HAVE_DWARF2_CFI_ASM) +# define __FRAME_POINTER \ + ,"d"(__builtin_dwarf_cfa()) +# define VALGRIND_CFI_PROLOGUE \ + ".cfi_remember_state\n\t" \ + "lgr 1,%1\n\t" /* copy the argvec pointer in r1 */ \ + "lgr 7,11\n\t" \ + "lgr 11,%2\n\t" \ + ".cfi_def_cfa r11, 0\n\t" +# define VALGRIND_CFI_EPILOGUE \ + "lgr 11, 7\n\t" \ + ".cfi_restore_state\n\t" +#else +# define __FRAME_POINTER +# define VALGRIND_CFI_PROLOGUE \ + "lgr 1,%1\n\t" +# define VALGRIND_CFI_EPILOGUE +#endif + +/* Nb: On s390 the stack pointer is properly aligned *at all times* + according to the s390 GCC maintainer. (The ABI specification is not + precise in this regard.) Therefore, VALGRIND_ALIGN_STACK and + VALGRIND_RESTORE_STACK are not defined here. */ + +/* These regs are trashed by the hidden call. Note that we overwrite + r14 in s390_irgen_noredir (VEX/priv/guest_s390_irgen.c) to give the + function a proper return address. All others are ABI defined call + clobbers. */ +#define __CALLER_SAVED_REGS "0","1","2","3","4","5","14", \ + "f0","f1","f2","f3","f4","f5","f6","f7" + +/* Nb: Although r11 is modified in the asm snippets below (inside + VALGRIND_CFI_PROLOGUE) it is not listed in the clobber section, for + two reasons: + (1) r11 is restored in VALGRIND_CFI_EPILOGUE, so effectively it is not + modified + (2) GCC will complain that r11 cannot appear inside a clobber section, + when compiled with -O -fno-omit-frame-pointer + */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-160\n\t" \ + "lg 1, 0(1)\n\t" /* target->r1 */ \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,160\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "d" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +/* The call abi has the arguments in r2-r6 and stack */ +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-160\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,160\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1, arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-160\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,160\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1, arg2, arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-160\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,160\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1, arg2, arg3, arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-160\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,160\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1, arg2, arg3, arg4, arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[6]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-160\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,160\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_6W(lval, orig, arg1, arg2, arg3, arg4, arg5, \ + arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[7]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-168\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "mvc 160(8,15), 48(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,168\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1, arg2, arg3, arg4, arg5, \ + arg6, arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[8]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-176\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "mvc 160(8,15), 48(1)\n\t" \ + "mvc 168(8,15), 56(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,176\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1, arg2, arg3, arg4, arg5, \ + arg6, arg7 ,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[9]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-184\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "mvc 160(8,15), 48(1)\n\t" \ + "mvc 168(8,15), 56(1)\n\t" \ + "mvc 176(8,15), 64(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,184\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1, arg2, arg3, arg4, arg5, \ + arg6, arg7 ,arg8, arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[10]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-192\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "mvc 160(8,15), 48(1)\n\t" \ + "mvc 168(8,15), 56(1)\n\t" \ + "mvc 176(8,15), 64(1)\n\t" \ + "mvc 184(8,15), 72(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,192\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1, arg2, arg3, arg4, arg5, \ + arg6, arg7 ,arg8, arg9, arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[11]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + _argvec[10] = (unsigned long)arg10; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-200\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "mvc 160(8,15), 48(1)\n\t" \ + "mvc 168(8,15), 56(1)\n\t" \ + "mvc 176(8,15), 64(1)\n\t" \ + "mvc 184(8,15), 72(1)\n\t" \ + "mvc 192(8,15), 80(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,200\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1, arg2, arg3, arg4, arg5, \ + arg6, arg7 ,arg8, arg9, arg10, arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[12]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + _argvec[10] = (unsigned long)arg10; \ + _argvec[11] = (unsigned long)arg11; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-208\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "mvc 160(8,15), 48(1)\n\t" \ + "mvc 168(8,15), 56(1)\n\t" \ + "mvc 176(8,15), 64(1)\n\t" \ + "mvc 184(8,15), 72(1)\n\t" \ + "mvc 192(8,15), 80(1)\n\t" \ + "mvc 200(8,15), 88(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,208\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1, arg2, arg3, arg4, arg5, \ + arg6, arg7 ,arg8, arg9, arg10, arg11, arg12)\ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[13]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)arg1; \ + _argvec[2] = (unsigned long)arg2; \ + _argvec[3] = (unsigned long)arg3; \ + _argvec[4] = (unsigned long)arg4; \ + _argvec[5] = (unsigned long)arg5; \ + _argvec[6] = (unsigned long)arg6; \ + _argvec[7] = (unsigned long)arg7; \ + _argvec[8] = (unsigned long)arg8; \ + _argvec[9] = (unsigned long)arg9; \ + _argvec[10] = (unsigned long)arg10; \ + _argvec[11] = (unsigned long)arg11; \ + _argvec[12] = (unsigned long)arg12; \ + __asm__ volatile( \ + VALGRIND_CFI_PROLOGUE \ + "aghi 15,-216\n\t" \ + "lg 2, 8(1)\n\t" \ + "lg 3,16(1)\n\t" \ + "lg 4,24(1)\n\t" \ + "lg 5,32(1)\n\t" \ + "lg 6,40(1)\n\t" \ + "mvc 160(8,15), 48(1)\n\t" \ + "mvc 168(8,15), 56(1)\n\t" \ + "mvc 176(8,15), 64(1)\n\t" \ + "mvc 184(8,15), 72(1)\n\t" \ + "mvc 192(8,15), 80(1)\n\t" \ + "mvc 200(8,15), 88(1)\n\t" \ + "mvc 208(8,15), 96(1)\n\t" \ + "lg 1, 0(1)\n\t" \ + VALGRIND_CALL_NOREDIR_R1 \ + "lgr %0, 2\n\t" \ + "aghi 15,216\n\t" \ + VALGRIND_CFI_EPILOGUE \ + : /*out*/ "=d" (_res) \ + : /*in*/ "a" (&_argvec[0]) __FRAME_POINTER \ + : /*trash*/ "cc", "memory", __CALLER_SAVED_REGS,"6","7" \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + + +#endif /* PLAT_s390x_linux */ + +/* ------------------------- mips32-linux ----------------------- */ + +#if defined(PLAT_mips32_linux) + +/* These regs are trashed by the hidden call. */ +#define __CALLER_SAVED_REGS "$2", "$3", "$4", "$5", "$6", \ +"$7", "$8", "$9", "$10", "$11", "$12", "$13", "$14", "$15", "$24", \ +"$25", "$31" + +/* These CALL_FN_ macros assume that on mips-linux, sizeof(unsigned + long) == 4. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "subu $29, $29, 16 \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 16\n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "subu $29, $29, 16 \n\t" \ + "lw $4, 4(%1) \n\t" /* arg1*/ \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 16 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "subu $29, $29, 16 \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 16 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "subu $29, $29, 16 \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 16 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "subu $29, $29, 16 \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 16 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1,arg2,arg3,arg4,arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[6]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 24\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 24 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) +#define CALL_FN_W_6W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[7]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 32\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 24(%1) \n\t" \ + "nop\n\t" \ + "sw $4, 20($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 32 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[8]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 32\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 24(%1) \n\t" \ + "sw $4, 20($29) \n\t" \ + "lw $4, 28(%1) \n\t" \ + "sw $4, 24($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 32 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[9]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 40\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 24(%1) \n\t" \ + "sw $4, 20($29) \n\t" \ + "lw $4, 28(%1) \n\t" \ + "sw $4, 24($29) \n\t" \ + "lw $4, 32(%1) \n\t" \ + "sw $4, 28($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 40 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[10]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 40\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 24(%1) \n\t" \ + "sw $4, 20($29) \n\t" \ + "lw $4, 28(%1) \n\t" \ + "sw $4, 24($29) \n\t" \ + "lw $4, 32(%1) \n\t" \ + "sw $4, 28($29) \n\t" \ + "lw $4, 36(%1) \n\t" \ + "sw $4, 32($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 40 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[11]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 48\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 24(%1) \n\t" \ + "sw $4, 20($29) \n\t" \ + "lw $4, 28(%1) \n\t" \ + "sw $4, 24($29) \n\t" \ + "lw $4, 32(%1) \n\t" \ + "sw $4, 28($29) \n\t" \ + "lw $4, 36(%1) \n\t" \ + "sw $4, 32($29) \n\t" \ + "lw $4, 40(%1) \n\t" \ + "sw $4, 36($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 48 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[12]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 48\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 24(%1) \n\t" \ + "sw $4, 20($29) \n\t" \ + "lw $4, 28(%1) \n\t" \ + "sw $4, 24($29) \n\t" \ + "lw $4, 32(%1) \n\t" \ + "sw $4, 28($29) \n\t" \ + "lw $4, 36(%1) \n\t" \ + "sw $4, 32($29) \n\t" \ + "lw $4, 40(%1) \n\t" \ + "sw $4, 36($29) \n\t" \ + "lw $4, 44(%1) \n\t" \ + "sw $4, 40($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 48 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11,arg12) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[13]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + _argvec[12] = (unsigned long)(arg12); \ + __asm__ volatile( \ + "subu $29, $29, 8 \n\t" \ + "sw $28, 0($29) \n\t" \ + "sw $31, 4($29) \n\t" \ + "lw $4, 20(%1) \n\t" \ + "subu $29, $29, 56\n\t" \ + "sw $4, 16($29) \n\t" \ + "lw $4, 24(%1) \n\t" \ + "sw $4, 20($29) \n\t" \ + "lw $4, 28(%1) \n\t" \ + "sw $4, 24($29) \n\t" \ + "lw $4, 32(%1) \n\t" \ + "sw $4, 28($29) \n\t" \ + "lw $4, 36(%1) \n\t" \ + "sw $4, 32($29) \n\t" \ + "lw $4, 40(%1) \n\t" \ + "sw $4, 36($29) \n\t" \ + "lw $4, 44(%1) \n\t" \ + "sw $4, 40($29) \n\t" \ + "lw $4, 48(%1) \n\t" \ + "sw $4, 44($29) \n\t" \ + "lw $4, 4(%1) \n\t" \ + "lw $5, 8(%1) \n\t" \ + "lw $6, 12(%1) \n\t" \ + "lw $7, 16(%1) \n\t" \ + "lw $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "addu $29, $29, 56 \n\t" \ + "lw $28, 0($29) \n\t" \ + "lw $31, 4($29) \n\t" \ + "addu $29, $29, 8 \n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_mips32_linux */ + +/* ------------------------- mips64-linux ------------------------- */ + +#if defined(PLAT_mips64_linux) + +/* These regs are trashed by the hidden call. */ +#define __CALLER_SAVED_REGS "$2", "$3", "$4", "$5", "$6", \ +"$7", "$8", "$9", "$10", "$11", "$12", "$13", "$14", "$15", "$24", \ +"$25", "$31" + +/* These CALL_FN_ macros assume that on mips-linux, sizeof(unsigned + long) == 4. */ + +#define CALL_FN_W_v(lval, orig) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[1]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + __asm__ volatile( \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "0" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_W(lval, orig, arg1) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[2]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" /* arg1*/ \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WW(lval, orig, arg1,arg2) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[3]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWW(lval, orig, arg1,arg2,arg3) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[4]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_WWWW(lval, orig, arg1,arg2,arg3,arg4) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[5]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_5W(lval, orig, arg1,arg2,arg3,arg4,arg5) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[6]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_6W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[7]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $9, 48(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_7W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[8]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $9, 48(%1)\n\t" \ + "ld $10, 56(%1)\n\t" \ + "ld $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_8W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[9]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + __asm__ volatile( \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $9, 48(%1)\n\t" \ + "ld $10, 56(%1)\n\t" \ + "ld $11, 64(%1)\n\t" \ + "ld $25, 0(%1) \n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_9W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[10]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + __asm__ volatile( \ + "dsubu $29, $29, 8\n\t" \ + "ld $4, 72(%1)\n\t" \ + "sd $4, 0($29)\n\t" \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $9, 48(%1)\n\t" \ + "ld $10, 56(%1)\n\t" \ + "ld $11, 64(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "daddu $29, $29, 8\n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_10W(lval, orig, arg1,arg2,arg3,arg4,arg5,arg6, \ + arg7,arg8,arg9,arg10) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[11]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + __asm__ volatile( \ + "dsubu $29, $29, 16\n\t" \ + "ld $4, 72(%1)\n\t" \ + "sd $4, 0($29)\n\t" \ + "ld $4, 80(%1)\n\t" \ + "sd $4, 8($29)\n\t" \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $9, 48(%1)\n\t" \ + "ld $10, 56(%1)\n\t" \ + "ld $11, 64(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "daddu $29, $29, 16\n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_11W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[12]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + __asm__ volatile( \ + "dsubu $29, $29, 24\n\t" \ + "ld $4, 72(%1)\n\t" \ + "sd $4, 0($29)\n\t" \ + "ld $4, 80(%1)\n\t" \ + "sd $4, 8($29)\n\t" \ + "ld $4, 88(%1)\n\t" \ + "sd $4, 16($29)\n\t" \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $9, 48(%1)\n\t" \ + "ld $10, 56(%1)\n\t" \ + "ld $11, 64(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "daddu $29, $29, 24\n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#define CALL_FN_W_12W(lval, orig, arg1,arg2,arg3,arg4,arg5, \ + arg6,arg7,arg8,arg9,arg10, \ + arg11,arg12) \ + do { \ + volatile OrigFn _orig = (orig); \ + volatile unsigned long _argvec[13]; \ + volatile unsigned long _res; \ + _argvec[0] = (unsigned long)_orig.nraddr; \ + _argvec[1] = (unsigned long)(arg1); \ + _argvec[2] = (unsigned long)(arg2); \ + _argvec[3] = (unsigned long)(arg3); \ + _argvec[4] = (unsigned long)(arg4); \ + _argvec[5] = (unsigned long)(arg5); \ + _argvec[6] = (unsigned long)(arg6); \ + _argvec[7] = (unsigned long)(arg7); \ + _argvec[8] = (unsigned long)(arg8); \ + _argvec[9] = (unsigned long)(arg9); \ + _argvec[10] = (unsigned long)(arg10); \ + _argvec[11] = (unsigned long)(arg11); \ + _argvec[12] = (unsigned long)(arg12); \ + __asm__ volatile( \ + "dsubu $29, $29, 32\n\t" \ + "ld $4, 72(%1)\n\t" \ + "sd $4, 0($29)\n\t" \ + "ld $4, 80(%1)\n\t" \ + "sd $4, 8($29)\n\t" \ + "ld $4, 88(%1)\n\t" \ + "sd $4, 16($29)\n\t" \ + "ld $4, 96(%1)\n\t" \ + "sd $4, 24($29)\n\t" \ + "ld $4, 8(%1)\n\t" \ + "ld $5, 16(%1)\n\t" \ + "ld $6, 24(%1)\n\t" \ + "ld $7, 32(%1)\n\t" \ + "ld $8, 40(%1)\n\t" \ + "ld $9, 48(%1)\n\t" \ + "ld $10, 56(%1)\n\t" \ + "ld $11, 64(%1)\n\t" \ + "ld $25, 0(%1)\n\t" /* target->t9 */ \ + VALGRIND_CALL_NOREDIR_T9 \ + "daddu $29, $29, 32\n\t" \ + "move %0, $2\n" \ + : /*out*/ "=r" (_res) \ + : /*in*/ "r" (&_argvec[0]) \ + : /*trash*/ "memory", __CALLER_SAVED_REGS \ + ); \ + lval = (__typeof__(lval)) _res; \ + } while (0) + +#endif /* PLAT_mips64_linux */ + + +/* ------------------------------------------------------------------ */ +/* ARCHITECTURE INDEPENDENT MACROS for CLIENT REQUESTS. */ +/* */ +/* ------------------------------------------------------------------ */ + +/* Some request codes. There are many more of these, but most are not + exposed to end-user view. These are the public ones, all of the + form 0x1000 + small_number. + + Core ones are in the range 0x00000000--0x0000ffff. The non-public + ones start at 0x2000. +*/ + +/* These macros are used by tools -- they must be public, but don't + embed them into other programs. */ +#define VG_USERREQ_TOOL_BASE(a,b) \ + ((unsigned int)(((a)&0xff) << 24 | ((b)&0xff) << 16)) +#define VG_IS_TOOL_USERREQ(a, b, v) \ + (VG_USERREQ_TOOL_BASE(a,b) == ((v) & 0xffff0000)) + +/* !! ABIWARNING !! ABIWARNING !! ABIWARNING !! ABIWARNING !! + This enum comprises an ABI exported by Valgrind to programs + which use client requests. DO NOT CHANGE THE ORDER OF THESE + ENTRIES, NOR DELETE ANY -- add new ones at the end. */ +typedef + enum { VG_USERREQ__RUNNING_ON_VALGRIND = 0x1001, + VG_USERREQ__DISCARD_TRANSLATIONS = 0x1002, + + /* These allow any function to be called from the simulated + CPU but run on the real CPU. Nb: the first arg passed to + the function is always the ThreadId of the running + thread! So CLIENT_CALL0 actually requires a 1 arg + function, etc. */ + VG_USERREQ__CLIENT_CALL0 = 0x1101, + VG_USERREQ__CLIENT_CALL1 = 0x1102, + VG_USERREQ__CLIENT_CALL2 = 0x1103, + VG_USERREQ__CLIENT_CALL3 = 0x1104, + + /* Can be useful in regression testing suites -- eg. can + send Valgrind's output to /dev/null and still count + errors. */ + VG_USERREQ__COUNT_ERRORS = 0x1201, + + /* Allows the client program and/or gdbserver to execute a monitor + command. */ + VG_USERREQ__GDB_MONITOR_COMMAND = 0x1202, + + /* These are useful and can be interpreted by any tool that + tracks malloc() et al, by using vg_replace_malloc.c. */ + VG_USERREQ__MALLOCLIKE_BLOCK = 0x1301, + VG_USERREQ__RESIZEINPLACE_BLOCK = 0x130b, + VG_USERREQ__FREELIKE_BLOCK = 0x1302, + /* Memory pool support. */ + VG_USERREQ__CREATE_MEMPOOL = 0x1303, + VG_USERREQ__DESTROY_MEMPOOL = 0x1304, + VG_USERREQ__MEMPOOL_ALLOC = 0x1305, + VG_USERREQ__MEMPOOL_FREE = 0x1306, + VG_USERREQ__MEMPOOL_TRIM = 0x1307, + VG_USERREQ__MOVE_MEMPOOL = 0x1308, + VG_USERREQ__MEMPOOL_CHANGE = 0x1309, + VG_USERREQ__MEMPOOL_EXISTS = 0x130a, + + /* Allow printfs to valgrind log. */ + /* The first two pass the va_list argument by value, which + assumes it is the same size as or smaller than a UWord, + which generally isn't the case. Hence are deprecated. + The second two pass the vargs by reference and so are + immune to this problem. */ + /* both :: char* fmt, va_list vargs (DEPRECATED) */ + VG_USERREQ__PRINTF = 0x1401, + VG_USERREQ__PRINTF_BACKTRACE = 0x1402, + /* both :: char* fmt, va_list* vargs */ + VG_USERREQ__PRINTF_VALIST_BY_REF = 0x1403, + VG_USERREQ__PRINTF_BACKTRACE_VALIST_BY_REF = 0x1404, + + /* Stack support. */ + VG_USERREQ__STACK_REGISTER = 0x1501, + VG_USERREQ__STACK_DEREGISTER = 0x1502, + VG_USERREQ__STACK_CHANGE = 0x1503, + + /* Wine support */ + VG_USERREQ__LOAD_PDB_DEBUGINFO = 0x1601, + + /* Querying of debug info. */ + VG_USERREQ__MAP_IP_TO_SRCLOC = 0x1701, + + /* Disable/enable error reporting level. Takes a single + Word arg which is the delta to this thread's error + disablement indicator. Hence 1 disables or further + disables errors, and -1 moves back towards enablement. + Other values are not allowed. */ + VG_USERREQ__CHANGE_ERR_DISABLEMENT = 0x1801, + + /* Initialise IR injection */ + VG_USERREQ__VEX_INIT_FOR_IRI = 0x1901 + } Vg_ClientRequest; + +#if !defined(__GNUC__) +# define __extension__ /* */ +#endif + + +/* Returns the number of Valgrinds this code is running under. That + is, 0 if running natively, 1 if running under Valgrind, 2 if + running under Valgrind which is running under another Valgrind, + etc. */ +#define RUNNING_ON_VALGRIND \ + (unsigned)VALGRIND_DO_CLIENT_REQUEST_EXPR(0 /* if not */, \ + VG_USERREQ__RUNNING_ON_VALGRIND, \ + 0, 0, 0, 0, 0) \ + + +/* Discard translation of code in the range [_qzz_addr .. _qzz_addr + + _qzz_len - 1]. Useful if you are debugging a JITter or some such, + since it provides a way to make sure valgrind will retranslate the + invalidated area. Returns no value. */ +#define VALGRIND_DISCARD_TRANSLATIONS(_qzz_addr,_qzz_len) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__DISCARD_TRANSLATIONS, \ + _qzz_addr, _qzz_len, 0, 0, 0) + + +/* These requests are for getting Valgrind itself to print something. + Possibly with a backtrace. This is a really ugly hack. The return value + is the number of characters printed, excluding the "**** " part at the + start and the backtrace (if present). */ + +#if defined(__GNUC__) || defined(__INTEL_COMPILER) && !defined(_MSC_VER) +/* Modern GCC will optimize the static routine out if unused, + and unused attribute will shut down warnings about it. */ +static int VALGRIND_PRINTF(const char *format, ...) + __attribute__((format(__printf__, 1, 2), __unused__)); +#endif +static int +#if defined(_MSC_VER) +__inline +#endif +VALGRIND_PRINTF(const char *format, ...) +{ +#if defined(NVALGRIND) + return 0; +#else /* NVALGRIND */ +#if defined(_MSC_VER) || defined(__MINGW64__) + uintptr_t _qzz_res; +#else + unsigned long _qzz_res; +#endif + va_list vargs; + va_start(vargs, format); +#if defined(_MSC_VER) || defined(__MINGW64__) + _qzz_res = VALGRIND_DO_CLIENT_REQUEST_EXPR(0, + VG_USERREQ__PRINTF_VALIST_BY_REF, + (uintptr_t)format, + (uintptr_t)&vargs, + 0, 0, 0); +#else + _qzz_res = VALGRIND_DO_CLIENT_REQUEST_EXPR(0, + VG_USERREQ__PRINTF_VALIST_BY_REF, + (unsigned long)format, + (unsigned long)&vargs, + 0, 0, 0); +#endif + va_end(vargs); + return (int)_qzz_res; +#endif /* NVALGRIND */ +} + +#if defined(__GNUC__) || defined(__INTEL_COMPILER) && !defined(_MSC_VER) +static int VALGRIND_PRINTF_BACKTRACE(const char *format, ...) + __attribute__((format(__printf__, 1, 2), __unused__)); +#endif +static int +#if defined(_MSC_VER) +__inline +#endif +VALGRIND_PRINTF_BACKTRACE(const char *format, ...) +{ +#if defined(NVALGRIND) + return 0; +#else /* NVALGRIND */ +#if defined(_MSC_VER) || defined(__MINGW64__) + uintptr_t _qzz_res; +#else + unsigned long _qzz_res; +#endif + va_list vargs; + va_start(vargs, format); +#if defined(_MSC_VER) || defined(__MINGW64__) + _qzz_res = VALGRIND_DO_CLIENT_REQUEST_EXPR(0, + VG_USERREQ__PRINTF_BACKTRACE_VALIST_BY_REF, + (uintptr_t)format, + (uintptr_t)&vargs, + 0, 0, 0); +#else + _qzz_res = VALGRIND_DO_CLIENT_REQUEST_EXPR(0, + VG_USERREQ__PRINTF_BACKTRACE_VALIST_BY_REF, + (unsigned long)format, + (unsigned long)&vargs, + 0, 0, 0); +#endif + va_end(vargs); + return (int)_qzz_res; +#endif /* NVALGRIND */ +} + + +/* These requests allow control to move from the simulated CPU to the + real CPU, calling an arbitary function. + + Note that the current ThreadId is inserted as the first argument. + So this call: + + VALGRIND_NON_SIMD_CALL2(f, arg1, arg2) + + requires f to have this signature: + + Word f(Word tid, Word arg1, Word arg2) + + where "Word" is a word-sized type. + + Note that these client requests are not entirely reliable. For example, + if you call a function with them that subsequently calls printf(), + there's a high chance Valgrind will crash. Generally, your prospects of + these working are made higher if the called function does not refer to + any global variables, and does not refer to any libc or other functions + (printf et al). Any kind of entanglement with libc or dynamic linking is + likely to have a bad outcome, for tricky reasons which we've grappled + with a lot in the past. +*/ +#define VALGRIND_NON_SIMD_CALL0(_qyy_fn) \ + VALGRIND_DO_CLIENT_REQUEST_EXPR(0 /* default return */, \ + VG_USERREQ__CLIENT_CALL0, \ + _qyy_fn, \ + 0, 0, 0, 0) + +#define VALGRIND_NON_SIMD_CALL1(_qyy_fn, _qyy_arg1) \ + VALGRIND_DO_CLIENT_REQUEST_EXPR(0 /* default return */, \ + VG_USERREQ__CLIENT_CALL1, \ + _qyy_fn, \ + _qyy_arg1, 0, 0, 0) + +#define VALGRIND_NON_SIMD_CALL2(_qyy_fn, _qyy_arg1, _qyy_arg2) \ + VALGRIND_DO_CLIENT_REQUEST_EXPR(0 /* default return */, \ + VG_USERREQ__CLIENT_CALL2, \ + _qyy_fn, \ + _qyy_arg1, _qyy_arg2, 0, 0) + +#define VALGRIND_NON_SIMD_CALL3(_qyy_fn, _qyy_arg1, _qyy_arg2, _qyy_arg3) \ + VALGRIND_DO_CLIENT_REQUEST_EXPR(0 /* default return */, \ + VG_USERREQ__CLIENT_CALL3, \ + _qyy_fn, \ + _qyy_arg1, _qyy_arg2, \ + _qyy_arg3, 0) + + +/* Counts the number of errors that have been recorded by a tool. Nb: + the tool must record the errors with VG_(maybe_record_error)() or + VG_(unique_error)() for them to be counted. */ +#define VALGRIND_COUNT_ERRORS \ + (unsigned)VALGRIND_DO_CLIENT_REQUEST_EXPR( \ + 0 /* default return */, \ + VG_USERREQ__COUNT_ERRORS, \ + 0, 0, 0, 0, 0) + +/* Several Valgrind tools (Memcheck, Massif, Helgrind, DRD) rely on knowing + when heap blocks are allocated in order to give accurate results. This + happens automatically for the standard allocator functions such as + malloc(), calloc(), realloc(), memalign(), new, new[], free(), delete, + delete[], etc. + + But if your program uses a custom allocator, this doesn't automatically + happen, and Valgrind will not do as well. For example, if you allocate + superblocks with mmap() and then allocates chunks of the superblocks, all + Valgrind's observations will be at the mmap() level and it won't know that + the chunks should be considered separate entities. In Memcheck's case, + that means you probably won't get heap block overrun detection (because + there won't be redzones marked as unaddressable) and you definitely won't + get any leak detection. + + The following client requests allow a custom allocator to be annotated so + that it can be handled accurately by Valgrind. + + VALGRIND_MALLOCLIKE_BLOCK marks a region of memory as having been allocated + by a malloc()-like function. For Memcheck (an illustrative case), this + does two things: + + - It records that the block has been allocated. This means any addresses + within the block mentioned in error messages will be + identified as belonging to the block. It also means that if the block + isn't freed it will be detected by the leak checker. + + - It marks the block as being addressable and undefined (if 'is_zeroed' is + not set), or addressable and defined (if 'is_zeroed' is set). This + controls how accesses to the block by the program are handled. + + 'addr' is the start of the usable block (ie. after any + redzone), 'sizeB' is its size. 'rzB' is the redzone size if the allocator + can apply redzones -- these are blocks of padding at the start and end of + each block. Adding redzones is recommended as it makes it much more likely + Valgrind will spot block overruns. `is_zeroed' indicates if the memory is + zeroed (or filled with another predictable value), as is the case for + calloc(). + + VALGRIND_MALLOCLIKE_BLOCK should be put immediately after the point where a + heap block -- that will be used by the client program -- is allocated. + It's best to put it at the outermost level of the allocator if possible; + for example, if you have a function my_alloc() which calls + internal_alloc(), and the client request is put inside internal_alloc(), + stack traces relating to the heap block will contain entries for both + my_alloc() and internal_alloc(), which is probably not what you want. + + For Memcheck users: if you use VALGRIND_MALLOCLIKE_BLOCK to carve out + custom blocks from within a heap block, B, that has been allocated with + malloc/calloc/new/etc, then block B will be *ignored* during leak-checking + -- the custom blocks will take precedence. + + VALGRIND_FREELIKE_BLOCK is the partner to VALGRIND_MALLOCLIKE_BLOCK. For + Memcheck, it does two things: + + - It records that the block has been deallocated. This assumes that the + block was annotated as having been allocated via + VALGRIND_MALLOCLIKE_BLOCK. Otherwise, an error will be issued. + + - It marks the block as being unaddressable. + + VALGRIND_FREELIKE_BLOCK should be put immediately after the point where a + heap block is deallocated. + + VALGRIND_RESIZEINPLACE_BLOCK informs a tool about reallocation. For + Memcheck, it does four things: + + - It records that the size of a block has been changed. This assumes that + the block was annotated as having been allocated via + VALGRIND_MALLOCLIKE_BLOCK. Otherwise, an error will be issued. + + - If the block shrunk, it marks the freed memory as being unaddressable. + + - If the block grew, it marks the new area as undefined and defines a red + zone past the end of the new block. + + - The V-bits of the overlap between the old and the new block are preserved. + + VALGRIND_RESIZEINPLACE_BLOCK should be put after allocation of the new block + and before deallocation of the old block. + + In many cases, these three client requests will not be enough to get your + allocator working well with Memcheck. More specifically, if your allocator + writes to freed blocks in any way then a VALGRIND_MAKE_MEM_UNDEFINED call + will be necessary to mark the memory as addressable just before the zeroing + occurs, otherwise you'll get a lot of invalid write errors. For example, + you'll need to do this if your allocator recycles freed blocks, but it + zeroes them before handing them back out (via VALGRIND_MALLOCLIKE_BLOCK). + Alternatively, if your allocator reuses freed blocks for allocator-internal + data structures, VALGRIND_MAKE_MEM_UNDEFINED calls will also be necessary. + + Really, what's happening is a blurring of the lines between the client + program and the allocator... after VALGRIND_FREELIKE_BLOCK is called, the + memory should be considered unaddressable to the client program, but the + allocator knows more than the rest of the client program and so may be able + to safely access it. Extra client requests are necessary for Valgrind to + understand the distinction between the allocator and the rest of the + program. + + Ignored if addr == 0. +*/ +#define VALGRIND_MALLOCLIKE_BLOCK(addr, sizeB, rzB, is_zeroed) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__MALLOCLIKE_BLOCK, \ + addr, sizeB, rzB, is_zeroed, 0) + +/* See the comment for VALGRIND_MALLOCLIKE_BLOCK for details. + Ignored if addr == 0. +*/ +#define VALGRIND_RESIZEINPLACE_BLOCK(addr, oldSizeB, newSizeB, rzB) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__RESIZEINPLACE_BLOCK, \ + addr, oldSizeB, newSizeB, rzB, 0) + +/* See the comment for VALGRIND_MALLOCLIKE_BLOCK for details. + Ignored if addr == 0. +*/ +#define VALGRIND_FREELIKE_BLOCK(addr, rzB) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__FREELIKE_BLOCK, \ + addr, rzB, 0, 0, 0) + +/* Create a memory pool. */ +#define VALGRIND_CREATE_MEMPOOL(pool, rzB, is_zeroed) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__CREATE_MEMPOOL, \ + pool, rzB, is_zeroed, 0, 0) + +/* Destroy a memory pool. */ +#define VALGRIND_DESTROY_MEMPOOL(pool) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__DESTROY_MEMPOOL, \ + pool, 0, 0, 0, 0) + +/* Associate a piece of memory with a memory pool. */ +#define VALGRIND_MEMPOOL_ALLOC(pool, addr, size) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__MEMPOOL_ALLOC, \ + pool, addr, size, 0, 0) + +/* Disassociate a piece of memory from a memory pool. */ +#define VALGRIND_MEMPOOL_FREE(pool, addr) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__MEMPOOL_FREE, \ + pool, addr, 0, 0, 0) + +/* Disassociate any pieces outside a particular range. */ +#define VALGRIND_MEMPOOL_TRIM(pool, addr, size) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__MEMPOOL_TRIM, \ + pool, addr, size, 0, 0) + +/* Resize and/or move a piece associated with a memory pool. */ +#define VALGRIND_MOVE_MEMPOOL(poolA, poolB) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__MOVE_MEMPOOL, \ + poolA, poolB, 0, 0, 0) + +/* Resize and/or move a piece associated with a memory pool. */ +#define VALGRIND_MEMPOOL_CHANGE(pool, addrA, addrB, size) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__MEMPOOL_CHANGE, \ + pool, addrA, addrB, size, 0) + +/* Return 1 if a mempool exists, else 0. */ +#define VALGRIND_MEMPOOL_EXISTS(pool) \ + (unsigned)VALGRIND_DO_CLIENT_REQUEST_EXPR(0, \ + VG_USERREQ__MEMPOOL_EXISTS, \ + pool, 0, 0, 0, 0) + +/* Mark a piece of memory as being a stack. Returns a stack id. */ +#define VALGRIND_STACK_REGISTER(start, end) \ + (unsigned)VALGRIND_DO_CLIENT_REQUEST_EXPR(0, \ + VG_USERREQ__STACK_REGISTER, \ + start, end, 0, 0, 0) + +/* Unmark the piece of memory associated with a stack id as being a + stack. */ +#define VALGRIND_STACK_DEREGISTER(id) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__STACK_DEREGISTER, \ + id, 0, 0, 0, 0) + +/* Change the start and end address of the stack id. */ +#define VALGRIND_STACK_CHANGE(id, start, end) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__STACK_CHANGE, \ + id, start, end, 0, 0) + +/* Load PDB debug info for Wine PE image_map. */ +#define VALGRIND_LOAD_PDB_DEBUGINFO(fd, ptr, total_size, delta) \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__LOAD_PDB_DEBUGINFO, \ + fd, ptr, total_size, delta, 0) + +/* Map a code address to a source file name and line number. buf64 + must point to a 64-byte buffer in the caller's address space. The + result will be dumped in there and is guaranteed to be zero + terminated. If no info is found, the first byte is set to zero. */ +#define VALGRIND_MAP_IP_TO_SRCLOC(addr, buf64) \ + (unsigned)VALGRIND_DO_CLIENT_REQUEST_EXPR(0, \ + VG_USERREQ__MAP_IP_TO_SRCLOC, \ + addr, buf64, 0, 0, 0) + +/* Disable error reporting for this thread. Behaves in a stack like + way, so you can safely call this multiple times provided that + VALGRIND_ENABLE_ERROR_REPORTING is called the same number of times + to re-enable reporting. The first call of this macro disables + reporting. Subsequent calls have no effect except to increase the + number of VALGRIND_ENABLE_ERROR_REPORTING calls needed to re-enable + reporting. Child threads do not inherit this setting from their + parents -- they are always created with reporting enabled. */ +#define VALGRIND_DISABLE_ERROR_REPORTING \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__CHANGE_ERR_DISABLEMENT, \ + 1, 0, 0, 0, 0) + +/* Re-enable error reporting, as per comments on + VALGRIND_DISABLE_ERROR_REPORTING. */ +#define VALGRIND_ENABLE_ERROR_REPORTING \ + VALGRIND_DO_CLIENT_REQUEST_STMT(VG_USERREQ__CHANGE_ERR_DISABLEMENT, \ + -1, 0, 0, 0, 0) + +/* Execute a monitor command from the client program. + If a connection is opened with GDB, the output will be sent + according to the output mode set for vgdb. + If no connection is opened, output will go to the log output. + Returns 1 if command not recognised, 0 otherwise. */ +#define VALGRIND_MONITOR_COMMAND(command) \ + VALGRIND_DO_CLIENT_REQUEST_EXPR(0, VG_USERREQ__GDB_MONITOR_COMMAND, \ + command, 0, 0, 0, 0) + + +#undef PLAT_x86_darwin +#undef PLAT_amd64_darwin +#undef PLAT_x86_win32 +#undef PLAT_amd64_win64 +#undef PLAT_x86_linux +#undef PLAT_amd64_linux +#undef PLAT_ppc32_linux +#undef PLAT_ppc64_linux +#undef PLAT_arm_linux +#undef PLAT_s390x_linux +#undef PLAT_mips32_linux +#undef PLAT_mips64_linux + +#endif /* __VALGRIND_H */ diff -Naur ns-3.19/src/core/model/wall-clock-synchronizer.h ns-3.20/src/core/model/wall-clock-synchronizer.h --- ns-3.19/src/core/model/wall-clock-synchronizer.h 2014-06-17 10:34:00.632635164 -0700 +++ ns-3.20/src/core/model/wall-clock-synchronizer.h 2014-06-17 10:33:13.966995398 -0700 @@ -67,6 +67,7 @@ static const uint64_t US_PER_NS = (uint64_t)1000; static const uint64_t US_PER_SEC = (uint64_t)1000000; + /// Conversion from ns to s. static const uint64_t NS_PER_SEC = (uint64_t)1000000000; protected: @@ -156,8 +157,9 @@ * real-time-clock-specific work of waiting (either busy-waiting or sleeping, * or some combination) until the requested simulation time. * - * @param ns The simulation time we need to wait for (normalized to nanosecond - * units). + * @param nsCurrent The current simulation time. + * @param nsDelay The simulation time of the next event (in nanosecond units). + * * @see TimeStepPrecision::Get */ virtual bool DoSynchronize (uint64_t nsCurrent, uint64_t nsDelay); diff -Naur ns-3.19/src/core/test/attribute-test-suite.cc ns-3.20/src/core/test/attribute-test-suite.cc --- ns-3.19/src/core/test/attribute-test-suite.cc 2014-06-17 10:34:00.635635140 -0700 +++ ns-3.20/src/core/test/attribute-test-suite.cc 2014-06-17 10:33:13.968995383 -0700 @@ -72,8 +72,7 @@ Derived () {} }; -NS_OBJECT_ENSURE_REGISTERED (Derived) - ; +NS_OBJECT_ENSURE_REGISTERED (Derived); class AttributeObjectTest : public Object { @@ -264,8 +263,7 @@ Time m_timeWithBounds; }; -NS_OBJECT_ENSURE_REGISTERED (AttributeObjectTest) - ; +NS_OBJECT_ENSURE_REGISTERED (AttributeObjectTest); // =========================================================================== // Test case template used for generic Attribute Value types -- used to make diff -Naur ns-3.19/src/core/test/event-garbage-collector-test-suite.cc ns-3.20/src/core/test/event-garbage-collector-test-suite.cc --- ns-3.19/src/core/test/event-garbage-collector-test-suite.cc 2014-06-17 10:34:00.636635133 -0700 +++ ns-3.20/src/core/test/event-garbage-collector-test-suite.cc 2014-06-17 10:33:13.970995367 -0700 @@ -21,7 +21,7 @@ #include "ns3/test.h" #include "ns3/event-garbage-collector.h" -namespace ns3 { +using namespace ns3; class EventGarbageCollectorTestCase : public TestCase { @@ -84,6 +84,3 @@ AddTestCase (new EventGarbageCollectorTestCase (), TestCase::QUICK); } } g_eventGarbageCollectorTests; - -} - diff -Naur ns-3.19/src/core/test/global-value-test-suite.cc ns-3.20/src/core/test/global-value-test-suite.cc --- ns-3.19/src/core/test/global-value-test-suite.cc 2014-06-17 10:34:00.637635125 -0700 +++ ns-3.20/src/core/test/global-value-test-suite.cc 2014-06-17 10:33:13.970995367 -0700 @@ -21,7 +21,7 @@ #include "ns3/test.h" #include "ns3/uinteger.h" -namespace ns3 { +using namespace ns3; // =========================================================================== // Test for the ability to get at a GlobalValue. @@ -89,6 +89,3 @@ } static GlobalValueTestSuite globalValueTestSuite; - -} // namespace ns3 - diff -Naur ns-3.19/src/core/test/hash-test-suite.cc ns-3.20/src/core/test/hash-test-suite.cc --- ns-3.19/src/core/test/hash-test-suite.cc 2014-06-17 10:34:00.637635125 -0700 +++ ns-3.20/src/core/test/hash-test-suite.cc 2014-06-17 10:33:13.971995360 -0700 @@ -24,7 +24,7 @@ #include "ns3/test.h" #include "ns3/hash.h" -namespace ns3 { +using namespace ns3; /** * Base class for hash tests @@ -385,5 +385,3 @@ } static HashTestSuite g_hashTestSuite; - -} // namespace ns3 diff -Naur ns-3.19/src/core/test/int64x64-test-suite.cc ns-3.20/src/core/test/int64x64-test-suite.cc --- ns-3.19/src/core/test/int64x64-test-suite.cc 2014-06-17 10:34:00.638635117 -0700 +++ ns-3.20/src/core/test/int64x64-test-suite.cc 2014-06-17 10:33:13.972995352 -0700 @@ -1,37 +1,150 @@ #include "ns3/int64x64.h" #include "ns3/test.h" +#include "ns3/valgrind.h" // Bug 1882 + +#include // fabs +#include +#include // numeric_limits<>::epsilon () using namespace ns3; -class Int64x64FracTestCase : public TestCase +namespace ns3 { + + namespace int64x64 { + + namespace test { + +/** + * \class ns3::int64x64::Int64x64TestSuite + * \internal + * + * Some of these tests are a little unusual for ns-3 in that they + * are sensitive to implementation, specifically the resolution + * of the double and long double implementations. + * + * To handle this, where needed we define a tolerance to use in the + * test comparisions. If you need to increase the tolerance, + * please append the system and compiler version. For example: + * + * \code + * // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + * tolerance = 1; + * // System Foo gcc 3.9 + * tolerance = 3; + * \endcode + */ + + +class Printer { public: - Int64x64FracTestCase (); + Printer (const int64_t high, const uint64_t low) + : m_haveInt (false), + m_value (0), + m_high (high), + m_low (low) + { } + + Printer (const int64x64_t value) + : m_haveInt (true), + m_value (value), + m_high (value.GetHigh ()), + m_low (value.GetLow ()) + { } + +private: + friend std::ostream & operator << (std::ostream & os, const Printer & p); + + bool m_haveInt; + int64x64_t m_value; + int64_t m_high; + uint64_t m_low; +}; + +std::ostream & operator << (std::ostream & os, const Printer & p) +{ + if (p.m_haveInt) + { + os << std::fixed << std::setprecision (22) + << p.m_value; + + } + + os << std::hex << std::setfill ('0') + << " (0x" << std::setw (16) << p.m_high + << " 0x" << std::setw (16) << p.m_low << ")" + << std::dec << std::setfill (' '); + return os; +} + + +class Int64x64HiLoTestCase : public TestCase +{ +public: + Int64x64HiLoTestCase (); virtual void DoRun (void); - void CheckFrac (int64_t hi, uint64_t lo); + void Check (const int64_t hi, const uint64_t lo); }; -void -Int64x64FracTestCase::CheckFrac (int64_t hi, uint64_t lo) +Int64x64HiLoTestCase::Int64x64HiLoTestCase () + : TestCase ("Manipulate the high and low part of every number") { - int64x64_t tmp = int64x64_t (hi,lo); - NS_TEST_EXPECT_MSG_EQ (tmp.GetHigh (), hi, - "High part does not match"); - NS_TEST_EXPECT_MSG_EQ (tmp.GetLow (), lo, - "Low part does not match"); } -Int64x64FracTestCase::Int64x64FracTestCase () - : TestCase ("Check that we can manipulate the high and low part of every number") +void +Int64x64HiLoTestCase::Check (const int64_t hi, const uint64_t lo) { + uint64_t tolerance = 0; + if (int64x64_t::implementation == int64x64_t::ld_impl) + { + // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + tolerance = 1; + } + + int64x64_t value = int64x64_t (hi,lo); + uint64_t vLow = value.GetLow (); + bool pass = ( (value.GetHigh () == hi) + && ( (Max (vLow, lo) - Min (vLow, lo)) <= tolerance) + ); + + std::cout << GetParent ()->GetName () << " Check: " + << (pass ? "pass " : "FAIL ") + << Printer (value) << " from" << Printer (hi, lo) + << std::endl; + + NS_TEST_EXPECT_MSG_EQ (value.GetHigh (), hi, + "High part does not match for hi:" << hi + << " lo: " << lo); + NS_TEST_EXPECT_MSG_EQ_TOL ((int64_t)vLow, (int64_t)lo, (int64_t)tolerance, + "Low part does not match for hi: " << hi + << " lo: " << lo); } + void -Int64x64FracTestCase::DoRun (void) +Int64x64HiLoTestCase::DoRun (void) { - CheckFrac (1, 0); - CheckFrac (1, 1); - CheckFrac (-1, 0); - CheckFrac (-1, 1); + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Check: " << GetName () + << std::endl; + + uint64_t low = 1; + if (int64x64_t::implementation == int64x64_t::ld_impl) + { + // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + low = HP_MAX_64 * std::numeric_limits::epsilon (); + } + + Check ( 0, 0); + Check ( 0, low); + Check ( 0, 0xffffffffffffffffULL - low); + + Check ( 1, 0); + Check ( 1, low); + Check ( 1, 0xffffffffffffffffULL - low); + + Check (-1, 0); + Check (-1, low); + Check (-1, 0xffffffffffffffffULL - low); } @@ -40,136 +153,301 @@ public: Int64x64InputTestCase (); virtual void DoRun (void); - void CheckString (std::string str, int64_t hi, uint64_t lo); + void Check (const std::string & str, + const int64_t hi, const uint64_t lo, + const int64_t tolerance = 0); }; Int64x64InputTestCase::Int64x64InputTestCase () - : TestCase ("Check that we parse Int64x64 numbers as strings") + : TestCase ("Parse int64x64_t numbers as strings") { } void -Int64x64InputTestCase::CheckString (std::string str, int64_t hi, uint64_t lo) +Int64x64InputTestCase::Check (const std::string & str, + const int64_t hi, const uint64_t lo, + const int64_t tolerance /* = 0 */) + { std::istringstream iss; iss.str (str); - int64x64_t hp; - iss >> hp; - NS_TEST_EXPECT_MSG_EQ (hp.GetHigh (), hi, "High parts do not match for input string " << str); - NS_TEST_EXPECT_MSG_EQ (hp.GetLow (), lo, "Low parts do not match for input string " << str); + int64x64_t value; + iss >> value; + + std::string input = "\"" + str + "\""; + uint64_t vLow = value.GetLow (); + bool pass = ( (value.GetHigh () == hi) && + ( Max (vLow, lo) - Min (vLow, lo) <= tolerance) + ); + + std::cout << GetParent ()->GetName () << " Input: " + << (pass ? "pass " : "FAIL ") + << std::left << std::setw (28) << input << std::right + << Printer (value) + << " expected: " << Printer (hi, lo) << " +/- " << tolerance + << std::endl; + + NS_TEST_EXPECT_MSG_EQ (value.GetHigh (), hi, + "High parts do not match for input string \"" + << str << "\""); + NS_TEST_EXPECT_MSG_EQ_TOL ((int64_t)value.GetLow (), (int64_t)lo, tolerance, + "Low parts do not match for input string \"" + << str << "\""); } void Int64x64InputTestCase::DoRun (void) { - CheckString ("1", 1, 0); - CheckString ("+1", 1, 0); - CheckString ("-1", -1, 0); - CheckString ("1.0", 1, 0); - CheckString ("+1.0", 1, 0); - CheckString ("001.0", 1, 0); - CheckString ("+001.0", 1, 0); - CheckString ("020.0", 20, 0); - CheckString ("+020.0", 20, 0); - CheckString ("-1.0", -1, 0); - CheckString ("-1.0000", -1, 0); - CheckString ("1.0000000", 1, 0); - CheckString ("1.08446744073709551615", 1, 8446744073709551615LL); - CheckString ("-1.08446744073709551615", -1, 8446744073709551615LL); + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Input: " << GetName () + << std::endl; + + int64_t tolerance = 0; + if (int64x64_t::implementation == int64x64_t::ld_impl) + { + // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + tolerance = 2; + } + + Check ("1", 1, 0); + Check ("+1", 1, 0); + Check ("-1", -1, 0); + Check ("1.0", 1, 0); + Check ("+1.0", 1, 0); + Check ("001.0", 1, 0); + Check ("+001.0", 1, 0); + Check ("020.0", 20, 0); + Check ("+020.0", 20, 0); + Check ("1.0000000", 1, 0); + Check ("-1.0", -1, 0, tolerance); + Check ("-1.0000", -1, 0, tolerance); + Check (" 1.000000000000000000054", 1, 1, tolerance); + Check ("-1.000000000000000000054", -2, -1, tolerance); } + class Int64x64InputOutputTestCase : public TestCase { public: Int64x64InputOutputTestCase (); virtual void DoRun (void); - void CheckString (std::string str); + void Check (const std::string & str, + const int64_t tolerance = 0); }; Int64x64InputOutputTestCase::Int64x64InputOutputTestCase () - : TestCase ("Check that we can roundtrip Int64x64 numbers as strings") + : TestCase ("Roundtrip int64x64_t numbers as strings") { } void -Int64x64InputOutputTestCase::CheckString (std::string str) +Int64x64InputOutputTestCase::Check (const std::string & str, + const int64_t tolerance /* = 0 */) { - std::istringstream iss; - iss.str (str); + std::stringstream iss (str); + int64x64_t expect; + iss >> expect; + + std::stringstream oss; + oss << std::scientific << std::setprecision (21) << expect; int64x64_t value; - iss >> value; - std::ostringstream oss; - oss << value; - NS_TEST_EXPECT_MSG_EQ (oss.str (), str, "Converted string does not match expected string"); + oss >> value; + + bool pass = Abs (value - expect) <= int64x64_t (0, tolerance + 1); + + std::string input = "\"" + str + "\""; + std::string output = "\"" + oss.str () + "\""; + + if (pass) + { + std::cout << GetParent ()->GetName () << " InputOutput: " + << (pass ? "pass " : "FAIL ") + << " in: " << std::left << std::setw (28) << input + << " out: " << std::left << std::setw (28) << output + << std::right + << std::endl; + } + else + { + std::cout << GetParent ()->GetName () << " InputOutput: " + << (pass ? "pass " : "FAIL ") + << " in: " << std::left << std::setw (28) << input + << std::right << Printer (expect) + << std::endl; + std::cout << GetParent ()->GetName () + << std::setw (19) << " " + << " out: " << std::left << std::setw (28) << output + << std::right << Printer (value) + << std::endl; + } + + NS_TEST_EXPECT_MSG_EQ_TOL (value, expect, int64x64_t (0, tolerance), + "Converted string does not match expected string"); } + void Int64x64InputOutputTestCase::DoRun (void) { - CheckString ("+1.0"); - CheckString ("-1.0"); - CheckString ("+20.0"); - CheckString ("+1.08446744073709551615"); - CheckString ("-1.08446744073709551615"); - CheckString ("+1.18446744073709551615"); - CheckString ("-1.18446744073709551615"); + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " InputOutput: " << GetName () + << std::endl; + + int64_t tolerance = 0; + if (int64x64_t::implementation == int64x64_t::ld_impl) + { + // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + tolerance = 1; + } + + Check ("+1.000000000000000000000"); + Check ("+20.000000000000000000000"); + Check ("+0.000000000000000000000", tolerance); + Check ("-1.000000000000000000000", tolerance); + Check ("+1.084467440737095516158", tolerance); + Check ("-2.084467440737095516158", tolerance); + Check ("+3.184467440737095516179", tolerance); + Check ("-4.184467440737095516179", tolerance); } -#define CHECK_EXPECTED(a,b) \ - NS_TEST_ASSERT_MSG_EQ ((a).GetHigh (),b,"Arithmetic failure: " << ((a).GetHigh ()) << "!=" << (b)) - -#define V(v) \ - int64x64_t (v) class Int64x64ArithmeticTestCase : public TestCase { public: Int64x64ArithmeticTestCase (); virtual void DoRun (void); + void Check (const int test, + const int64x64_t value, const int64x64_t expect); + void Check (const int test, + const int64x64_t value, const int64x64_t expect, + const int64x64_t tolerance); }; Int64x64ArithmeticTestCase::Int64x64ArithmeticTestCase () - : TestCase ("Check basic arithmetic operations") + : TestCase ("Basic arithmetic operations") { } void -Int64x64ArithmeticTestCase::DoRun (void) +Int64x64ArithmeticTestCase::Check (const int test, + const int64x64_t value, + const int64x64_t expect) { - int64x64_t a, b; + int64x64_t zero (0,0); + Check (test, value, expect, zero); +} +void +Int64x64ArithmeticTestCase::Check (const int test, + const int64x64_t value, + const int64x64_t expect, + const int64x64_t tolerance) +{ + bool pass = Abs (value - expect) <= tolerance; + + std::cout << GetParent ()->GetName () << " Arithmetic: " + << (pass ? "pass " : "FAIL ") + << test << ": " << value << " == " << expect + << " (+/- " << tolerance << ")" + << std::endl; + + NS_TEST_ASSERT_MSG_EQ_TOL ( value, expect, tolerance, + "Arithmetic failure in test case " << test); +} - CHECK_EXPECTED (V (1) - V (1), 0); - CHECK_EXPECTED (V (1) - V (2), -1); - CHECK_EXPECTED (V (1) - V (3), -2); - CHECK_EXPECTED (V (1) - V (-1), 2); - CHECK_EXPECTED (V (1) - V (-2), 3); - CHECK_EXPECTED (V (-3) - V (-4), 1); - CHECK_EXPECTED (V (-2) - V (3), -5); - CHECK_EXPECTED (V (1) + V (2), 3); - CHECK_EXPECTED (V (1) + V (-3), -2); - CHECK_EXPECTED (V (0) + V (0), 0); - CHECK_EXPECTED (V (0) * V (0), 0); - CHECK_EXPECTED (V (0) * V (1), 0); - CHECK_EXPECTED (V (0) * V (-1), 0); - CHECK_EXPECTED (V (1) * V (0), 0); - CHECK_EXPECTED (V (1) * V (1), 1); - CHECK_EXPECTED (V (1) * V (-1), -1); - CHECK_EXPECTED (V (-1) * V (-1), 1); - CHECK_EXPECTED (V (0) * V (1), 0); - CHECK_EXPECTED (V (0) * V (-1), 0); - CHECK_EXPECTED (V (-1) * V (1), -1); - - - CHECK_EXPECTED (V (2) * V (3) / V (3), 2); - - // Below, the division loses precision because 2/3 is not - // representable exactly in 64.64 integers. So, we got - // something super close but the final rounding kills us. - a = V (2); - b = V (3); - a /= b; - a *= b; - CHECK_EXPECTED (V (2) / V (3) * V (3), 1); +void +Int64x64ArithmeticTestCase::DoRun (void) +{ + const int64x64_t tol1 (0, 1); + const int64x64_t zero (0, 0); + const int64x64_t one (1, 0); + const int64x64_t two (2, 0); + const int64x64_t thre (3, 0); + + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Arithmetic: " << GetName () + << std::endl; + + Check ( 0, zero - zero , zero ); + Check ( 1, zero - one , -one ); + Check ( 2, one - one , zero ); + Check ( 3, one - two , -one ); + Check ( 4, one - (-one ), two ); + Check ( 5, (-one ) - (-two ), one ); + Check ( 6, (-one ) - two , -thre ); + + Check ( 7, zero + zero , zero ); + Check ( 8, zero + one , one ); + Check ( 9, one + one , two ); + Check (10, one + two , thre ); + Check (11, one + (-one ), zero ); + Check (12, (-one ) + (-two ), -thre ); + Check (13, (-one ) + two , one ); + + Check (14, zero * zero , zero ); + Check (15, zero * one , zero ); + Check (16, zero * (-one ), zero ); + Check (17, one * one , one ); + Check (18, one * (-one ), -one ); + Check (19, (-one ) * (-one ), one ); + + Check (20, (two * thre ) / thre , two ); + + const int64x64_t frac = int64x64_t (0, 0xc000000000000000ULL); // 0.75 + const int64x64_t fplf2 = frac + frac * frac; // 1.3125 + + Check (21, frac, 0.75); + Check (22, fplf2, 1.3125); + + const int64x64_t zerof = zero + frac; + const int64x64_t onef = one + frac; + const int64x64_t twof = two + frac; + const int64x64_t thref = thre + frac; + + Check (23, zerof, frac); + + + Check (24, zerof - zerof, zero ); + Check (25, zerof - onef, -one ); + Check (26, onef - onef, zero ); + Check (27, onef - twof, -one ); + Check (28, onef - (-onef), twof + frac ); + Check (29 , (-onef) - (-twof), one ); + Check (30 , (-onef) - twof, -thref - frac ); + + Check (31, zerof + zerof, zerof + frac ); + Check (32, zerof + onef, onef + frac ); + Check (33, onef + onef, twof + frac ); + Check (34, onef + twof, thref + frac ); + Check (35, onef + (-onef), zero ); + Check (36 , (-onef) + (-twof), -thref - frac ); + Check (37, (-onef) + twof, one ); + + Check (38, zerof * zerof, frac * frac ); + Check (39 , zero * onef, zero ); + Check (40 , zerof * one, frac ); + + Check (41, zerof * onef, fplf2 ); + Check (42, zerof * (-onef), -fplf2 ); + Check (43, onef * onef, onef + fplf2 ); + Check (44, onef * (-onef), -onef - fplf2 ); + Check (45, (-onef) * (-onef), onef + fplf2 ); + + + // Multiplication followed by division is exact: + Check (46, (two * thre ) / thre , two ); + Check (47, (twof * thref) / thref, twof ); + + // Division followed by multiplication loses a bit or two: + Check (48, (two / thre) * thre, two , 2 * tol1 ); + Check (49, (twof / thref) * thref, twof, 3 * tol1 ); // The example below shows that we really do not lose // much precision internally: it is almost always the // final conversion which loses precision. - CHECK_EXPECTED (V (2000000000) / V (3) * V (3), 1999999999); + Check (50, (int64x64_t (2000000000) / int64x64_t (3)) * int64x64_t (3), + int64x64_t (1999999999, 0xfffffffffffffffeULL)); + + // Check special values + Check (51, int64x64_t (0, 0x159fa87f8aeaad21ULL) * 10, + int64x64_t (0, 0xd83c94fb6d2ac34aULL)); + } + + /** * See \bugid{455} */ @@ -178,6 +456,8 @@ public: Int64x64Bug455TestCase (); virtual void DoRun (void); + void Check (const double result, const double expect, + const std::string & msg); }; Int64x64Bug455TestCase::Int64x64Bug455TestCase () @@ -185,25 +465,51 @@ { } void +Int64x64Bug455TestCase::Check (const double result, const double expect, + const std::string & msg) +{ + bool pass = result == expect; + + std::cout << GetParent ()->GetName () << " Bug 455: " + << (pass ? "pass " : "FAIL ") + << "res: " << result + << " exp: " << expect + << ": " << msg + << std::endl; + + NS_TEST_ASSERT_MSG_EQ (result, expect, msg); +} + +void Int64x64Bug455TestCase::DoRun (void) { + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Bug 455: " << GetName () + << std::endl; + int64x64_t a = int64x64_t (0.1); a /= int64x64_t (1.25); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), 0.08, "The original testcase"); + Check (a.GetDouble (), 0.08, "The original testcase"); + a = int64x64_t (0.5); a *= int64x64_t (5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), 2.5, "Simple test for multiplication"); + Check (a.GetDouble (), 2.5, "Simple test for multiplication"); + a = int64x64_t (-0.5); a *= int64x64_t (5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), -2.5, "Test sign, first operation negative"); + Check (a.GetDouble (), -2.5, "Test sign, first operation negative"); + a = int64x64_t (-0.5); a *=int64x64_t (-5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), 2.5, "both operands negative"); + Check (a.GetDouble (), 2.5, "both operands negative"); + a = int64x64_t (0.5); a *= int64x64_t (-5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), -2.5, "only second operand negative"); + Check (a.GetDouble (), -2.5, "only second operand negative"); } + + /** * See \bugid{863} */ @@ -212,6 +518,8 @@ public: Int64x64Bug863TestCase (); virtual void DoRun (void); + void Check (const double result, const double expect, + const std::string & msg); }; Int64x64Bug863TestCase::Int64x64Bug863TestCase () @@ -219,125 +527,686 @@ { } void +Int64x64Bug863TestCase::Check (const double result, const double expect, + const std::string & msg) +{ + bool pass = result == expect; + + std::cout << GetParent ()->GetName () << " Bug 863: " + << (pass ? "pass " : "FAIL ") + << "res: " << result + << " exp: " << expect + << ": " << msg + << std::endl; + + NS_TEST_ASSERT_MSG_EQ (result, expect, msg); +} + +void Int64x64Bug863TestCase::DoRun (void) { + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Bug 863: " << GetName () + << std::endl; + int64x64_t a = int64x64_t (0.9); a /= int64x64_t (1); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), 0.9, "The original testcase"); + Check (a.GetDouble (), 0.9, "The original testcase"); + a = int64x64_t (0.5); a /= int64x64_t (0.5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), 1.0, "Simple test for division"); + Check (a.GetDouble (), 1.0, "Simple test for division"); + a = int64x64_t (-0.5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), -0.5, "Check that we actually convert doubles correctly"); + Check (a.GetDouble (), -0.5, "Check that we actually convert doubles correctly"); + a /= int64x64_t (0.5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), -1.0, "first argument negative"); + Check (a.GetDouble (), -1.0, "first argument negative"); + a = int64x64_t (0.5); a /= int64x64_t (-0.5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), -1.0, "second argument negative"); + Check (a.GetDouble (), -1.0, "second argument negative"); + a = int64x64_t (-0.5); a /= int64x64_t (-0.5); - NS_TEST_ASSERT_MSG_EQ (a.GetDouble (), 1.0, "both arguments negative"); + Check (a.GetDouble (), 1.0, "both arguments negative"); } + +/** + * See \bugid{1786} + */ +class Int64x64Bug1786TestCase : public TestCase +{ +public: + Int64x64Bug1786TestCase (); + virtual void DoRun (void); + void Check (const uint64_t low, const std::string & value, + const int64_t tolerance = 0); +}; + +Int64x64Bug1786TestCase::Int64x64Bug1786TestCase () + : TestCase ("Test case for bug 1786") +{ +} +void +Int64x64Bug1786TestCase::Check (const uint64_t low, + const std::string & str, + const int64_t tolerance /* = 0 */) +{ + int64x64_t value (0, low); + std::ostringstream oss; + oss << std::scientific << std::setprecision (22) << value; + + if (tolerance == 0) + { + bool pass = oss.str () == str; + + std::cout << GetParent ()->GetName () << " Bug 1786: " + << (pass ? "pass " : "FAIL ") + << " 0x" << std::hex << std::setw (16) << low << std::dec + << " = " << oss.str (); + if (!pass) + { + std::cout << ", expected " << str; + } + std::cout << std::endl; + + NS_TEST_EXPECT_MSG_EQ (oss.str (), str, + "Fraction string not correct"); + } + else + { + // No obvious way to implement a tolerance on the strings + + std::cout << GetParent ()->GetName () << " Bug 1786: " + << "skip " + << " 0x" << std::hex << std::setw (16) << low << std::dec + << " = " << oss.str () + << ", expected " << str + << std::endl; + + } +} +void +Int64x64Bug1786TestCase::DoRun (void) +{ + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " But 1786: " << GetName () + << std::endl; + + int64_t tolerance = 0; + if (int64x64_t::implementation == int64x64_t::ld_impl) + { + // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + tolerance = 1; + } + + // Some of these values differ from the DoubleTestCase + // by one count in the last place + // because operator<< truncates the last output digit, + // instead of rounding. + Check ( 1ULL, "+0.0000000000000000000542"); + Check ( 2ULL, "+0.0000000000000000001084"); + Check ( 3ULL, "+0.0000000000000000001626"); + Check ( 4ULL, "+0.0000000000000000002168"); + Check ( 5ULL, "+0.0000000000000000002710"); + Check ( 6ULL, "+0.0000000000000000003253"); + Check ( 7ULL, "+0.0000000000000000003795"); + Check ( 8ULL, "+0.0000000000000000004337"); + Check ( 9ULL, "+0.0000000000000000004879"); + Check ( 0xAULL, "+0.0000000000000000005421"); + Check ( 0xFULL, "+0.0000000000000000008132"); + Check ( 0xF0ULL, "+0.0000000000000000130104"); + Check ( 0xF00ULL, "+0.0000000000000002081668"); + Check ( 0xF000ULL, "+0.0000000000000033306691"); + Check ( 0xF0000ULL, "+0.0000000000000532907052"); + Check ( 0xF00000ULL, "+0.0000000000008526512829"); + Check ( 0xF000000ULL, "+0.0000000000136424205266"); + Check ( 0xF0000000ULL, "+0.0000000002182787284255"); + Check ( 0xF00000000ULL, "+0.0000000034924596548080"); + Check ( 0xF000000000ULL, "+0.0000000558793544769287"); + Check ( 0xF0000000000ULL, "+0.0000008940696716308594"); + Check ( 0xF00000000000ULL, "+0.0000143051147460937500"); + Check ( 0xF000000000000ULL, "+0.0002288818359375000000"); + Check ( 0xF0000000000000ULL, "+0.0036621093750000000000"); + Check ( 0xF00000000000000ULL, "+0.0585937500000000000000"); + std::cout << std::endl; + Check (0x7FFFFFFFFFFFFFFDULL, "+0.4999999999999999998374", tolerance); + Check (0x7FFFFFFFFFFFFFFEULL, "+0.4999999999999999998916", tolerance); + Check (0x7FFFFFFFFFFFFFFFULL, "+0.4999999999999999999458", tolerance); + Check (0x8000000000000000ULL, "+0.5000000000000000000000"); + Check (0x8000000000000001ULL, "+0.5000000000000000000542", tolerance); + Check (0x8000000000000002ULL, "+0.5000000000000000001084", tolerance); + Check (0x8000000000000003ULL, "+0.5000000000000000001626", tolerance); + std::cout << std::endl; + Check (0xF000000000000000ULL, "+0.9375000000000000000000"); + Check (0xFF00000000000000ULL, "+0.9960937500000000000000"); + Check (0xFFF0000000000000ULL, "+0.9997558593750000000000"); + Check (0xFFFF000000000000ULL, "+0.9999847412109375000000"); + Check (0xFFFFF00000000000ULL, "+0.9999990463256835937500"); + Check (0xFFFFFF0000000000ULL, "+0.9999999403953552246094"); + Check (0xFFFFFFF000000000ULL, "+0.9999999962747097015381"); + Check (0xFFFFFFFF00000000ULL, "+0.9999999997671693563461"); + Check (0xFFFFFFFFF0000000ULL, "+0.9999999999854480847716"); + Check (0xFFFFFFFFFF000000ULL, "+0.9999999999990905052982"); + Check (0xFFFFFFFFFFF00000ULL, "+0.9999999999999431565811"); + Check (0xFFFFFFFFFFFF0000ULL, "+0.9999999999999964472863"); + Check (0xFFFFFFFFFFFFF000ULL, "+0.9999999999999997779554"); + Check (0xFFFFFFFFFFFFFF00ULL, "+0.9999999999999999861222"); + Check (0xFFFFFFFFFFFFFFF0ULL, "+0.9999999999999999991326"); + Check (0xFFFFFFFFFFFFFFF5ULL, "+0.9999999999999999994037", tolerance); + Check (0xFFFFFFFFFFFFFFF6ULL, "+0.9999999999999999994579", tolerance); + Check (0xFFFFFFFFFFFFFFF7ULL, "+0.9999999999999999995121", tolerance); + Check (0xFFFFFFFFFFFFFFF8ULL, "+0.9999999999999999995663", tolerance); + Check (0xFFFFFFFFFFFFFFF9ULL, "+0.9999999999999999996205", tolerance); + Check (0xFFFFFFFFFFFFFFFAULL, "+0.9999999999999999996747", tolerance); + Check (0xFFFFFFFFFFFFFFFBULL, "+0.9999999999999999997289", tolerance); + Check (0xFFFFFFFFFFFFFFFCULL, "+0.9999999999999999997832", tolerance); + Check (0xFFFFFFFFFFFFFFFDULL, "+0.9999999999999999998374", tolerance); + Check (0xFFFFFFFFFFFFFFFEULL, "+0.9999999999999999998916", tolerance); + Check (0xFFFFFFFFFFFFFFFFULL, "+0.9999999999999999999458", tolerance); +} + + class Int64x64CompareTestCase : public TestCase { public: Int64x64CompareTestCase (); virtual void DoRun (void); + + void Check (const bool result, const bool expect, + const std::string & msg); }; Int64x64CompareTestCase::Int64x64CompareTestCase () - : TestCase ("Check basic compare operations") + : TestCase ("Basic compare operations") { } void -Int64x64CompareTestCase::DoRun (void) +Int64x64CompareTestCase::Check (const bool result, const bool expect, + const std::string & msg) { + bool pass = result == expect; + + std::cout << GetParent ()->GetName () << " Compare: " + << (pass ? "pass " : "FAIL ") + << msg + << std::endl; + + NS_TEST_ASSERT_MSG_EQ (result, expect, msg); +} - NS_TEST_ASSERT_MSG_EQ ((V (-1) < V (1)), true, "a is smaller than b"); - NS_TEST_ASSERT_MSG_EQ ((V (-1) > V (-2)), true, "a is bigger than b"); - NS_TEST_ASSERT_MSG_EQ ((V (-1) == V (-1)), true, "a is equal to b"); - - NS_TEST_ASSERT_MSG_EQ ((V (1) > V (-1)), true, "a is bigger than b"); - NS_TEST_ASSERT_MSG_EQ ((V (1) < V (2)), true, "a is smaller than b"); +void +Int64x64CompareTestCase::DoRun (void) +{ + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Compare: " << GetName () + << std::endl; + + const int64x64_t zero ( 0, 0); + const int64x64_t one ( 1, 0); + const int64x64_t two ( 2, 0); + const int64x64_t mone (-1, 0); + const int64x64_t mtwo (-2, 0); + const int64x64_t frac = int64x64_t (0, 0xc000000000000000ULL); // 0.75 + const int64x64_t zerof = zero + frac; + const int64x64_t onef = one + frac; + const int64x64_t monef = mone - frac; + const int64x64_t mtwof = mtwo - frac; + + Check ( zerof == zerof, true, "equality, zero"); + Check ( onef == onef, true, "equality, positive"); + Check ( mtwof == mtwof, true, "equality, negative"); + Check ( zero == one, false, "equality false, zero"); + Check ( one == two, false, "equality false, unsigned"); + Check ( one == mone, false, "equality false, signed"); + Check ( onef == one, false, "equality false, fraction"); + std::cout << std::endl; + + Check ( zerof != zerof, false, "inequality, zero"); + Check ( onef != onef, false, "inequality, positive"); + Check ( mtwof != mtwof, false, "inequality, negative"); + Check ( zero != one, true, "inequality true, zero"); + Check ( one != two, true, "inequality true, unsigned"); + Check ( one != mone, true, "inequality true, signed"); + Check ( onef != one, true, "inequality true, fraction"); + std::cout << std::endl; + + Check ( zerof < onef, true, "less, zerof"); + Check ( zero < zerof, true, "less, zero"); + Check ( one < onef, true, "less, positive"); + Check ( monef < mone, true, "less, negative"); + Check ( onef < one, false, "less, false, positive"); + Check ( mtwo < mtwof, false, "less, false, negative"); + std::cout << std::endl; + + Check ( zerof <= zerof, true, "less equal, equal, zerof"); + Check ( zero <= zerof, true, "less equal, less, zero"); + Check ( onef <= onef, true, "less equal, equal, positive"); + Check ( monef <= mone, true, "less equal, less, negative"); + Check ( onef <= one, false, "less equal, false, positive"); + Check ( mtwo <= mtwof, false, "less equal, false, negative"); + std::cout << std::endl; + + Check ( onef > zerof, true, "greater, zerof"); + Check ( zerof > zero, true, "greater, zero"); + Check ( onef > one, true, "greater, positive"); + Check ( mone > monef, true, "greater, negative"); + Check ( one > onef, false, "greater, false, positive"); + Check ( mtwof > mtwo, false, "greater, false, negative"); + std::cout << std::endl; + + Check ( zerof >= zerof, true, "greater equal, equal, zerof"); + Check ( zerof >= zero, true, "greater equal, greater, zero"); + Check ( onef >= onef, true, "greater equal, equal, positive"); + Check ( mone >= monef, true, "greater equal, greater, negative"); + Check ( one >= onef, false, "greater equal, false, positive"); + Check ( mtwof >= mtwo, false, "greater equal, false, negative"); + std::cout << std::endl; + + Check ( zero == false, true, "zero == false"); + Check ( one == true, true, "one == true"); + Check ( zerof != false, true, "zerof != false"); + Check ( (!zero) == true, true, "!zero == true"); + Check ( (!zerof) == false, true, "!zerof == false"); + Check ( (!one) == false, true, "!one == false"); + Check ( (+onef) == onef, true, "unary positive"); + Check ( (-onef) == monef, true, "unary negative"); } + class Int64x64InvertTestCase : public TestCase { public: Int64x64InvertTestCase (); virtual void DoRun (void); + void Check (const int64_t factor); + void CheckCase (const uint64_t factor, + const int64x64_t result, const int64x64_t expect, + const std::string & msg, + const double tolerance = 0); }; Int64x64InvertTestCase::Int64x64InvertTestCase () - : TestCase ("Test case for invertion") + : TestCase ("Invert and MulByInvert") { } +void +Int64x64InvertTestCase::CheckCase (const uint64_t factor, + const int64x64_t result, + const int64x64_t expect, + const std::string & msg, + const double tolerance /* = 0 */) +{ + bool pass = Abs (result - expect) <= tolerance; + + std::cout << GetParent ()->GetName () << " Invert: "; + + if (pass) + { + std::cout << "pass: " << factor << ": "; + + } + else + { + std::cout << "FAIL: " << factor << ": " + << "(res: " << result + << " exp: " << expect + << " tol: " << tolerance << ") "; + } + std::cout << msg + << std::endl; + + NS_TEST_ASSERT_MSG_EQ_TOL (result, expect, int64x64_t(tolerance), msg); +} + +void +Int64x64InvertTestCase::Check (const int64_t factor) +{ + const int64x64_t one (1, 0); + const int64x64_t factorI = one / int64x64_t (factor); + + const int64x64_t a = int64x64_t::Invert (factor); + int64x64_t b = int64x64_t (factor); + + double tolerance = 0; + if (int64x64_t::implementation == int64x64_t::ld_impl) + { + // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + tolerance = 0.000000000000000001L; + } + + b.MulByInvert (a); + CheckCase (factor, b, one, "x * x^-1 == 1", tolerance); + + int64x64_t c = int64x64_t (1); + c.MulByInvert (a); + CheckCase (factor, c, factorI, "1 * x^-1 == 1 / x"); + + int64x64_t d = int64x64_t (1); + d /= (int64x64_t (factor)); + CheckCase (factor, d, c, "1/x == x^-1"); + + int64x64_t e = int64x64_t (-factor); + e.MulByInvert (a); + CheckCase (factor, e, -one, "-x * x^-1 == -1", tolerance); +} void Int64x64InvertTestCase::DoRun (void) { -#define TEST(factor) \ - do { \ - int64x64_t a; \ - a = int64x64_t::Invert (factor); \ - int64x64_t b = V (factor); \ - b.MulByInvert (a); \ - NS_TEST_ASSERT_MSG_EQ (b.GetHigh (), 1, \ - "x * 1/x should be 1 for x=" << factor); \ - int64x64_t c = V (1); \ - c.MulByInvert (a); \ - NS_TEST_ASSERT_MSG_EQ (c.GetHigh (), 0, \ - "1 * 1/x should be 0 for x=" << factor); \ - int64x64_t d = V (1); \ - d /= (V (factor)); \ - NS_TEST_ASSERT_MSG_EQ (d.GetDouble (), c.GetDouble (), \ - "1 * 1/x should be equal to 1/x for x=" << factor); \ - int64x64_t e = V (-factor); \ - e.MulByInvert (a); \ - NS_TEST_ASSERT_MSG_EQ (e.GetHigh (), -1, \ - "-x * 1/x should be -1 for x=" << factor); \ - } \ - while(false) - TEST (2); - TEST (3); - TEST (4); - TEST (5); - TEST (6); - TEST (10); - TEST (99); - TEST (100); - TEST (1000); - TEST (10000); - TEST (100000); - TEST (100000); - TEST (1000000); - TEST (10000000); - TEST (100000000); - TEST (1000000000); - TEST (10000000000LL); - TEST (100000000000LL); - TEST (1000000000000LL); - TEST (10000000000000LL); - TEST (100000000000000LL); - TEST (1000000000000000LL); -#undef TEST + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Invert: " << GetName () + << std::endl; + + Check (2); + Check (3); + Check (4); + Check (5); + Check (6); + Check (10); + Check (99); + Check (100); + Check (1000); + Check (10000); + Check (100000); + Check (100000); + Check (1000000); + Check (10000000); + Check (100000000); + Check (1000000000); + Check (10000000000LL); + Check (100000000000LL); + Check (1000000000000LL); + Check (10000000000000LL); + Check (100000000000000LL); + Check (1000000000000000LL); +} + + +class Int64x64DoubleTestCase : public TestCase +{ +public: + Int64x64DoubleTestCase (); + virtual void DoRun (void); + void Check (const int64_t intPart); + void Check (const long double value, + const int64_t intPart, + const uint64_t lo); +private: + long double m_last; + int64x64_t m_deltaMax; + int m_deltaCount; +}; + +Int64x64DoubleTestCase::Int64x64DoubleTestCase () + : TestCase ("Construct from floating point.") +{ +} + +void +Int64x64DoubleTestCase::Check (const long double value, + const int64_t intPart, + const uint64_t lo) +{ + // Construct the expected value + int64x64_t expect = int64x64_t (0, lo); + expect += intPart; + + // Actual value of conversion from double + const int64x64_t result = int64x64_t (value); + + // Make tolerance depend on magnitude of value + long double epsilon = std::numeric_limits::epsilon (); + long double margin = 0; + if (int64x64_t::implementation == int64x64_t::ld_impl) + { + // Darwin 12.5.0 (Mac 10.8.5) g++ 4.2.1 + margin = 1.0; + } + if (RUNNING_ON_VALGRIND) + { + // Valgrind uses 64-bit doubles for long doubles + // See ns-3 bug 1882 + // Need non-zero margin to ensure final tolerance is non-zero + margin = 1.0; + epsilon = std::numeric_limits::epsilon (); + } + + const int64x64_t tolerance = (margin + std::fabs (value)) * epsilon; + + const int64x64_t delta = Abs (result - expect); + const bool skip = value == m_last; + const bool pass = delta <= tolerance; + + // Save stream format flags + std::ios_base::fmtflags ff = std::cout.flags (); + std::cout << std::fixed << std::setprecision (22); + + std::cout << GetParent ()->GetName () << " Double: " + << (skip ? "skip " : (pass ? "pass " : "FAIL ")) + << std::showpos << value << " == " + << Printer (result) + << std::endl; + + // Log non-zero delta + if ( delta > int64x64_t() ) + { + std::cout << GetParent ()->GetName () + << std::left << std::setw (43) << " expected" + << std::right << Printer (expect) + << std::endl; + + if (delta == tolerance) + { + std::cout << GetParent ()->GetName () + << std::left << std::setw (43) << " delta = tolerance" + << std::right << Printer (delta) + << std::endl; + } + else + { + std::cout << GetParent ()->GetName () + << std::left << std::setw (43) << " delta" + << std::right << Printer (delta) + << std::endl; + std::cout << GetParent ()->GetName () + << std::left << std::setw (43) << " +/-" + << std::right << Printer (tolerance) + << std::endl; + } + + ++m_deltaCount; + + if ( delta > m_deltaMax ) + { + m_deltaMax = delta; + } + } + + NS_TEST_ASSERT_MSG_EQ_TOL (result, expect, tolerance, + "int64x64_t (long double) failed"); + m_last = value; + std::cout.flags (ff); + +} + +void +Int64x64DoubleTestCase::Check (const int64_t intPart) +{ + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Double: " + << "integer: " << intPart + << std::endl; + m_last = intPart; + m_deltaCount = 0; + + // Nudging the integer part eliminates deltas around 0 + long double v = intPart; + + Check (v +0.0000000000000000000542L, intPart, 0x1ULL); + Check (v +0.0000000000000000001084L, intPart, 0x2ULL); + Check (v +0.0000000000000000001626L, intPart, 0x3ULL); + Check (v +0.0000000000000000002168L, intPart, 0x4ULL); + Check (v +0.0000000000000000002710L, intPart, 0x5ULL); + Check (v +0.0000000000000000003253L, intPart, 0x6ULL); + Check (v +0.0000000000000000003795L, intPart, 0x7ULL); + Check (v +0.0000000000000000004337L, intPart, 0x8ULL); + Check (v +0.0000000000000000004879L, intPart, 0x9ULL); + Check (v +0.0000000000000000005421L, intPart, 0xAULL); + Check (v +0.0000000000000000008132L, intPart, 0xFULL); + Check (v +0.0000000000000000130104L, intPart, 0xF0ULL); + Check (v +0.0000000000000002081668L, intPart, 0xF00ULL); + Check (v +0.0000000000000033306691L, intPart, 0xF000ULL); + Check (v +0.0000000000000532907052L, intPart, 0xF0000ULL); + Check (v +0.0000000000008526512829L, intPart, 0xF00000ULL); + Check (v +0.0000000000136424205266L, intPart, 0xF000000ULL); + Check (v +0.0000000002182787284255L, intPart, 0xF0000000ULL); + Check (v +0.0000000034924596548080L, intPart, 0xF00000000ULL); + Check (v +0.0000000558793544769287L, intPart, 0xF000000000ULL); + Check (v +0.0000008940696716308594L, intPart, 0xF0000000000ULL); + Check (v +0.0000143051147460937500L, intPart, 0xF00000000000ULL); + Check (v +0.0002288818359375000000L, intPart, 0xF000000000000ULL); + Check (v +0.0036621093750000000000L, intPart, 0xF0000000000000ULL); + Check (v +0.0585937500000000000000L, intPart, 0xF00000000000000ULL); + std::cout << std::endl; + Check (v +0.4999999999999999998374L, intPart, 0x7FFFFFFFFFFFFFFDULL); + Check (v +0.4999999999999999998916L, intPart, 0x7FFFFFFFFFFFFFFEULL); + Check (v +0.4999999999999999999458L, intPart, 0x7FFFFFFFFFFFFFFFULL); + Check (v +0.5000000000000000000000L, intPart, 0x8000000000000000ULL); + Check (v +0.5000000000000000000542L, intPart, 0x8000000000000001ULL); + Check (v +0.5000000000000000001084L, intPart, 0x8000000000000002ULL); + Check (v +0.5000000000000000001626L, intPart, 0x8000000000000003ULL); + std::cout << std::endl; + Check (v +0.9375000000000000000000L, intPart, 0xF000000000000000ULL); + Check (v +0.9960937500000000000000L, intPart, 0xFF00000000000000ULL); + Check (v +0.9997558593750000000000L, intPart, 0xFFF0000000000000ULL); + Check (v +0.9999847412109375000000L, intPart, 0xFFFF000000000000ULL); + Check (v +0.9999990463256835937500L, intPart, 0xFFFFF00000000000ULL); + Check (v +0.9999999403953552246094L, intPart, 0xFFFFFF0000000000ULL); + Check (v +0.9999999962747097015381L, intPart, 0xFFFFFFF000000000ULL); + Check (v +0.9999999997671693563461L, intPart, 0xFFFFFFFF00000000ULL); + Check (v +0.9999999999854480847716L, intPart, 0xFFFFFFFFF0000000ULL); + Check (v +0.9999999999990905052982L, intPart, 0xFFFFFFFFFF000000ULL); + Check (v +0.9999999999999431565811L, intPart, 0xFFFFFFFFFFF00000ULL); + Check (v +0.9999999999999964472863L, intPart, 0xFFFFFFFFFFFF0000ULL); + Check (v +0.9999999999999997779554L, intPart, 0xFFFFFFFFFFFFF000ULL); + Check (v +0.9999999999999999861222L, intPart, 0xFFFFFFFFFFFFFF00ULL); + Check (v +0.9999999999999999991326L, intPart, 0xFFFFFFFFFFFFFFF0ULL); + Check (v +0.9999999999999999994037L, intPart, 0xFFFFFFFFFFFFFFF5ULL); + Check (v +0.9999999999999999994579L, intPart, 0xFFFFFFFFFFFFFFF6ULL); + Check (v +0.9999999999999999995121L, intPart, 0xFFFFFFFFFFFFFFF7ULL); + Check (v +0.9999999999999999995663L, intPart, 0xFFFFFFFFFFFFFFF8ULL); + Check (v +0.9999999999999999996205L, intPart, 0xFFFFFFFFFFFFFFF9ULL); + Check (v +0.9999999999999999996747L, intPart, 0xFFFFFFFFFFFFFFFAULL); + Check (v +0.9999999999999999997289L, intPart, 0xFFFFFFFFFFFFFFFBULL); + Check (v +0.9999999999999999997832L, intPart, 0xFFFFFFFFFFFFFFFCULL); + Check (v +0.9999999999999999998374L, intPart, 0xFFFFFFFFFFFFFFFDULL); + Check (v +0.9999999999999999998916L, intPart, 0xFFFFFFFFFFFFFFFEULL); + Check (v +0.9999999999999999999458L, intPart, 0xFFFFFFFFFFFFFFFFULL); + + std::cout << GetParent ()->GetName () << " Double: " + << "integer: " << intPart + << ": delta count: " << m_deltaCount + << ", max: " << Printer (m_deltaMax) + << std::endl; +} + +void +Int64x64DoubleTestCase::DoRun (void) +{ + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Double: " << GetName () + << std::endl; + + // Save stream format flags + std::ios_base::fmtflags ff = std::cout.flags (); + std::cout << std::scientific << std::setprecision (21); + + m_deltaMax = int64x64_t (); + + std::cout << GetParent ()->GetName () << " Double: " + << std::endl; + + Check (-2); + Check (-1); + Check ( 0); + Check ( 1); + Check ( 2); + + std::cout << GetParent ()->GetName () << " Double: " + << "max delta: " << Printer (m_deltaMax) + << std::endl; + + std::cout.flags (ff); +} + + +class Int64x64ImplTestCase : public TestCase +{ +public: + Int64x64ImplTestCase (); + virtual void DoRun (void); +}; + +Int64x64ImplTestCase::Int64x64ImplTestCase () + : TestCase ("Print the implementation") +{ } +void +Int64x64ImplTestCase::DoRun (void) +{ + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " Impl: " << GetName () + << std::endl; + + + std::cout << "int64x64_t::implementation: "; + switch (int64x64_t::implementation) + { + case (int64x64_t::int128_impl) : std::cout << "int128_impl"; break; + case (int64x64_t::cairo_impl) : std::cout << "cairo_impl"; break; + case (int64x64_t::ld_impl) : std::cout << "ld_impl"; break; + default : std::cout << "unknown!"; + } + std::cout << std::endl; + +#if defined (INT64X64_USE_CAIRO) && !defined (PYTHON_SCAN) + std::cout << "cairo_impl64: " << cairo_impl64 << std::endl; + std::cout << "cairo_impl128: " << cairo_impl128 << std::endl; +#endif + + if (RUNNING_ON_VALGRIND != 0) + { + std::cout << "Running with valgrind" << std::endl; + } +} -static class Int64x64128TestSuite : public TestSuite +static class Int64x64TestSuite : public TestSuite { public: - Int64x64128TestSuite () + Int64x64TestSuite () : TestSuite ("int64x64", UNIT) { - AddTestCase (new Int64x64FracTestCase (), TestCase::QUICK); + AddTestCase (new Int64x64ImplTestCase (), TestCase::QUICK); + AddTestCase (new Int64x64HiLoTestCase (), TestCase::QUICK); + AddTestCase (new Int64x64ArithmeticTestCase (), TestCase::QUICK); + AddTestCase (new Int64x64CompareTestCase (), 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 Int64x64Bug1786TestCase (), TestCase::QUICK); AddTestCase (new Int64x64InvertTestCase (), TestCase::QUICK); + AddTestCase (new Int64x64DoubleTestCase (), TestCase::QUICK); } -} g_int64x64TestSuite; +} g_int64x64TestSuite; + +} // namespace test + +} // namespace int64x64 + +} // namespace ns3 + diff -Naur ns-3.19/src/core/test/object-test-suite.cc ns-3.20/src/core/test/object-test-suite.cc --- ns-3.19/src/core/test/object-test-suite.cc 2014-06-17 10:34:00.639635109 -0700 +++ ns-3.20/src/core/test/object-test-suite.cc 2014-06-17 10:33:13.973995344 -0700 @@ -89,18 +89,14 @@ } }; -NS_OBJECT_ENSURE_REGISTERED (BaseA) - ; -NS_OBJECT_ENSURE_REGISTERED (DerivedA) - ; -NS_OBJECT_ENSURE_REGISTERED (BaseB) - ; -NS_OBJECT_ENSURE_REGISTERED (DerivedB) - ; +NS_OBJECT_ENSURE_REGISTERED (BaseA); +NS_OBJECT_ENSURE_REGISTERED (DerivedA); +NS_OBJECT_ENSURE_REGISTERED (BaseB); +NS_OBJECT_ENSURE_REGISTERED (DerivedB); } // namespace anonymous -namespace ns3 { +using namespace ns3; // =========================================================================== // Test case to make sure that we can make Objects using CreateObject. @@ -429,5 +425,3 @@ } static ObjectTestSuite objectTestSuite; - -} // namespace ns3 diff -Naur ns-3.19/src/core/test/ptr-test-suite.cc ns-3.20/src/core/test/ptr-test-suite.cc --- ns-3.19/src/core/test/ptr-test-suite.cc 2014-06-17 10:34:00.261638028 -0700 +++ ns-3.20/src/core/test/ptr-test-suite.cc 2014-06-17 10:33:13.974995337 -0700 @@ -25,18 +25,18 @@ class PtrTestCase; -class Base +class PtrTestBase { public: - Base (); - virtual ~Base (); + PtrTestBase (); + virtual ~PtrTestBase (); void Ref (void) const; void Unref (void) const; private: mutable uint32_t m_count; }; -class NoCount : public Base +class NoCount : public PtrTestBase { public: NoCount (PtrTestCase *test); @@ -60,20 +60,20 @@ }; -Base::Base () +PtrTestBase::PtrTestBase () : m_count (1) { } -Base::~Base () +PtrTestBase::~PtrTestBase () { } void -Base::Ref (void) const +PtrTestBase::Ref (void) const { m_count++; } void -Base::Unref (void) const +PtrTestBase::Unref (void) const { m_count--; if (m_count == 0) @@ -256,7 +256,7 @@ NS_TEST_EXPECT_MSG_EQ (m_nDestroyed, 1, "013"); { - Ptr p0 = Create (this); + Ptr p0 = Create (this); Ptr p1 = Create (this); NS_TEST_EXPECT_MSG_EQ ((p0 == p1), false, "operator == failed"); NS_TEST_EXPECT_MSG_EQ ((p0 != p1), true, "operator != failed"); diff -Naur ns-3.19/src/core/test/random-variable-stream-test-suite.cc ns-3.20/src/core/test/random-variable-stream-test-suite.cc --- ns-3.19/src/core/test/random-variable-stream-test-suite.cc 2014-06-17 10:34:00.263638013 -0700 +++ ns-3.20/src/core/test/random-variable-stream-test-suite.cc 2014-06-17 10:33:13.975995329 -0700 @@ -288,7 +288,7 @@ { public: static const uint32_t N_MEASUREMENTS = 1000000; - static const double TOLERANCE = 1e-8; + static const double TOLERANCE; RandomVariableStreamConstantTestCase (); virtual ~RandomVariableStreamConstantTestCase (); @@ -297,6 +297,8 @@ virtual void DoRun (void); }; +const double RandomVariableStreamConstantTestCase::TOLERANCE = 1e-8; + RandomVariableStreamConstantTestCase::RandomVariableStreamConstantTestCase () : TestCase ("Constant Random Variable Stream Generator") { @@ -336,7 +338,7 @@ class RandomVariableStreamSequentialTestCase : public TestCase { public: - static const double TOLERANCE = 1e-8; + static const double TOLERANCE; RandomVariableStreamSequentialTestCase (); virtual ~RandomVariableStreamSequentialTestCase (); @@ -345,6 +347,8 @@ virtual void DoRun (void); }; +const double RandomVariableStreamSequentialTestCase::TOLERANCE = 1e-8; + RandomVariableStreamSequentialTestCase::RandomVariableStreamSequentialTestCase () : TestCase ("Sequential Random Variable Stream Generator") { @@ -2590,7 +2594,7 @@ class RandomVariableStreamDeterministicTestCase : public TestCase { public: - static const double TOLERANCE = 1e-8; + static const double TOLERANCE; RandomVariableStreamDeterministicTestCase (); virtual ~RandomVariableStreamDeterministicTestCase (); @@ -2599,6 +2603,8 @@ virtual void DoRun (void); }; +const double RandomVariableStreamDeterministicTestCase::TOLERANCE = 1e-8; + RandomVariableStreamDeterministicTestCase::RandomVariableStreamDeterministicTestCase () : TestCase ("Deterministic Random Variable Stream Generator") { diff -Naur ns-3.19/src/core/test/simulator-test-suite.cc ns-3.20/src/core/test/simulator-test-suite.cc --- ns-3.19/src/core/test/simulator-test-suite.cc 2014-06-17 10:34:00.265637997 -0700 +++ ns-3.20/src/core/test/simulator-test-suite.cc 2014-06-17 10:33:13.976995321 -0700 @@ -31,11 +31,11 @@ public: SimulatorEventsTestCase (ObjectFactory schedulerFactory); virtual void DoRun (void); - void A (int a); - void B (int b); - void C (int c); - void D (int d); - void foo0 (void); + void EventA (int a); + void EventB (int b); + void EventC (int c); + void EventD (int d); + void Eventfoo0 (void); uint64_t NowUs (void); void destroy (void); bool m_b; @@ -62,13 +62,13 @@ } void -SimulatorEventsTestCase::A (int a) +SimulatorEventsTestCase::EventA (int a) { m_a = false; } void -SimulatorEventsTestCase::B (int b) +SimulatorEventsTestCase::EventB (int b) { if (b != 2 || NowUs () != 11) { @@ -79,17 +79,17 @@ m_b = true; } Simulator::Remove (m_idC); - Simulator::Schedule (MicroSeconds (10), &SimulatorEventsTestCase::D, this, 4); + Simulator::Schedule (MicroSeconds (10), &SimulatorEventsTestCase::EventD, this, 4); } void -SimulatorEventsTestCase::C (int c) +SimulatorEventsTestCase::EventC (int c) { m_c = false; } void -SimulatorEventsTestCase::D (int d) +SimulatorEventsTestCase::EventD (int d) { if (d != 4 || NowUs () != (11+10)) { @@ -102,7 +102,7 @@ } void -SimulatorEventsTestCase::foo0 (void) +SimulatorEventsTestCase::Eventfoo0 (void) {} void @@ -123,9 +123,9 @@ Simulator::SetScheduler (m_schedulerFactory); - EventId a = Simulator::Schedule (MicroSeconds (10), &SimulatorEventsTestCase::A, this, 1); - Simulator::Schedule (MicroSeconds (11), &SimulatorEventsTestCase::B, this, 2); - m_idC = Simulator::Schedule (MicroSeconds (12), &SimulatorEventsTestCase::C, this, 3); + EventId a = Simulator::Schedule (MicroSeconds (10), &SimulatorEventsTestCase::EventA, this, 1); + Simulator::Schedule (MicroSeconds (11), &SimulatorEventsTestCase::EventB, this, 2); + m_idC = Simulator::Schedule (MicroSeconds (12), &SimulatorEventsTestCase::EventC, this, 3); NS_TEST_EXPECT_MSG_EQ (!m_idC.IsExpired (), true, ""); NS_TEST_EXPECT_MSG_EQ (!a.IsExpired (), true, ""); @@ -137,7 +137,7 @@ NS_TEST_EXPECT_MSG_EQ (m_c, true, "Event C did not run ?"); NS_TEST_EXPECT_MSG_EQ (m_d, true, "Event D did not run ?"); - EventId anId = Simulator::ScheduleNow (&SimulatorEventsTestCase::foo0, this); + EventId anId = Simulator::ScheduleNow (&SimulatorEventsTestCase::Eventfoo0, this); EventId anotherId = anId; NS_TEST_EXPECT_MSG_EQ (!(anId.IsExpired () || anotherId.IsExpired ()), true, "Event should not have expired yet."); diff -Naur ns-3.19/src/core/test/threaded-test-suite.cc ns-3.20/src/core/test/threaded-test-suite.cc --- ns-3.19/src/core/test/threaded-test-suite.cc 2014-06-17 10:34:00.266637989 -0700 +++ ns-3.20/src/core/test/threaded-test-suite.cc 2014-06-17 10:33:13.976995321 -0700 @@ -39,10 +39,10 @@ { public: ThreadedSimulatorEventsTestCase (ObjectFactory schedulerFactory, const std::string &simulatorType, unsigned int threads); - void A (int a); - void B (int b); - void C (int c); - void D (int d); + void EventA (int a); + void EventB (int b); + void EventC (int c); + void EventD (int d); void DoNothing (unsigned int threadno); static void SchedulingThread (std::pair context); void End (void); @@ -113,7 +113,7 @@ m_threadWaiting[threadno] = false; } void -ThreadedSimulatorEventsTestCase::A (int a) +ThreadedSimulatorEventsTestCase::EventA (int a) { if (m_a != m_b || m_a != m_c || m_a != m_d) { @@ -122,11 +122,11 @@ }; ++m_a; Simulator::Schedule (MicroSeconds (10), - &ThreadedSimulatorEventsTestCase::B, this, a+1); + &ThreadedSimulatorEventsTestCase::EventB, this, a+1); } void -ThreadedSimulatorEventsTestCase::B (int b) +ThreadedSimulatorEventsTestCase::EventB (int b) { if (m_a != (m_b+1) || m_a != (m_c+1) || m_a != (m_d+1)) { @@ -135,11 +135,11 @@ }; ++m_b; Simulator::Schedule (MicroSeconds (10), - &ThreadedSimulatorEventsTestCase::C, this, b+1); + &ThreadedSimulatorEventsTestCase::EventC, this, b+1); } void -ThreadedSimulatorEventsTestCase::C (int c) +ThreadedSimulatorEventsTestCase::EventC (int c) { if (m_a != m_b || m_a != (m_c+1) || m_a != (m_d+1)) { @@ -148,11 +148,11 @@ }; ++m_c; Simulator::Schedule (MicroSeconds (10), - &ThreadedSimulatorEventsTestCase::D, this, c+1); + &ThreadedSimulatorEventsTestCase::EventD, this, c+1); } void -ThreadedSimulatorEventsTestCase::D (int d) +ThreadedSimulatorEventsTestCase::EventD (int d) { if (m_a != m_b || m_a != m_c || m_a != (m_d+1)) { @@ -167,7 +167,7 @@ else { Simulator::Schedule (MicroSeconds (10), - &ThreadedSimulatorEventsTestCase::A, this, d+1); + &ThreadedSimulatorEventsTestCase::EventA, this, d+1); } } @@ -207,7 +207,7 @@ m_stop = false; Simulator::SetScheduler (m_schedulerFactory); - Simulator::Schedule (MicroSeconds (10), &ThreadedSimulatorEventsTestCase::A, this, 1); + Simulator::Schedule (MicroSeconds (10), &ThreadedSimulatorEventsTestCase::EventA, this, 1); Simulator::Schedule (Seconds (1), &ThreadedSimulatorEventsTestCase::End, this); diff -Naur ns-3.19/src/core/test/time-test-suite.cc ns-3.20/src/core/test/time-test-suite.cc --- ns-3.19/src/core/test/time-test-suite.cc 2014-06-17 10:34:00.267637982 -0700 +++ ns-3.20/src/core/test/time-test-suite.cc 2014-06-17 10:33:13.977995313 -0700 @@ -19,7 +19,14 @@ * Author: Mathieu Lacage * TimeStep support by Emmanuelle Laprise */ + +#include +#include +#include +#include + #include "ns3/nstime.h" +#include "ns3/int64x64.h" #include "ns3/test.h" using namespace ns3; @@ -150,13 +157,90 @@ { } + +class TimeIntputOutputTestCase : public TestCase +{ +public: + TimeIntputOutputTestCase (); +private: + virtual void DoRun (void); + void Check (const std::string & str); +}; + +TimeIntputOutputTestCase::TimeIntputOutputTestCase () + : TestCase ("Input,output from,to strings") +{ +} + +void +TimeIntputOutputTestCase::Check (const std::string & str) +{ + std::stringstream ss (str); + Time time; + ss >> time; + ss << time; + bool pass = (str == ss.str ()); + + std::cout << GetParent ()->GetName () << " InputOutput: " + << (pass ? "pass " : "FAIL ") + << "\"" << str << "\""; + if (!pass) + { + std::cout << ", got " << ss.str (); + } + std::cout << std::endl; +} + +void +TimeIntputOutputTestCase::DoRun (void) +{ + std::cout << std::endl; + std::cout << GetParent ()->GetName () << " InputOutput: " << GetName () + << std::endl; + + Check ("2ns"); + Check ("+3.1us"); + Check ("-4.2ms"); + Check ("5.3s"); + Check ("6.4min"); + Check ("7.5h"); + Check ("8.6d"); + Check ("10.8y"); + + Time t (3.141592654e9); // Pi seconds + + std::cout << GetParent ()->GetName () << " InputOutput: " + << "example: raw: " << t + << std::endl; + + std::cout << GetParent ()->GetName () << " InputOutput: " + << std::fixed << std::setprecision (9) + << "example: in s: " << t.As (Time::S) + << std::endl; + + std::cout << GetParent ()->GetName () << " InputOutput: " + << std::setprecision (6) + << "example: in ms: " << t.As (Time::MS) + << std::endl; + + std::cout << GetParent ()->GetName () << " InputOutput: " + << "example: Get ns: " << t.GetNanoSeconds () + << std::endl; + + std::cout << std::endl; +} + static class TimeTestSuite : public TestSuite { public: TimeTestSuite () : TestSuite ("time", UNIT) { - AddTestCase (new TimeSimpleTestCase (), TestCase::QUICK); AddTestCase (new TimesWithSignsTestCase (), TestCase::QUICK); + AddTestCase (new TimeIntputOutputTestCase (), TestCase::QUICK); + // This should be last, since it changes the resolution + AddTestCase (new TimeSimpleTestCase (), TestCase::QUICK); } } g_timeTestSuite; + + diff -Naur ns-3.19/src/core/test/type-id-test-suite.cc ns-3.20/src/core/test/type-id-test-suite.cc --- ns-3.19/src/core/test/type-id-test-suite.cc 2014-06-17 10:34:00.268637974 -0700 +++ ns-3.20/src/core/test/type-id-test-suite.cc 2014-06-17 10:33:13.978995306 -0700 @@ -28,7 +28,7 @@ using namespace std; -namespace ns3 { +using namespace ns3; const std::string suite("type-id: "); @@ -315,7 +315,4 @@ AddTestCase (new LookupTimeTestCase, QUICK); } -static TypeIdPerformanceSuite g_TypeIdPerformanceSuite; - - -} // namespace ns3 +static TypeIdPerformanceSuite g_TypeIdPerformanceSuite; diff -Naur ns-3.19/src/core/waf ns-3.20/src/core/waf --- ns-3.19/src/core/waf 2014-06-17 10:34:00.269637966 -0700 +++ ns-3.20/src/core/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" \ No newline at end of file diff -Naur ns-3.19/src/core/wscript ns-3.20/src/core/wscript --- ns-3.19/src/core/wscript 2014-06-17 10:34:00.270637958 -0700 +++ ns-3.20/src/core/wscript 2014-06-17 10:33:13.980995290 -0700 @@ -4,14 +4,38 @@ from waflib import Options import wutils +int64x64 = { + # implementation name: [define, env, highprec] + 'default': ['INT64X64_USE_128', 'INT64X64_USE_128', '128-bit integer'], + 'int128': ['INT64X64_USE_128', 'INT64X64_USE_128', '128-bit integer'], + 'cairo': ['INT64X64_USE_CAIRO', 'INT64X64_USE_CAIRO', 'cairo 128-bit integer'], + 'double': ['INT64X64_USE_DOUBLE', 'INT64X64_USE_DOUBLE', 'long double'], + } + +default_int64x64 = 'default' + def options(opt): - opt.add_option('--int64x64-as-double', - help=('Whether to use a double floating point' - ' type for int64x64 values' - ' WARNING: this option only has effect ' - 'with the configure command.'), - action="store_true", default=False, - dest='int64x64_as_double') + assert default_int64x64 in int64x64 + opt.add_option('--int64x64', + action='store', + default=default_int64x64, + help=("Force the choice of int64x64_t implementation " + "(normally only for debugging). " + "The supported implementations use int128_t, " + "cairo_int128, or long double. " + "The int128_t implementation (the preferred option) " + "requires compiler support. " + "The cairo implementation fallback provides exactly " + "the same numerical results, but possibly at lower " + "execution speed. The long double implementation " + "may not provide the same numerical results because " + "the implementation-defined numerical precision may " + "be less than the other implementations. " + "[Allowed Values: %s]" + % ", ".join([repr(p) for p in int64x64.keys()])), + choices=int64x64.keys(), + dest='int64x64_impl') + opt.add_option('--disable-pthread', help=('Whether to enable the use of POSIX threads'), action="store_true", default=False, @@ -20,23 +44,24 @@ def configure(conf): - a = conf.check_nonfatal(type_name='uint128_t', define_name='HAVE_UINT128_T') - b = conf.check_nonfatal(type_name='__uint128_t', define_name='HAVE___UINT128_T') - - if Options.options.int64x64_as_double: - conf.define('INT64X64_USE_DOUBLE', 1) - conf.env['INT64X64_USE_DOUBLE'] = 1 - highprec = 'long double' - elif a or b: - conf.define('INT64X64_USE_128', 1) - conf.env['INT64X64_USE_128'] = 1 - highprec = '128-bit integer' - else: - conf.define('INT64X64_USE_CAIRO', 1) - conf.env['INT64X64_USE_CAIRO'] = 1 - highprec = 'cairo 128-bit integer' - - conf.msg('Checking high precision time implementation', highprec) + int64x64_impl = Options.options.int64x64_impl + if int64x64_impl == 'default' or int64x64_impl == 'int128': + have_uint128 = conf.check_nonfatal(type_name='uint128_t', + define_name='HAVE_UINT128_T') + have__uint128 = conf.check_nonfatal(type_name='__uint128_t', + define_name='HAVE___UINT128_T') + if have_uint128 or have__uint128: + int64x64_impl = 'int128' + else: + int64x64_impl = 'cairo' + + def_flag, env_flag, highprec = int64x64[int64x64_impl] + # Add a tag confirming default choice + if Options.options.int64x64_impl == 'default': + highprec += ' (default)' + conf.define(def_flag, 1) + conf.env[env_flag] = 1 + conf.msg('Checking high precision implementation', highprec) conf.check_nonfatal(header_name='stdint.h', define_name='HAVE_STDINT_H') conf.check_nonfatal(header_name='inttypes.h', define_name='HAVE_INTTYPES_H') @@ -223,6 +248,8 @@ 'model/ptr.h', 'model/object.h', 'model/log.h', + 'model/log-macros-enabled.h', + 'model/log-macros-disabled.h', 'model/assert.h', 'model/breakpoint.h', 'model/fatal-error.h', @@ -271,6 +298,7 @@ 'model/hash-murmur3.h', 'model/hash-fnv.h', 'model/hash.h', + 'model/valgrind.h', ] if sys.platform == 'win32': @@ -330,7 +358,10 @@ if env['ENABLE_GSL']: core.use.extend(['GSL', 'GSLCBLAS', 'M']) core_test.use.extend(['GSL', 'GSLCBLAS', 'M']) - core_test.source.extend(['test/rng-test-suite.cc']) + core_test.source.extend([ + 'test/rng-test-suite.cc', + 'test/random-variable-stream-test-suite.cc' + ]) if (bld.env['ENABLE_EXAMPLES']): bld.recurse('examples') diff -Naur ns-3.19/src/csma/bindings/modulegen__gcc_ILP32.py ns-3.20/src/csma/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/csma/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.289637812 -0700 +++ ns-3.20/src/csma/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.621998061 -0700 @@ -109,7 +109,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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 [class] @@ -120,6 +120,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -132,6 +134,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## csma-helper.h (module 'csma'): ns3::CsmaHelper [class] @@ -296,7 +300,7 @@ module.add_class('CsmaNetDevice', parent=root_module['ns3::NetDevice']) ## csma-net-device.h (module 'csma'): ns3::CsmaNetDevice::EncapsulationMode [enumeration] module.add_enum('EncapsulationMode', ['ILLEGAL', 'DIX', 'LLC'], outer_class=root_module['ns3::CsmaNetDevice']) - module.add_container('std::list< unsigned int >', 'unsigned int', container_type='list') + module.add_container('std::list< unsigned int >', 'unsigned int', container_type=u'list') ## Register a nested module for the namespace FatalImpl @@ -319,12 +323,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -387,6 +391,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -878,6 +883,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -890,6 +899,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2469,6 +2482,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2666,62 +2687,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2730,6 +2707,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2770,6 +2749,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3339,13 +3320,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3372,6 +3355,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4256,10 +4244,10 @@ cls.add_method('Reset', 'void', []) - ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr arg0) [member function] + ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr p) [member function] cls.add_method('DoCorrupt', 'bool', - [param('ns3::Ptr< ns3::Packet >', 'arg0')], + [param('ns3::Ptr< ns3::Packet >', 'p')], is_pure_virtual=True, visibility='private', is_virtual=True) ## error-model.h (module 'network'): void ns3::ErrorModel::DoReset() [member function] cls.add_method('DoReset', @@ -5173,10 +5161,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): diff -Naur ns-3.19/src/csma/bindings/modulegen__gcc_LP64.py ns-3.20/src/csma/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/csma/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.294637773 -0700 +++ ns-3.20/src/csma/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.625998030 -0700 @@ -109,7 +109,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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 [class] @@ -120,6 +120,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -132,6 +134,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## csma-helper.h (module 'csma'): ns3::CsmaHelper [class] @@ -296,7 +300,7 @@ module.add_class('CsmaNetDevice', parent=root_module['ns3::NetDevice']) ## csma-net-device.h (module 'csma'): ns3::CsmaNetDevice::EncapsulationMode [enumeration] module.add_enum('EncapsulationMode', ['ILLEGAL', 'DIX', 'LLC'], outer_class=root_module['ns3::CsmaNetDevice']) - module.add_container('std::list< unsigned int >', 'unsigned int', container_type='list') + module.add_container('std::list< unsigned int >', 'unsigned int', container_type=u'list') ## Register a nested module for the namespace FatalImpl @@ -319,12 +323,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -387,6 +391,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -878,6 +883,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -890,6 +899,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2469,6 +2482,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2666,62 +2687,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2730,6 +2707,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2770,6 +2749,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3339,13 +3320,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3372,6 +3355,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4256,10 +4244,10 @@ cls.add_method('Reset', 'void', []) - ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr arg0) [member function] + ## error-model.h (module 'network'): bool ns3::ErrorModel::DoCorrupt(ns3::Ptr p) [member function] cls.add_method('DoCorrupt', 'bool', - [param('ns3::Ptr< ns3::Packet >', 'arg0')], + [param('ns3::Ptr< ns3::Packet >', 'p')], is_pure_virtual=True, visibility='private', is_virtual=True) ## error-model.h (module 'network'): void ns3::ErrorModel::DoReset() [member function] cls.add_method('DoReset', @@ -5173,10 +5161,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): diff -Naur ns-3.19/src/csma/examples/waf ns-3.20/src/csma/examples/waf --- ns-3.19/src/csma/examples/waf 2014-06-17 10:34:00.298637743 -0700 +++ ns-3.20/src/csma/examples/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/src/csma/model/csma-channel.cc ns-3.20/src/csma/model/csma-channel.cc --- ns-3.19/src/csma/model/csma-channel.cc 2014-06-17 10:34:00.300637727 -0700 +++ ns-3.20/src/csma/model/csma-channel.cc 2014-06-17 10:33:13.632997976 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (CsmaChannel) - ; +NS_OBJECT_ENSURE_REGISTERED (CsmaChannel); TypeId CsmaChannel::GetTypeId (void) diff -Naur ns-3.19/src/csma/model/csma-net-device.cc ns-3.20/src/csma/model/csma-net-device.cc --- ns-3.19/src/csma/model/csma-net-device.cc 2014-06-17 10:34:00.301637719 -0700 +++ ns-3.20/src/csma/model/csma-net-device.cc 2014-06-17 10:33:13.633997968 -0700 @@ -37,8 +37,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (CsmaNetDevice) - ; +NS_OBJECT_ENSURE_REGISTERED (CsmaNetDevice); TypeId CsmaNetDevice::GetTypeId (void) diff -Naur ns-3.19/src/csma/waf ns-3.20/src/csma/waf --- ns-3.19/src/csma/waf 2014-06-17 10:34:00.303637704 -0700 +++ ns-3.20/src/csma/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../../waf "$@" diff -Naur ns-3.19/src/csma-layout/bindings/modulegen__gcc_ILP32.py ns-3.20/src/csma-layout/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/csma-layout/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.277637905 -0700 +++ ns-3.20/src/csma-layout/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.985995252 -0700 @@ -72,34 +72,6 @@ module.add_class('InetSocketAddress', import_from_module='ns.network') ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] root_module['ns3::InetSocketAddress'].implicitly_converts_to(root_module['ns3::Address']) - ## int-to-type.h (module 'core'): ns3::IntToType<0> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['0']) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 0 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<1> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['1']) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 1 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<2> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['2']) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 2 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<3> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['3']) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 3 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<4> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['4']) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 4 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<5> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['5']) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 5 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<6> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['6']) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 6 >'], 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] @@ -165,7 +137,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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') ## internet-trace-helper.h (module 'internet'): ns3::PcapHelperForIpv4 [class] @@ -180,14 +152,8 @@ 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') - ## timer.h (module 'core'): ns3::Timer [class] - module.add_class('Timer', import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] - module.add_enum('DestroyPolicy', ['CANCEL_ON_DESTROY', 'REMOVE_ON_DESTROY', 'CHECK_ON_DESTROY'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::State [enumeration] - module.add_enum('State', ['RUNNING', 'EXPIRED', 'SUSPENDED'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer-impl.h (module 'core'): ns3::TimerImpl [class] - module.add_class('TimerImpl', allow_subclassing=True, import_from_module='ns.core') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -200,6 +166,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## csma-helper.h (module 'csma'): ns3::CsmaHelper [class] @@ -300,10 +268,6 @@ module.add_class('EmptyAttributeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## 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 >']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -330,12 +294,10 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol [class] module.add_class('Ipv6L3Protocol', import_from_module='ns.internet', parent=root_module['ns3::Ipv6']) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::DropReason [enumeration] - module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL'], outer_class=root_module['ns3::Ipv6L3Protocol'], import_from_module='ns.internet') + module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT'], outer_class=root_module['ns3::Ipv6L3Protocol'], import_from_module='ns.internet') ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache [class] module.add_class('Ipv6PmtuCache', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker [class] @@ -368,8 +330,8 @@ 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']) - module.add_container('std::vector< bool >', 'bool', container_type='vector') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') + module.add_container('std::vector< bool >', 'bool', container_type=u'vector') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') ## Register a nested module for the namespace FatalImpl @@ -392,12 +354,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -440,13 +402,6 @@ register_Ns3Hasher_methods(root_module, root_module['ns3::Hasher']) register_Ns3Inet6SocketAddress_methods(root_module, root_module['ns3::Inet6SocketAddress']) register_Ns3InetSocketAddress_methods(root_module, root_module['ns3::InetSocketAddress']) - register_Ns3IntToType__0_methods(root_module, root_module['ns3::IntToType< 0 >']) - register_Ns3IntToType__1_methods(root_module, root_module['ns3::IntToType< 1 >']) - register_Ns3IntToType__2_methods(root_module, root_module['ns3::IntToType< 2 >']) - register_Ns3IntToType__3_methods(root_module, root_module['ns3::IntToType< 3 >']) - register_Ns3IntToType__4_methods(root_module, root_module['ns3::IntToType< 4 >']) - register_Ns3IntToType__5_methods(root_module, root_module['ns3::IntToType< 5 >']) - register_Ns3IntToType__6_methods(root_module, root_module['ns3::IntToType< 6 >']) register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address']) register_Ns3Ipv4AddressHelper_methods(root_module, root_module['ns3::Ipv4AddressHelper']) register_Ns3Ipv4InterfaceAddress_methods(root_module, root_module['ns3::Ipv4InterfaceAddress']) @@ -479,8 +434,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) - register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) - register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -529,7 +483,6 @@ register_Ns3DataRateValue_methods(root_module, root_module['ns3::DataRateValue']) register_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue']) register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -542,7 +495,6 @@ register_Ns3Ipv6_methods(root_module, root_module['ns3::Ipv6']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6L3Protocol_methods(root_module, root_module['ns3::Ipv6L3Protocol']) register_Ns3Ipv6PmtuCache_methods(root_module, root_module['ns3::Ipv6PmtuCache']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) @@ -1050,6 +1002,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1062,6 +1018,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1552,55 +1512,6 @@ [param('uint16_t', 'port')]) return -def register_Ns3IntToType__0_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType(ns3::IntToType<0> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 0 > const &', 'arg0')]) - return - -def register_Ns3IntToType__1_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType(ns3::IntToType<1> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 1 > const &', 'arg0')]) - return - -def register_Ns3IntToType__2_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType(ns3::IntToType<2> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 2 > const &', 'arg0')]) - return - -def register_Ns3IntToType__3_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType(ns3::IntToType<3> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 3 > const &', 'arg0')]) - return - -def register_Ns3IntToType__4_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType(ns3::IntToType<4> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 4 > const &', 'arg0')]) - return - -def register_Ns3IntToType__5_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType(ns3::IntToType<5> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 5 > const &', 'arg0')]) - return - -def register_Ns3IntToType__6_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType(ns3::IntToType<6> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 6 > const &', 'arg0')]) - return - def register_Ns3Ipv4Address_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2240,6 +2151,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -3204,88 +3120,12 @@ [param('uint8_t', 'v')]) return -def register_Ns3Timer_methods(root_module, cls): - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Timer const &', 'arg0')]) - ## timer.h (module 'core'): ns3::Timer::Timer() [constructor] - cls.add_constructor([]) - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer::DestroyPolicy destroyPolicy) [constructor] - cls.add_constructor([param('ns3::Timer::DestroyPolicy', 'destroyPolicy')]) - ## timer.h (module 'core'): void ns3::Timer::Cancel() [member function] - cls.add_method('Cancel', - 'void', - []) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelay() const [member function] - cls.add_method('GetDelay', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelayLeft() const [member function] - cls.add_method('GetDelayLeft', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Timer::State ns3::Timer::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Timer::State', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsExpired() const [member function] - cls.add_method('IsExpired', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsRunning() const [member function] - cls.add_method('IsRunning', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsSuspended() const [member function] - cls.add_method('IsSuspended', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): void ns3::Timer::Remove() [member function] - cls.add_method('Remove', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Resume() [member function] - cls.add_method('Resume', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule() [member function] - cls.add_method('Schedule', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule(ns3::Time delay) [member function] - cls.add_method('Schedule', - 'void', - [param('ns3::Time', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::SetDelay(ns3::Time const & delay) [member function] - cls.add_method('SetDelay', - 'void', - [param('ns3::Time const &', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::Suspend() [member function] - cls.add_method('Suspend', - 'void', - []) - return - -def register_Ns3TimerImpl_methods(root_module, cls): - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl() [constructor] - cls.add_constructor([]) - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl(ns3::TimerImpl const & arg0) [copy constructor] - cls.add_constructor([param('ns3::TimerImpl const &', 'arg0')]) - ## timer-impl.h (module 'core'): void ns3::TimerImpl::Invoke() [member function] - cls.add_method('Invoke', - 'void', - [], - is_pure_virtual=True, is_virtual=True) - ## timer-impl.h (module 'core'): ns3::EventId ns3::TimerImpl::Schedule(ns3::Time const & delay) [member function] - cls.add_method('Schedule', - 'ns3::EventId', - [param('ns3::Time const &', 'delay')], - is_pure_virtual=True, is_virtual=True) +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) return def register_Ns3TypeId_methods(root_module, cls): @@ -3485,62 +3325,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3549,6 +3345,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -3589,6 +3387,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -4981,13 +4781,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -5014,6 +4816,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -5567,63 +5374,6 @@ is_pure_virtual=True, visibility='protected', is_virtual=True) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -5946,6 +5696,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -6299,6 +6054,11 @@ 'ns3::Ptr< ns3::NetDevice >', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetRoutingProtocol() const [member function] cls.add_method('GetRoutingProtocol', 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', @@ -6369,6 +6129,11 @@ 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_pure_virtual=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ipv6::IF_ANY [variable] cls.add_static_attribute('IF_ANY', 'uint32_t const', is_const=True) ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetIpForward() const [member function] @@ -6433,151 +6198,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6L3Protocol_methods(root_module, cls): ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::PROT_NUMBER [variable] cls.add_static_attribute('PROT_NUMBER', 'uint16_t const', is_const=True) @@ -6604,7 +6224,7 @@ cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber')], - is_const=True) + is_const=True, is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::CreateRawSocket() [member function] cls.add_method('CreateRawSocket', 'ns3::Ptr< ns3::Socket >', @@ -6739,6 +6359,11 @@ 'void', [param('uint32_t', 'i'), param('bool', 'val')], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6L3Protocol::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetNetDevice(uint32_t i) [member function] cls.add_method('GetNetDevice', 'ns3::Ptr< ns3::NetDevice >', @@ -6767,6 +6392,11 @@ 'void', [], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::ReportDrop(ns3::Ipv6Header ipHeader, ns3::Ptr p, ns3::Ipv6L3Protocol::DropReason dropReason) [member function] + cls.add_method('ReportDrop', + 'void', + [param('ns3::Ipv6Header', 'ipHeader'), param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6L3Protocol::DropReason', 'dropReason')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DoDispose() [member function] cls.add_method('DoDispose', 'void', @@ -7374,10 +7004,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TimeValue_methods(root_module, cls): diff -Naur ns-3.19/src/csma-layout/bindings/modulegen__gcc_LP64.py ns-3.20/src/csma-layout/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/csma-layout/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.282637866 -0700 +++ ns-3.20/src/csma-layout/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.614998115 -0700 @@ -72,34 +72,6 @@ module.add_class('InetSocketAddress', import_from_module='ns.network') ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] root_module['ns3::InetSocketAddress'].implicitly_converts_to(root_module['ns3::Address']) - ## int-to-type.h (module 'core'): ns3::IntToType<0> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['0']) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 0 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<1> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['1']) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 1 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<2> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['2']) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 2 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<3> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['3']) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 3 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<4> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['4']) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 4 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<5> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['5']) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 5 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<6> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['6']) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 6 >'], 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] @@ -165,7 +137,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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') ## internet-trace-helper.h (module 'internet'): ns3::PcapHelperForIpv4 [class] @@ -180,14 +152,8 @@ 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') - ## timer.h (module 'core'): ns3::Timer [class] - module.add_class('Timer', import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] - module.add_enum('DestroyPolicy', ['CANCEL_ON_DESTROY', 'REMOVE_ON_DESTROY', 'CHECK_ON_DESTROY'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::State [enumeration] - module.add_enum('State', ['RUNNING', 'EXPIRED', 'SUSPENDED'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer-impl.h (module 'core'): ns3::TimerImpl [class] - module.add_class('TimerImpl', allow_subclassing=True, import_from_module='ns.core') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -200,6 +166,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## csma-helper.h (module 'csma'): ns3::CsmaHelper [class] @@ -300,10 +268,6 @@ module.add_class('EmptyAttributeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## 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 >']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -330,12 +294,10 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol [class] module.add_class('Ipv6L3Protocol', import_from_module='ns.internet', parent=root_module['ns3::Ipv6']) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::DropReason [enumeration] - module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL'], outer_class=root_module['ns3::Ipv6L3Protocol'], import_from_module='ns.internet') + module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT'], outer_class=root_module['ns3::Ipv6L3Protocol'], import_from_module='ns.internet') ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache [class] module.add_class('Ipv6PmtuCache', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker [class] @@ -368,8 +330,8 @@ 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']) - module.add_container('std::vector< bool >', 'bool', container_type='vector') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') + module.add_container('std::vector< bool >', 'bool', container_type=u'vector') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') ## Register a nested module for the namespace FatalImpl @@ -392,12 +354,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -440,13 +402,6 @@ register_Ns3Hasher_methods(root_module, root_module['ns3::Hasher']) register_Ns3Inet6SocketAddress_methods(root_module, root_module['ns3::Inet6SocketAddress']) register_Ns3InetSocketAddress_methods(root_module, root_module['ns3::InetSocketAddress']) - register_Ns3IntToType__0_methods(root_module, root_module['ns3::IntToType< 0 >']) - register_Ns3IntToType__1_methods(root_module, root_module['ns3::IntToType< 1 >']) - register_Ns3IntToType__2_methods(root_module, root_module['ns3::IntToType< 2 >']) - register_Ns3IntToType__3_methods(root_module, root_module['ns3::IntToType< 3 >']) - register_Ns3IntToType__4_methods(root_module, root_module['ns3::IntToType< 4 >']) - register_Ns3IntToType__5_methods(root_module, root_module['ns3::IntToType< 5 >']) - register_Ns3IntToType__6_methods(root_module, root_module['ns3::IntToType< 6 >']) register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address']) register_Ns3Ipv4AddressHelper_methods(root_module, root_module['ns3::Ipv4AddressHelper']) register_Ns3Ipv4InterfaceAddress_methods(root_module, root_module['ns3::Ipv4InterfaceAddress']) @@ -479,8 +434,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) - register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) - register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -529,7 +483,6 @@ register_Ns3DataRateValue_methods(root_module, root_module['ns3::DataRateValue']) register_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue']) register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -542,7 +495,6 @@ register_Ns3Ipv6_methods(root_module, root_module['ns3::Ipv6']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6L3Protocol_methods(root_module, root_module['ns3::Ipv6L3Protocol']) register_Ns3Ipv6PmtuCache_methods(root_module, root_module['ns3::Ipv6PmtuCache']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) @@ -1050,6 +1002,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1062,6 +1018,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1552,55 +1512,6 @@ [param('uint16_t', 'port')]) return -def register_Ns3IntToType__0_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType(ns3::IntToType<0> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 0 > const &', 'arg0')]) - return - -def register_Ns3IntToType__1_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType(ns3::IntToType<1> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 1 > const &', 'arg0')]) - return - -def register_Ns3IntToType__2_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType(ns3::IntToType<2> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 2 > const &', 'arg0')]) - return - -def register_Ns3IntToType__3_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType(ns3::IntToType<3> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 3 > const &', 'arg0')]) - return - -def register_Ns3IntToType__4_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType(ns3::IntToType<4> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 4 > const &', 'arg0')]) - return - -def register_Ns3IntToType__5_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType(ns3::IntToType<5> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 5 > const &', 'arg0')]) - return - -def register_Ns3IntToType__6_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType(ns3::IntToType<6> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 6 > const &', 'arg0')]) - return - def register_Ns3Ipv4Address_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2240,6 +2151,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -3204,88 +3120,12 @@ [param('uint8_t', 'v')]) return -def register_Ns3Timer_methods(root_module, cls): - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Timer const &', 'arg0')]) - ## timer.h (module 'core'): ns3::Timer::Timer() [constructor] - cls.add_constructor([]) - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer::DestroyPolicy destroyPolicy) [constructor] - cls.add_constructor([param('ns3::Timer::DestroyPolicy', 'destroyPolicy')]) - ## timer.h (module 'core'): void ns3::Timer::Cancel() [member function] - cls.add_method('Cancel', - 'void', - []) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelay() const [member function] - cls.add_method('GetDelay', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelayLeft() const [member function] - cls.add_method('GetDelayLeft', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Timer::State ns3::Timer::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Timer::State', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsExpired() const [member function] - cls.add_method('IsExpired', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsRunning() const [member function] - cls.add_method('IsRunning', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsSuspended() const [member function] - cls.add_method('IsSuspended', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): void ns3::Timer::Remove() [member function] - cls.add_method('Remove', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Resume() [member function] - cls.add_method('Resume', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule() [member function] - cls.add_method('Schedule', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule(ns3::Time delay) [member function] - cls.add_method('Schedule', - 'void', - [param('ns3::Time', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::SetDelay(ns3::Time const & delay) [member function] - cls.add_method('SetDelay', - 'void', - [param('ns3::Time const &', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::Suspend() [member function] - cls.add_method('Suspend', - 'void', - []) - return - -def register_Ns3TimerImpl_methods(root_module, cls): - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl() [constructor] - cls.add_constructor([]) - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl(ns3::TimerImpl const & arg0) [copy constructor] - cls.add_constructor([param('ns3::TimerImpl const &', 'arg0')]) - ## timer-impl.h (module 'core'): void ns3::TimerImpl::Invoke() [member function] - cls.add_method('Invoke', - 'void', - [], - is_pure_virtual=True, is_virtual=True) - ## timer-impl.h (module 'core'): ns3::EventId ns3::TimerImpl::Schedule(ns3::Time const & delay) [member function] - cls.add_method('Schedule', - 'ns3::EventId', - [param('ns3::Time const &', 'delay')], - is_pure_virtual=True, is_virtual=True) +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) return def register_Ns3TypeId_methods(root_module, cls): @@ -3485,62 +3325,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3549,6 +3345,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -3589,6 +3387,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -4981,13 +4781,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -5014,6 +4816,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -5567,63 +5374,6 @@ is_pure_virtual=True, visibility='protected', is_virtual=True) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -5946,6 +5696,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -6299,6 +6054,11 @@ 'ns3::Ptr< ns3::NetDevice >', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetRoutingProtocol() const [member function] cls.add_method('GetRoutingProtocol', 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', @@ -6369,6 +6129,11 @@ 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_pure_virtual=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ipv6::IF_ANY [variable] cls.add_static_attribute('IF_ANY', 'uint32_t const', is_const=True) ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetIpForward() const [member function] @@ -6433,151 +6198,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6L3Protocol_methods(root_module, cls): ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::PROT_NUMBER [variable] cls.add_static_attribute('PROT_NUMBER', 'uint16_t const', is_const=True) @@ -6604,7 +6224,7 @@ cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber')], - is_const=True) + is_const=True, is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::CreateRawSocket() [member function] cls.add_method('CreateRawSocket', 'ns3::Ptr< ns3::Socket >', @@ -6739,6 +6359,11 @@ 'void', [param('uint32_t', 'i'), param('bool', 'val')], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6L3Protocol::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetNetDevice(uint32_t i) [member function] cls.add_method('GetNetDevice', 'ns3::Ptr< ns3::NetDevice >', @@ -6767,6 +6392,11 @@ 'void', [], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::ReportDrop(ns3::Ipv6Header ipHeader, ns3::Ptr p, ns3::Ipv6L3Protocol::DropReason dropReason) [member function] + cls.add_method('ReportDrop', + 'void', + [param('ns3::Ipv6Header', 'ipHeader'), param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6L3Protocol::DropReason', 'dropReason')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DoDispose() [member function] cls.add_method('DoDispose', 'void', @@ -7374,10 +7004,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TimeValue_methods(root_module, cls): diff -Naur ns-3.19/src/csma-layout/examples/waf ns-3.20/src/csma-layout/examples/waf --- ns-3.19/src/csma-layout/examples/waf 2014-06-17 10:34:00.283637858 -0700 +++ ns-3.20/src/csma-layout/examples/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/src/csma-layout/waf ns-3.20/src/csma-layout/waf --- ns-3.19/src/csma-layout/waf 2014-06-17 10:34:00.284637851 -0700 +++ ns-3.20/src/csma-layout/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" \ No newline at end of file diff -Naur ns-3.19/src/dsdv/bindings/modulegen__gcc_ILP32.py ns-3.20/src/dsdv/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/dsdv/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.308637665 -0700 +++ ns-3.20/src/dsdv/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.639997922 -0700 @@ -100,12 +100,6 @@ 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-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress [class] - module.add_class('Ipv6InterfaceAddress', import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e [enumeration] - module.add_enum('State_e', ['TENTATIVE', 'DEPRECATED', 'PREFERRED', 'PERMANENT', 'HOMEADDRESS', 'TENTATIVE_OPTIMISTIC', 'INVALID'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e [enumeration] - module.add_enum('Scope_e', ['HOST', 'LINKLOCAL', 'GLOBAL'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix [class] module.add_class('Ipv6Prefix', import_from_module='ns.network') ## node-container.h (module 'network'): ns3::NodeContainer [class] @@ -142,6 +136,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -162,6 +158,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## dsdv-helper.h (module 'dsdv'): ns3::DsdvHelper [class] @@ -174,10 +172,6 @@ module.add_enum('DscpType', ['DscpDefault', 'DSCP_CS1', 'DSCP_AF11', 'DSCP_AF12', 'DSCP_AF13', 'DSCP_CS2', 'DSCP_AF21', 'DSCP_AF22', 'DSCP_AF23', 'DSCP_CS3', 'DSCP_AF31', 'DSCP_AF32', 'DSCP_AF33', 'DSCP_CS4', 'DSCP_AF41', 'DSCP_AF42', 'DSCP_AF43', 'DSCP_CS5', 'DSCP_EF', 'DSCP_CS6', 'DSCP_CS7'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType [enumeration] module.add_enum('EcnType', ['ECN_NotECT', 'ECN_ECT1', 'ECN_ECT0', 'ECN_CE'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header [class] - module.add_class('Ipv6Header', import_from_module='ns.internet', parent=root_module['ns3::Header']) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::NextHeader_e [enumeration] - module.add_enum('NextHeader_e', ['IPV6_EXT_HOP_BY_HOP', 'IPV6_IPV4', 'IPV6_TCP', 'IPV6_UDP', 'IPV6_IPV6', 'IPV6_EXT_ROUTING', 'IPV6_EXT_FRAGMENTATION', 'IPV6_EXT_CONFIDENTIALITY', 'IPV6_EXT_AUTHENTIFICATION', 'IPV6_ICMPV6', 'IPV6_EXT_END', 'IPV6_EXT_DESTINATION', 'IPV6_SCTP', 'IPV6_EXT_MOBILITY', 'IPV6_UDP_LITE'], outer_class=root_module['ns3::Ipv6Header'], import_from_module='ns.internet') ## 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] @@ -276,10 +270,6 @@ module.add_class('ExponentialRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::GammaRandomVariable [class] module.add_class('GammaRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -306,8 +296,6 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -346,7 +334,7 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv4-list-routing.h (module 'internet'): ns3::Ipv4ListRouting [class] module.add_class('Ipv4ListRouting', import_from_module='ns.internet', parent=root_module['ns3::Ipv4RoutingProtocol']) - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') ## Register a nested module for the namespace FatalImpl @@ -375,12 +363,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -417,7 +405,7 @@ module.add_class('RoutingTable') ## dsdv-rtable.h (module 'dsdv'): ns3::dsdv::RoutingTableEntry [class] module.add_class('RoutingTableEntry') - module.add_container('std::map< ns3::Ipv4Address, ns3::dsdv::RoutingTableEntry >', ('ns3::Ipv4Address', 'ns3::dsdv::RoutingTableEntry'), container_type='map') + module.add_container('std::map< ns3::Ipv4Address, ns3::dsdv::RoutingTableEntry >', ('ns3::Ipv4Address', 'ns3::dsdv::RoutingTableEntry'), container_type=u'map') def register_methods(root_module): register_Ns3Address_methods(root_module, root_module['ns3::Address']) @@ -447,7 +435,6 @@ register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) register_Ns3Ipv4RoutingHelper_methods(root_module, root_module['ns3::Ipv4RoutingHelper']) register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address']) - register_Ns3Ipv6InterfaceAddress_methods(root_module, root_module['ns3::Ipv6InterfaceAddress']) register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix']) register_Ns3NodeContainer_methods(root_module, root_module['ns3::NodeContainer']) register_Ns3ObjectBase_methods(root_module, root_module['ns3::ObjectBase']) @@ -464,6 +451,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) @@ -475,7 +463,6 @@ register_Ns3DsdvHelper_methods(root_module, root_module['ns3::DsdvHelper']) register_Ns3Header_methods(root_module, root_module['ns3::Header']) register_Ns3Ipv4Header_methods(root_module, root_module['ns3::Ipv4Header']) - register_Ns3Ipv6Header_methods(root_module, root_module['ns3::Ipv6Header']) register_Ns3Object_methods(root_module, root_module['ns3::Object']) register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3RandomVariableStream_methods(root_module, root_module['ns3::RandomVariableStream']) @@ -521,7 +508,6 @@ register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) register_Ns3ExponentialRandomVariable_methods(root_module, root_module['ns3::ExponentialRandomVariable']) register_Ns3GammaRandomVariable_methods(root_module, root_module['ns3::GammaRandomVariable']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -534,7 +520,6 @@ register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3LogNormalRandomVariable_methods(root_module, root_module['ns3::LogNormalRandomVariable']) @@ -811,6 +796,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -823,6 +812,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1721,61 +1714,6 @@ [param('uint8_t *', 'address')]) return -def register_Ns3Ipv6InterfaceAddress_methods(root_module, cls): - cls.add_binary_comparison_operator('!=') - cls.add_output_stream_operator() - cls.add_binary_comparison_operator('==') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress() [constructor] - cls.add_constructor([]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address, ns3::Ipv6Prefix prefix) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'prefix')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6InterfaceAddress const & o) [copy constructor] - cls.add_constructor([param('ns3::Ipv6InterfaceAddress const &', 'o')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6InterfaceAddress::GetAddress() const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): uint32_t ns3::Ipv6InterfaceAddress::GetNsDadUid() const [member function] - cls.add_method('GetNsDadUid', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Prefix ns3::Ipv6InterfaceAddress::GetPrefix() const [member function] - cls.add_method('GetPrefix', - 'ns3::Ipv6Prefix', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e ns3::Ipv6InterfaceAddress::GetScope() const [member function] - cls.add_method('GetScope', - 'ns3::Ipv6InterfaceAddress::Scope_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e ns3::Ipv6InterfaceAddress::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Ipv6InterfaceAddress::State_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] - cls.add_method('SetAddress', - 'void', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetNsDadUid(uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('uint32_t', 'uid')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetScope(ns3::Ipv6InterfaceAddress::Scope_e scope) [member function] - cls.add_method('SetScope', - 'void', - [param('ns3::Ipv6InterfaceAddress::Scope_e', 'scope')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetState(ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - return - def register_Ns3Ipv6Prefix_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() @@ -2385,6 +2323,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -2666,62 +2612,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2730,6 +2632,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2770,6 +2674,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3020,106 +2926,6 @@ [param('uint8_t', 'ttl')]) return -def register_Ns3Ipv6Header_methods(root_module, cls): - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header(ns3::Ipv6Header const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Header const &', 'arg0')]) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header() [constructor] - cls.add_constructor([]) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::Deserialize(ns3::Buffer::Iterator start) [member function] - cls.add_method('Deserialize', - 'uint32_t', - [param('ns3::Buffer::Iterator', 'start')], - is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetDestinationAddress() const [member function] - cls.add_method('GetDestinationAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetFlowLabel() const [member function] - cls.add_method('GetFlowLabel', - 'uint32_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetHopLimit() const [member function] - cls.add_method('GetHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): ns3::TypeId ns3::Ipv6Header::GetInstanceTypeId() const [member function] - cls.add_method('GetInstanceTypeId', - 'ns3::TypeId', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetNextHeader() const [member function] - cls.add_method('GetNextHeader', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint16_t ns3::Ipv6Header::GetPayloadLength() const [member function] - cls.add_method('GetPayloadLength', - 'uint16_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetSerializedSize() const [member function] - cls.add_method('GetSerializedSize', - 'uint32_t', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetSourceAddress() const [member function] - cls.add_method('GetSourceAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetTrafficClass() const [member function] - cls.add_method('GetTrafficClass', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): static ns3::TypeId ns3::Ipv6Header::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Print(std::ostream & os) const [member function] - cls.add_method('Print', - 'void', - [param('std::ostream &', 'os')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Serialize(ns3::Buffer::Iterator start) const [member function] - cls.add_method('Serialize', - 'void', - [param('ns3::Buffer::Iterator', 'start')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetDestinationAddress(ns3::Ipv6Address dst) [member function] - cls.add_method('SetDestinationAddress', - 'void', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetFlowLabel(uint32_t flow) [member function] - cls.add_method('SetFlowLabel', - 'void', - [param('uint32_t', 'flow')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetHopLimit(uint8_t limit) [member function] - cls.add_method('SetHopLimit', - 'void', - [param('uint8_t', 'limit')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetNextHeader(uint8_t next) [member function] - cls.add_method('SetNextHeader', - 'void', - [param('uint8_t', 'next')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetPayloadLength(uint16_t len) [member function] - cls.add_method('SetPayloadLength', - 'void', - [param('uint16_t', 'len')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetSourceAddress(ns3::Ipv6Address src) [member function] - cls.add_method('SetSourceAddress', - 'void', - [param('ns3::Ipv6Address', 'src')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetTrafficClass(uint8_t traffic) [member function] - cls.add_method('SetTrafficClass', - 'void', - [param('uint8_t', 'traffic')]) - return - def register_Ns3Object_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::Object() [constructor] cls.add_constructor([]) @@ -4025,13 +3831,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -4058,6 +3866,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4859,63 +4672,6 @@ is_virtual=True) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -5339,6 +5095,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -5672,151 +5433,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor] cls.add_constructor([]) @@ -6431,10 +6047,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): diff -Naur ns-3.19/src/dsdv/bindings/modulegen__gcc_LP64.py ns-3.20/src/dsdv/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/dsdv/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.312637634 -0700 +++ ns-3.20/src/dsdv/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.644997883 -0700 @@ -100,12 +100,6 @@ 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-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress [class] - module.add_class('Ipv6InterfaceAddress', import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e [enumeration] - module.add_enum('State_e', ['TENTATIVE', 'DEPRECATED', 'PREFERRED', 'PERMANENT', 'HOMEADDRESS', 'TENTATIVE_OPTIMISTIC', 'INVALID'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e [enumeration] - module.add_enum('Scope_e', ['HOST', 'LINKLOCAL', 'GLOBAL'], outer_class=root_module['ns3::Ipv6InterfaceAddress'], import_from_module='ns.internet') ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix [class] module.add_class('Ipv6Prefix', import_from_module='ns.network') ## node-container.h (module 'network'): ns3::NodeContainer [class] @@ -142,6 +136,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -162,6 +158,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## dsdv-helper.h (module 'dsdv'): ns3::DsdvHelper [class] @@ -174,10 +172,6 @@ module.add_enum('DscpType', ['DscpDefault', 'DSCP_CS1', 'DSCP_AF11', 'DSCP_AF12', 'DSCP_AF13', 'DSCP_CS2', 'DSCP_AF21', 'DSCP_AF22', 'DSCP_AF23', 'DSCP_CS3', 'DSCP_AF31', 'DSCP_AF32', 'DSCP_AF33', 'DSCP_CS4', 'DSCP_AF41', 'DSCP_AF42', 'DSCP_AF43', 'DSCP_CS5', 'DSCP_EF', 'DSCP_CS6', 'DSCP_CS7'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType [enumeration] module.add_enum('EcnType', ['ECN_NotECT', 'ECN_ECT1', 'ECN_ECT0', 'ECN_CE'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header [class] - module.add_class('Ipv6Header', import_from_module='ns.internet', parent=root_module['ns3::Header']) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::NextHeader_e [enumeration] - module.add_enum('NextHeader_e', ['IPV6_EXT_HOP_BY_HOP', 'IPV6_IPV4', 'IPV6_TCP', 'IPV6_UDP', 'IPV6_IPV6', 'IPV6_EXT_ROUTING', 'IPV6_EXT_FRAGMENTATION', 'IPV6_EXT_CONFIDENTIALITY', 'IPV6_EXT_AUTHENTIFICATION', 'IPV6_ICMPV6', 'IPV6_EXT_END', 'IPV6_EXT_DESTINATION', 'IPV6_SCTP', 'IPV6_EXT_MOBILITY', 'IPV6_UDP_LITE'], outer_class=root_module['ns3::Ipv6Header'], import_from_module='ns.internet') ## 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] @@ -276,10 +270,6 @@ module.add_class('ExponentialRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::GammaRandomVariable [class] module.add_class('GammaRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -306,8 +296,6 @@ 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -346,7 +334,7 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv4-list-routing.h (module 'internet'): ns3::Ipv4ListRouting [class] module.add_class('Ipv4ListRouting', import_from_module='ns.internet', parent=root_module['ns3::Ipv4RoutingProtocol']) - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') ## Register a nested module for the namespace FatalImpl @@ -375,12 +363,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -417,7 +405,7 @@ module.add_class('RoutingTable') ## dsdv-rtable.h (module 'dsdv'): ns3::dsdv::RoutingTableEntry [class] module.add_class('RoutingTableEntry') - module.add_container('std::map< ns3::Ipv4Address, ns3::dsdv::RoutingTableEntry >', ('ns3::Ipv4Address', 'ns3::dsdv::RoutingTableEntry'), container_type='map') + module.add_container('std::map< ns3::Ipv4Address, ns3::dsdv::RoutingTableEntry >', ('ns3::Ipv4Address', 'ns3::dsdv::RoutingTableEntry'), container_type=u'map') def register_methods(root_module): register_Ns3Address_methods(root_module, root_module['ns3::Address']) @@ -447,7 +435,6 @@ register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) register_Ns3Ipv4RoutingHelper_methods(root_module, root_module['ns3::Ipv4RoutingHelper']) register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address']) - register_Ns3Ipv6InterfaceAddress_methods(root_module, root_module['ns3::Ipv6InterfaceAddress']) register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix']) register_Ns3NodeContainer_methods(root_module, root_module['ns3::NodeContainer']) register_Ns3ObjectBase_methods(root_module, root_module['ns3::ObjectBase']) @@ -464,6 +451,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) @@ -475,7 +463,6 @@ register_Ns3DsdvHelper_methods(root_module, root_module['ns3::DsdvHelper']) register_Ns3Header_methods(root_module, root_module['ns3::Header']) register_Ns3Ipv4Header_methods(root_module, root_module['ns3::Ipv4Header']) - register_Ns3Ipv6Header_methods(root_module, root_module['ns3::Ipv6Header']) register_Ns3Object_methods(root_module, root_module['ns3::Object']) register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3RandomVariableStream_methods(root_module, root_module['ns3::RandomVariableStream']) @@ -521,7 +508,6 @@ register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) register_Ns3ExponentialRandomVariable_methods(root_module, root_module['ns3::ExponentialRandomVariable']) register_Ns3GammaRandomVariable_methods(root_module, root_module['ns3::GammaRandomVariable']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -534,7 +520,6 @@ register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3LogNormalRandomVariable_methods(root_module, root_module['ns3::LogNormalRandomVariable']) @@ -811,6 +796,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -823,6 +812,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1721,61 +1714,6 @@ [param('uint8_t *', 'address')]) return -def register_Ns3Ipv6InterfaceAddress_methods(root_module, cls): - cls.add_binary_comparison_operator('!=') - cls.add_output_stream_operator() - cls.add_binary_comparison_operator('==') - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress() [constructor] - cls.add_constructor([]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6Address address, ns3::Ipv6Prefix prefix) [constructor] - cls.add_constructor([param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'prefix')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Ipv6InterfaceAddress(ns3::Ipv6InterfaceAddress const & o) [copy constructor] - cls.add_constructor([param('ns3::Ipv6InterfaceAddress const &', 'o')]) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6InterfaceAddress::GetAddress() const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): uint32_t ns3::Ipv6InterfaceAddress::GetNsDadUid() const [member function] - cls.add_method('GetNsDadUid', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6Prefix ns3::Ipv6InterfaceAddress::GetPrefix() const [member function] - cls.add_method('GetPrefix', - 'ns3::Ipv6Prefix', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::Scope_e ns3::Ipv6InterfaceAddress::GetScope() const [member function] - cls.add_method('GetScope', - 'ns3::Ipv6InterfaceAddress::Scope_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): ns3::Ipv6InterfaceAddress::State_e ns3::Ipv6InterfaceAddress::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Ipv6InterfaceAddress::State_e', - [], - is_const=True) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] - cls.add_method('SetAddress', - 'void', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetNsDadUid(uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('uint32_t', 'uid')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetScope(ns3::Ipv6InterfaceAddress::Scope_e scope) [member function] - cls.add_method('SetScope', - 'void', - [param('ns3::Ipv6InterfaceAddress::Scope_e', 'scope')]) - ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetState(ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - return - def register_Ns3Ipv6Prefix_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() @@ -2385,6 +2323,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -2666,62 +2612,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2730,6 +2632,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2770,6 +2674,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3020,106 +2926,6 @@ [param('uint8_t', 'ttl')]) return -def register_Ns3Ipv6Header_methods(root_module, cls): - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header(ns3::Ipv6Header const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Header const &', 'arg0')]) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Header::Ipv6Header() [constructor] - cls.add_constructor([]) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::Deserialize(ns3::Buffer::Iterator start) [member function] - cls.add_method('Deserialize', - 'uint32_t', - [param('ns3::Buffer::Iterator', 'start')], - is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetDestinationAddress() const [member function] - cls.add_method('GetDestinationAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetFlowLabel() const [member function] - cls.add_method('GetFlowLabel', - 'uint32_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetHopLimit() const [member function] - cls.add_method('GetHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): ns3::TypeId ns3::Ipv6Header::GetInstanceTypeId() const [member function] - cls.add_method('GetInstanceTypeId', - 'ns3::TypeId', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetNextHeader() const [member function] - cls.add_method('GetNextHeader', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint16_t ns3::Ipv6Header::GetPayloadLength() const [member function] - cls.add_method('GetPayloadLength', - 'uint16_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint32_t ns3::Ipv6Header::GetSerializedSize() const [member function] - cls.add_method('GetSerializedSize', - 'uint32_t', - [], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6Header::GetSourceAddress() const [member function] - cls.add_method('GetSourceAddress', - 'ns3::Ipv6Address', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): uint8_t ns3::Ipv6Header::GetTrafficClass() const [member function] - cls.add_method('GetTrafficClass', - 'uint8_t', - [], - is_const=True) - ## ipv6-header.h (module 'internet'): static ns3::TypeId ns3::Ipv6Header::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Print(std::ostream & os) const [member function] - cls.add_method('Print', - 'void', - [param('std::ostream &', 'os')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::Serialize(ns3::Buffer::Iterator start) const [member function] - cls.add_method('Serialize', - 'void', - [param('ns3::Buffer::Iterator', 'start')], - is_const=True, is_virtual=True) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetDestinationAddress(ns3::Ipv6Address dst) [member function] - cls.add_method('SetDestinationAddress', - 'void', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetFlowLabel(uint32_t flow) [member function] - cls.add_method('SetFlowLabel', - 'void', - [param('uint32_t', 'flow')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetHopLimit(uint8_t limit) [member function] - cls.add_method('SetHopLimit', - 'void', - [param('uint8_t', 'limit')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetNextHeader(uint8_t next) [member function] - cls.add_method('SetNextHeader', - 'void', - [param('uint8_t', 'next')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetPayloadLength(uint16_t len) [member function] - cls.add_method('SetPayloadLength', - 'void', - [param('uint16_t', 'len')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetSourceAddress(ns3::Ipv6Address src) [member function] - cls.add_method('SetSourceAddress', - 'void', - [param('ns3::Ipv6Address', 'src')]) - ## ipv6-header.h (module 'internet'): void ns3::Ipv6Header::SetTrafficClass(uint8_t traffic) [member function] - cls.add_method('SetTrafficClass', - 'void', - [param('uint8_t', 'traffic')]) - return - def register_Ns3Object_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::Object() [constructor] cls.add_constructor([]) @@ -4025,13 +3831,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -4058,6 +3866,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4859,63 +4672,6 @@ is_virtual=True) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -5339,6 +5095,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -5672,151 +5433,6 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] - cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', - 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', - [], - is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] - cls.add_method('GetNAddresses', - 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', - 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] - cls.add_method('IsForwarding', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', - 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', - 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', - 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', - 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', - 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', - 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', - 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', - 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', - 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] - cls.add_method('DoDispose', - 'void', - [], - visibility='protected', is_virtual=True) - return - def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor] cls.add_constructor([]) @@ -6431,10 +6047,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): diff -Naur ns-3.19/src/dsdv/model/dsdv-packet.cc ns-3.20/src/dsdv/model/dsdv-packet.cc --- ns-3.19/src/dsdv/model/dsdv-packet.cc 2014-06-17 10:34:00.316637604 -0700 +++ ns-3.20/src/dsdv/model/dsdv-packet.cc 2014-06-17 10:33:13.647997860 -0700 @@ -34,8 +34,9 @@ namespace ns3 { namespace dsdv { -NS_OBJECT_ENSURE_REGISTERED (DsdvHeader) - ; + +NS_OBJECT_ENSURE_REGISTERED (DsdvHeader); + DsdvHeader::DsdvHeader (Ipv4Address dst, uint32_t hopCount, uint32_t dstSeqNo) : m_dst (dst), m_hopCount (hopCount), diff -Naur ns-3.19/src/dsdv/model/dsdv-routing-protocol.cc ns-3.20/src/dsdv/model/dsdv-routing-protocol.cc --- ns-3.19/src/dsdv/model/dsdv-routing-protocol.cc 2014-06-17 10:34:00.317637596 -0700 +++ ns-3.20/src/dsdv/model/dsdv-routing-protocol.cc 2014-06-17 10:33:13.649997845 -0700 @@ -44,8 +44,8 @@ namespace ns3 { namespace dsdv { -NS_OBJECT_ENSURE_REGISTERED (RoutingProtocol) - ; + +NS_OBJECT_ENSURE_REGISTERED (RoutingProtocol); /// UDP Port for DSDV control traffic const uint32_t RoutingProtocol::DSDV_PORT = 269; diff -Naur ns-3.19/src/dsdv/test/dsdv-testcase.cc ns-3.20/src/dsdv/test/dsdv-testcase.cc --- ns-3.19/src/dsdv/test/dsdv-testcase.cc 2014-06-17 10:34:00.318637588 -0700 +++ ns-3.20/src/dsdv/test/dsdv-testcase.cc 2014-06-17 10:33:13.650997837 -0700 @@ -46,7 +46,8 @@ #include "ns3/dsdv-packet.h" #include "ns3/dsdv-rtable.h" -namespace ns3 { +using namespace ns3; + class DsdvHeaderTestCase : public TestCase { public: @@ -192,4 +193,3 @@ AddTestCase (new DsdvTableTestCase (), TestCase::QUICK); } } g_dsdvTestSuite; -} diff -Naur ns-3.19/src/dsr/bindings/modulegen__gcc_ILP32.py ns-3.20/src/dsr/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/dsr/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.327637518 -0700 +++ ns-3.20/src/dsr/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.659997768 -0700 @@ -164,6 +164,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -200,6 +202,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## header.h (module 'network'): ns3::Header [class] @@ -448,25 +452,25 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## icmpv4-l4-protocol.h (module 'internet'): ns3::Icmpv4L4Protocol [class] module.add_class('Icmpv4L4Protocol', import_from_module='ns.internet', parent=root_module['ns3::IpL4Protocol']) - module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type='vector') - module.add_container('ns3::WifiMcsList', 'unsigned char', container_type='vector') - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', 'ns3::WifiMcsListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', 'ns3::WifiMcsListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', 'ns3::WifiMcsListIterator&') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >', 'ns3::WifiMcsList') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >*', 'ns3::WifiMcsList*') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >&', 'ns3::WifiMcsList&') - typehandlers.add_type_alias('uint8_t', 'ns3::WifiInformationElementId') - typehandlers.add_type_alias('uint8_t*', 'ns3::WifiInformationElementId*') - typehandlers.add_type_alias('uint8_t&', 'ns3::WifiInformationElementId&') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', 'ns3::WifiModeListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', 'ns3::WifiModeListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', 'ns3::WifiModeListIterator&') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', 'ns3::WifiModeList') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', 'ns3::WifiModeList*') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', 'ns3::WifiModeList&') + module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type=u'vector') + module.add_container('ns3::WifiMcsList', 'unsigned char', container_type=u'vector') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', u'ns3::WifiMcsListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', u'ns3::WifiMcsListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', u'ns3::WifiMcsListIterator&') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >', u'ns3::WifiMcsList') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >*', u'ns3::WifiMcsList*') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >&', u'ns3::WifiMcsList&') + typehandlers.add_type_alias(u'uint8_t', u'ns3::WifiInformationElementId') + typehandlers.add_type_alias(u'uint8_t*', u'ns3::WifiInformationElementId*') + typehandlers.add_type_alias(u'uint8_t&', u'ns3::WifiInformationElementId&') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', u'ns3::WifiModeListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', u'ns3::WifiModeListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', u'ns3::WifiModeListIterator&') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', u'ns3::WifiModeList') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', u'ns3::WifiModeList*') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', u'ns3::WifiModeList&') ## Register a nested module for the namespace FatalImpl @@ -501,12 +505,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') ## Register a nested module for the namespace Function @@ -635,16 +639,16 @@ module.add_class('DsrOptionRreq', parent=root_module['ns3::dsr::DsrOptions']) ## dsr-options.h (module 'dsr'): ns3::dsr::DsrOptionSR [class] module.add_class('DsrOptionSR', parent=root_module['ns3::dsr::DsrOptions']) - module.add_container('std::vector< ns3::dsr::DsrNetworkQueueEntry >', 'ns3::dsr::DsrNetworkQueueEntry', container_type='vector') - module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type='vector') - module.add_container('std::vector< std::string >', 'std::string', container_type='vector') - module.add_container('std::vector< ns3::dsr::ErrorBuffEntry >', 'ns3::dsr::ErrorBuffEntry', container_type='vector') - module.add_container('std::vector< ns3::dsr::RouteCache::Neighbor >', 'ns3::dsr::RouteCache::Neighbor', container_type='vector') - module.add_container('std::vector< ns3::Ptr< ns3::ArpCache > >', 'ns3::Ptr< ns3::ArpCache >', container_type='vector') - module.add_container('std::list< std::vector< ns3::Ipv4Address > >', 'std::vector< ns3::Ipv4Address >', container_type='list') - module.add_container('std::list< ns3::dsr::RouteCacheEntry >', 'ns3::dsr::RouteCacheEntry', container_type='list') - module.add_container('std::map< ns3::Ipv4Address, ns3::dsr::RreqTableEntry >', ('ns3::Ipv4Address', 'ns3::dsr::RreqTableEntry'), container_type='map') - module.add_container('std::vector< ns3::dsr::SendBuffEntry >', 'ns3::dsr::SendBuffEntry', container_type='vector') + module.add_container('std::vector< ns3::dsr::DsrNetworkQueueEntry >', 'ns3::dsr::DsrNetworkQueueEntry', container_type=u'vector') + module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type=u'vector') + module.add_container('std::vector< std::string >', 'std::string', container_type=u'vector') + module.add_container('std::vector< ns3::dsr::ErrorBuffEntry >', 'ns3::dsr::ErrorBuffEntry', container_type=u'vector') + module.add_container('std::vector< ns3::dsr::RouteCache::Neighbor >', 'ns3::dsr::RouteCache::Neighbor', container_type=u'vector') + module.add_container('std::vector< ns3::Ptr< ns3::ArpCache > >', 'ns3::Ptr< ns3::ArpCache >', container_type=u'vector') + module.add_container('std::list< std::vector< ns3::Ipv4Address > >', 'std::vector< ns3::Ipv4Address >', container_type=u'list') + module.add_container('std::list< ns3::dsr::RouteCacheEntry >', 'ns3::dsr::RouteCacheEntry', container_type=u'list') + module.add_container('std::map< ns3::Ipv4Address, ns3::dsr::RreqTableEntry >', ('ns3::Ipv4Address', 'ns3::dsr::RreqTableEntry'), container_type=u'map') + module.add_container('std::vector< ns3::dsr::SendBuffEntry >', 'ns3::dsr::SendBuffEntry', container_type=u'vector') def register_types_ns3_internal(module): root_module = module.get_root() @@ -699,6 +703,7 @@ register_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) @@ -1123,6 +1128,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1135,6 +1144,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2080,6 +2093,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -2809,6 +2827,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -3328,61 +3354,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -3390,6 +3372,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -3430,6 +3414,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -4925,12 +4911,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -4956,6 +4944,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -6516,6 +6509,11 @@ 'ns3::TypeId', [], is_static=True) + ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsModeSupported(ns3::WifiMode mode) const [member function] + cls.add_method('IsModeSupported', + 'bool', + [param('ns3::WifiMode', 'mode')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsStateBusy() [member function] cls.add_method('IsStateBusy', 'bool', @@ -8462,6 +8460,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -9594,10 +9597,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): @@ -10485,6 +10488,14 @@ cls.add_method('Enqueue', 'bool', [param('ns3::dsr::DsrNetworkQueueEntry &', 'entry')]) + ## dsr-network-queue.h (module 'dsr'): bool ns3::dsr::DsrNetworkQueue::Find(ns3::Ipv4Address nextHop) [member function] + cls.add_method('Find', + 'bool', + [param('ns3::Ipv4Address', 'nextHop')]) + ## dsr-network-queue.h (module 'dsr'): bool ns3::dsr::DsrNetworkQueue::FindPacketWithNexthop(ns3::Ipv4Address nextHop, ns3::dsr::DsrNetworkQueueEntry & entry) [member function] + cls.add_method('FindPacketWithNexthop', + 'bool', + [param('ns3::Ipv4Address', 'nextHop'), param('ns3::dsr::DsrNetworkQueueEntry &', 'entry')]) ## dsr-network-queue.h (module 'dsr'): void ns3::dsr::DsrNetworkQueue::Flush() [member function] cls.add_method('Flush', 'void', @@ -11373,6 +11384,10 @@ cls.add_method('CancelNetworkPacketTimer', 'void', [param('ns3::dsr::MaintainBuffEntry &', 'mb')]) + ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::CancelPacketAllTimer(ns3::dsr::MaintainBuffEntry & mb) [member function] + cls.add_method('CancelPacketAllTimer', + 'void', + [param('ns3::dsr::MaintainBuffEntry &', 'mb')]) ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::CancelPacketTimerNextHop(ns3::Ipv4Address nextHop, uint8_t protocol) [member function] cls.add_method('CancelPacketTimerNextHop', 'void', @@ -11631,10 +11646,10 @@ cls.add_method('SendRequest', 'void', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source')]) - ## 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] + ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SendUnreachError(ns3::Ipv4Address unreachNode, ns3::Ipv4Address destination, ns3::Ipv4Address originalDst, uint8_t salvage, uint8_t protocol) [member function] cls.add_method('SendUnreachError', 'void', - [param('ns3::Ipv4Address', 'errorHop'), param('ns3::Ipv4Address', 'destination'), param('ns3::Ipv4Address', 'originalDst'), param('uint8_t', 'salvage'), param('uint8_t', 'protocol')]) + [param('ns3::Ipv4Address', 'unreachNode'), param('ns3::Ipv4Address', 'destination'), param('ns3::Ipv4Address', 'originalDst'), param('uint8_t', 'salvage'), param('uint8_t', 'protocol')]) ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SetDownTarget(ns3::Callback, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [member function] cls.add_method('SetDownTarget', 'void', diff -Naur ns-3.19/src/dsr/bindings/modulegen__gcc_LP64.py ns-3.20/src/dsr/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/dsr/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.335637457 -0700 +++ ns-3.20/src/dsr/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.666997713 -0700 @@ -164,6 +164,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -200,6 +202,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## header.h (module 'network'): ns3::Header [class] @@ -448,25 +452,25 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## icmpv4-l4-protocol.h (module 'internet'): ns3::Icmpv4L4Protocol [class] module.add_class('Icmpv4L4Protocol', import_from_module='ns.internet', parent=root_module['ns3::IpL4Protocol']) - module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type='vector') - module.add_container('ns3::WifiMcsList', 'unsigned char', container_type='vector') - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', 'ns3::WifiMcsListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', 'ns3::WifiMcsListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', 'ns3::WifiMcsListIterator&') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >', 'ns3::WifiMcsList') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >*', 'ns3::WifiMcsList*') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >&', 'ns3::WifiMcsList&') - typehandlers.add_type_alias('uint8_t', 'ns3::WifiInformationElementId') - typehandlers.add_type_alias('uint8_t*', 'ns3::WifiInformationElementId*') - typehandlers.add_type_alias('uint8_t&', 'ns3::WifiInformationElementId&') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', 'ns3::WifiModeListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', 'ns3::WifiModeListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', 'ns3::WifiModeListIterator&') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', 'ns3::WifiModeList') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', 'ns3::WifiModeList*') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', 'ns3::WifiModeList&') + module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type=u'vector') + module.add_container('ns3::WifiMcsList', 'unsigned char', container_type=u'vector') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', u'ns3::WifiMcsListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', u'ns3::WifiMcsListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', u'ns3::WifiMcsListIterator&') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >', u'ns3::WifiMcsList') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >*', u'ns3::WifiMcsList*') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >&', u'ns3::WifiMcsList&') + typehandlers.add_type_alias(u'uint8_t', u'ns3::WifiInformationElementId') + typehandlers.add_type_alias(u'uint8_t*', u'ns3::WifiInformationElementId*') + typehandlers.add_type_alias(u'uint8_t&', u'ns3::WifiInformationElementId&') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', u'ns3::WifiModeListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', u'ns3::WifiModeListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', u'ns3::WifiModeListIterator&') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', u'ns3::WifiModeList') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', u'ns3::WifiModeList*') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', u'ns3::WifiModeList&') ## Register a nested module for the namespace FatalImpl @@ -501,12 +505,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') ## Register a nested module for the namespace Function @@ -635,16 +639,16 @@ module.add_class('DsrOptionRreq', parent=root_module['ns3::dsr::DsrOptions']) ## dsr-options.h (module 'dsr'): ns3::dsr::DsrOptionSR [class] module.add_class('DsrOptionSR', parent=root_module['ns3::dsr::DsrOptions']) - module.add_container('std::vector< ns3::dsr::DsrNetworkQueueEntry >', 'ns3::dsr::DsrNetworkQueueEntry', container_type='vector') - module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type='vector') - module.add_container('std::vector< std::string >', 'std::string', container_type='vector') - module.add_container('std::vector< ns3::dsr::ErrorBuffEntry >', 'ns3::dsr::ErrorBuffEntry', container_type='vector') - module.add_container('std::vector< ns3::dsr::RouteCache::Neighbor >', 'ns3::dsr::RouteCache::Neighbor', container_type='vector') - module.add_container('std::vector< ns3::Ptr< ns3::ArpCache > >', 'ns3::Ptr< ns3::ArpCache >', container_type='vector') - module.add_container('std::list< std::vector< ns3::Ipv4Address > >', 'std::vector< ns3::Ipv4Address >', container_type='list') - module.add_container('std::list< ns3::dsr::RouteCacheEntry >', 'ns3::dsr::RouteCacheEntry', container_type='list') - module.add_container('std::map< ns3::Ipv4Address, ns3::dsr::RreqTableEntry >', ('ns3::Ipv4Address', 'ns3::dsr::RreqTableEntry'), container_type='map') - module.add_container('std::vector< ns3::dsr::SendBuffEntry >', 'ns3::dsr::SendBuffEntry', container_type='vector') + module.add_container('std::vector< ns3::dsr::DsrNetworkQueueEntry >', 'ns3::dsr::DsrNetworkQueueEntry', container_type=u'vector') + module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type=u'vector') + module.add_container('std::vector< std::string >', 'std::string', container_type=u'vector') + module.add_container('std::vector< ns3::dsr::ErrorBuffEntry >', 'ns3::dsr::ErrorBuffEntry', container_type=u'vector') + module.add_container('std::vector< ns3::dsr::RouteCache::Neighbor >', 'ns3::dsr::RouteCache::Neighbor', container_type=u'vector') + module.add_container('std::vector< ns3::Ptr< ns3::ArpCache > >', 'ns3::Ptr< ns3::ArpCache >', container_type=u'vector') + module.add_container('std::list< std::vector< ns3::Ipv4Address > >', 'std::vector< ns3::Ipv4Address >', container_type=u'list') + module.add_container('std::list< ns3::dsr::RouteCacheEntry >', 'ns3::dsr::RouteCacheEntry', container_type=u'list') + module.add_container('std::map< ns3::Ipv4Address, ns3::dsr::RreqTableEntry >', ('ns3::Ipv4Address', 'ns3::dsr::RreqTableEntry'), container_type=u'map') + module.add_container('std::vector< ns3::dsr::SendBuffEntry >', 'ns3::dsr::SendBuffEntry', container_type=u'vector') def register_types_ns3_internal(module): root_module = module.get_root() @@ -699,6 +703,7 @@ register_Ns3SystemWallClockMs_methods(root_module, root_module['ns3::SystemWallClockMs']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) @@ -1123,6 +1128,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1135,6 +1144,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2080,6 +2093,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -2809,6 +2827,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -3328,61 +3354,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -3390,6 +3372,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -3430,6 +3414,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -4925,12 +4911,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -4956,6 +4944,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -6516,6 +6509,11 @@ 'ns3::TypeId', [], is_static=True) + ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsModeSupported(ns3::WifiMode mode) const [member function] + cls.add_method('IsModeSupported', + 'bool', + [param('ns3::WifiMode', 'mode')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsStateBusy() [member function] cls.add_method('IsStateBusy', 'bool', @@ -8462,6 +8460,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -9594,10 +9597,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): @@ -10485,6 +10488,14 @@ cls.add_method('Enqueue', 'bool', [param('ns3::dsr::DsrNetworkQueueEntry &', 'entry')]) + ## dsr-network-queue.h (module 'dsr'): bool ns3::dsr::DsrNetworkQueue::Find(ns3::Ipv4Address nextHop) [member function] + cls.add_method('Find', + 'bool', + [param('ns3::Ipv4Address', 'nextHop')]) + ## dsr-network-queue.h (module 'dsr'): bool ns3::dsr::DsrNetworkQueue::FindPacketWithNexthop(ns3::Ipv4Address nextHop, ns3::dsr::DsrNetworkQueueEntry & entry) [member function] + cls.add_method('FindPacketWithNexthop', + 'bool', + [param('ns3::Ipv4Address', 'nextHop'), param('ns3::dsr::DsrNetworkQueueEntry &', 'entry')]) ## dsr-network-queue.h (module 'dsr'): void ns3::dsr::DsrNetworkQueue::Flush() [member function] cls.add_method('Flush', 'void', @@ -11373,6 +11384,10 @@ cls.add_method('CancelNetworkPacketTimer', 'void', [param('ns3::dsr::MaintainBuffEntry &', 'mb')]) + ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::CancelPacketAllTimer(ns3::dsr::MaintainBuffEntry & mb) [member function] + cls.add_method('CancelPacketAllTimer', + 'void', + [param('ns3::dsr::MaintainBuffEntry &', 'mb')]) ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::CancelPacketTimerNextHop(ns3::Ipv4Address nextHop, uint8_t protocol) [member function] cls.add_method('CancelPacketTimerNextHop', 'void', @@ -11631,10 +11646,10 @@ cls.add_method('SendRequest', 'void', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source')]) - ## 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] + ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SendUnreachError(ns3::Ipv4Address unreachNode, ns3::Ipv4Address destination, ns3::Ipv4Address originalDst, uint8_t salvage, uint8_t protocol) [member function] cls.add_method('SendUnreachError', 'void', - [param('ns3::Ipv4Address', 'errorHop'), param('ns3::Ipv4Address', 'destination'), param('ns3::Ipv4Address', 'originalDst'), param('uint8_t', 'salvage'), param('uint8_t', 'protocol')]) + [param('ns3::Ipv4Address', 'unreachNode'), param('ns3::Ipv4Address', 'destination'), param('ns3::Ipv4Address', 'originalDst'), param('uint8_t', 'salvage'), param('uint8_t', 'protocol')]) ## dsr-routing.h (module 'dsr'): void ns3::dsr::DsrRouting::SetDownTarget(ns3::Callback, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr, ns3::empty, ns3::empty, ns3::empty, ns3::empty> callback) [member function] cls.add_method('SetDownTarget', 'void', diff -Naur ns-3.19/src/dsr/doc/dsr.rst ns-3.20/src/dsr/doc/dsr.rst --- ns-3.19/src/dsr/doc/dsr.rst 2014-06-17 10:34:00.336637449 -0700 +++ ns-3.20/src/dsr/doc/dsr.rst 2014-06-17 10:33:13.667997706 -0700 @@ -14,7 +14,8 @@ ******************** This model implements the base specification of the Dynamic Source Routing -(DSR) protocol. Implementation is based on :rfc:`4728`. +(DSR) protocol. Implementation is based on :rfc:`4728`, with some extensions +and modifications to the RFC specifications. DSR operates on a on-demand behavior. Therefore, our DSR model buffers all packets while a route request packet (RREQ) is disseminated. We implement @@ -188,7 +189,16 @@ * manet-routing-compare.cc has been used to compare DSR with three of other routing protocols. A paper was presented on these results at the Workshop on ns-3 in 2011. - + +Limitations +*********** + +The model is not fully compliant with :rfc:`4728`. As an example, Dsr fixed size header +has been extended and it is four octects longer then the RFC specification. +As a consequence, the DSR headers can not be correctly decoded by Wireshark. + +The model full compliance with the RFC is planned for the future. + References ********** diff -Naur ns-3.19/src/dsr/model/dsr-errorbuff.cc ns-3.20/src/dsr/model/dsr-errorbuff.cc --- ns-3.19/src/dsr/model/dsr-errorbuff.cc 2014-06-17 10:34:00.338637433 -0700 +++ ns-3.20/src/dsr/model/dsr-errorbuff.cc 2014-06-17 10:33:13.670997683 -0700 @@ -116,7 +116,7 @@ if (i->GetDestination () == dst) { entry = *i; - m_errorBuffer.erase (i); + i = m_errorBuffer.erase (i); NS_LOG_DEBUG ("Packet size while dequeuing " << entry.GetPacket ()->GetSize ()); return true; } diff -Naur ns-3.19/src/dsr/model/dsr-fs-header.cc ns-3.20/src/dsr/model/dsr-fs-header.cc --- ns-3.19/src/dsr/model/dsr-fs-header.cc 2014-06-17 10:34:00.339637426 -0700 +++ ns-3.20/src/dsr/model/dsr-fs-header.cc 2014-06-17 10:33:13.671997675 -0700 @@ -39,8 +39,7 @@ NS_LOG_COMPONENT_DEFINE ("DsrFsHeader"); -NS_OBJECT_ENSURE_REGISTERED (DsrFsHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrFsHeader); TypeId DsrFsHeader::GetTypeId () { @@ -259,8 +258,7 @@ return m_optionData; } -NS_OBJECT_ENSURE_REGISTERED (DsrRoutingHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrRoutingHeader); TypeId DsrRoutingHeader::GetTypeId () { diff -Naur ns-3.19/src/dsr/model/dsr-gratuitous-reply-table.cc ns-3.20/src/dsr/model/dsr-gratuitous-reply-table.cc --- ns-3.19/src/dsr/model/dsr-gratuitous-reply-table.cc 2014-06-17 10:34:00.340637418 -0700 +++ ns-3.20/src/dsr/model/dsr-gratuitous-reply-table.cc 2014-06-17 10:33:13.671997675 -0700 @@ -38,8 +38,7 @@ namespace ns3 { namespace dsr { -NS_OBJECT_ENSURE_REGISTERED (GraReply) - ; +NS_OBJECT_ENSURE_REGISTERED (GraReply); TypeId GraReply::GetTypeId () { diff -Naur ns-3.19/src/dsr/model/dsr-maintain-buff.cc ns-3.20/src/dsr/model/dsr-maintain-buff.cc --- ns-3.19/src/dsr/model/dsr-maintain-buff.cc 2014-06-17 10:34:00.340637418 -0700 +++ ns-3.20/src/dsr/model/dsr-maintain-buff.cc 2014-06-17 10:33:13.672997667 -0700 @@ -97,7 +97,7 @@ if (i->GetNextHop () == nextHop) { entry = *i; - m_maintainBuffer.erase (i); + i = m_maintainBuffer.erase (i); NS_LOG_DEBUG ("Packet size while dequeuing " << entry.GetPacket ()->GetSize ()); return true; } @@ -134,7 +134,7 @@ && (i->GetSrc () == entry.GetSrc ()) && (i->GetDst () == entry.GetDst ()) && (i->GetAckId () == entry.GetAckId ()) && (i->GetSegsLeft () == entry.GetSegsLeft ())) { - m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the received packet + i = m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the received packet return true; } } @@ -155,7 +155,7 @@ && (i->GetSrc () == entry.GetSrc ()) && (i->GetDst () == entry.GetDst ()) && (i->GetAckId () == entry.GetAckId ())) { - m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the received packet + i = m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the received packet return true; } } @@ -178,7 +178,7 @@ && (i->GetSegsLeft () == entry.GetSegsLeft ()) && (i->GetAckId () == entry.GetAckId ()) ) { - m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the promisc received packet + i = m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the promisc received packet return true; } } @@ -201,7 +201,7 @@ && (i->GetNextHop () == entry.GetNextHop ()) ) { - m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the promisc received packet + i = m_maintainBuffer.erase (i); // Erase the same maintain buffer entry for the promisc received packet return true; } } diff -Naur ns-3.19/src/dsr/model/dsr-maintain-buff.h ns-3.20/src/dsr/model/dsr-maintain-buff.h --- ns-3.19/src/dsr/model/dsr-maintain-buff.h 2014-06-17 10:34:00.341637411 -0700 +++ ns-3.20/src/dsr/model/dsr-maintain-buff.h 2014-06-17 10:33:13.673997660 -0700 @@ -55,12 +55,18 @@ * Compare maintain Buffer entries * \param o * \return true if equal - */ - bool operator < (LinkKey const & o) const + */ + bool operator < (const LinkKey & o) const { - return ((m_source < o.m_source) && (m_destination < o.m_destination) - && (m_ourAdd < o.m_nextHop) && (m_nextHop < o.m_nextHop) - ); + if (m_source < o.m_source) return true; + if (o.m_source < m_source) return false; + if (m_destination < o.m_destination) return true; + if (o.m_destination < m_destination) return false; + if (m_ourAdd < o.m_ourAdd) return true; + if (o.m_ourAdd < m_ourAdd) return false; + if (m_nextHop < o.m_nextHop) return true; + if (o.m_nextHop < m_nextHop) return false; + return false; } }; @@ -77,11 +83,19 @@ * \param o * \return true if equal */ - bool operator < (NetworkKey const & o) const + bool operator < (const NetworkKey & o) const { - return ((m_ackId < o.m_ackId) && (m_ourAdd < o.m_ourAdd) && (m_nextHop < o.m_nextHop) && (m_source < o.m_source) - && (m_destination < o.m_destination) - ); + if (m_ackId < o.m_ackId) return true; + if (o.m_ackId < m_ackId) return false; + if (m_source < o.m_source) return true; + if (o.m_source < m_source) return false; + if (m_destination < o.m_destination) return true; + if (o.m_destination < m_destination) return false; + if (m_ourAdd < o.m_ourAdd) return true; + if (o.m_ourAdd < m_ourAdd) return false; + if (m_nextHop < o.m_nextHop) return true; + if (o.m_nextHop < m_nextHop) return false; + return false; } }; @@ -97,11 +111,17 @@ * \param o * \return true if equal */ - bool operator < (PassiveKey const & o) const + bool operator < (const PassiveKey & o) const { - return ((m_ackId < o.m_ackId) && (m_source < o.m_source) - && (m_destination < o.m_destination) && (m_segsLeft < o.m_segsLeft) - ); + if (m_ackId < o.m_ackId) return true; + if (o.m_ackId < m_ackId) return false; + if (m_source < o.m_source) return true; + if (o.m_source < m_source) return false; + if (m_destination < o.m_destination) return true; + if (o.m_destination < m_destination) return false; + if (m_segsLeft < o.m_segsLeft) return true; + if (o.m_segsLeft < m_segsLeft) return false; + return false; } }; diff -Naur ns-3.19/src/dsr/model/dsr-network-queue.cc ns-3.20/src/dsr/model/dsr-network-queue.cc --- ns-3.19/src/dsr/model/dsr-network-queue.cc 2014-06-17 10:34:00.341637411 -0700 +++ ns-3.20/src/dsr/model/dsr-network-queue.cc 2014-06-17 10:33:13.673997660 -0700 @@ -43,8 +43,7 @@ namespace ns3 { namespace dsr { -NS_OBJECT_ENSURE_REGISTERED (DsrNetworkQueue) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrNetworkQueue); TypeId DsrNetworkQueue::GetTypeId (void) @@ -100,6 +99,36 @@ } bool +DsrNetworkQueue::FindPacketWithNexthop (Ipv4Address nextHop, DsrNetworkQueueEntry & entry) +{ + Cleanup (); + for (std::vector::iterator i = m_dsrNetworkQueue.begin (); i != m_dsrNetworkQueue.end (); ++i) + { + if (i->GetNextHopAddress () == nextHop) + { + entry = *i; + i = m_dsrNetworkQueue.erase (i); + return true; + } + } + return false; +} + +bool +DsrNetworkQueue::Find (Ipv4Address nextHop) +{ + Cleanup (); + for (std::vector::iterator i = m_dsrNetworkQueue.begin (); i != m_dsrNetworkQueue.end (); ++i) + { + if (i->GetNextHopAddress () == nextHop) + { + return true; + } + } + return false; +} + +bool DsrNetworkQueue::Enqueue (DsrNetworkQueueEntry & entry) { NS_LOG_FUNCTION (this << m_size << m_maxSize); diff -Naur ns-3.19/src/dsr/model/dsr-network-queue.h ns-3.20/src/dsr/model/dsr-network-queue.h --- ns-3.19/src/dsr/model/dsr-network-queue.h 2014-06-17 10:34:00.341637411 -0700 +++ ns-3.20/src/dsr/model/dsr-network-queue.h 2014-06-17 10:33:13.673997660 -0700 @@ -151,6 +151,8 @@ DsrNetworkQueue (uint32_t maxLen, Time maxDelay); ~DsrNetworkQueue (); + bool FindPacketWithNexthop (Ipv4Address nextHop, DsrNetworkQueueEntry & entry); + bool Find (Ipv4Address nextHop); /** * Push entry in queue, if there is no entry with the same * packet and destination address in queue. diff -Naur ns-3.19/src/dsr/model/dsr-option-header.cc ns-3.20/src/dsr/model/dsr-option-header.cc --- ns-3.19/src/dsr/model/dsr-option-header.cc 2014-06-17 10:34:00.342637403 -0700 +++ ns-3.20/src/dsr/model/dsr-option-header.cc 2014-06-17 10:33:13.674997652 -0700 @@ -42,8 +42,7 @@ namespace dsr { NS_LOG_COMPONENT_DEFINE ("DsrOptionHeader"); -NS_OBJECT_ENSURE_REGISTERED (DsrOptionHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionHeader); TypeId DsrOptionHeader::GetTypeId () { @@ -131,8 +130,7 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionPad1Header) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionPad1Header); TypeId DsrOptionPad1Header::GetTypeId () { @@ -183,8 +181,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionPadnHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionPadnHeader); TypeId DsrOptionPadnHeader::GetTypeId () { @@ -244,8 +241,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRreqHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRreqHeader); TypeId DsrOptionRreqHeader::GetTypeId () { @@ -392,8 +388,7 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRrepHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRrepHeader); TypeId DsrOptionRrepHeader::GetTypeId () { @@ -514,8 +509,7 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionSRHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionSRHeader); TypeId DsrOptionSRHeader::GetTypeId () { @@ -657,20 +651,13 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerrHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerrHeader); TypeId DsrOptionRerrHeader::GetTypeId () { static TypeId tid = TypeId ("ns3::dsr::DsrOptionRerrHeader") .AddConstructor () .SetParent () - .AddAttribute ("ErrorType","Type of route errors", - EnumValue (NODE_UNREACHABLE), - MakeEnumAccessor (&DsrOptionRerrHeader::m_errorType), - MakeEnumChecker (NODE_UNREACHABLE, "Node unreachable", - FLOW_STATE_NOT_SUPPORTED, "Flow state not supported", - OPTION_NOT_SUPPORTED, "Option not supported")) ; return tid; } @@ -786,8 +773,7 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerrUnreachHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerrUnreachHeader); TypeId DsrOptionRerrUnreachHeader::GetTypeId () { @@ -915,8 +901,7 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerrUnsupportHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerrUnsupportHeader); TypeId DsrOptionRerrUnsupportHeader::GetTypeId () { @@ -1034,8 +1019,7 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionAckReqHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionAckReqHeader); TypeId DsrOptionAckReqHeader::GetTypeId () { @@ -1110,8 +1094,7 @@ return retVal; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionAckHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionAckHeader); TypeId DsrOptionAckHeader::GetTypeId () { diff -Naur ns-3.19/src/dsr/model/dsr-options.cc ns-3.20/src/dsr/model/dsr-options.cc --- ns-3.19/src/dsr/model/dsr-options.cc 2014-06-17 10:34:00.344637387 -0700 +++ ns-3.20/src/dsr/model/dsr-options.cc 2014-06-17 10:33:13.676997636 -0700 @@ -65,8 +65,7 @@ namespace ns3 { namespace dsr { -NS_OBJECT_ENSURE_REGISTERED (DsrOptions) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptions); TypeId DsrOptions::GetTypeId () { @@ -372,8 +371,7 @@ return 0; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionPad1) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionPad1); TypeId DsrOptionPad1::GetTypeId () { @@ -413,8 +411,7 @@ return pad1Header.GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionPadn) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionPadn); TypeId DsrOptionPadn::GetTypeId () { @@ -454,8 +451,7 @@ return padnHeader.GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRreq) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRreq); TypeId DsrOptionRreq::GetTypeId () { @@ -497,9 +493,9 @@ * \ when the ip source address is equal to the address of our own, this is request packet originated * \ by the node itself, discard it */ - if (srcAddress == ipv4Address) + if (source == ipv4Address) { - NS_LOG_DEBUG ("Discard the packet"); + NS_LOG_DEBUG ("Discard the packet since it was originated from same source address"); m_dropTrace (packet); // call the drop trace to show in the tracing return 0; } @@ -603,6 +599,14 @@ { // A node ignores all RREQs received from any node in its blacklist RouteCacheEntry toPrev; + bool isRouteInCache = dsr->LookupRoute (targetAddress, + toPrev); + RouteCacheEntry::IP_VECTOR ip = toPrev.GetVector (); // The route from our own route cache to dst + PrintVector (ip); + std::vector saveRoute (nodeList); + PrintVector (saveRoute); + bool areThereDuplicates = IfDuplicates (ip, + saveRoute); /* * When the reverse route is created or updated, the following actions on the route are also carried out: * 3. the next hop in the routing table becomes the node from which the RREQ was received @@ -622,7 +626,8 @@ { NS_LOG_DEBUG ("These two nodes are neighbors"); m_finalRoute.clear (); - m_finalRoute.push_back (srcAddress); // push back the request originator's address + /// TODO has changed the srcAddress to source, should not matter either way, check later + m_finalRoute.push_back (source); // push back the request originator's address m_finalRoute.push_back (ipv4Address); // push back our own address nextHop = srcAddress; } @@ -696,10 +701,14 @@ DsrOptionSRHeader sourceRoute; NS_LOG_DEBUG ("The route length " << m_finalRoute.size ()); sourceRoute.SetNodesAddress (m_finalRoute); - if (dsr->IsLinkCache ()) - { - dsr->UseExtends (m_finalRoute); - } + + /// TODO !!!!!!!!!!!!!! + /// Think about this part, we just added the route, + /// probability no need to increase stability now????? + // if (dsr->IsLinkCache ()) + // { + // dsr->UseExtends (m_finalRoute); + // } sourceRoute.SetSegmentsLeft ((m_finalRoute.size () - 2)); // The salvage value here is 0 sourceRoute.SetSalvage (0); @@ -737,18 +746,12 @@ /* * (ii) or it has an active route to the destination, send reply based on request header and route cache, * need to delay based on a random value from d = H * (h - 1 + r), which can avoid possible route - * reply storm. + * reply storm. Also, verify if two vectors do not contain duplicates (part of the route to the + * destination from route cache and route collected so far). If so, do not use the route found + * and forward the route request. */ - else if (dsr->LookupRoute (targetAddress, toPrev)) + else if (isRouteInCache && !areThereDuplicates) { - RouteCacheEntry::IP_VECTOR ip = toPrev.GetVector (); // The route from our own route cache to dst - PrintVector (ip); - std::vector saveRoute (nodeList); - PrintVector (saveRoute); - // Verify if the two vector contains duplicates, if so, do not use - // the route found and forward the route request - if (!(IfDuplicates (ip, saveRoute))) - { m_finalRoute.clear (); // Clear the final route vector /** * push back the intermediate node address from the source to this node @@ -800,10 +803,10 @@ PrintVector (saveRoute); sourceRoute.SetNodesAddress (saveRoute); - if (dsr->IsLinkCache ()) - { - dsr->UseExtends (saveRoute); - } + // if (dsr->IsLinkCache ()) + // { + // dsr->UseExtends (saveRoute); + // } sourceRoute.SetSegmentsLeft ((saveRoute.size () - 2)); uint8_t salvage = 0; sourceRoute.SetSalvage (salvage); @@ -839,7 +842,6 @@ * Need to first pin down the next hop address before removing duplicates */ Ipv4Address nextHop = ReverseSearchNextHop (ipv4Address, m_finalRoute); - NS_LOG_DEBUG ("The nextHop address " << nextHop); /* * First remove the duplicate ip address to automatically shorten the route, and then reversely * search the next hop address @@ -870,11 +872,6 @@ newPacket->AddHeader (dsrRoutingHeader); dsr->ScheduleCachedReply (newPacket, ipv4Address, nextHop, m_ipv4Route, hops); isPromisc = false; - } - else - { - NS_LOG_DEBUG ("There is duplicate ip addresses in the two route parts"); - } return rreq.GetSerializedSize (); } /* @@ -953,8 +950,7 @@ //unreachable: return rreq.GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRrep) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRrep); TypeId DsrOptionRrep::GetTypeId () { @@ -1154,8 +1150,7 @@ return rrep.GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionSR) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionSR); TypeId DsrOptionSR::GetTypeId () { @@ -1313,7 +1308,8 @@ m_dropTrace (packet); return 0; } - if (numberAddress - segsLeft - 2 < 0) // The index is invalid + // -fstrict-overflow sensitive, see bug 1868 + if (numberAddress - segsLeft < 2) // The index is invalid { NS_LOG_LOGIC ("Malformed header. Drop!"); m_dropTrace (packet); @@ -1395,8 +1391,7 @@ return sourceRoute.GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerr) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionRerr); TypeId DsrOptionRerr::GetTypeId () { @@ -1575,8 +1570,7 @@ return serializedSize; } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionAckReq) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionAckReq); TypeId DsrOptionAckReq::GetTypeId () { @@ -1631,8 +1625,7 @@ return ackReq.GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (DsrOptionAck) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrOptionAck); TypeId DsrOptionAck::GetTypeId () { diff -Naur ns-3.19/src/dsr/model/dsr-passive-buff.cc ns-3.20/src/dsr/model/dsr-passive-buff.cc --- ns-3.19/src/dsr/model/dsr-passive-buff.cc 2014-06-17 10:34:00.345637379 -0700 +++ ns-3.20/src/dsr/model/dsr-passive-buff.cc 2014-06-17 10:33:13.677997629 -0700 @@ -41,8 +41,7 @@ namespace ns3 { namespace dsr { -NS_OBJECT_ENSURE_REGISTERED (PassiveBuffer) - ; +NS_OBJECT_ENSURE_REGISTERED (PassiveBuffer); TypeId PassiveBuffer::GetTypeId () { @@ -117,7 +116,7 @@ && (i->GetDestination () == entry.GetDestination ()) && (i->GetIdentification () == entry.GetIdentification ()) && (i->GetFragmentOffset () == entry.GetFragmentOffset ()) && (i->GetSegsLeft () == entry.GetSegsLeft () + 1)) { - m_passiveBuffer.erase (i); // Erase the same maintain buffer entry for the received packet + i = m_passiveBuffer.erase (i); // Erase the same maintain buffer entry for the received packet return true; } } @@ -136,7 +135,7 @@ if (i->GetDestination () == dst) { entry = *i; - m_passiveBuffer.erase (i); + i = m_passiveBuffer.erase (i); NS_LOG_DEBUG ("Packet size while dequeuing " << entry.GetPacket ()->GetSize ()); return true; } diff -Naur ns-3.19/src/dsr/model/dsr-rcache.cc ns-3.20/src/dsr/model/dsr-rcache.cc --- ns-3.19/src/dsr/model/dsr-rcache.cc 2014-06-17 10:34:00.346637372 -0700 +++ ns-3.20/src/dsr/model/dsr-rcache.cc 2014-06-17 10:33:13.678997621 -0700 @@ -131,8 +131,7 @@ << "\t"; } -NS_OBJECT_ENSURE_REGISTERED (RouteCache) - ; +NS_OBJECT_ENSURE_REGISTERED (RouteCache); TypeId RouteCache::GetTypeId () { @@ -696,7 +695,7 @@ else { // Check if the expire time for the new route has expired or not - if (rt.GetExpireTime () > 0) + if (rt.GetExpireTime () > Time (0)) { rtVector.push_back (rt); // This sort function will sort the route cache entries based on the size of route in each of the diff -Naur ns-3.19/src/dsr/model/dsr-routing.cc ns-3.20/src/dsr/model/dsr-routing.cc --- ns-3.19/src/dsr/model/dsr-routing.cc 2014-06-17 10:34:00.349637349 -0700 +++ ns-3.20/src/dsr/model/dsr-routing.cc 2014-06-17 10:33:13.682997590 -0700 @@ -52,6 +52,7 @@ #include "ns3/node-list.h" #include "ns3/double.h" #include "ns3/pointer.h" +#include "ns3/timer.h" #include "ns3/object-vector.h" #include "ns3/ipv4-address.h" #include "ns3/ipv4-header.h" @@ -79,8 +80,7 @@ namespace ns3 { namespace dsr { -NS_OBJECT_ENSURE_REGISTERED (DsrRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (DsrRouting); /* see http://www.iana.org/assignments/protocol-numbers */ const uint8_t DsrRouting::PROT_NUMBER = 48; @@ -276,7 +276,7 @@ MakeUintegerAccessor (&DsrRouting::m_numPriorityQueues), MakeUintegerChecker ()) .AddAttribute ("LinkAcknowledgment","Enable Link layer acknowledgment mechanism", - BooleanValue (false), + BooleanValue (true), MakeBooleanAccessor (&DsrRouting::m_linkAck), MakeBooleanChecker ()) .AddTraceSource ("Tx", "Send DSR packet.", @@ -422,7 +422,8 @@ routeCache->SetUseExtends (m_useExtends); routeCache->ScheduleTimer (); // The call back to handle link error and send error message to appropriate nodes - routeCache->SetCallback (MakeCallback (&DsrRouting::SendRerrWhenBreaksLinkToNextHop, this)); + /// TODO whether this SendRerrWhenBreaksLinkToNextHop is used or not + // routeCache->SetCallback (MakeCallback (&DsrRouting::SendRerrWhenBreaksLinkToNextHop, this)); SetRouteCache (routeCache); // Set the main address as the current ip address m_mainAddress = addr; @@ -478,14 +479,14 @@ /// \todo this is a hard-coded check, need to find a better way to work on this if (newP->GetSize () == 4) { - NS_LOG_WARN ("WifiMacTrailer left, skip this packet"); + // NS_LOG_WARN ("WifiMacTrailer left, skip this packet"); return; } LlcSnapHeader llc; if(!newP->PeekHeader (llc)) { - NS_LOG_WARN ("llc snap header not present"); + // NS_LOG_WARN ("llc snap header not present"); NS_ASSERT (newP->GetSize() < 64); return; } @@ -499,7 +500,7 @@ ArpHeader arp; if(newP->PeekHeader (arp)) { - NS_LOG_WARN ("arp header present, skip this packet"); + // NS_LOG_WARN ("arp header present, skip this packet"); NS_ASSERT (newP->GetSize() < 64); return; } @@ -536,6 +537,8 @@ newEntry.SetNextHop (ourAddress); /// Get the previous node's maintenance buffer and passive ack Ptr node = GetNodeWithAddress (previousHop); + NS_LOG_DEBUG ("The previous node " << previousHop); + Ptr dsr = node->GetObject (); dsr->CancelLinkPacketTimer (newEntry); } @@ -842,151 +845,6 @@ } } -void DsrRouting::SendRerrWhenBreaksLinkToNextHop (Ipv4Address nextHop, uint8_t protocol) -{ - NS_LOG_FUNCTION (this << nextHop << (uint32_t)protocol); - MaintainBuffEntry entry; - // Find the packet in send buffer - if (m_maintainBuffer.Find (nextHop)) - { - NS_LOG_DEBUG ("Trying to dequeue"); - - if (m_maintainBuffer.Dequeue (nextHop, entry)) - { - NS_LOG_DEBUG ("creating new packet"); - /* - * Copy the packet and save a copy to the send buffer. - * if only queue the original packet to the buffer, - * when dequeue the packet, it turns to be empty. - */ - Ptr dequeP = ConstCast (entry.GetPacket ()); - Ptr newPacket = dequeP->Copy (); - Ptr p = dequeP->Copy (); - - Ipv4Address source = entry.GetSrc (); - Ipv4Address destination = entry.GetDst (); - - DsrRoutingHeader dsrRoutingHeader; - p->RemoveHeader (dsrRoutingHeader); - Ptr cleanP = p->Copy (); - uint8_t offset = dsrRoutingHeader.GetDsrOptionsOffset (); - newPacket->RemoveAtStart (offset); - - // Get the number of routers' address field - uint8_t buf[2]; - newPacket->CopyData (buf, sizeof(buf)); - uint8_t numberAddress = (buf[1] - 2) / 4; - - DsrOptionSRHeader sourceRoute; - sourceRoute.SetNumberAddress (numberAddress); - newPacket->RemoveHeader (sourceRoute); - uint8_t salvage = sourceRoute.GetSalvage (); - - DsrOptionAckReqHeader ackReq; - newPacket->RemoveHeader (ackReq); - /* - * Get the node list address - */ - std::vector nodeList = sourceRoute.GetNodesAddress (); - Ipv4Address address1 = nodeList[1]; - Ipv4Address nextHop = SearchNextHop (m_mainAddress, nodeList); - NS_LOG_DEBUG ("The next hop address" << nextHop); - if (nextHop == "0.0.0.0") - { - PacketNewRoute (cleanP, m_mainAddress, destination, protocol); - return; - } - RouteCacheEntry salvageRoute; - bool findRoute = m_routeCache->LookupRoute (destination, salvageRoute); - // Check the salvage value in header, if salvage is needed, we should find alternative route - if (findRoute && (salvage < m_maxSalvageCount)) - { - // Need to salvage the packet instead of discard it - std::vector nodeList = salvageRoute.GetVector (); - DsrOptionSRHeader newSR; - newSR.SetNodesAddress (nodeList); - newSR.SetSegmentsLeft ((nodeList.size () - 2)); - newSR.SetSalvage (salvage + 1); - /// When found a route and use it, UseExtends to the link cache - if (m_routeCache->IsLinkCache ()) - { - m_routeCache->UseExtends (nodeList); - } - NetworkKey networkKey; - networkKey.m_ackId = entry.GetAckId (); - networkKey.m_ourAdd = entry.GetOurAdd (); - networkKey.m_nextHop = entry.GetNextHop (); - networkKey.m_source = entry.GetSrc (); - networkKey.m_destination = entry.GetDst (); - - PassiveKey passiveKey; - passiveKey.m_ackId = 0; - passiveKey.m_source = entry.GetSrc (); - passiveKey.m_destination = entry.GetDst (); - passiveKey.m_segsLeft = entry.GetSegsLeft (); - - LinkKey linkKey; - linkKey.m_source = entry.GetSrc (); - linkKey.m_destination = entry.GetDst (); - linkKey.m_ourAdd = entry.GetOurAdd (); - linkKey.m_nextHop = entry.GetNextHop (); - - m_addressForwardCnt[networkKey] = 0; - m_passiveCnt[passiveKey] = 0; - m_linkCnt[linkKey] = 0; - - if (m_linkAck) - { - ScheduleLinkPacketRetry (entry, protocol); - } - else - { - NS_LOG_LOGIC ("Not using link acknowledgment"); - if (nextHop != destination) - { - SchedulePassivePacketRetry (entry, protocol); - } - else - { - // This is the first network retry - ScheduleNetworkPacketRetry (entry, true, protocol); - } - } - } - else - { - /* - * This code block create a packet and attach a route error option to it - */ - m_routeCache->DeleteAllRoutesIncludeLink (source, nextHop, m_mainAddress); - /* - * If the salvage is not 0, use the first address in the route as the error dst in error header - * otherwise use the source of packet as the error destination - */ - Ipv4Address errorDst; - if (salvage) - { - errorDst = address1; - } - else - { - errorDst = source; - } - SendUnreachError (nextHop, errorDst, destination, salvage, protocol); - /* - * here we cancel the packet retransmission time for all the packets have next hop address - * as nextHop - */ - } - if (m_maintainBuffer.GetSize () != 0 && m_maintainBuffer.Find (nextHop)) - { - Simulator::Schedule (MilliSeconds (m_uniformRandomVariable->GetInteger (0,100)), - &DsrRouting::SendRerrWhenBreaksLinkToNextHop,this,nextHop,protocol); - } - } - } -} - void DsrRouting::SendBuffTimerExpire () { if (m_sendBuffTimer.IsRunning ()) @@ -1093,19 +951,19 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_LOGIC ("Will be inserting into priority queue number: " << priority); - m_downTarget (newPacket, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); + //m_downTarget (newPacket, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (newPacket, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); -// -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (newPacket, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); + + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } } else @@ -1389,9 +1247,9 @@ } void -DsrRouting::SendUnreachError (Ipv4Address errorHop, Ipv4Address destination, Ipv4Address originalDst, uint8_t salvage, uint8_t protocol) +DsrRouting::SendUnreachError (Ipv4Address unreachNode, Ipv4Address destination, Ipv4Address originalDst, uint8_t salvage, uint8_t protocol) { - NS_LOG_FUNCTION (this << errorHop << destination << originalDst << (uint32_t)salvage << (uint32_t)protocol); + NS_LOG_FUNCTION (this << unreachNode << destination << originalDst << (uint32_t)salvage << (uint32_t)protocol); DsrRoutingHeader dsrRoutingHeader; dsrRoutingHeader.SetNextHeader (protocol); dsrRoutingHeader.SetMessageType (1); @@ -1401,42 +1259,52 @@ DsrOptionRerrUnreachHeader rerrUnreachHeader; rerrUnreachHeader.SetErrorType (1); rerrUnreachHeader.SetErrorSrc (m_mainAddress); - rerrUnreachHeader.SetUnreachNode (errorHop); + rerrUnreachHeader.SetUnreachNode (unreachNode); rerrUnreachHeader.SetErrorDst (destination); rerrUnreachHeader.SetOriginalDst (originalDst); rerrUnreachHeader.SetSalvage (salvage); // Set the value about whether to salvage a packet or not uint8_t rerrLength = rerrUnreachHeader.GetLength (); + RouteCacheEntry toDst; bool findRoute = m_routeCache->LookupRoute (destination, toDst); // Queue the packet if there is no route pre-existing Ptr newPacket = Create (); if (!findRoute) { - NS_LOG_INFO (Simulator::Now ().GetSeconds () - << "s " << m_mainAddress << " there is no route for this packet, queue the packet"); - - dsrRoutingHeader.SetPayloadLength (rerrLength + 2); - dsrRoutingHeader.AddDsrOption (rerrUnreachHeader); - newPacket->AddHeader (dsrRoutingHeader); - Ptr p = newPacket->Copy (); - // Save the error packet in the error buffer - ErrorBuffEntry newEntry (p, destination, m_mainAddress, errorHop, m_sendBufferTimeout, protocol); - bool result = m_errorBuffer.Enqueue (newEntry); // Enqueue the packet in send buffer - if (result) - { - NS_LOG_INFO (Simulator::Now ().GetSeconds () - << "s Add packet PID: " << p->GetUid () << " to queue. Packet: " << *p); - NS_LOG_LOGIC ("Send RREQ to" << destination); - if ((m_addressReqTimer.find (destination) == m_addressReqTimer.end ()) && (m_nonPropReqTimer.find (destination) == m_nonPropReqTimer.end ())) - { - NS_LOG_DEBUG ("When there is no existing route request for " << destination << ", initialize one"); - /* - * Call the send request function, it will update the request table entry and ttl there - */ - SendInitialRequest (m_mainAddress, destination, protocol); - } - } + if (destination == m_mainAddress) + { + NS_LOG_INFO ("We are the error source, send request to original dst " << originalDst); + // Send error request message if we are the source node + SendErrorRequest (rerrUnreachHeader, protocol); + } + else + { + NS_LOG_INFO (Simulator::Now ().GetSeconds () + << "s " << m_mainAddress << " there is no route for this packet, queue the packet"); + + dsrRoutingHeader.SetPayloadLength (rerrLength + 2); + dsrRoutingHeader.AddDsrOption (rerrUnreachHeader); + newPacket->AddHeader (dsrRoutingHeader); + Ptr p = newPacket->Copy (); + // Save the error packet in the error buffer + ErrorBuffEntry newEntry (p, destination, m_mainAddress, unreachNode, m_sendBufferTimeout, protocol); + bool result = m_errorBuffer.Enqueue (newEntry); // Enqueue the packet in send buffer + if (result) + { + NS_LOG_INFO (Simulator::Now ().GetSeconds () + << "s Add packet PID: " << p->GetUid () << " to queue. Packet: " << *p); + NS_LOG_LOGIC ("Send RREQ to" << destination); + if ((m_addressReqTimer.find (destination) == m_addressReqTimer.end ()) && (m_nonPropReqTimer.find (destination) == m_nonPropReqTimer.end ())) + { + NS_LOG_DEBUG ("When there is no existing route request for " << destination << ", initialize one"); + /* + * Call the send request function, it will update the request table entry and ttl there + */ + SendInitialRequest (m_mainAddress, destination, protocol); + } + } + } } else { @@ -1474,19 +1342,19 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_DEBUG ("Will be inserting into priority queue " << dsrNetworkQueue << " number: " << priority); - m_downTarget (newPacket, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); + //m_downTarget (newPacket, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (newPacket, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); -// -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (newPacket, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); + + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } } @@ -1519,19 +1387,19 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_DEBUG ("Will be inserting into priority queue " << dsrNetworkQueue << " number: " << priority); - m_downTarget (packet, m_mainAddress, nextHop, GetProtocolNumber (), route); + //m_downTarget (packet, m_mainAddress, nextHop, GetProtocolNumber (), route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (packet, m_mainAddress, nextHop, Simulator::Now (), route); -// -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (packet, m_mainAddress, nextHop, Simulator::Now (), route); + + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } void @@ -1731,19 +1599,19 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_INFO ("Will be inserting into priority queue number: " << priority); - m_downTarget (packet, source, nextHop, GetProtocolNumber (), m_ipv4Route); + //m_downTarget (packet, source, nextHop, GetProtocolNumber (), m_ipv4Route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (packet, source, nextHop, Simulator::Now (), m_ipv4Route); -// -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (packet, source, nextHop, Simulator::Now (), m_ipv4Route); + + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } void @@ -1879,6 +1747,12 @@ if (m_sendBuffer.Find (destination)) { NS_LOG_DEBUG ("destination over here " << destination); + + /// When found a route and use it, UseExtends to the link cache + if (m_routeCache->IsLinkCache ()) + { + m_routeCache->UseExtends (nodeList); + } SendBuffEntry entry; if (m_sendBuffer.Dequeue (destination, entry)) { @@ -2037,19 +1911,19 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_DEBUG ("Will be inserting into priority queue " << dsrNetworkQueue << " number: " << priority); - m_downTarget (newPacket, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); + //m_downTarget (newPacket, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (newPacket, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); -// -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (newPacket, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); + + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } } @@ -2138,6 +2012,32 @@ } void +DsrRouting::CallCancelPacketTimer (uint16_t ackId, Ipv4Header const& ipv4Header, Ipv4Address realSrc, Ipv4Address realDst) +{ + NS_LOG_FUNCTION (this << (uint32_t)ackId << ipv4Header << realSrc << realDst); + Ipv4Address sender = ipv4Header.GetDestination (); + Ipv4Address receiver = ipv4Header.GetSource (); + /* + * Create a packet to fill maintenance buffer, not used to compare with maintainance entry + * The reason is ack header doesn't have the original packet copy + */ + Ptr mainP = Create (); + MaintainBuffEntry newEntry (/*Packet=*/ mainP, /*ourAddress=*/ sender, /*nextHop=*/ receiver, + /*source=*/ realSrc, /*destination=*/ realDst, /*ackId=*/ ackId, + /*SegsLeft=*/ 0, /*expire time=*/ Simulator::Now ()); + CancelNetworkPacketTimer (newEntry); // Only need to cancel network packet timer +} + +void +DsrRouting::CancelPacketAllTimer (MaintainBuffEntry & mb) +{ + NS_LOG_FUNCTION (this); + CancelLinkPacketTimer (mb); + CancelNetworkPacketTimer (mb); + CancelPassivePacketTimer (mb); +} + +void DsrRouting::CancelLinkPacketTimer (MaintainBuffEntry & mb) { NS_LOG_FUNCTION (this); @@ -2149,15 +2049,15 @@ /* * Here we have found the entry for send retries, so we get the value and increase it by one */ + /// TODO need to think about this part m_linkCnt[linkKey] = 0; m_linkCnt.erase (linkKey); - NS_LOG_INFO ("ourAdd " << mb.GetOurAdd () << " nextHop " << mb.GetNextHop () - << " source " << mb.GetSrc () << " destination " << mb.GetDst () - ); - // Find the link acknowledgment timer + // TODO if find the linkkey, we need to remove it + + // Find the network acknowledgment timer std::map::const_iterator i = - m_linkAckTimer.find (linkKey); + m_linkAckTimer.find (linkKey); if (i == m_linkAckTimer.end ()) { NS_LOG_INFO ("did not find the link timer"); @@ -2177,6 +2077,7 @@ } m_linkAckTimer.erase (linkKey); } + // Erase the maintenance entry // yet this does not check the segments left value here NS_LOG_DEBUG ("The link buffer size " << m_maintainBuffer.GetSize()); @@ -2187,23 +2088,6 @@ } void -DsrRouting::CallCancelPacketTimer (uint16_t ackId, Ipv4Header const& ipv4Header, Ipv4Address realSrc, Ipv4Address realDst) -{ - NS_LOG_FUNCTION (this << (uint32_t)ackId << ipv4Header << realSrc << realDst); - Ipv4Address sender = ipv4Header.GetDestination (); - Ipv4Address receiver = ipv4Header.GetSource (); - /* - * Create a packet to fill maintenance buffer, not used to compare with maintainance entry - * The reason is ack header doesn't have the original packet copy - */ - Ptr mainP = Create (); - MaintainBuffEntry newEntry (/*Packet=*/ mainP, /*ourAddress=*/ sender, /*nextHop=*/ receiver, - /*source=*/ realSrc, /*destination=*/ realDst, /*ackId=*/ ackId, - /*SegsLeft=*/ 0, /*expire time=*/ Simulator::Now ()); - CancelNetworkPacketTimer (newEntry); -} - -void DsrRouting::CancelNetworkPacketTimer (MaintainBuffEntry & mb) { NS_LOG_FUNCTION (this); @@ -2293,16 +2177,61 @@ DsrRouting::CancelPacketTimerNextHop (Ipv4Address nextHop, uint8_t protocol) { NS_LOG_FUNCTION (this << nextHop << (uint32_t)protocol); + MaintainBuffEntry entry; + std::vector previousErrorDst; if (m_maintainBuffer.Dequeue (nextHop, entry)) { - Ptr packet = entry.GetPacket ()->Copy (); Ipv4Address source = entry.GetSrc (); Ipv4Address destination = entry.GetDst (); + + Ptr dsrP = entry.GetPacket ()->Copy (); + Ptr p = dsrP->Copy (); + Ptr packet = dsrP->Copy (); + DsrRoutingHeader dsrRoutingHeader; + dsrP->RemoveHeader (dsrRoutingHeader); // Remove the dsr header in whole + uint32_t offset = dsrRoutingHeader.GetDsrOptionsOffset (); + p->RemoveAtStart (offset); + + // Get the number of routers' address field + uint8_t buf[2]; + p->CopyData (buf, sizeof(buf)); + uint8_t numberAddress = (buf[1] - 2) / 4; + NS_LOG_DEBUG ("The number of addresses " << (uint32_t)numberAddress); + DsrOptionSRHeader sourceRoute; + sourceRoute.SetNumberAddress (numberAddress); + p->RemoveHeader (sourceRoute); + std::vector nodeList = sourceRoute.GetNodesAddress (); + uint8_t salvage = sourceRoute.GetSalvage (); + Ipv4Address address1 = nodeList[1]; + PrintVector (nodeList); + + /* + * If the salvage is not 0, use the first address in the route as the error dst in error header + * otherwise use the source of packet as the error destination + */ + Ipv4Address errorDst; + if (salvage) + { + errorDst = address1; + } + else + { + errorDst = source; + } + /// TODO if the errorDst is not seen before + if (std::find(previousErrorDst.begin(), previousErrorDst.end(), destination)==previousErrorDst.end()) + { + NS_LOG_DEBUG ("have not seen this dst before " << errorDst << " in " << previousErrorDst.size()); + SendUnreachError (nextHop, errorDst, destination, salvage, protocol); + previousErrorDst.push_back(errorDst); + } + /* * Cancel the packet timer and then salvage the data packet */ - CancelNetworkPacketTimer (entry); + + CancelPacketAllTimer (entry); SalvagePacket (packet, source, destination, protocol); if (m_maintainBuffer.GetSize () && m_maintainBuffer.Find (nextHop)) @@ -2316,6 +2245,7 @@ { NS_LOG_INFO ("Maintenance buffer entry not found"); } + /// TODO need to think about whether we need the network queue entry or not } void @@ -2389,19 +2319,19 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_DEBUG ("Will be inserting into priority queue " << dsrNetworkQueue << " number: " << priority); - m_downTarget (p, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); + //m_downTarget (p, m_mainAddress, nextHop, GetProtocolNumber (), m_ipv4Route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (p, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); -// -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (p, m_mainAddress, nextHop, Simulator::Now (), m_ipv4Route); + + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } /* * Mark the next hop address in blacklist @@ -2590,7 +2520,6 @@ { NS_LOG_FUNCTION (this << (uint32_t)protocol); Ipv4Address nextHop = mb.GetNextHop (); - Ipv4Address source = mb.GetSrc (); Ptr packet = mb.GetPacket (); SetRoute (nextHop, m_mainAddress); Ptr p = packet->Copy (); @@ -2619,46 +2548,14 @@ } else { - NS_LOG_DEBUG ("We may need to send error messages now"); - Ptr dsrP = mb.GetPacket ()->Copy (); - // The packet retries time has exceed the max maintenance retransmission times - DsrRoutingHeader dsrRoutingHeader; - dsrP->RemoveHeader (dsrRoutingHeader); // Remove the dsr header in whole - uint32_t offset = dsrRoutingHeader.GetDsrOptionsOffset (); - p->RemoveAtStart (offset); - - // Get the number of routers' address field - uint8_t buf[2]; - p->CopyData (buf, sizeof(buf)); - uint8_t numberAddress = (buf[1] - 2) / 4; - NS_LOG_DEBUG ("The number of addresses " << (uint32_t)numberAddress); - DsrOptionSRHeader sourceRoute; - sourceRoute.SetNumberAddress (numberAddress); - p->RemoveHeader (sourceRoute); - std::vector nodeList = sourceRoute.GetNodesAddress (); - uint8_t salvage = sourceRoute.GetSalvage (); - Ipv4Address address1 = nodeList[1]; - PrintVector (nodeList); + NS_LOG_INFO ("We need to send error messages now"); // Delete all the routes including the links m_routeCache->DeleteAllRoutesIncludeLink (m_mainAddress, nextHop, m_mainAddress); /* - * If the salvage is not 0, use the first address in the route as the error dst in error header - * otherwise use the source of packet as the error destination - */ - Ipv4Address errorDst; - if (salvage) - { - errorDst = address1; - } - else - { - errorDst = source; - } - SendUnreachError (nextHop, errorDst, mb.GetDst (), salvage, protocol); - /* * here we cancel the packet retransmission time for all the packets have next hop address as nextHop * Also salvage the packet for the all the packet destined for the nextHop address + * this is also responsible for send unreachable error back to source */ CancelPacketTimerNextHop (nextHop, protocol); } @@ -2734,44 +2631,9 @@ if (m_sendRetries >= m_maxMaintRexmt) { - Ptr dsrP = mb.GetPacket ()->Copy (); - // The packet retries time has exceed the max maintenance retransmission times - NS_LOG_LOGIC ("Packet transmissions to " << nextHop << " has been attempted SendRetries times for " << networkKey.m_ackId); - DsrRoutingHeader dsrRoutingHeader; - dsrP->RemoveHeader (dsrRoutingHeader); // Remove the dsr header in whole - uint32_t offset = dsrRoutingHeader.GetDsrOptionsOffset (); - p->RemoveAtStart (offset); - - // Get the number of routers' address field - uint8_t buf[2]; - p->CopyData (buf, sizeof(buf)); - uint8_t numberAddress = (buf[1] - 2) / 4; - NS_LOG_DEBUG ("The number of addresses " << (uint32_t)numberAddress); - DsrOptionSRHeader sourceRoute; - sourceRoute.SetNumberAddress (numberAddress); - p->RemoveHeader (sourceRoute); - std::vector nodeList = sourceRoute.GetNodesAddress (); - uint8_t salvage = sourceRoute.GetSalvage (); - Ipv4Address address1 = nodeList[1]; - PrintVector (nodeList); - // Delete all the routes including the links m_routeCache->DeleteAllRoutesIncludeLink (m_mainAddress, nextHop, m_mainAddress); /* - * If the salvage is not 0, use the first address in the route as the error dst in error header - * otherwise use the source of packet as the error destination - */ - Ipv4Address errorDst; - if (salvage) - { - errorDst = address1; - } - else - { - errorDst = source; - } - SendUnreachError (nextHop, errorDst, dst, salvage, protocol); - /* * here we cancel the packet retransmission time for all the packets have next hop address as nextHop * Also salvage the packet for the all the packet destined for the nextHop address */ @@ -3226,18 +3088,18 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_LOGIC ("Inserting into priority queue number: " << priority); - m_downTarget (packet, source, m_broadcast, GetProtocolNumber (), 0); + //m_downTarget (packet, source, m_broadcast, GetProtocolNumber (), 0); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (packet, source, m_broadcast, Simulator::Now (), 0); -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (packet, source, m_broadcast, Simulator::Now (), 0); + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } void @@ -3332,18 +3194,18 @@ Ptr dsrNetworkQueue = i->second; NS_LOG_INFO ("Inserting into priority queue number: " << priority); - m_downTarget (packet, source, nextHop, GetProtocolNumber (), route); + //m_downTarget (packet, source, nextHop, GetProtocolNumber (), route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (packet, source, nextHop, Simulator::Now (), route); -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (packet, source, nextHop, Simulator::Now (), route); + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } void @@ -3409,18 +3271,18 @@ NS_LOG_LOGIC ("Will be inserting into priority queue " << dsrNetworkQueue << " number: " << priority); - m_downTarget (packet, m_mainAddress, destination, GetProtocolNumber (), route); + //m_downTarget (packet, m_mainAddress, destination, GetProtocolNumber (), route); /// \todo New DsrNetworkQueueEntry -// DsrNetworkQueueEntry newEntry (packet, m_mainAddress, destination, Simulator::Now (), route); -// if (dsrNetworkQueue->Enqueue (newEntry)) -// { -// Scheduler (priority); -// } -// else -// { -// NS_LOG_INFO ("Packet dropped as dsr network queue is full"); -// } + DsrNetworkQueueEntry newEntry (packet, m_mainAddress, destination, Simulator::Now (), route); + if (dsrNetworkQueue->Enqueue (newEntry)) + { + Scheduler (priority); + } + else + { + NS_LOG_INFO ("Packet dropped as dsr network queue is full"); + } } enum IpL4Protocol::RxStatus diff -Naur ns-3.19/src/dsr/model/dsr-routing.h ns-3.20/src/dsr/model/dsr-routing.h --- ns-3.19/src/dsr/model/dsr-routing.h 2014-06-17 10:34:00.350637341 -0700 +++ ns-3.20/src/dsr/model/dsr-routing.h 2014-06-17 10:33:13.682997590 -0700 @@ -254,8 +254,7 @@ /** * \brief This function is responsible for sending error packets in case of break link to next hop */ - void SendUnreachError (Ipv4Address errorHop, Ipv4Address destination, Ipv4Address originalDst, uint8_t salvage, uint8_t protocol); - /** + void SendUnreachError (Ipv4Address unreachNode, Ipv4Address destination, Ipv4Address originalDst, uint8_t salvage, uint8_t protocol); /** * \brief This function is responsible for forwarding error packets along the route */ void ForwardErrPacket (DsrOptionRerrUnreachHeader &rerr, @@ -304,6 +303,11 @@ */ bool PassiveEntryCheck (Ptr packet, Ipv4Address source, Ipv4Address destination, uint8_t segsLeft, uint16_t fragmentOffset, uint16_t identification, bool saveEntry); + + /** + * \brief Cancel all the packet timers + */ + void CancelPacketAllTimer (MaintainBuffEntry & mb); /** * \brief Cancel the passive timer */ @@ -752,6 +756,8 @@ GraReply m_graReply; ///< The gratuitous route reply. + DsrNetworkQueue m_networkQueue; ///< The network queue. + std::vector m_clearList; ///< The node that is clear to send packet to std::vector m_addresses; ///< The bind ipv4 addresses with next hop, src, destination address in sequence diff -Naur ns-3.19/src/dsr/model/dsr-rreq-table.cc ns-3.20/src/dsr/model/dsr-rreq-table.cc --- ns-3.19/src/dsr/model/dsr-rreq-table.cc 2014-06-17 10:34:00.351637333 -0700 +++ ns-3.20/src/dsr/model/dsr-rreq-table.cc 2014-06-17 10:33:13.683997582 -0700 @@ -39,8 +39,7 @@ namespace ns3 { namespace dsr { -NS_OBJECT_ENSURE_REGISTERED (RreqTable) - ; +NS_OBJECT_ENSURE_REGISTERED (RreqTable); TypeId RreqTable::GetTypeId () { diff -Naur ns-3.19/src/dsr/model/dsr-rsendbuff.cc ns-3.20/src/dsr/model/dsr-rsendbuff.cc --- ns-3.19/src/dsr/model/dsr-rsendbuff.cc 2014-06-17 10:34:00.352637325 -0700 +++ ns-3.20/src/dsr/model/dsr-rsendbuff.cc 2014-06-17 10:33:13.684997575 -0700 @@ -111,7 +111,7 @@ if (i->GetDestination () == dst) { entry = *i; - m_sendBuffer.erase (i); + i = m_sendBuffer.erase (i); NS_LOG_DEBUG ("Packet size while dequeuing " << entry.GetPacket ()->GetSize ()); return true; } diff -Naur ns-3.19/src/dsr/test/dsr-test-suite.cc ns-3.20/src/dsr/test/dsr-test-suite.cc --- ns-3.19/src/dsr/test/dsr-test-suite.cc 2014-06-17 10:34:00.353637318 -0700 +++ ns-3.20/src/dsr/test/dsr-test-suite.cc 2014-06-17 10:33:13.685997567 -0700 @@ -49,8 +49,8 @@ #include "ns3/dsr-main-helper.h" #include "ns3/dsr-helper.h" -namespace ns3 { -namespace dsr { +using namespace ns3; +using namespace dsr; // ----------------------------------------------------------------------------- // / Unit test for DSR Fixed Size Header @@ -519,5 +519,3 @@ AddTestCase (new DsrSendBuffTest, TestCase::QUICK); } } g_dsrTestSuite; -} // namespace dsr -} // namespace ns3 diff -Naur ns-3.19/src/emu/bindings/modulegen__gcc_ILP32.py ns-3.20/src/emu/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/emu/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.356637295 -0700 +++ ns-3.20/src/emu/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.689997536 -0700 @@ -105,7 +105,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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 [class] @@ -118,6 +118,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -130,6 +132,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## emu-helper.h (module 'emu'): ns3::EmuHelper [class] @@ -268,12 +272,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -336,6 +340,7 @@ 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_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -766,6 +771,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -778,6 +787,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2362,6 +2375,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2559,62 +2580,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2623,6 +2600,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2663,6 +2642,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3060,13 +3041,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3093,6 +3076,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4225,10 +4213,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TimeValue_methods(root_module, cls): diff -Naur ns-3.19/src/emu/bindings/modulegen__gcc_LP64.py ns-3.20/src/emu/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/emu/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.359637271 -0700 +++ ns-3.20/src/emu/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.692997513 -0700 @@ -105,7 +105,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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 [class] @@ -118,6 +118,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -130,6 +132,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## emu-helper.h (module 'emu'): ns3::EmuHelper [class] @@ -268,12 +272,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -336,6 +340,7 @@ 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_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -766,6 +771,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -778,6 +787,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2362,6 +2375,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2559,62 +2580,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2623,6 +2600,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2663,6 +2642,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3060,13 +3041,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3093,6 +3076,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4225,10 +4213,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TimeValue_methods(root_module, cls): diff -Naur ns-3.19/src/emu/examples/waf ns-3.20/src/emu/examples/waf --- ns-3.19/src/emu/examples/waf 2014-06-17 10:34:00.376637141 -0700 +++ ns-3.20/src/emu/examples/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/src/emu/model/emu-net-device.cc ns-3.20/src/emu/model/emu-net-device.cc --- ns-3.19/src/emu/model/emu-net-device.cc 2014-06-17 10:34:00.378637125 -0700 +++ ns-3.20/src/emu/model/emu-net-device.cc 2014-06-17 10:33:13.696997482 -0700 @@ -55,8 +55,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (EmuNetDevice) - ; +NS_OBJECT_ENSURE_REGISTERED (EmuNetDevice); #define EMU_MAGIC 65867 diff -Naur ns-3.19/src/emu/waf ns-3.20/src/emu/waf --- ns-3.19/src/emu/waf 2014-06-17 10:34:00.380637109 -0700 +++ ns-3.20/src/emu/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../../waf "$@" diff -Naur ns-3.19/src/energy/bindings/modulegen__gcc_ILP32.py ns-3.20/src/energy/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/energy/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.384637079 -0700 +++ ns-3.20/src/energy/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.702997436 -0700 @@ -110,6 +110,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## traced-value.h (module 'core'): ns3::TracedValue [class] module.add_class('TracedValue', import_from_module='ns.core', template_parameters=['double']) ## type-id.h (module 'core'): ns3::TypeId [class] @@ -136,6 +138,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## basic-energy-source-helper.h (module 'energy'): ns3::BasicEnergySourceHelper [class] module.add_class('BasicEnergySourceHelper', parent=root_module['ns3::EnergySourceHelper']) ## chunk.h (module 'network'): ns3::Chunk [class] @@ -272,19 +276,19 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## basic-energy-source.h (module 'energy'): ns3::BasicEnergySource [class] module.add_class('BasicEnergySource', parent=root_module['ns3::EnergySource']) - module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type='vector') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >', 'ns3::WifiMcsList') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >*', 'ns3::WifiMcsList*') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >&', 'ns3::WifiMcsList&') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', 'ns3::WifiModeList') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', 'ns3::WifiModeList*') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', 'ns3::WifiModeList&') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', 'ns3::WifiModeListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', 'ns3::WifiModeListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', 'ns3::WifiModeListIterator&') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', 'ns3::WifiMcsListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', 'ns3::WifiMcsListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', 'ns3::WifiMcsListIterator&') + module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type=u'vector') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >', u'ns3::WifiMcsList') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >*', u'ns3::WifiMcsList*') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >&', u'ns3::WifiMcsList&') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', u'ns3::WifiModeList') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', u'ns3::WifiModeList*') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', u'ns3::WifiModeList&') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', u'ns3::WifiModeListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', u'ns3::WifiModeListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', u'ns3::WifiModeListIterator&') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', u'ns3::WifiMcsListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', u'ns3::WifiMcsListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', u'ns3::WifiMcsListIterator&') ## Register a nested module for the namespace FatalImpl @@ -313,12 +317,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -379,6 +383,7 @@ register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3TracedValue__Double_methods(root_module, root_module['ns3::TracedValue< double >']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) register_Ns3TypeIdAttributeInformation_methods(root_module, root_module['ns3::TypeId::AttributeInformation']) @@ -706,6 +711,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -718,6 +727,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2087,6 +2100,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TracedValue__Double_methods(root_module, cls): ## traced-value.h (module 'core'): ns3::TracedValue::TracedValue() [constructor] cls.add_constructor([]) @@ -2556,62 +2577,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2620,6 +2597,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2660,6 +2639,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3BasicEnergySourceHelper_methods(root_module, cls): @@ -2909,13 +2890,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2942,6 +2925,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -3713,6 +3701,11 @@ 'ns3::TypeId', [], is_static=True) + ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsModeSupported(ns3::WifiMode mode) const [member function] + cls.add_method('IsModeSupported', + 'bool', + [param('ns3::WifiMode', 'mode')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsStateBusy() [member function] cls.add_method('IsStateBusy', 'bool', @@ -5121,10 +5114,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3RvBatteryModel_methods(root_module, cls): diff -Naur ns-3.19/src/energy/bindings/modulegen__gcc_LP64.py ns-3.20/src/energy/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/energy/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.387637055 -0700 +++ ns-3.20/src/energy/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.705997412 -0700 @@ -110,6 +110,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## traced-value.h (module 'core'): ns3::TracedValue [class] module.add_class('TracedValue', import_from_module='ns.core', template_parameters=['double']) ## type-id.h (module 'core'): ns3::TypeId [class] @@ -136,6 +138,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## basic-energy-source-helper.h (module 'energy'): ns3::BasicEnergySourceHelper [class] module.add_class('BasicEnergySourceHelper', parent=root_module['ns3::EnergySourceHelper']) ## chunk.h (module 'network'): ns3::Chunk [class] @@ -272,19 +276,19 @@ module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## basic-energy-source.h (module 'energy'): ns3::BasicEnergySource [class] module.add_class('BasicEnergySource', parent=root_module['ns3::EnergySource']) - module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type='vector') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >', 'ns3::WifiMcsList') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >*', 'ns3::WifiMcsList*') - typehandlers.add_type_alias('std::vector< unsigned char, std::allocator< unsigned char > >&', 'ns3::WifiMcsList&') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', 'ns3::WifiModeList') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', 'ns3::WifiModeList*') - typehandlers.add_type_alias('std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', 'ns3::WifiModeList&') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', 'ns3::WifiModeListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', 'ns3::WifiModeListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', 'ns3::WifiModeListIterator&') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', 'ns3::WifiMcsListIterator') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', 'ns3::WifiMcsListIterator*') - typehandlers.add_type_alias('__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', 'ns3::WifiMcsListIterator&') + module.add_container('ns3::WifiModeList', 'ns3::WifiMode', container_type=u'vector') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >', u'ns3::WifiMcsList') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >*', u'ns3::WifiMcsList*') + typehandlers.add_type_alias(u'std::vector< unsigned char, std::allocator< unsigned char > >&', u'ns3::WifiMcsList&') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >', u'ns3::WifiModeList') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >*', u'ns3::WifiModeList*') + typehandlers.add_type_alias(u'std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > >&', u'ns3::WifiModeList&') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >', u'ns3::WifiModeListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >*', u'ns3::WifiModeListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< ns3::WifiMode const *, std::vector< ns3::WifiMode, std::allocator< ns3::WifiMode > > >&', u'ns3::WifiModeListIterator&') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >', u'ns3::WifiMcsListIterator') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >*', u'ns3::WifiMcsListIterator*') + typehandlers.add_type_alias(u'__gnu_cxx::__normal_iterator< unsigned char const *, std::vector< unsigned char, std::allocator< unsigned char > > >&', u'ns3::WifiMcsListIterator&') ## Register a nested module for the namespace FatalImpl @@ -313,12 +317,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -379,6 +383,7 @@ register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3TracedValue__Double_methods(root_module, root_module['ns3::TracedValue< double >']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) register_Ns3TypeIdAttributeInformation_methods(root_module, root_module['ns3::TypeId::AttributeInformation']) @@ -706,6 +711,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -718,6 +727,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2087,6 +2100,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TracedValue__Double_methods(root_module, cls): ## traced-value.h (module 'core'): ns3::TracedValue::TracedValue() [constructor] cls.add_constructor([]) @@ -2556,62 +2577,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2620,6 +2597,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2660,6 +2639,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3BasicEnergySourceHelper_methods(root_module, cls): @@ -2909,13 +2890,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2942,6 +2925,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -3713,6 +3701,11 @@ 'ns3::TypeId', [], is_static=True) + ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsModeSupported(ns3::WifiMode mode) const [member function] + cls.add_method('IsModeSupported', + 'bool', + [param('ns3::WifiMode', 'mode')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## wifi-phy.h (module 'wifi'): bool ns3::WifiPhy::IsStateBusy() [member function] cls.add_method('IsStateBusy', 'bool', @@ -5121,10 +5114,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3RvBatteryModel_methods(root_module, cls): diff -Naur ns-3.19/src/energy/helper/basic-energy-source-helper.cc ns-3.20/src/energy/helper/basic-energy-source-helper.cc --- ns-3.19/src/energy/helper/basic-energy-source-helper.cc 2014-06-17 10:34:00.389637040 -0700 +++ ns-3.20/src/energy/helper/basic-energy-source-helper.cc 2014-06-17 10:33:13.707997397 -0700 @@ -42,13 +42,7 @@ BasicEnergySourceHelper::DoInstall (Ptr node) const { NS_ASSERT (node != NULL); - // check if energy source already exists - Ptr source = node->GetObject (); - if (source != NULL) - { - NS_FATAL_ERROR ("Energy source already installed!"); - } - source = m_basicEnergySource.Create (); + Ptr source = m_basicEnergySource.Create (); NS_ASSERT (source != NULL); source->SetNode (node); return source; diff -Naur ns-3.19/src/energy/helper/energy-model-helper.h ns-3.20/src/energy/helper/energy-model-helper.h --- ns-3.19/src/energy/helper/energy-model-helper.h 2014-06-17 10:34:00.390637032 -0700 +++ ns-3.20/src/energy/helper/energy-model-helper.h 2014-06-17 10:33:13.708997389 -0700 @@ -38,8 +38,8 @@ * \ingroup energy * \brief Creates EnergySource objects. * - * This class creates and installs an energy source onto network nodes. Only a - * single source can exist on a network node. + * This class creates and installs an energy source onto network nodes. + * Multiple sources can exist on a network node. * */ class EnergySourceHelper diff -Naur ns-3.19/src/energy/helper/rv-battery-model-helper.cc ns-3.20/src/energy/helper/rv-battery-model-helper.cc --- ns-3.19/src/energy/helper/rv-battery-model-helper.cc 2014-06-17 10:34:00.391637024 -0700 +++ ns-3.20/src/energy/helper/rv-battery-model-helper.cc 2014-06-17 10:33:13.709997382 -0700 @@ -42,13 +42,7 @@ RvBatteryModelHelper::DoInstall (Ptr node) const { NS_ASSERT (node != NULL); - // check if energy source already exists - Ptr source = node->GetObject (); - if (source != NULL) - { - NS_FATAL_ERROR ("Energy source already installed!"); - } - source = m_rvBatteryModel.Create (); + Ptr source = m_rvBatteryModel.Create (); NS_ASSERT (source != NULL); source->SetNode (node); return source; diff -Naur ns-3.19/src/energy/model/basic-energy-source.cc ns-3.20/src/energy/model/basic-energy-source.cc --- ns-3.19/src/energy/model/basic-energy-source.cc 2014-06-17 10:34:00.392637016 -0700 +++ ns-3.20/src/energy/model/basic-energy-source.cc 2014-06-17 10:33:13.710997374 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (BasicEnergySource) - ; +NS_OBJECT_ENSURE_REGISTERED (BasicEnergySource); TypeId BasicEnergySource::GetTypeId (void) diff -Naur ns-3.19/src/energy/model/device-energy-model.cc ns-3.20/src/energy/model/device-energy-model.cc --- ns-3.19/src/energy/model/device-energy-model.cc 2014-06-17 10:34:00.393637009 -0700 +++ ns-3.20/src/energy/model/device-energy-model.cc 2014-06-17 10:33:13.711997366 -0700 @@ -25,8 +25,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (DeviceEnergyModel) - ; +NS_OBJECT_ENSURE_REGISTERED (DeviceEnergyModel); TypeId DeviceEnergyModel::GetTypeId (void) diff -Naur ns-3.19/src/energy/model/energy-source.cc ns-3.20/src/energy/model/energy-source.cc --- ns-3.19/src/energy/model/energy-source.cc 2014-06-17 10:34:00.394637001 -0700 +++ ns-3.20/src/energy/model/energy-source.cc 2014-06-17 10:33:13.712997359 -0700 @@ -25,8 +25,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (EnergySource) - ; +NS_OBJECT_ENSURE_REGISTERED (EnergySource); TypeId EnergySource::GetTypeId (void) diff -Naur ns-3.19/src/energy/model/li-ion-energy-source.cc ns-3.20/src/energy/model/li-ion-energy-source.cc --- ns-3.19/src/energy/model/li-ion-energy-source.cc 2014-06-17 10:34:00.395636994 -0700 +++ ns-3.20/src/energy/model/li-ion-energy-source.cc 2014-06-17 10:33:13.713997351 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (LiIonEnergySource) - ; +NS_OBJECT_ENSURE_REGISTERED (LiIonEnergySource); TypeId LiIonEnergySource::GetTypeId (void) diff -Naur ns-3.19/src/energy/model/rv-battery-model.cc ns-3.20/src/energy/model/rv-battery-model.cc --- ns-3.19/src/energy/model/rv-battery-model.cc 2014-06-17 10:34:00.396636986 -0700 +++ ns-3.20/src/energy/model/rv-battery-model.cc 2014-06-17 10:33:13.713997351 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (RvBatteryModel) - ; +NS_OBJECT_ENSURE_REGISTERED (RvBatteryModel); TypeId RvBatteryModel::GetTypeId (void) diff -Naur ns-3.19/src/energy/model/simple-device-energy-model.cc ns-3.20/src/energy/model/simple-device-energy-model.cc --- ns-3.19/src/energy/model/simple-device-energy-model.cc 2014-06-17 10:34:00.396636986 -0700 +++ ns-3.20/src/energy/model/simple-device-energy-model.cc 2014-06-17 10:33:13.714997343 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (SimpleDeviceEnergyModel) - ; +NS_OBJECT_ENSURE_REGISTERED (SimpleDeviceEnergyModel); TypeId SimpleDeviceEnergyModel::GetTypeId (void) diff -Naur ns-3.19/src/energy/model/wifi-radio-energy-model.cc ns-3.20/src/energy/model/wifi-radio-energy-model.cc --- ns-3.19/src/energy/model/wifi-radio-energy-model.cc 2014-06-17 10:34:00.397636978 -0700 +++ ns-3.20/src/energy/model/wifi-radio-energy-model.cc 2014-06-17 10:33:13.715997336 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (WifiRadioEnergyModel) - ; +NS_OBJECT_ENSURE_REGISTERED (WifiRadioEnergyModel); TypeId WifiRadioEnergyModel::GetTypeId (void) diff -Naur ns-3.19/src/energy/test/li-ion-energy-source-test.cc ns-3.20/src/energy/test/li-ion-energy-source-test.cc --- ns-3.19/src/energy/test/li-ion-energy-source-test.cc 2014-06-17 10:34:00.398636970 -0700 +++ ns-3.20/src/energy/test/li-ion-energy-source-test.cc 2014-06-17 10:33:13.716997328 -0700 @@ -25,10 +25,9 @@ #include "ns3/node.h" #include "ns3/simulator.h" -namespace ns3 { +using namespace ns3; -NS_LOG_COMPONENT_DEFINE ("LiIonEnergySourceTestSuite") - ; +NS_LOG_COMPONENT_DEFINE ("LiIonEnergySourceTestSuite"); class LiIonEnergyTestCase : public TestCase { @@ -93,5 +92,3 @@ // create an instance of the test suite static LiIonEnergySourceTestSuite g_liIonEnergySourceTestSuite; - -} // namespace ns3 diff -Naur ns-3.19/src/fd-net-device/bindings/modulegen_customizations.py ns-3.20/src/fd-net-device/bindings/modulegen_customizations.py --- ns-3.19/src/fd-net-device/bindings/modulegen_customizations.py 2014-06-17 10:34:00.406636909 -0700 +++ ns-3.20/src/fd-net-device/bindings/modulegen_customizations.py 2014-06-17 10:33:13.724997266 -0700 @@ -5,7 +5,7 @@ if 'EmuFdNetDevice' not in enabled_features: if 'ns3::EmuFdNetDeviceHelper'in root_module: - root_module.classes.remove(root_module['ns3::EmuFdNetDeviceHelper']) + root_module.classes.remove(root_module['ns3::EmuFdNetDeviceHelper']) if 'TapFdNetDevice' not in enabled_features: if 'ns3::TapFdNetDeviceHelper'in root_module: diff -Naur ns-3.19/src/fd-net-device/bindings/modulegen__gcc_ILP32.py ns-3.20/src/fd-net-device/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/fd-net-device/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.402636940 -0700 +++ ns-3.20/src/fd-net-device/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.720997297 -0700 @@ -105,7 +105,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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 [class] @@ -120,6 +120,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -132,6 +134,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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] @@ -280,12 +284,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -349,6 +353,7 @@ 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_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -784,6 +789,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -796,6 +805,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2411,6 +2424,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2608,62 +2629,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2672,6 +2649,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2712,6 +2691,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3122,13 +3103,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3155,6 +3138,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4337,10 +4325,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TapFdNetDeviceHelper_methods(root_module, cls): diff -Naur ns-3.19/src/fd-net-device/bindings/modulegen__gcc_LP64.py ns-3.20/src/fd-net-device/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/fd-net-device/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.405636916 -0700 +++ ns-3.20/src/fd-net-device/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.723997274 -0700 @@ -105,7 +105,7 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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 [class] @@ -120,6 +120,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -132,6 +134,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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] @@ -280,12 +284,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -349,6 +353,7 @@ 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_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -784,6 +789,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -796,6 +805,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -2411,6 +2424,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -2608,62 +2629,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2672,6 +2649,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2712,6 +2691,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3122,13 +3103,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3155,6 +3138,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4337,10 +4325,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TapFdNetDeviceHelper_methods(root_module, cls): diff -Naur ns-3.19/src/fd-net-device/examples/fd-tap-ping.cc ns-3.20/src/fd-net-device/examples/fd-tap-ping.cc --- ns-3.19/src/fd-net-device/examples/fd-tap-ping.cc 2014-06-17 10:34:00.408636893 -0700 +++ ns-3.20/src/fd-net-device/examples/fd-tap-ping.cc 2014-06-17 10:33:13.727997243 -0700 @@ -37,9 +37,9 @@ // | 1.2.3.4 | | // +-------------------------------|-----+ // | -// | -// ------------ (Internet) ----- -// +// | +-------------+ +// ------------ (Internet) ----- | Remote host | +// +-------------+ // // To use this example: // 1) ns-3 will create the TAP device for you in the host machine. @@ -47,15 +47,15 @@ // 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. +// to forward 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. +// Also enable natting so the ICMP replys from the remote host can 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 /24 -j SNAT --to-source +// - TAP-network-mask is the same as 'tapMask' +// # iptables -t nat -A POSTROUTING -s / -j MASQUERADE // // 3) Before running the example make sure that the tap creator binary has root suid. // If the --enable-sudo option was used to configure ns-3 with waf, then the following diff -Naur ns-3.19/src/fd-net-device/examples/waf ns-3.20/src/fd-net-device/examples/waf --- ns-3.19/src/fd-net-device/examples/waf 2014-06-17 10:34:00.410636878 -0700 +++ ns-3.20/src/fd-net-device/examples/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" diff -Naur ns-3.19/src/fd-net-device/model/fd-net-device.cc ns-3.20/src/fd-net-device/model/fd-net-device.cc --- ns-3.19/src/fd-net-device/model/fd-net-device.cc 2014-06-17 10:34:00.416636831 -0700 +++ ns-3.20/src/fd-net-device/model/fd-net-device.cc 2014-06-17 10:33:13.734997189 -0700 @@ -74,8 +74,7 @@ return FdReader::Data (buf, len); } -NS_OBJECT_ENSURE_REGISTERED (FdNetDevice) - ; +NS_OBJECT_ENSURE_REGISTERED (FdNetDevice); TypeId FdNetDevice::GetTypeId (void) diff -Naur ns-3.19/src/fd-net-device/waf ns-3.20/src/fd-net-device/waf --- ns-3.19/src/fd-net-device/waf 2014-06-17 10:34:00.417636824 -0700 +++ ns-3.20/src/fd-net-device/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../../waf "$@" diff -Naur ns-3.19/src/flow-monitor/bindings/modulegen__gcc_ILP32.py ns-3.20/src/flow-monitor/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/flow-monitor/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.422636785 -0700 +++ ns-3.20/src/flow-monitor/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.739997150 -0700 @@ -60,34 +60,6 @@ module.add_class('InetSocketAddress', import_from_module='ns.network') ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] root_module['ns3::InetSocketAddress'].implicitly_converts_to(root_module['ns3::Address']) - ## int-to-type.h (module 'core'): ns3::IntToType<0> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['0']) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 0 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<1> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['1']) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 1 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<2> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['2']) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 2 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<3> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['3']) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 3 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<4> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['4']) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 4 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<5> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['5']) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 5 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<6> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['6']) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 6 >'], 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] @@ -144,14 +116,8 @@ 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') - ## timer.h (module 'core'): ns3::Timer [class] - module.add_class('Timer', import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] - module.add_enum('DestroyPolicy', ['CANCEL_ON_DESTROY', 'REMOVE_ON_DESTROY', 'CHECK_ON_DESTROY'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::State [enumeration] - module.add_enum('State', ['RUNNING', 'EXPIRED', 'SUSPENDED'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer-impl.h (module 'core'): ns3::TimerImpl [class] - module.add_class('TimerImpl', allow_subclassing=True, import_from_module='ns.core') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -164,6 +130,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## header.h (module 'network'): ns3::Header [class] @@ -262,10 +230,6 @@ module.add_class('FlowProbe', parent=root_module['ns3::Object']) ## flow-probe.h (module 'flow-monitor'): ns3::FlowProbe::FlowStats [struct] module.add_class('FlowStats', outer_class=root_module['ns3::FlowProbe']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -294,12 +258,26 @@ module.add_class('Ipv4Route', import_from_module='ns.internet', parent=root_module['ns3::SimpleRefCount< ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter >']) ## ipv4-routing-protocol.h (module 'internet'): ns3::Ipv4RoutingProtocol [class] module.add_class('Ipv4RoutingProtocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) + ## ipv6.h (module 'internet'): ns3::Ipv6 [class] + module.add_class('Ipv6', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier [class] + module.add_class('Ipv6FlowClassifier', parent=root_module['ns3::FlowClassifier']) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple [struct] + module.add_class('FiveTuple', outer_class=root_module['ns3::Ipv6FlowClassifier']) + ## ipv6-flow-probe.h (module 'flow-monitor'): ns3::Ipv6FlowProbe [class] + module.add_class('Ipv6FlowProbe', parent=root_module['ns3::FlowProbe']) + ## ipv6-flow-probe.h (module 'flow-monitor'): ns3::Ipv6FlowProbe::DropReason [enumeration] + module.add_enum('DropReason', ['DROP_NO_ROUTE', 'DROP_TTL_EXPIRE', 'DROP_BAD_CHECKSUM', 'DROP_QUEUE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT', 'DROP_INVALID_REASON'], outer_class=root_module['ns3::Ipv6FlowProbe']) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol [class] + module.add_class('Ipv6L3Protocol', import_from_module='ns.internet', parent=root_module['ns3::Ipv6']) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::DropReason [enumeration] + module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT'], outer_class=root_module['ns3::Ipv6L3Protocol'], import_from_module='ns.internet') + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache [class] + module.add_class('Ipv6PmtuCache', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -330,18 +308,18 @@ 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']) - module.add_container('std::vector< unsigned int >', 'unsigned int', container_type='vector') - module.add_container('std::vector< unsigned long long >', 'long long unsigned int', container_type='vector') - module.add_container('std::map< unsigned int, ns3::FlowMonitor::FlowStats >', ('unsigned int', 'ns3::FlowMonitor::FlowStats'), container_type='map') - module.add_container('std::vector< ns3::Ptr< ns3::FlowProbe > >', 'ns3::Ptr< ns3::FlowProbe >', container_type='vector') - module.add_container('std::map< unsigned int, ns3::FlowProbe::FlowStats >', ('unsigned int', 'ns3::FlowProbe::FlowStats'), container_type='map') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') - typehandlers.add_type_alias('uint32_t', 'ns3::FlowPacketId') - typehandlers.add_type_alias('uint32_t*', 'ns3::FlowPacketId*') - typehandlers.add_type_alias('uint32_t&', 'ns3::FlowPacketId&') - typehandlers.add_type_alias('uint32_t', 'ns3::FlowId') - typehandlers.add_type_alias('uint32_t*', 'ns3::FlowId*') - typehandlers.add_type_alias('uint32_t&', 'ns3::FlowId&') + module.add_container('std::vector< unsigned int >', 'unsigned int', container_type=u'vector') + module.add_container('std::vector< unsigned long long >', 'long long unsigned int', container_type=u'vector') + module.add_container('std::map< unsigned int, ns3::FlowMonitor::FlowStats >', ('unsigned int', 'ns3::FlowMonitor::FlowStats'), container_type=u'map') + module.add_container('std::vector< ns3::Ptr< ns3::FlowProbe > >', 'ns3::Ptr< ns3::FlowProbe >', container_type=u'vector') + module.add_container('std::map< unsigned int, ns3::FlowProbe::FlowStats >', ('unsigned int', 'ns3::FlowProbe::FlowStats'), container_type=u'map') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') + typehandlers.add_type_alias(u'uint32_t', u'ns3::FlowPacketId') + typehandlers.add_type_alias(u'uint32_t*', u'ns3::FlowPacketId*') + typehandlers.add_type_alias(u'uint32_t&', u'ns3::FlowPacketId&') + typehandlers.add_type_alias(u'uint32_t', u'ns3::FlowId') + typehandlers.add_type_alias(u'uint32_t*', u'ns3::FlowId*') + typehandlers.add_type_alias(u'uint32_t&', u'ns3::FlowId&') ## Register a nested module for the namespace FatalImpl @@ -364,12 +342,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -407,13 +385,6 @@ register_Ns3Histogram_methods(root_module, root_module['ns3::Histogram']) register_Ns3Inet6SocketAddress_methods(root_module, root_module['ns3::Inet6SocketAddress']) register_Ns3InetSocketAddress_methods(root_module, root_module['ns3::InetSocketAddress']) - register_Ns3IntToType__0_methods(root_module, root_module['ns3::IntToType< 0 >']) - register_Ns3IntToType__1_methods(root_module, root_module['ns3::IntToType< 1 >']) - register_Ns3IntToType__2_methods(root_module, root_module['ns3::IntToType< 2 >']) - register_Ns3IntToType__3_methods(root_module, root_module['ns3::IntToType< 3 >']) - register_Ns3IntToType__4_methods(root_module, root_module['ns3::IntToType< 4 >']) - register_Ns3IntToType__5_methods(root_module, root_module['ns3::IntToType< 5 >']) - register_Ns3IntToType__6_methods(root_module, root_module['ns3::IntToType< 6 >']) register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address']) register_Ns3Ipv4InterfaceAddress_methods(root_module, root_module['ns3::Ipv4InterfaceAddress']) register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) @@ -435,8 +406,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) - register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) - register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -484,7 +454,6 @@ register_Ns3FlowMonitorFlowStats_methods(root_module, root_module['ns3::FlowMonitor::FlowStats']) register_Ns3FlowProbe_methods(root_module, root_module['ns3::FlowProbe']) register_Ns3FlowProbeFlowStats_methods(root_module, root_module['ns3::FlowProbe::FlowStats']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -497,9 +466,14 @@ register_Ns3Ipv4MulticastRoute_methods(root_module, root_module['ns3::Ipv4MulticastRoute']) register_Ns3Ipv4Route_methods(root_module, root_module['ns3::Ipv4Route']) register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) + register_Ns3Ipv6_methods(root_module, root_module['ns3::Ipv6']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) + register_Ns3Ipv6FlowClassifier_methods(root_module, root_module['ns3::Ipv6FlowClassifier']) + register_Ns3Ipv6FlowClassifierFiveTuple_methods(root_module, root_module['ns3::Ipv6FlowClassifier::FiveTuple']) + register_Ns3Ipv6FlowProbe_methods(root_module, root_module['ns3::Ipv6FlowProbe']) + register_Ns3Ipv6L3Protocol_methods(root_module, root_module['ns3::Ipv6L3Protocol']) + register_Ns3Ipv6PmtuCache_methods(root_module, root_module['ns3::Ipv6PmtuCache']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3NetDevice_methods(root_module, root_module['ns3::NetDevice']) @@ -766,6 +740,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -778,6 +756,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1045,18 +1027,12 @@ return def register_Ns3FlowMonitorHelper_methods(root_module, cls): - ## flow-monitor-helper.h (module 'flow-monitor'): ns3::FlowMonitorHelper::FlowMonitorHelper(ns3::FlowMonitorHelper const & arg0) [copy constructor] - cls.add_constructor([param('ns3::FlowMonitorHelper const &', 'arg0')]) ## flow-monitor-helper.h (module 'flow-monitor'): ns3::FlowMonitorHelper::FlowMonitorHelper() [constructor] cls.add_constructor([]) - ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetClassifier() [member function] - cls.add_method('GetClassifier', - 'ns3::Ptr< ns3::FlowClassifier >', - []) - ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetMonitor() [member function] - cls.add_method('GetMonitor', - 'ns3::Ptr< ns3::FlowMonitor >', - []) + ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SetMonitorAttribute(std::string n1, ns3::AttributeValue const & v1) [member function] + cls.add_method('SetMonitorAttribute', + 'void', + [param('std::string', 'n1'), param('ns3::AttributeValue const &', 'v1')]) ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::Install(ns3::NodeContainer nodes) [member function] cls.add_method('Install', 'ns3::Ptr< ns3::FlowMonitor >', @@ -1069,10 +1045,30 @@ cls.add_method('InstallAll', 'ns3::Ptr< ns3::FlowMonitor >', []) - ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SetMonitorAttribute(std::string n1, ns3::AttributeValue const & v1) [member function] - cls.add_method('SetMonitorAttribute', + ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetMonitor() [member function] + cls.add_method('GetMonitor', + 'ns3::Ptr< ns3::FlowMonitor >', + []) + ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetClassifier() [member function] + cls.add_method('GetClassifier', + 'ns3::Ptr< ns3::FlowClassifier >', + []) + ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetClassifier6() [member function] + cls.add_method('GetClassifier6', + 'ns3::Ptr< ns3::FlowClassifier >', + []) + ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SerializeToXmlStream(std::ostream & os, int indent, bool enableHistograms, bool enableProbes) [member function] + cls.add_method('SerializeToXmlStream', 'void', - [param('std::string', 'n1'), param('ns3::AttributeValue const &', 'v1')]) + [param('std::ostream &', 'os'), param('int', 'indent'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) + ## flow-monitor-helper.h (module 'flow-monitor'): std::string ns3::FlowMonitorHelper::SerializeToXmlString(int indent, bool enableHistograms, bool enableProbes) [member function] + cls.add_method('SerializeToXmlString', + 'std::string', + [param('int', 'indent'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) + ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SerializeToXmlFile(std::string fileName, bool enableHistograms, bool enableProbes) [member function] + cls.add_method('SerializeToXmlFile', + 'void', + [param('std::string', 'fileName'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) return def register_Ns3Hasher_methods(root_module, cls): @@ -1234,55 +1230,6 @@ [param('uint16_t', 'port')]) return -def register_Ns3IntToType__0_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType(ns3::IntToType<0> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 0 > const &', 'arg0')]) - return - -def register_Ns3IntToType__1_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType(ns3::IntToType<1> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 1 > const &', 'arg0')]) - return - -def register_Ns3IntToType__2_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType(ns3::IntToType<2> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 2 > const &', 'arg0')]) - return - -def register_Ns3IntToType__3_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType(ns3::IntToType<3> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 3 > const &', 'arg0')]) - return - -def register_Ns3IntToType__4_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType(ns3::IntToType<4> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 4 > const &', 'arg0')]) - return - -def register_Ns3IntToType__5_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType(ns3::IntToType<5> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 5 > const &', 'arg0')]) - return - -def register_Ns3IntToType__6_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType(ns3::IntToType<6> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 6 > const &', 'arg0')]) - return - def register_Ns3Ipv4Address_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1751,6 +1698,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -2378,88 +2330,12 @@ [param('uint8_t', 'v')]) return -def register_Ns3Timer_methods(root_module, cls): - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Timer const &', 'arg0')]) - ## timer.h (module 'core'): ns3::Timer::Timer() [constructor] - cls.add_constructor([]) - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer::DestroyPolicy destroyPolicy) [constructor] - cls.add_constructor([param('ns3::Timer::DestroyPolicy', 'destroyPolicy')]) - ## timer.h (module 'core'): void ns3::Timer::Cancel() [member function] - cls.add_method('Cancel', - 'void', - []) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelay() const [member function] - cls.add_method('GetDelay', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelayLeft() const [member function] - cls.add_method('GetDelayLeft', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Timer::State ns3::Timer::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Timer::State', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsExpired() const [member function] - cls.add_method('IsExpired', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsRunning() const [member function] - cls.add_method('IsRunning', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsSuspended() const [member function] - cls.add_method('IsSuspended', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): void ns3::Timer::Remove() [member function] - cls.add_method('Remove', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Resume() [member function] - cls.add_method('Resume', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule() [member function] - cls.add_method('Schedule', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule(ns3::Time delay) [member function] - cls.add_method('Schedule', - 'void', - [param('ns3::Time', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::SetDelay(ns3::Time const & delay) [member function] - cls.add_method('SetDelay', - 'void', - [param('ns3::Time const &', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::Suspend() [member function] - cls.add_method('Suspend', - 'void', - []) - return - -def register_Ns3TimerImpl_methods(root_module, cls): - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl() [constructor] - cls.add_constructor([]) - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl(ns3::TimerImpl const & arg0) [copy constructor] - cls.add_constructor([param('ns3::TimerImpl const &', 'arg0')]) - ## timer-impl.h (module 'core'): void ns3::TimerImpl::Invoke() [member function] - cls.add_method('Invoke', - 'void', - [], - is_pure_virtual=True, is_virtual=True) - ## timer-impl.h (module 'core'): ns3::EventId ns3::TimerImpl::Schedule(ns3::Time const & delay) [member function] - cls.add_method('Schedule', - 'ns3::EventId', - [param('ns3::Time const &', 'delay')], - is_pure_virtual=True, is_virtual=True) +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) return def register_Ns3TypeId_methods(root_module, cls): @@ -2659,62 +2535,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2723,6 +2555,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2763,6 +2597,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3926,13 +3762,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3959,6 +3797,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4380,6 +4223,10 @@ cls.add_constructor([param('ns3::FlowMonitor const &', 'arg0')]) ## flow-monitor.h (module 'flow-monitor'): ns3::FlowMonitor::FlowMonitor() [constructor] cls.add_constructor([]) + ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::AddFlowClassifier(ns3::Ptr classifier) [member function] + cls.add_method('AddFlowClassifier', + 'void', + [param('ns3::Ptr< ns3::FlowClassifier >', 'classifier')]) ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::AddProbe(ns3::Ptr probe) [member function] cls.add_method('AddProbe', 'void', @@ -4440,10 +4287,6 @@ cls.add_method('SerializeToXmlString', 'std::string', [param('int', 'indent'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) - ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::SetFlowClassifier(ns3::Ptr classifier) [member function] - cls.add_method('SetFlowClassifier', - 'void', - [param('ns3::Ptr< ns3::FlowClassifier >', 'classifier')]) ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::Start(ns3::Time const & time) [member function] cls.add_method('Start', 'void', @@ -4563,63 +4406,6 @@ cls.add_instance_attribute('packetsDropped', 'std::vector< unsigned int >', is_const=False) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -4990,6 +4776,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -5283,6 +5074,170 @@ is_pure_virtual=True, is_virtual=True) return +def register_Ns3Ipv6_methods(root_module, cls): + ## ipv6.h (module 'internet'): ns3::Ipv6::Ipv6(ns3::Ipv6 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Ipv6 const &', 'arg0')]) + ## ipv6.h (module 'internet'): ns3::Ipv6::Ipv6() [constructor] + cls.add_constructor([]) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::AddAddress(uint32_t interface, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('AddAddress', + 'bool', + [param('uint32_t', 'interface'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint32_t ns3::Ipv6::AddInterface(ns3::Ptr device) [member function] + cls.add_method('AddInterface', + 'uint32_t', + [param('ns3::Ptr< ns3::NetDevice >', 'device')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6::GetAddress(uint32_t interface, uint32_t addressIndex) const [member function] + cls.add_method('GetAddress', + 'ns3::Ipv6InterfaceAddress', + [param('uint32_t', 'interface'), param('uint32_t', 'addressIndex')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): int32_t ns3::Ipv6::GetInterfaceForAddress(ns3::Ipv6Address address) const [member function] + cls.add_method('GetInterfaceForAddress', + 'int32_t', + [param('ns3::Ipv6Address', 'address')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): int32_t ns3::Ipv6::GetInterfaceForDevice(ns3::Ptr device) const [member function] + cls.add_method('GetInterfaceForDevice', + 'int32_t', + [param('ns3::Ptr< ns3::NetDevice const >', 'device')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): int32_t ns3::Ipv6::GetInterfaceForPrefix(ns3::Ipv6Address address, ns3::Ipv6Prefix mask) const [member function] + cls.add_method('GetInterfaceForPrefix', + 'int32_t', + [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'mask')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint16_t ns3::Ipv6::GetMetric(uint32_t interface) const [member function] + cls.add_method('GetMetric', + 'uint16_t', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint16_t ns3::Ipv6::GetMtu(uint32_t interface) const [member function] + cls.add_method('GetMtu', + 'uint16_t', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint32_t ns3::Ipv6::GetNAddresses(uint32_t interface) const [member function] + cls.add_method('GetNAddresses', + 'uint32_t', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint32_t ns3::Ipv6::GetNInterfaces() const [member function] + cls.add_method('GetNInterfaces', + 'uint32_t', + [], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetNetDevice(uint32_t interface) [member function] + cls.add_method('GetNetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetRoutingProtocol() const [member function] + cls.add_method('GetRoutingProtocol', + 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', + [], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): static ns3::TypeId ns3::Ipv6::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::IsForwarding(uint32_t interface) const [member function] + cls.add_method('IsForwarding', + 'bool', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::IsUp(uint32_t interface) const [member function] + cls.add_method('IsUp', + 'bool', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::RegisterExtensions() [member function] + cls.add_method('RegisterExtensions', + 'void', + [], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::RegisterOptions() [member function] + cls.add_method('RegisterOptions', + 'void', + [], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::RemoveAddress(uint32_t interface, uint32_t addressIndex) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interface'), param('uint32_t', 'addressIndex')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::RemoveAddress(uint32_t interface, ns3::Ipv6Address address) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'address')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetDown(uint32_t interface) [member function] + cls.add_method('SetDown', + 'void', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetForwarding(uint32_t interface, bool val) [member function] + cls.add_method('SetForwarding', + 'void', + [param('uint32_t', 'interface'), param('bool', 'val')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetMetric(uint32_t interface, uint16_t metric) [member function] + cls.add_method('SetMetric', + 'void', + [param('uint32_t', 'interface'), param('uint16_t', 'metric')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetPmtu(ns3::Ipv6Address dst, uint32_t pmtu) [member function] + cls.add_method('SetPmtu', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('uint32_t', 'pmtu')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetRoutingProtocol(ns3::Ptr routingProtocol) [member function] + cls.add_method('SetRoutingProtocol', + 'void', + [param('ns3::Ptr< ns3::Ipv6RoutingProtocol >', 'routingProtocol')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetUp(uint32_t interface) [member function] + cls.add_method('SetUp', + 'void', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6::IF_ANY [variable] + cls.add_static_attribute('IF_ANY', 'uint32_t const', is_const=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetIpForward() const [member function] + cls.add_method('GetIpForward', + 'bool', + [], + is_pure_virtual=True, is_const=True, visibility='private', is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetMtuDiscover() const [member function] + cls.add_method('GetMtuDiscover', + 'bool', + [], + is_pure_virtual=True, is_const=True, visibility='private', is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetIpForward(bool forward) [member function] + cls.add_method('SetIpForward', + 'void', + [param('bool', 'forward')], + is_pure_virtual=True, visibility='private', is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetMtuDiscover(bool mtuDiscover) [member function] + cls.add_method('SetMtuDiscover', + 'void', + [param('bool', 'mtuDiscover')], + is_pure_virtual=True, visibility='private', is_virtual=True) + return + def register_Ns3Ipv6AddressChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker() [constructor] cls.add_constructor([]) @@ -5323,149 +5278,327 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] +def register_Ns3Ipv6FlowClassifier_methods(root_module, cls): + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::Ipv6FlowClassifier() [constructor] cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', + ## ipv6-flow-classifier.h (module 'flow-monitor'): bool ns3::Ipv6FlowClassifier::Classify(ns3::Ipv6Header const & ipHeader, ns3::Ptr ipPayload, uint32_t * out_flowId, uint32_t * out_packetId) [member function] + cls.add_method('Classify', 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], + [param('ns3::Ipv6Header const &', 'ipHeader'), param('ns3::Ptr< ns3::Packet const >', 'ipPayload'), param('uint32_t *', 'out_flowId'), param('uint32_t *', 'out_packetId')]) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple ns3::Ipv6FlowClassifier::FindFlow(ns3::FlowId flowId) const [member function] + cls.add_method('FindFlow', + 'ns3::Ipv6FlowClassifier::FiveTuple', + [param('ns3::FlowId', 'flowId')], is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', + ## ipv6-flow-classifier.h (module 'flow-monitor'): void ns3::Ipv6FlowClassifier::SerializeToXmlStream(std::ostream & os, int indent) const [member function] + cls.add_method('SerializeToXmlStream', + 'void', + [param('std::ostream &', 'os'), param('int', 'indent')], + is_const=True, is_virtual=True) + return + +def register_Ns3Ipv6FlowClassifierFiveTuple_methods(root_module, cls): + cls.add_binary_comparison_operator('<') + cls.add_binary_comparison_operator('==') + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::FiveTuple() [constructor] + cls.add_constructor([]) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::FiveTuple(ns3::Ipv6FlowClassifier::FiveTuple const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Ipv6FlowClassifier::FiveTuple const &', 'arg0')]) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::destinationAddress [variable] + cls.add_instance_attribute('destinationAddress', 'ns3::Ipv6Address', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::destinationPort [variable] + cls.add_instance_attribute('destinationPort', 'uint16_t', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::protocol [variable] + cls.add_instance_attribute('protocol', 'uint8_t', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::sourceAddress [variable] + cls.add_instance_attribute('sourceAddress', 'ns3::Ipv6Address', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::sourcePort [variable] + cls.add_instance_attribute('sourcePort', 'uint16_t', is_const=False) + return + +def register_Ns3Ipv6FlowProbe_methods(root_module, cls): + ## ipv6-flow-probe.h (module 'flow-monitor'): ns3::Ipv6FlowProbe::Ipv6FlowProbe(ns3::Ptr monitor, ns3::Ptr classifier, ns3::Ptr node) [constructor] + cls.add_constructor([param('ns3::Ptr< ns3::FlowMonitor >', 'monitor'), param('ns3::Ptr< ns3::Ipv6FlowClassifier >', 'classifier'), param('ns3::Ptr< ns3::Node >', 'node')]) + ## ipv6-flow-probe.h (module 'flow-monitor'): void ns3::Ipv6FlowProbe::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', + visibility='protected', is_virtual=True) + return + +def register_Ns3Ipv6L3Protocol_methods(root_module, cls): + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::PROT_NUMBER [variable] + cls.add_static_attribute('PROT_NUMBER', 'uint16_t const', is_const=True) + ## ipv6-l3-protocol.h (module 'internet'): static ns3::TypeId ns3::Ipv6L3Protocol::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', [], + is_static=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::Ipv6L3Protocol() [constructor] + cls.add_constructor([]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetNode(ns3::Ptr node) [member function] + cls.add_method('SetNode', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Insert(ns3::Ptr protocol) [member function] + cls.add_method('Insert', + 'void', + [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Remove(ns3::Ptr protocol) [member function] + cls.add_method('Remove', + 'void', + [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')]) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::CreateRawSocket() [member function] + cls.add_method('CreateRawSocket', + 'ns3::Ptr< ns3::Socket >', + []) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DeleteRawSocket(ns3::Ptr socket) [member function] + cls.add_method('DeleteRawSocket', + 'void', + [param('ns3::Ptr< ns3::Socket >', 'socket')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetDefaultTtl(uint8_t ttl) [member function] + cls.add_method('SetDefaultTtl', + 'void', + [param('uint8_t', 'ttl')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetDefaultTclass(uint8_t tclass) [member function] + cls.add_method('SetDefaultTclass', + 'void', + [param('uint8_t', 'tclass')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Receive(ns3::Ptr device, ns3::Ptr p, uint16_t protocol, ns3::Address const & from, ns3::Address const & to, ns3::NetDevice::PacketType packetType) [member function] + cls.add_method('Receive', + 'void', + [param('ns3::Ptr< ns3::NetDevice >', 'device'), param('ns3::Ptr< ns3::Packet const >', 'p'), param('uint16_t', 'protocol'), param('ns3::Address const &', 'from'), param('ns3::Address const &', 'to'), param('ns3::NetDevice::PacketType', 'packetType')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Send(ns3::Ptr packet, ns3::Ipv6Address source, ns3::Ipv6Address destination, uint8_t protocol, ns3::Ptr route) [member function] + cls.add_method('Send', + 'void', + [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv6Address', 'source'), param('ns3::Ipv6Address', 'destination'), param('uint8_t', 'protocol'), param('ns3::Ptr< ns3::Ipv6Route >', 'route')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetRoutingProtocol(ns3::Ptr routingProtocol) [member function] + cls.add_method('SetRoutingProtocol', + 'void', + [param('ns3::Ptr< ns3::Ipv6RoutingProtocol >', 'routingProtocol')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetRoutingProtocol() const [member function] + cls.add_method('GetRoutingProtocol', + 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', [], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv6L3Protocol::AddInterface(ns3::Ptr device) [member function] + cls.add_method('AddInterface', + 'uint32_t', + [param('ns3::Ptr< ns3::NetDevice >', 'device')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetInterface(uint32_t i) const [member function] + cls.add_method('GetInterface', + 'ns3::Ptr< ns3::Ipv6Interface >', + [param('uint32_t', 'i')], is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', + ## ipv6-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv6L3Protocol::GetNInterfaces() const [member function] + cls.add_method('GetNInterfaces', + 'uint32_t', [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): int32_t ns3::Ipv6L3Protocol::GetInterfaceForAddress(ns3::Ipv6Address addr) const [member function] + cls.add_method('GetInterfaceForAddress', + 'int32_t', + [param('ns3::Ipv6Address', 'addr')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): int32_t ns3::Ipv6L3Protocol::GetInterfaceForPrefix(ns3::Ipv6Address addr, ns3::Ipv6Prefix mask) const [member function] + cls.add_method('GetInterfaceForPrefix', + 'int32_t', + [param('ns3::Ipv6Address', 'addr'), param('ns3::Ipv6Prefix', 'mask')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): int32_t ns3::Ipv6L3Protocol::GetInterfaceForDevice(ns3::Ptr device) const [member function] + cls.add_method('GetInterfaceForDevice', + 'int32_t', + [param('ns3::Ptr< ns3::NetDevice const >', 'device')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::AddAddress(uint32_t i, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('AddAddress', + 'bool', + [param('uint32_t', 'i'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6L3Protocol::GetAddress(uint32_t interfaceIndex, uint32_t addressIndex) const [member function] + cls.add_method('GetAddress', + 'ns3::Ipv6InterfaceAddress', + [param('uint32_t', 'interfaceIndex'), param('uint32_t', 'addressIndex')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv6L3Protocol::GetNAddresses(uint32_t interface) const [member function] cls.add_method('GetNAddresses', 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', + [param('uint32_t', 'interface')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::RemoveAddress(uint32_t interfaceIndex, uint32_t addressIndex) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interfaceIndex'), param('uint32_t', 'addressIndex')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::RemoveAddress(uint32_t interfaceIndex, ns3::Ipv6Address address) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interfaceIndex'), param('ns3::Ipv6Address', 'address')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetMetric(uint32_t i, uint16_t metric) [member function] + cls.add_method('SetMetric', + 'void', + [param('uint32_t', 'i'), param('uint16_t', 'metric')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint16_t ns3::Ipv6L3Protocol::GetMetric(uint32_t i) const [member function] + cls.add_method('GetMetric', 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint16_t ns3::Ipv6L3Protocol::GetMtu(uint32_t i) const [member function] + cls.add_method('GetMtu', 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetPmtu(ns3::Ipv6Address dst, uint32_t pmtu) [member function] + cls.add_method('SetPmtu', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('uint32_t', 'pmtu')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::IsUp(uint32_t i) const [member function] + cls.add_method('IsUp', 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetUp(uint32_t i) [member function] + cls.add_method('SetUp', + 'void', + [param('uint32_t', 'i')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetDown(uint32_t i) [member function] + cls.add_method('SetDown', + 'void', + [param('uint32_t', 'i')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::IsForwarding(uint32_t i) const [member function] cls.add_method('IsForwarding', 'bool', + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetForwarding(uint32_t i, bool val) [member function] + cls.add_method('SetForwarding', + 'void', + [param('uint32_t', 'i'), param('bool', 'val')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6L3Protocol::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetNetDevice(uint32_t i) [member function] + cls.add_method('GetNetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [param('uint32_t', 'i')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetIcmpv6() const [member function] + cls.add_method('GetIcmpv6', + 'ns3::Ptr< ns3::Icmpv6L4Protocol >', [], is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::AddAutoconfiguredAddress(uint32_t interface, ns3::Ipv6Address network, ns3::Ipv6Prefix mask, uint8_t flags, uint32_t validTime, uint32_t preferredTime, ns3::Ipv6Address defaultRouter=ns3::Ipv6Address::GetZero( )) [member function] + cls.add_method('AddAutoconfiguredAddress', 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'mask'), param('uint8_t', 'flags'), param('uint32_t', 'validTime'), param('uint32_t', 'preferredTime'), param('ns3::Ipv6Address', 'defaultRouter', default_value='ns3::Ipv6Address::GetZero( )')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::RemoveAutoconfiguredAddress(uint32_t interface, ns3::Ipv6Address network, ns3::Ipv6Prefix mask, ns3::Ipv6Address defaultRouter) [member function] + cls.add_method('RemoveAutoconfiguredAddress', 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'mask'), param('ns3::Ipv6Address', 'defaultRouter')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::RegisterExtensions() [member function] + cls.add_method('RegisterExtensions', 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', + [], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::RegisterOptions() [member function] + cls.add_method('RegisterOptions', 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', + [], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::ReportDrop(ns3::Ipv6Header ipHeader, ns3::Ptr p, ns3::Ipv6L3Protocol::DropReason dropReason) [member function] + cls.add_method('ReportDrop', 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', + [param('ns3::Ipv6Header', 'ipHeader'), param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6L3Protocol::DropReason', 'dropReason')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DoDispose() [member function] + cls.add_method('DoDispose', 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', + [], + visibility='protected', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::NotifyNewAggregate() [member function] + cls.add_method('NotifyNewAggregate', 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', + [], + visibility='protected', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetIpForward(bool forward) [member function] + cls.add_method('SetIpForward', 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', + [param('bool', 'forward')], + visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::GetIpForward() const [member function] + cls.add_method('GetIpForward', + 'bool', + [], + is_const=True, visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetMtuDiscover(bool mtuDiscover) [member function] + cls.add_method('SetMtuDiscover', 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', + [param('bool', 'mtuDiscover')], + visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::GetMtuDiscover() const [member function] + cls.add_method('GetMtuDiscover', + 'bool', + [], + is_const=True, visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetSendIcmpv6Redirect(bool sendIcmpv6Redirect) [member function] + cls.add_method('SetSendIcmpv6Redirect', 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] + [param('bool', 'sendIcmpv6Redirect')], + visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::GetSendIcmpv6Redirect() const [member function] + cls.add_method('GetSendIcmpv6Redirect', + 'bool', + [], + is_const=True, visibility='private', is_virtual=True) + return + +def register_Ns3Ipv6PmtuCache_methods(root_module, cls): + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache::Ipv6PmtuCache(ns3::Ipv6PmtuCache const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Ipv6PmtuCache const &', 'arg0')]) + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache::Ipv6PmtuCache() [constructor] + cls.add_constructor([]) + ## ipv6-pmtu-cache.h (module 'internet'): void ns3::Ipv6PmtuCache::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], - visibility='protected', is_virtual=True) + is_virtual=True) + ## ipv6-pmtu-cache.h (module 'internet'): uint32_t ns3::Ipv6PmtuCache::GetPmtu(ns3::Ipv6Address dst) [member function] + cls.add_method('GetPmtu', + 'uint32_t', + [param('ns3::Ipv6Address', 'dst')]) + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Time ns3::Ipv6PmtuCache::GetPmtuValidityTime() const [member function] + cls.add_method('GetPmtuValidityTime', + 'ns3::Time', + [], + is_const=True) + ## ipv6-pmtu-cache.h (module 'internet'): static ns3::TypeId ns3::Ipv6PmtuCache::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ipv6-pmtu-cache.h (module 'internet'): void ns3::Ipv6PmtuCache::SetPmtu(ns3::Ipv6Address dst, uint32_t pmtu) [member function] + cls.add_method('SetPmtu', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('uint32_t', 'pmtu')]) + ## ipv6-pmtu-cache.h (module 'internet'): bool ns3::Ipv6PmtuCache::SetPmtuValidityTime(ns3::Time validity) [member function] + cls.add_method('SetPmtuValidityTime', + 'bool', + [param('ns3::Time', 'validity')]) return def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): @@ -5999,10 +6132,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TimeValue_methods(root_module, cls): diff -Naur ns-3.19/src/flow-monitor/bindings/modulegen__gcc_LP64.py ns-3.20/src/flow-monitor/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/flow-monitor/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.425636762 -0700 +++ ns-3.20/src/flow-monitor/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.743997119 -0700 @@ -60,34 +60,6 @@ module.add_class('InetSocketAddress', import_from_module='ns.network') ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] root_module['ns3::InetSocketAddress'].implicitly_converts_to(root_module['ns3::Address']) - ## int-to-type.h (module 'core'): ns3::IntToType<0> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['0']) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 0 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<1> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['1']) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 1 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<2> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['2']) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 2 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<3> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['3']) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 3 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<4> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['4']) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 4 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<5> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['5']) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 5 >'], import_from_module='ns.core') - ## int-to-type.h (module 'core'): ns3::IntToType<6> [struct] - module.add_class('IntToType', import_from_module='ns.core', template_parameters=['6']) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::v_e [enumeration] - module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 6 >'], 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] @@ -144,14 +116,8 @@ 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') - ## timer.h (module 'core'): ns3::Timer [class] - module.add_class('Timer', import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] - module.add_enum('DestroyPolicy', ['CANCEL_ON_DESTROY', 'REMOVE_ON_DESTROY', 'CHECK_ON_DESTROY'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer.h (module 'core'): ns3::Timer::State [enumeration] - module.add_enum('State', ['RUNNING', 'EXPIRED', 'SUSPENDED'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') - ## timer-impl.h (module 'core'): ns3::TimerImpl [class] - module.add_class('TimerImpl', allow_subclassing=True, import_from_module='ns.core') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## 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] @@ -164,6 +130,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## header.h (module 'network'): ns3::Header [class] @@ -262,10 +230,6 @@ module.add_class('FlowProbe', parent=root_module['ns3::Object']) ## flow-probe.h (module 'flow-monitor'): ns3::FlowProbe::FlowStats [struct] module.add_class('FlowStats', outer_class=root_module['ns3::FlowProbe']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol [class] - module.add_class('IpL4Protocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus [enumeration] - module.add_enum('RxStatus', ['RX_OK', 'RX_CSUM_FAILED', 'RX_ENDPOINT_CLOSED', 'RX_ENDPOINT_UNREACH'], outer_class=root_module['ns3::IpL4Protocol'], import_from_module='ns.internet') ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] @@ -294,12 +258,26 @@ module.add_class('Ipv4Route', import_from_module='ns.internet', parent=root_module['ns3::SimpleRefCount< ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter >']) ## ipv4-routing-protocol.h (module 'internet'): ns3::Ipv4RoutingProtocol [class] module.add_class('Ipv4RoutingProtocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) + ## ipv6.h (module 'internet'): ns3::Ipv6 [class] + module.add_class('Ipv6', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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-interface.h (module 'internet'): ns3::Ipv6Interface [class] - module.add_class('Ipv6Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier [class] + module.add_class('Ipv6FlowClassifier', parent=root_module['ns3::FlowClassifier']) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple [struct] + module.add_class('FiveTuple', outer_class=root_module['ns3::Ipv6FlowClassifier']) + ## ipv6-flow-probe.h (module 'flow-monitor'): ns3::Ipv6FlowProbe [class] + module.add_class('Ipv6FlowProbe', parent=root_module['ns3::FlowProbe']) + ## ipv6-flow-probe.h (module 'flow-monitor'): ns3::Ipv6FlowProbe::DropReason [enumeration] + module.add_enum('DropReason', ['DROP_NO_ROUTE', 'DROP_TTL_EXPIRE', 'DROP_BAD_CHECKSUM', 'DROP_QUEUE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT', 'DROP_INVALID_REASON'], outer_class=root_module['ns3::Ipv6FlowProbe']) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol [class] + module.add_class('Ipv6L3Protocol', import_from_module='ns.internet', parent=root_module['ns3::Ipv6']) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::DropReason [enumeration] + module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT'], outer_class=root_module['ns3::Ipv6L3Protocol'], import_from_module='ns.internet') + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache [class] + module.add_class('Ipv6PmtuCache', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## 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] @@ -330,18 +308,18 @@ 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']) - module.add_container('std::vector< unsigned int >', 'unsigned int', container_type='vector') - module.add_container('std::vector< unsigned long >', 'long unsigned int', container_type='vector') - module.add_container('std::map< unsigned int, ns3::FlowMonitor::FlowStats >', ('unsigned int', 'ns3::FlowMonitor::FlowStats'), container_type='map') - module.add_container('std::vector< ns3::Ptr< ns3::FlowProbe > >', 'ns3::Ptr< ns3::FlowProbe >', container_type='vector') - module.add_container('std::map< unsigned int, ns3::FlowProbe::FlowStats >', ('unsigned int', 'ns3::FlowProbe::FlowStats'), container_type='map') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') - typehandlers.add_type_alias('uint32_t', 'ns3::FlowPacketId') - typehandlers.add_type_alias('uint32_t*', 'ns3::FlowPacketId*') - typehandlers.add_type_alias('uint32_t&', 'ns3::FlowPacketId&') - typehandlers.add_type_alias('uint32_t', 'ns3::FlowId') - typehandlers.add_type_alias('uint32_t*', 'ns3::FlowId*') - typehandlers.add_type_alias('uint32_t&', 'ns3::FlowId&') + module.add_container('std::vector< unsigned int >', 'unsigned int', container_type=u'vector') + module.add_container('std::vector< unsigned long >', 'long unsigned int', container_type=u'vector') + module.add_container('std::map< unsigned int, ns3::FlowMonitor::FlowStats >', ('unsigned int', 'ns3::FlowMonitor::FlowStats'), container_type=u'map') + module.add_container('std::vector< ns3::Ptr< ns3::FlowProbe > >', 'ns3::Ptr< ns3::FlowProbe >', container_type=u'vector') + module.add_container('std::map< unsigned int, ns3::FlowProbe::FlowStats >', ('unsigned int', 'ns3::FlowProbe::FlowStats'), container_type=u'map') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') + typehandlers.add_type_alias(u'uint32_t', u'ns3::FlowPacketId') + typehandlers.add_type_alias(u'uint32_t*', u'ns3::FlowPacketId*') + typehandlers.add_type_alias(u'uint32_t&', u'ns3::FlowPacketId&') + typehandlers.add_type_alias(u'uint32_t', u'ns3::FlowId') + typehandlers.add_type_alias(u'uint32_t*', u'ns3::FlowId*') + typehandlers.add_type_alias(u'uint32_t&', u'ns3::FlowId&') ## Register a nested module for the namespace FatalImpl @@ -364,12 +342,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') ## Register a nested module for the namespace Function @@ -407,13 +385,6 @@ register_Ns3Histogram_methods(root_module, root_module['ns3::Histogram']) register_Ns3Inet6SocketAddress_methods(root_module, root_module['ns3::Inet6SocketAddress']) register_Ns3InetSocketAddress_methods(root_module, root_module['ns3::InetSocketAddress']) - register_Ns3IntToType__0_methods(root_module, root_module['ns3::IntToType< 0 >']) - register_Ns3IntToType__1_methods(root_module, root_module['ns3::IntToType< 1 >']) - register_Ns3IntToType__2_methods(root_module, root_module['ns3::IntToType< 2 >']) - register_Ns3IntToType__3_methods(root_module, root_module['ns3::IntToType< 3 >']) - register_Ns3IntToType__4_methods(root_module, root_module['ns3::IntToType< 4 >']) - register_Ns3IntToType__5_methods(root_module, root_module['ns3::IntToType< 5 >']) - register_Ns3IntToType__6_methods(root_module, root_module['ns3::IntToType< 6 >']) register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address']) register_Ns3Ipv4InterfaceAddress_methods(root_module, root_module['ns3::Ipv4InterfaceAddress']) register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) @@ -435,8 +406,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) - register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) - register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) 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']) @@ -484,7 +454,6 @@ register_Ns3FlowMonitorFlowStats_methods(root_module, root_module['ns3::FlowMonitor::FlowStats']) register_Ns3FlowProbe_methods(root_module, root_module['ns3::FlowProbe']) register_Ns3FlowProbeFlowStats_methods(root_module, root_module['ns3::FlowProbe::FlowStats']) - register_Ns3IpL4Protocol_methods(root_module, root_module['ns3::IpL4Protocol']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) @@ -497,9 +466,14 @@ register_Ns3Ipv4MulticastRoute_methods(root_module, root_module['ns3::Ipv4MulticastRoute']) register_Ns3Ipv4Route_methods(root_module, root_module['ns3::Ipv4Route']) register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) + register_Ns3Ipv6_methods(root_module, root_module['ns3::Ipv6']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) - register_Ns3Ipv6Interface_methods(root_module, root_module['ns3::Ipv6Interface']) + register_Ns3Ipv6FlowClassifier_methods(root_module, root_module['ns3::Ipv6FlowClassifier']) + register_Ns3Ipv6FlowClassifierFiveTuple_methods(root_module, root_module['ns3::Ipv6FlowClassifier::FiveTuple']) + register_Ns3Ipv6FlowProbe_methods(root_module, root_module['ns3::Ipv6FlowProbe']) + register_Ns3Ipv6L3Protocol_methods(root_module, root_module['ns3::Ipv6L3Protocol']) + register_Ns3Ipv6PmtuCache_methods(root_module, root_module['ns3::Ipv6PmtuCache']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3NetDevice_methods(root_module, root_module['ns3::NetDevice']) @@ -766,6 +740,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -778,6 +756,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -1045,18 +1027,12 @@ return def register_Ns3FlowMonitorHelper_methods(root_module, cls): - ## flow-monitor-helper.h (module 'flow-monitor'): ns3::FlowMonitorHelper::FlowMonitorHelper(ns3::FlowMonitorHelper const & arg0) [copy constructor] - cls.add_constructor([param('ns3::FlowMonitorHelper const &', 'arg0')]) ## flow-monitor-helper.h (module 'flow-monitor'): ns3::FlowMonitorHelper::FlowMonitorHelper() [constructor] cls.add_constructor([]) - ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetClassifier() [member function] - cls.add_method('GetClassifier', - 'ns3::Ptr< ns3::FlowClassifier >', - []) - ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetMonitor() [member function] - cls.add_method('GetMonitor', - 'ns3::Ptr< ns3::FlowMonitor >', - []) + ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SetMonitorAttribute(std::string n1, ns3::AttributeValue const & v1) [member function] + cls.add_method('SetMonitorAttribute', + 'void', + [param('std::string', 'n1'), param('ns3::AttributeValue const &', 'v1')]) ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::Install(ns3::NodeContainer nodes) [member function] cls.add_method('Install', 'ns3::Ptr< ns3::FlowMonitor >', @@ -1069,10 +1045,30 @@ cls.add_method('InstallAll', 'ns3::Ptr< ns3::FlowMonitor >', []) - ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SetMonitorAttribute(std::string n1, ns3::AttributeValue const & v1) [member function] - cls.add_method('SetMonitorAttribute', + ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetMonitor() [member function] + cls.add_method('GetMonitor', + 'ns3::Ptr< ns3::FlowMonitor >', + []) + ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetClassifier() [member function] + cls.add_method('GetClassifier', + 'ns3::Ptr< ns3::FlowClassifier >', + []) + ## flow-monitor-helper.h (module 'flow-monitor'): ns3::Ptr ns3::FlowMonitorHelper::GetClassifier6() [member function] + cls.add_method('GetClassifier6', + 'ns3::Ptr< ns3::FlowClassifier >', + []) + ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SerializeToXmlStream(std::ostream & os, int indent, bool enableHistograms, bool enableProbes) [member function] + cls.add_method('SerializeToXmlStream', 'void', - [param('std::string', 'n1'), param('ns3::AttributeValue const &', 'v1')]) + [param('std::ostream &', 'os'), param('int', 'indent'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) + ## flow-monitor-helper.h (module 'flow-monitor'): std::string ns3::FlowMonitorHelper::SerializeToXmlString(int indent, bool enableHistograms, bool enableProbes) [member function] + cls.add_method('SerializeToXmlString', + 'std::string', + [param('int', 'indent'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) + ## flow-monitor-helper.h (module 'flow-monitor'): void ns3::FlowMonitorHelper::SerializeToXmlFile(std::string fileName, bool enableHistograms, bool enableProbes) [member function] + cls.add_method('SerializeToXmlFile', + 'void', + [param('std::string', 'fileName'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) return def register_Ns3Hasher_methods(root_module, cls): @@ -1234,55 +1230,6 @@ [param('uint16_t', 'port')]) return -def register_Ns3IntToType__0_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType(ns3::IntToType<0> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 0 > const &', 'arg0')]) - return - -def register_Ns3IntToType__1_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType(ns3::IntToType<1> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 1 > const &', 'arg0')]) - return - -def register_Ns3IntToType__2_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType(ns3::IntToType<2> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 2 > const &', 'arg0')]) - return - -def register_Ns3IntToType__3_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType(ns3::IntToType<3> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 3 > const &', 'arg0')]) - return - -def register_Ns3IntToType__4_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType(ns3::IntToType<4> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 4 > const &', 'arg0')]) - return - -def register_Ns3IntToType__5_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType(ns3::IntToType<5> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 5 > const &', 'arg0')]) - return - -def register_Ns3IntToType__6_methods(root_module, cls): - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType() [constructor] - cls.add_constructor([]) - ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType(ns3::IntToType<6> const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IntToType< 6 > const &', 'arg0')]) - return - def register_Ns3Ipv4Address_methods(root_module, cls): cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('!=') @@ -1751,6 +1698,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -2378,88 +2330,12 @@ [param('uint8_t', 'v')]) return -def register_Ns3Timer_methods(root_module, cls): - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Timer const &', 'arg0')]) - ## timer.h (module 'core'): ns3::Timer::Timer() [constructor] - cls.add_constructor([]) - ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer::DestroyPolicy destroyPolicy) [constructor] - cls.add_constructor([param('ns3::Timer::DestroyPolicy', 'destroyPolicy')]) - ## timer.h (module 'core'): void ns3::Timer::Cancel() [member function] - cls.add_method('Cancel', - 'void', - []) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelay() const [member function] - cls.add_method('GetDelay', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelayLeft() const [member function] - cls.add_method('GetDelayLeft', - 'ns3::Time', - [], - is_const=True) - ## timer.h (module 'core'): ns3::Timer::State ns3::Timer::GetState() const [member function] - cls.add_method('GetState', - 'ns3::Timer::State', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsExpired() const [member function] - cls.add_method('IsExpired', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsRunning() const [member function] - cls.add_method('IsRunning', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): bool ns3::Timer::IsSuspended() const [member function] - cls.add_method('IsSuspended', - 'bool', - [], - is_const=True) - ## timer.h (module 'core'): void ns3::Timer::Remove() [member function] - cls.add_method('Remove', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Resume() [member function] - cls.add_method('Resume', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule() [member function] - cls.add_method('Schedule', - 'void', - []) - ## timer.h (module 'core'): void ns3::Timer::Schedule(ns3::Time delay) [member function] - cls.add_method('Schedule', - 'void', - [param('ns3::Time', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::SetDelay(ns3::Time const & delay) [member function] - cls.add_method('SetDelay', - 'void', - [param('ns3::Time const &', 'delay')]) - ## timer.h (module 'core'): void ns3::Timer::Suspend() [member function] - cls.add_method('Suspend', - 'void', - []) - return - -def register_Ns3TimerImpl_methods(root_module, cls): - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl() [constructor] - cls.add_constructor([]) - ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl(ns3::TimerImpl const & arg0) [copy constructor] - cls.add_constructor([param('ns3::TimerImpl const &', 'arg0')]) - ## timer-impl.h (module 'core'): void ns3::TimerImpl::Invoke() [member function] - cls.add_method('Invoke', - 'void', - [], - is_pure_virtual=True, is_virtual=True) - ## timer-impl.h (module 'core'): ns3::EventId ns3::TimerImpl::Schedule(ns3::Time const & delay) [member function] - cls.add_method('Schedule', - 'ns3::EventId', - [param('ns3::Time const &', 'delay')], - is_pure_virtual=True, is_virtual=True) +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) return def register_Ns3TypeId_methods(root_module, cls): @@ -2659,62 +2535,18 @@ 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_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -2723,6 +2555,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -2763,6 +2597,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -3926,13 +3762,15 @@ 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_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -3959,6 +3797,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -4380,6 +4223,10 @@ cls.add_constructor([param('ns3::FlowMonitor const &', 'arg0')]) ## flow-monitor.h (module 'flow-monitor'): ns3::FlowMonitor::FlowMonitor() [constructor] cls.add_constructor([]) + ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::AddFlowClassifier(ns3::Ptr classifier) [member function] + cls.add_method('AddFlowClassifier', + 'void', + [param('ns3::Ptr< ns3::FlowClassifier >', 'classifier')]) ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::AddProbe(ns3::Ptr probe) [member function] cls.add_method('AddProbe', 'void', @@ -4440,10 +4287,6 @@ cls.add_method('SerializeToXmlString', 'std::string', [param('int', 'indent'), param('bool', 'enableHistograms'), param('bool', 'enableProbes')]) - ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::SetFlowClassifier(ns3::Ptr classifier) [member function] - cls.add_method('SetFlowClassifier', - 'void', - [param('ns3::Ptr< ns3::FlowClassifier >', 'classifier')]) ## flow-monitor.h (module 'flow-monitor'): void ns3::FlowMonitor::Start(ns3::Time const & time) [member function] cls.add_method('Start', 'void', @@ -4563,63 +4406,6 @@ cls.add_instance_attribute('packetsDropped', 'std::vector< unsigned int >', is_const=False) return -def register_Ns3IpL4Protocol_methods(root_module, cls): - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol() [constructor] - cls.add_constructor([]) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::IpL4Protocol(ns3::IpL4Protocol const & arg0) [copy constructor] - cls.add_constructor([param('ns3::IpL4Protocol const &', 'arg0')]) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget() const [member function] - cls.add_method('GetDownTarget', - 'ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::IpL4Protocol::GetDownTarget6() const [member function] - cls.add_method('GetDownTarget6', - '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_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): int ns3::IpL4Protocol::GetProtocolNumber() const [member function] - cls.add_method('GetProtocolNumber', - 'int', - [], - is_pure_virtual=True, is_const=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): static ns3::TypeId ns3::IpL4Protocol::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv4Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::Ipv4Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): ns3::IpL4Protocol::RxStatus ns3::IpL4Protocol::Receive(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr incomingInterface) [member function] - cls.add_method('Receive', - 'ns3::IpL4Protocol::RxStatus', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::Ipv6Interface >', 'incomingInterface')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv4Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv4Address payloadSource, ns3::Ipv4Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv4Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv4Address', 'payloadSource'), param('ns3::Ipv4Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::ReceiveIcmp(ns3::Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo, ns3::Ipv6Address payloadSource, ns3::Ipv6Address payloadDestination, uint8_t const * payload) [member function] - cls.add_method('ReceiveIcmp', - 'void', - [param('ns3::Ipv6Address', 'icmpSource'), param('uint8_t', 'icmpTtl'), param('uint8_t', 'icmpType'), param('uint8_t', 'icmpCode'), param('uint32_t', 'icmpInfo'), param('ns3::Ipv6Address', 'payloadSource'), param('ns3::Ipv6Address', 'payloadDestination'), param('uint8_t const *', 'payload')], - is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget(ns3::Callback,ns3::Ipv4Address,ns3::Ipv4Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget', - 'void', - [param('ns3::Callback< void, ns3::Ptr< ns3::Packet >, ns3::Ipv4Address, ns3::Ipv4Address, unsigned char, ns3::Ptr< ns3::Ipv4Route >, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], - is_pure_virtual=True, is_virtual=True) - ## ip-l4-protocol.h (module 'internet'): void ns3::IpL4Protocol::SetDownTarget6(ns3::Callback,ns3::Ipv6Address,ns3::Ipv6Address,unsigned char,ns3::Ptr,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] - cls.add_method('SetDownTarget6', - 'void', - [param('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 >', 'cb')], - is_pure_virtual=True, is_virtual=True) - return - def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) @@ -4990,6 +4776,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -5283,6 +5074,170 @@ is_pure_virtual=True, is_virtual=True) return +def register_Ns3Ipv6_methods(root_module, cls): + ## ipv6.h (module 'internet'): ns3::Ipv6::Ipv6(ns3::Ipv6 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Ipv6 const &', 'arg0')]) + ## ipv6.h (module 'internet'): ns3::Ipv6::Ipv6() [constructor] + cls.add_constructor([]) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::AddAddress(uint32_t interface, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('AddAddress', + 'bool', + [param('uint32_t', 'interface'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint32_t ns3::Ipv6::AddInterface(ns3::Ptr device) [member function] + cls.add_method('AddInterface', + 'uint32_t', + [param('ns3::Ptr< ns3::NetDevice >', 'device')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6::GetAddress(uint32_t interface, uint32_t addressIndex) const [member function] + cls.add_method('GetAddress', + 'ns3::Ipv6InterfaceAddress', + [param('uint32_t', 'interface'), param('uint32_t', 'addressIndex')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): int32_t ns3::Ipv6::GetInterfaceForAddress(ns3::Ipv6Address address) const [member function] + cls.add_method('GetInterfaceForAddress', + 'int32_t', + [param('ns3::Ipv6Address', 'address')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): int32_t ns3::Ipv6::GetInterfaceForDevice(ns3::Ptr device) const [member function] + cls.add_method('GetInterfaceForDevice', + 'int32_t', + [param('ns3::Ptr< ns3::NetDevice const >', 'device')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): int32_t ns3::Ipv6::GetInterfaceForPrefix(ns3::Ipv6Address address, ns3::Ipv6Prefix mask) const [member function] + cls.add_method('GetInterfaceForPrefix', + 'int32_t', + [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6Prefix', 'mask')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint16_t ns3::Ipv6::GetMetric(uint32_t interface) const [member function] + cls.add_method('GetMetric', + 'uint16_t', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint16_t ns3::Ipv6::GetMtu(uint32_t interface) const [member function] + cls.add_method('GetMtu', + 'uint16_t', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint32_t ns3::Ipv6::GetNAddresses(uint32_t interface) const [member function] + cls.add_method('GetNAddresses', + 'uint32_t', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): uint32_t ns3::Ipv6::GetNInterfaces() const [member function] + cls.add_method('GetNInterfaces', + 'uint32_t', + [], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetNetDevice(uint32_t interface) [member function] + cls.add_method('GetNetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetRoutingProtocol() const [member function] + cls.add_method('GetRoutingProtocol', + 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', + [], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): static ns3::TypeId ns3::Ipv6::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::IsForwarding(uint32_t interface) const [member function] + cls.add_method('IsForwarding', + 'bool', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::IsUp(uint32_t interface) const [member function] + cls.add_method('IsUp', + 'bool', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::RegisterExtensions() [member function] + cls.add_method('RegisterExtensions', + 'void', + [], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::RegisterOptions() [member function] + cls.add_method('RegisterOptions', + 'void', + [], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::RemoveAddress(uint32_t interface, uint32_t addressIndex) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interface'), param('uint32_t', 'addressIndex')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::RemoveAddress(uint32_t interface, ns3::Ipv6Address address) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'address')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetDown(uint32_t interface) [member function] + cls.add_method('SetDown', + 'void', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetForwarding(uint32_t interface, bool val) [member function] + cls.add_method('SetForwarding', + 'void', + [param('uint32_t', 'interface'), param('bool', 'val')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetMetric(uint32_t interface, uint16_t metric) [member function] + cls.add_method('SetMetric', + 'void', + [param('uint32_t', 'interface'), param('uint16_t', 'metric')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetPmtu(ns3::Ipv6Address dst, uint32_t pmtu) [member function] + cls.add_method('SetPmtu', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('uint32_t', 'pmtu')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetRoutingProtocol(ns3::Ptr routingProtocol) [member function] + cls.add_method('SetRoutingProtocol', + 'void', + [param('ns3::Ptr< ns3::Ipv6RoutingProtocol >', 'routingProtocol')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetUp(uint32_t interface) [member function] + cls.add_method('SetUp', + 'void', + [param('uint32_t', 'interface')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6::IF_ANY [variable] + cls.add_static_attribute('IF_ANY', 'uint32_t const', is_const=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetIpForward() const [member function] + cls.add_method('GetIpForward', + 'bool', + [], + is_pure_virtual=True, is_const=True, visibility='private', is_virtual=True) + ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetMtuDiscover() const [member function] + cls.add_method('GetMtuDiscover', + 'bool', + [], + is_pure_virtual=True, is_const=True, visibility='private', is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetIpForward(bool forward) [member function] + cls.add_method('SetIpForward', + 'void', + [param('bool', 'forward')], + is_pure_virtual=True, visibility='private', is_virtual=True) + ## ipv6.h (module 'internet'): void ns3::Ipv6::SetMtuDiscover(bool mtuDiscover) [member function] + cls.add_method('SetMtuDiscover', + 'void', + [param('bool', 'mtuDiscover')], + is_pure_virtual=True, visibility='private', is_virtual=True) + return + def register_Ns3Ipv6AddressChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker() [constructor] cls.add_constructor([]) @@ -5323,149 +5278,327 @@ [param('ns3::Ipv6Address const &', 'value')]) return -def register_Ns3Ipv6Interface_methods(root_module, cls): - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface(ns3::Ipv6Interface const & arg0) [copy constructor] - cls.add_constructor([param('ns3::Ipv6Interface const &', 'arg0')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6Interface::Ipv6Interface() [constructor] +def register_Ns3Ipv6FlowClassifier_methods(root_module, cls): + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::Ipv6FlowClassifier() [constructor] cls.add_constructor([]) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::AddAddress(ns3::Ipv6InterfaceAddress iface) [member function] - cls.add_method('AddAddress', + ## ipv6-flow-classifier.h (module 'flow-monitor'): bool ns3::Ipv6FlowClassifier::Classify(ns3::Ipv6Header const & ipHeader, ns3::Ptr ipPayload, uint32_t * out_flowId, uint32_t * out_packetId) [member function] + cls.add_method('Classify', 'bool', - [param('ns3::Ipv6InterfaceAddress', 'iface')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddress(uint32_t index) const [member function] - cls.add_method('GetAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetAddressMatchingDestination(ns3::Ipv6Address dst) [member function] - cls.add_method('GetAddressMatchingDestination', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'dst')]) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetBaseReachableTime() const [member function] - cls.add_method('GetBaseReachableTime', - 'uint16_t', - [], + [param('ns3::Ipv6Header const &', 'ipHeader'), param('ns3::Ptr< ns3::Packet const >', 'ipPayload'), param('uint32_t *', 'out_flowId'), param('uint32_t *', 'out_packetId')]) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple ns3::Ipv6FlowClassifier::FindFlow(ns3::FlowId flowId) const [member function] + cls.add_method('FindFlow', + 'ns3::Ipv6FlowClassifier::FiveTuple', + [param('ns3::FlowId', 'flowId')], is_const=True) - ## ipv6-interface.h (module 'internet'): uint8_t ns3::Ipv6Interface::GetCurHopLimit() const [member function] - cls.add_method('GetCurHopLimit', - 'uint8_t', + ## ipv6-flow-classifier.h (module 'flow-monitor'): void ns3::Ipv6FlowClassifier::SerializeToXmlStream(std::ostream & os, int indent) const [member function] + cls.add_method('SerializeToXmlStream', + 'void', + [param('std::ostream &', 'os'), param('int', 'indent')], + is_const=True, is_virtual=True) + return + +def register_Ns3Ipv6FlowClassifierFiveTuple_methods(root_module, cls): + cls.add_binary_comparison_operator('<') + cls.add_binary_comparison_operator('==') + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::FiveTuple() [constructor] + cls.add_constructor([]) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::FiveTuple(ns3::Ipv6FlowClassifier::FiveTuple const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Ipv6FlowClassifier::FiveTuple const &', 'arg0')]) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::destinationAddress [variable] + cls.add_instance_attribute('destinationAddress', 'ns3::Ipv6Address', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::destinationPort [variable] + cls.add_instance_attribute('destinationPort', 'uint16_t', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::protocol [variable] + cls.add_instance_attribute('protocol', 'uint8_t', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::sourceAddress [variable] + cls.add_instance_attribute('sourceAddress', 'ns3::Ipv6Address', is_const=False) + ## ipv6-flow-classifier.h (module 'flow-monitor'): ns3::Ipv6FlowClassifier::FiveTuple::sourcePort [variable] + cls.add_instance_attribute('sourcePort', 'uint16_t', is_const=False) + return + +def register_Ns3Ipv6FlowProbe_methods(root_module, cls): + ## ipv6-flow-probe.h (module 'flow-monitor'): ns3::Ipv6FlowProbe::Ipv6FlowProbe(ns3::Ptr monitor, ns3::Ptr classifier, ns3::Ptr node) [constructor] + cls.add_constructor([param('ns3::Ptr< ns3::FlowMonitor >', 'monitor'), param('ns3::Ptr< ns3::Ipv6FlowClassifier >', 'classifier'), param('ns3::Ptr< ns3::Node >', 'node')]) + ## ipv6-flow-probe.h (module 'flow-monitor'): void ns3::Ipv6FlowProbe::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ptr ns3::Ipv6Interface::GetDevice() const [member function] - cls.add_method('GetDevice', - 'ns3::Ptr< ns3::NetDevice >', + visibility='protected', is_virtual=True) + return + +def register_Ns3Ipv6L3Protocol_methods(root_module, cls): + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::PROT_NUMBER [variable] + cls.add_static_attribute('PROT_NUMBER', 'uint16_t const', is_const=True) + ## ipv6-l3-protocol.h (module 'internet'): static ns3::TypeId ns3::Ipv6L3Protocol::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', [], + is_static=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::Ipv6L3Protocol() [constructor] + cls.add_constructor([]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetNode(ns3::Ptr node) [member function] + cls.add_method('SetNode', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Insert(ns3::Ptr protocol) [member function] + cls.add_method('Insert', + 'void', + [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Remove(ns3::Ptr protocol) [member function] + cls.add_method('Remove', + 'void', + [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')]) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], is_const=True, is_virtual=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::GetLinkLocalAddress() const [member function] - cls.add_method('GetLinkLocalAddress', - 'ns3::Ipv6InterfaceAddress', + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::CreateRawSocket() [member function] + cls.add_method('CreateRawSocket', + 'ns3::Ptr< ns3::Socket >', + []) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DeleteRawSocket(ns3::Ptr socket) [member function] + cls.add_method('DeleteRawSocket', + 'void', + [param('ns3::Ptr< ns3::Socket >', 'socket')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetDefaultTtl(uint8_t ttl) [member function] + cls.add_method('SetDefaultTtl', + 'void', + [param('uint8_t', 'ttl')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetDefaultTclass(uint8_t tclass) [member function] + cls.add_method('SetDefaultTclass', + 'void', + [param('uint8_t', 'tclass')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Receive(ns3::Ptr device, ns3::Ptr p, uint16_t protocol, ns3::Address const & from, ns3::Address const & to, ns3::NetDevice::PacketType packetType) [member function] + cls.add_method('Receive', + 'void', + [param('ns3::Ptr< ns3::NetDevice >', 'device'), param('ns3::Ptr< ns3::Packet const >', 'p'), param('uint16_t', 'protocol'), param('ns3::Address const &', 'from'), param('ns3::Address const &', 'to'), param('ns3::NetDevice::PacketType', 'packetType')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::Send(ns3::Ptr packet, ns3::Ipv6Address source, ns3::Ipv6Address destination, uint8_t protocol, ns3::Ptr route) [member function] + cls.add_method('Send', + 'void', + [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv6Address', 'source'), param('ns3::Ipv6Address', 'destination'), param('uint8_t', 'protocol'), param('ns3::Ptr< ns3::Ipv6Route >', 'route')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetRoutingProtocol(ns3::Ptr routingProtocol) [member function] + cls.add_method('SetRoutingProtocol', + 'void', + [param('ns3::Ptr< ns3::Ipv6RoutingProtocol >', 'routingProtocol')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetRoutingProtocol() const [member function] + cls.add_method('GetRoutingProtocol', + 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', [], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv6L3Protocol::AddInterface(ns3::Ptr device) [member function] + cls.add_method('AddInterface', + 'uint32_t', + [param('ns3::Ptr< ns3::NetDevice >', 'device')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetInterface(uint32_t i) const [member function] + cls.add_method('GetInterface', + 'ns3::Ptr< ns3::Ipv6Interface >', + [param('uint32_t', 'i')], is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetMetric() const [member function] - cls.add_method('GetMetric', - 'uint16_t', + ## ipv6-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv6L3Protocol::GetNInterfaces() const [member function] + cls.add_method('GetNInterfaces', + 'uint32_t', [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint32_t ns3::Ipv6Interface::GetNAddresses() const [member function] + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): int32_t ns3::Ipv6L3Protocol::GetInterfaceForAddress(ns3::Ipv6Address addr) const [member function] + cls.add_method('GetInterfaceForAddress', + 'int32_t', + [param('ns3::Ipv6Address', 'addr')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): int32_t ns3::Ipv6L3Protocol::GetInterfaceForPrefix(ns3::Ipv6Address addr, ns3::Ipv6Prefix mask) const [member function] + cls.add_method('GetInterfaceForPrefix', + 'int32_t', + [param('ns3::Ipv6Address', 'addr'), param('ns3::Ipv6Prefix', 'mask')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): int32_t ns3::Ipv6L3Protocol::GetInterfaceForDevice(ns3::Ptr device) const [member function] + cls.add_method('GetInterfaceForDevice', + 'int32_t', + [param('ns3::Ptr< ns3::NetDevice const >', 'device')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::AddAddress(uint32_t i, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('AddAddress', + 'bool', + [param('uint32_t', 'i'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6L3Protocol::GetAddress(uint32_t interfaceIndex, uint32_t addressIndex) const [member function] + cls.add_method('GetAddress', + 'ns3::Ipv6InterfaceAddress', + [param('uint32_t', 'interfaceIndex'), param('uint32_t', 'addressIndex')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv6L3Protocol::GetNAddresses(uint32_t interface) const [member function] cls.add_method('GetNAddresses', 'uint32_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetReachableTime() const [member function] - cls.add_method('GetReachableTime', + [param('uint32_t', 'interface')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::RemoveAddress(uint32_t interfaceIndex, uint32_t addressIndex) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interfaceIndex'), param('uint32_t', 'addressIndex')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::RemoveAddress(uint32_t interfaceIndex, ns3::Ipv6Address address) [member function] + cls.add_method('RemoveAddress', + 'bool', + [param('uint32_t', 'interfaceIndex'), param('ns3::Ipv6Address', 'address')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetMetric(uint32_t i, uint16_t metric) [member function] + cls.add_method('SetMetric', + 'void', + [param('uint32_t', 'i'), param('uint16_t', 'metric')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint16_t ns3::Ipv6L3Protocol::GetMetric(uint32_t i) const [member function] + cls.add_method('GetMetric', 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): uint16_t ns3::Ipv6Interface::GetRetransTimer() const [member function] - cls.add_method('GetRetransTimer', + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): uint16_t ns3::Ipv6L3Protocol::GetMtu(uint32_t i) const [member function] + cls.add_method('GetMtu', 'uint16_t', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv6Interface::GetTypeId() [member function] - cls.add_method('GetTypeId', - 'ns3::TypeId', - [], - is_static=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsDown() const [member function] - cls.add_method('IsDown', + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetPmtu(ns3::Ipv6Address dst, uint32_t pmtu) [member function] + cls.add_method('SetPmtu', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('uint32_t', 'pmtu')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::IsUp(uint32_t i) const [member function] + cls.add_method('IsUp', 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsForwarding() const [member function] + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetUp(uint32_t i) [member function] + cls.add_method('SetUp', + 'void', + [param('uint32_t', 'i')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetDown(uint32_t i) [member function] + cls.add_method('SetDown', + 'void', + [param('uint32_t', 'i')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::IsForwarding(uint32_t i) const [member function] cls.add_method('IsForwarding', 'bool', + [param('uint32_t', 'i')], + is_const=True, is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetForwarding(uint32_t i, bool val) [member function] + cls.add_method('SetForwarding', + 'void', + [param('uint32_t', 'i'), param('bool', 'val')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6L3Protocol::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetNetDevice(uint32_t i) [member function] + cls.add_method('GetNetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [param('uint32_t', 'i')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetIcmpv6() const [member function] + cls.add_method('GetIcmpv6', + 'ns3::Ptr< ns3::Icmpv6L4Protocol >', [], is_const=True) - ## ipv6-interface.h (module 'internet'): bool ns3::Ipv6Interface::IsUp() const [member function] - cls.add_method('IsUp', - 'bool', - [], - is_const=True) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(uint32_t index) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('uint32_t', 'index')]) - ## ipv6-interface.h (module 'internet'): ns3::Ipv6InterfaceAddress ns3::Ipv6Interface::RemoveAddress(ns3::Ipv6Address address) [member function] - cls.add_method('RemoveAddress', - 'ns3::Ipv6InterfaceAddress', - [param('ns3::Ipv6Address', 'address')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::Send(ns3::Ptr p, ns3::Ipv6Address dest) [member function] - cls.add_method('Send', + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::AddAutoconfiguredAddress(uint32_t interface, ns3::Ipv6Address network, ns3::Ipv6Prefix mask, uint8_t flags, uint32_t validTime, uint32_t preferredTime, ns3::Ipv6Address defaultRouter=ns3::Ipv6Address::GetZero( )) [member function] + cls.add_method('AddAutoconfiguredAddress', 'void', - [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Address', 'dest')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetBaseReachableTime(uint16_t baseReachableTime) [member function] - cls.add_method('SetBaseReachableTime', - 'void', - [param('uint16_t', 'baseReachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetCurHopLimit(uint8_t curHopLimit) [member function] - cls.add_method('SetCurHopLimit', - 'void', - [param('uint8_t', 'curHopLimit')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDevice(ns3::Ptr device) [member function] - cls.add_method('SetDevice', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'mask'), param('uint8_t', 'flags'), param('uint32_t', 'validTime'), param('uint32_t', 'preferredTime'), param('ns3::Ipv6Address', 'defaultRouter', default_value='ns3::Ipv6Address::GetZero( )')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::RemoveAutoconfiguredAddress(uint32_t interface, ns3::Ipv6Address network, ns3::Ipv6Prefix mask, ns3::Ipv6Address defaultRouter) [member function] + cls.add_method('RemoveAutoconfiguredAddress', 'void', - [param('ns3::Ptr< ns3::NetDevice >', 'device')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetDown() [member function] - cls.add_method('SetDown', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'mask'), param('ns3::Ipv6Address', 'defaultRouter')]) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::RegisterExtensions() [member function] + cls.add_method('RegisterExtensions', 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetForwarding(bool forward) [member function] - cls.add_method('SetForwarding', + [], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::RegisterOptions() [member function] + cls.add_method('RegisterOptions', 'void', - [param('bool', 'forward')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetMetric(uint16_t metric) [member function] - cls.add_method('SetMetric', + [], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::ReportDrop(ns3::Ipv6Header ipHeader, ns3::Ptr p, ns3::Ipv6L3Protocol::DropReason dropReason) [member function] + cls.add_method('ReportDrop', 'void', - [param('uint16_t', 'metric')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNode(ns3::Ptr node) [member function] - cls.add_method('SetNode', + [param('ns3::Ipv6Header', 'ipHeader'), param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6L3Protocol::DropReason', 'dropReason')], + is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DoDispose() [member function] + cls.add_method('DoDispose', 'void', - [param('ns3::Ptr< ns3::Node >', 'node')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetNsDadUid(ns3::Ipv6Address address, uint32_t uid) [member function] - cls.add_method('SetNsDadUid', + [], + visibility='protected', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::NotifyNewAggregate() [member function] + cls.add_method('NotifyNewAggregate', 'void', - [param('ns3::Ipv6Address', 'address'), param('uint32_t', 'uid')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetReachableTime(uint16_t reachableTime) [member function] - cls.add_method('SetReachableTime', - 'void', - [param('uint16_t', 'reachableTime')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetRetransTimer(uint16_t retransTimer) [member function] - cls.add_method('SetRetransTimer', + [], + visibility='protected', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetIpForward(bool forward) [member function] + cls.add_method('SetIpForward', 'void', - [param('uint16_t', 'retransTimer')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetState(ns3::Ipv6Address address, ns3::Ipv6InterfaceAddress::State_e state) [member function] - cls.add_method('SetState', + [param('bool', 'forward')], + visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::GetIpForward() const [member function] + cls.add_method('GetIpForward', + 'bool', + [], + is_const=True, visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetMtuDiscover(bool mtuDiscover) [member function] + cls.add_method('SetMtuDiscover', 'void', - [param('ns3::Ipv6Address', 'address'), param('ns3::Ipv6InterfaceAddress::State_e', 'state')]) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::SetUp() [member function] - cls.add_method('SetUp', + [param('bool', 'mtuDiscover')], + visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::GetMtuDiscover() const [member function] + cls.add_method('GetMtuDiscover', + 'bool', + [], + is_const=True, visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::SetSendIcmpv6Redirect(bool sendIcmpv6Redirect) [member function] + cls.add_method('SetSendIcmpv6Redirect', 'void', - []) - ## ipv6-interface.h (module 'internet'): void ns3::Ipv6Interface::DoDispose() [member function] + [param('bool', 'sendIcmpv6Redirect')], + visibility='private', is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): bool ns3::Ipv6L3Protocol::GetSendIcmpv6Redirect() const [member function] + cls.add_method('GetSendIcmpv6Redirect', + 'bool', + [], + is_const=True, visibility='private', is_virtual=True) + return + +def register_Ns3Ipv6PmtuCache_methods(root_module, cls): + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache::Ipv6PmtuCache(ns3::Ipv6PmtuCache const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Ipv6PmtuCache const &', 'arg0')]) + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache::Ipv6PmtuCache() [constructor] + cls.add_constructor([]) + ## ipv6-pmtu-cache.h (module 'internet'): void ns3::Ipv6PmtuCache::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], - visibility='protected', is_virtual=True) + is_virtual=True) + ## ipv6-pmtu-cache.h (module 'internet'): uint32_t ns3::Ipv6PmtuCache::GetPmtu(ns3::Ipv6Address dst) [member function] + cls.add_method('GetPmtu', + 'uint32_t', + [param('ns3::Ipv6Address', 'dst')]) + ## ipv6-pmtu-cache.h (module 'internet'): ns3::Time ns3::Ipv6PmtuCache::GetPmtuValidityTime() const [member function] + cls.add_method('GetPmtuValidityTime', + 'ns3::Time', + [], + is_const=True) + ## ipv6-pmtu-cache.h (module 'internet'): static ns3::TypeId ns3::Ipv6PmtuCache::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ipv6-pmtu-cache.h (module 'internet'): void ns3::Ipv6PmtuCache::SetPmtu(ns3::Ipv6Address dst, uint32_t pmtu) [member function] + cls.add_method('SetPmtu', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('uint32_t', 'pmtu')]) + ## ipv6-pmtu-cache.h (module 'internet'): bool ns3::Ipv6PmtuCache::SetPmtuValidityTime(ns3::Time validity) [member function] + cls.add_method('SetPmtuValidityTime', + 'bool', + [param('ns3::Time', 'validity')]) return def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): @@ -5999,10 +6132,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3TimeValue_methods(root_module, cls): diff -Naur ns-3.19/src/flow-monitor/doc/flow-monitor.rst ns-3.20/src/flow-monitor/doc/flow-monitor.rst --- ns-3.19/src/flow-monitor/doc/flow-monitor.rst 2014-06-17 10:34:00.426636754 -0700 +++ ns-3.20/src/flow-monitor/doc/flow-monitor.rst 2014-06-17 10:33:13.744997112 -0700 @@ -1,9 +1,198 @@ Flow Monitor ------------ -*Placeholder chapter* +.. include:: replace.txt +.. highlight:: cpp -This feature was added as contributed code (``src/contrib``) in -*ns-3.6* and to the main distribution (``src/flow-monitor``) for -*ns-3.7*. A paper on this feature is published in the proceedings of -NSTools: ``_. +.. heading hierarchy: + ------------- Chapter + ************* Section (#.#) + ============= Subsection (#.#.#) + ############# Paragraph (no number) + +Model Description +***************** + +The source code for the new module lives in the directory ``src/flow-monitor``. + +The Flow Monitor module goal is to provide a flexible system to measure the +performance of network protocols. The module uses probes, installed in network +nodes, to track the packets exchanged by the nodes, and it will measure +a number of parameters. Packets are divided according to the flow they belong +to, where each flow is defined according to the probe's characteristics (e.g., +for IP, a flow is defined as the packets with the same {protocol, source (IP, port), +destination (IP, port)} tuple. + +The statistics are collected for each flow can be exported in XML format. Moreover, +the user can access the probes directly to request specific stats about each flow. + +Design +====== + +Flow Monitor module is designed in a modular way. It can be extended by subclassing +``ns3::FlowProbe`` and ``ns3::FlowClassifier``. + +The full module design is described in [FlowMonitor]_ + +Scope and Limitations +===================== + +At the moment, probes and classifiers are available for IPv4 and IPv6. + +Each probe will classify packets in four points: + +* When a packet is sent (SendOutgoing IPv[4,6] traces) +* When a packet is forwarded (UnicastForward IPv[4,6] traces) +* When a packet is received (LocalDeliver IPv[4,6] traces) +* When a packet is dropped (Drop IPv[4,6] traces) + +Since the packets are tracked at IP level, any retransmission caused by L4 protocols (e.g., TCP) +will be seen by the probe as a new packet. + +A Tag will be added to the packet (``ns3::Ipv[4,6]FlowProbeTag``). The tag will carry +basic packet's data, useful for the packet's classification. + +It must be underlined that only L4 (TCP, UDP) packets are, so far, classified. +Moreover, only unicast packets will be classified. +These limitations may be removed in the future. + +The data collected for each flow are: + +* timeFirstTxPacket: when the first packet in the flow was transmitted; +* timeLastTxPacket: when the last packet in the flow was transmitted; +* timeFirstRxPacket: when the first packet in the flow was received by an end node; +* timeLastRxPacket: when the last packet in the flow was received; +* delaySum: the sum of all end-to-end delays for all received packets of the flow; +* jitterSum: the sum of all end-to-end delay jitter (delay variation) values for all received packets of the flow, as defined in :rfc:`3393`; +* txBytes, txPackets: total number of transmitted bytes / packets for the flow; +* rxBytes, rxPackets: total number of received bytes / packets for the flow; +* lostPackets: total number of packets that are assumed to be lost (not reported over 10 seconds); +* timesForwarded: the number of times a packet has been reportedly forwarded; +* delayHistogram, jitterHistogram, packetSizeHistogram: histogram versions for the delay, jitter, and packet sizes, respectively; +* packetsDropped, bytesDropped: the number of lost packets and bytes, divided according to the loss reason code (defined in the probe). + +It is worth pointing out that the probes measure the packet bytes including IP headers. +The L2 headers are not included in the measure. + +These stats will be written in XML form upon request (see the Usage section). + + +References +========== + +.. [FlowMonitor] G. Carneiro, P. Fortuna, and M. Ricardo. 2009. FlowMonitor: a network monitoring framework for the network simulator 3 (NS-3). In Proceedings of the Fourth International ICST Conference on Performance Evaluation Methodologies and Tools (VALUETOOLS '09). http://dx.doi.org/10.4108/ICST.VALUETOOLS2009.7493 + +Usage +***** + +The module usage is extremely simple. The helper will take care of about everything. + +The typical use is:: + + // Flow monitor + Ptr flowMonitor; + FlowMonitorHelper flowHelper; + flowMonitor = flowHelper.InstallAll(); + + Simulator::Stop (Seconds(stop_time)); + Simulator::Run (); + + flowMonitor->SerializeToXmlFile("NameOfFile.xml", true, true); + +the ``SerializeToXmlFile ()`` function 2nd and 3rd parameters are used respectively to +activate/deactivate the histograms and the per-probe detailed stats. + +Other possible alternatives can be found in the Doxygen documentation. + + +Helpers +======= + +The helper API follows the pattern usage of normal helpers. +Through the helper you can install the monitor in the nodes, set the monitor attributes, and +print the statistics. + +One important thing is: the :cpp:class:`ns3::FlowMonitorHelper` must be instantiated only +once in the main. + +Attributes +========== + +The module provides the following attributes in :cpp:class:`ns3::FlowMonitor`: + +* MaxPerHopDelay (Time, default 10s): The maximum per-hop delay that should be considered; +* StartTime (Time, default 0s): The time when the monitoring starts; +* DelayBinWidth (double, default 0.001): The width used in the delay histogram; +* JitterBinWidth (double, default 0.001): The width used in the jitter histogram; +* PacketSizeBinWidth (double, default 20.0): The width used in the packetSize histogram; +* FlowInterruptionsBinWidth (double, default 0.25): The width used in the flowInterruptions histogram; +* FlowInterruptionsMinTime (double, default 0.5): The minimum inter-arrival time that is considered a flow interruption. + + +Output +====== + +The main model output is an XML formatted report about flow statistics. An example is:: + + + + + + + + + + + + + + + + + + + + + + + + + + + + +The output was generated by a TCP flow from 10.1.3.1 to 10.1.2.2. + +It is worth noticing that the index 2 probe is reporting more packets and more bytes than the other probles. +That's a perfectly normal behaviour, as packets are fragmented at IP level in that node. + +It should also be observed that the receiving node's probe (index 4) doesn't count the fragments, as the +reassembly is done before the probing point. + +Examples +======== + +The examples are located in `src/flow-monitor/examples`. + +Moreover, the following examples use the flow-monitor module: + +* examples/matrix-topology/matrix-topology.cc +* examples/routing/manet-routing-compare.cc +* examples/routing/simple-global-routing.cc +* examples/tcp/tcp-variants-comparison.cc +* examples/wireless/multirate.cc +* examples/wireless/wifi-hidden-terminal.cc + + +Troubleshooting +=============== + +Do not define more than one :cpp:class:`ns3::FlowMonitorHelper` in the simulation. + +Validation +********** + +The paper in the references contains a full description of the module validation against +a test network. + +Tests are provided to ensure the Histogram correct functionality. diff -Naur ns-3.19/src/flow-monitor/helper/flow-monitor-helper.cc ns-3.20/src/flow-monitor/helper/flow-monitor-helper.cc --- ns-3.19/src/flow-monitor/helper/flow-monitor-helper.cc 2014-06-17 10:34:00.428636739 -0700 +++ ns-3.20/src/flow-monitor/helper/flow-monitor-helper.cc 2014-06-17 10:33:13.746997096 -0700 @@ -24,6 +24,9 @@ #include "ns3/ipv4-flow-classifier.h" #include "ns3/ipv4-flow-probe.h" #include "ns3/ipv4-l3-protocol.h" +#include "ns3/ipv6-flow-classifier.h" +#include "ns3/ipv6-flow-probe.h" +#include "ns3/ipv6-l3-protocol.h" #include "ns3/node.h" #include "ns3/node-list.h" @@ -41,7 +44,8 @@ { m_flowMonitor->Dispose (); m_flowMonitor = 0; - m_flowClassifier = 0; + m_flowClassifier4 = 0; + m_flowClassifier6 = 0; } } @@ -58,8 +62,10 @@ if (!m_flowMonitor) { m_flowMonitor = m_monitorFactory.Create (); - m_flowClassifier = Create (); - m_flowMonitor->SetFlowClassifier (m_flowClassifier); + m_flowClassifier4 = Create (); + m_flowMonitor->AddFlowClassifier (m_flowClassifier4); + m_flowClassifier6 = Create (); + m_flowMonitor->AddFlowClassifier (m_flowClassifier6); } return m_flowMonitor; } @@ -68,11 +74,22 @@ Ptr FlowMonitorHelper::GetClassifier () { - if (!m_flowClassifier) + if (!m_flowClassifier4) { - m_flowClassifier = Create (); + m_flowClassifier4 = Create (); } - return m_flowClassifier; + return m_flowClassifier4; +} + + +Ptr +FlowMonitorHelper::GetClassifier6 () +{ + if (!m_flowClassifier6) + { + m_flowClassifier6 = Create (); + } + return m_flowClassifier6; } @@ -81,9 +98,21 @@ { Ptr monitor = GetMonitor (); Ptr classifier = GetClassifier (); - Ptr probe = Create (monitor, - DynamicCast (classifier), - node); + Ptr ipv4 = node->GetObject (); + if (ipv4) + { + Ptr probe = Create (monitor, + DynamicCast (classifier), + node); + } + Ptr classifier6 = GetClassifier6 (); + Ptr ipv6 = node->GetObject (); + if (ipv6) + { + Ptr probe6 = Create (monitor, + DynamicCast (classifier6), + node); + } return m_flowMonitor; } @@ -94,7 +123,7 @@ for (NodeContainer::Iterator i = nodes.Begin (); i != nodes.End (); ++i) { Ptr node = *i; - if (node->GetObject ()) + if (node->GetObject () || node->GetObject ()) { Install (node); } @@ -108,7 +137,7 @@ for (NodeList::Iterator i = NodeList::Begin (); i != NodeList::End (); ++i) { Ptr node = *i; - if (node->GetObject ()) + if (node->GetObject () || node->GetObject ()) { Install (node); } @@ -116,5 +145,34 @@ return m_flowMonitor; } +void +FlowMonitorHelper::SerializeToXmlStream (std::ostream &os, int indent, bool enableHistograms, bool enableProbes) +{ + if (m_flowMonitor) + { + m_flowMonitor->SerializeToXmlStream (os, indent, enableHistograms, enableProbes); + } +} + +std::string +FlowMonitorHelper::SerializeToXmlString (int indent, bool enableHistograms, bool enableProbes) +{ + std::ostringstream os; + if (m_flowMonitor) + { + m_flowMonitor->SerializeToXmlStream (os, indent, enableHistograms, enableProbes); + } + return os.str (); +} + +void +FlowMonitorHelper::SerializeToXmlFile (std::string fileName, bool enableHistograms, bool enableProbes) +{ + if (m_flowMonitor) + { + m_flowMonitor->SerializeToXmlFile (fileName, enableHistograms, enableProbes); + } +} + } // namespace ns3 diff -Naur ns-3.19/src/flow-monitor/helper/flow-monitor-helper.h ns-3.20/src/flow-monitor/helper/flow-monitor-helper.h --- ns-3.19/src/flow-monitor/helper/flow-monitor-helper.h 2014-06-17 10:34:00.428636739 -0700 +++ ns-3.20/src/flow-monitor/helper/flow-monitor-helper.h 2014-06-17 10:33:13.746997096 -0700 @@ -30,10 +30,11 @@ class AttributeValue; class Ipv4FlowClassifier; +class Ipv6FlowClassifier; /** * \ingroup flow-monitor - * \brief Helper to enable IPv4 flow monitoring on a set of Nodes + * \brief Helper to enable IP flow monitoring on a set of Nodes */ class FlowMonitorHelper { @@ -74,15 +75,62 @@ Ptr GetMonitor (); /** - * \brief Retrieve the FlowClassifier object created by the Install* methods + * \brief Retrieve the FlowClassifier object for IPv4 created by the Install* methods * \returns a pointer to the FlowClassifier object */ Ptr GetClassifier (); + /** + * \brief Retrieve the FlowClassifier object for IPv6 created by the Install* methods + * \returns a pointer to the FlowClassifier object + */ + Ptr GetClassifier6 (); + + /** + * Serializes the results to an std::ostream in XML format + * \param os the output stream + * \param indent number of spaces to use as base indentation level + * \param enableHistograms if true, include also the histograms in the output + * \param enableProbes if true, include also the per-probe/flow pair statistics in the output + */ + void SerializeToXmlStream (std::ostream &os, int indent, bool enableHistograms, bool enableProbes); + + /** + * Same as SerializeToXmlStream, but returns the output as a std::string + * \param indent number of spaces to use as base indentation level + * \param enableHistograms if true, include also the histograms in the output + * \param enableProbes if true, include also the per-probe/flow pair statistics in the output + * \return the XML output as string + */ + std::string SerializeToXmlString (int indent, bool enableHistograms, bool enableProbes); + + /** + * Same as SerializeToXmlStream, but writes to a file instead + * \param fileName name or path of the output file that will be created + * \param enableHistograms if true, include also the histograms in the output + * \param enableProbes if true, include also the per-probe/flow pair statistics in the output + */ + void SerializeToXmlFile (std::string fileName, bool enableHistograms, bool enableProbes); + private: - ObjectFactory m_monitorFactory; //!< Object factory - Ptr m_flowMonitor; //!< the FlowMonitor object - Ptr m_flowClassifier; //!< the FlowClassifier object + /** + * \brief Copy constructor + * + * Defined and unimplemented to avoid misuse + */ + FlowMonitorHelper (const FlowMonitorHelper&); + /** + * \brief Copy constructor + * + * Defined and unimplemented to avoid misuse + * \returns + */ + FlowMonitorHelper& operator= (const FlowMonitorHelper&); + + ObjectFactory m_monitorFactory; //!< Object factory + Ptr m_flowMonitor; //!< the FlowMonitor object + Ptr m_flowClassifier4; //!< the FlowClassifier object for IPv4 + Ptr m_flowClassifier6; //!< the FlowClassifier object for IPv6 }; } // namespace ns3 diff -Naur ns-3.19/src/flow-monitor/model/flow-classifier.h ns-3.20/src/flow-monitor/model/flow-classifier.h --- ns-3.19/src/flow-monitor/model/flow-classifier.h 2014-06-17 10:34:00.429636731 -0700 +++ ns-3.20/src/flow-monitor/model/flow-classifier.h 2014-06-17 10:33:13.747997088 -0700 @@ -41,7 +41,7 @@ /// \ingroup flow-monitor /// Provides a method to translate raw packet data into abstract -/// ``flow identifier'' and ``packet identifier'' parameters. These +/// `flow identifier` and `packet identifier` parameters. These /// identifiers are unsigned 32-bit integers that uniquely identify a /// flow and a packet within that flow, respectively, for the whole /// simulation, regardless of the point in which the packet was diff -Naur ns-3.19/src/flow-monitor/model/flow-monitor.cc ns-3.20/src/flow-monitor/model/flow-monitor.cc --- ns-3.19/src/flow-monitor/model/flow-monitor.cc 2014-06-17 10:34:00.429636731 -0700 +++ ns-3.20/src/flow-monitor/model/flow-monitor.cc 2014-06-17 10:33:13.747997088 -0700 @@ -31,11 +31,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("FlowMonitor") - ; +NS_LOG_COMPONENT_DEFINE ("FlowMonitor"); -NS_OBJECT_ENSURE_REGISTERED (FlowMonitor) - ; +NS_OBJECT_ENSURE_REGISTERED (FlowMonitor); TypeId @@ -92,7 +90,12 @@ void FlowMonitor::DoDispose (void) { - m_classifier = 0; + for (std::list >::iterator iter = m_classifiers.begin (); + iter != m_classifiers.end (); + iter ++) + { + *iter = 0; + } for (uint32_t i = 0; i < m_flowProbes.size (); i++) { m_flowProbes[i]->Dispose (); @@ -391,9 +394,9 @@ } void -FlowMonitor::SetFlowClassifier (Ptr classifier) +FlowMonitor::AddFlowClassifier (Ptr classifier) { - m_classifier = classifier; + m_classifiers.push_back (classifier); } void @@ -458,7 +461,12 @@ indent -= 2; INDENT (indent); os << "\n"; - m_classifier->SerializeToXmlStream (os, indent); + for (std::list >::iterator iter = m_classifiers.begin (); + iter != m_classifiers.end (); + iter ++) + { + (*iter)->SerializeToXmlStream (os, indent); + } if (enableProbes) { diff -Naur ns-3.19/src/flow-monitor/model/flow-monitor.h ns-3.20/src/flow-monitor/model/flow-monitor.h --- ns-3.19/src/flow-monitor/model/flow-monitor.h 2014-06-17 10:34:00.430636723 -0700 +++ ns-3.20/src/flow-monitor/model/flow-monitor.h 2014-06-17 10:33:13.748997081 -0700 @@ -146,9 +146,9 @@ TypeId GetInstanceTypeId () const; FlowMonitor (); - /// Set the FlowClassifier to be used by the flow monitor. + /// Add a FlowClassifier to be used by the flow monitor. /// \param classifier the FlowClassifier - void SetFlowClassifier (Ptr classifier); + void AddFlowClassifier (Ptr classifier); /// Set the time, counting from the current time, from which to start monitoring flows. /// \param time delta time to start @@ -266,7 +266,7 @@ std::vector< Ptr > m_flowProbes; //!< all the FlowProbes // note: this is needed only for serialization - Ptr m_classifier; //!< the FlowClassifier + std::list > m_classifiers; //!< the FlowClassifiers EventId m_startEvent; //!< Start event EventId m_stopEvent; //!< Stop event diff -Naur ns-3.19/src/flow-monitor/model/histogram.cc ns-3.20/src/flow-monitor/model/histogram.cc --- ns-3.19/src/flow-monitor/model/histogram.cc 2014-06-17 10:34:00.431636715 -0700 +++ ns-3.20/src/flow-monitor/model/histogram.cc 2014-06-17 10:33:13.749997073 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Histogram") - ; +NS_LOG_COMPONENT_DEFINE ("Histogram"); // uint32_t // Histogram::GetSize () const diff -Naur ns-3.19/src/flow-monitor/model/ipv4-flow-classifier.cc ns-3.20/src/flow-monitor/model/ipv4-flow-classifier.cc --- ns-3.19/src/flow-monitor/model/ipv4-flow-classifier.cc 2014-06-17 10:34:00.432636708 -0700 +++ ns-3.20/src/flow-monitor/model/ipv4-flow-classifier.cc 2014-06-17 10:33:13.750997065 -0700 @@ -103,12 +103,6 @@ Ipv4FlowClassifier::Classify (const Ipv4Header &ipHeader, Ptr ipPayload, uint32_t *out_flowId, uint32_t *out_packetId) { - if (ipHeader.GetDestination () == Ipv4Address::GetBroadcast ()) - { - // we are not prepared to handle broadcast yet - return false; - } - if (ipHeader.GetFragmentOffset () > 0 ) { // Ignore fragments: they don't carry a valid L4 header @@ -159,11 +153,17 @@ // if the insertion succeeded, we need to assign this tuple a new flow identifier if (insert.second) { - insert.first->second = GetNewFlowId (); + FlowId newFlowId = GetNewFlowId (); + insert.first->second = newFlowId; + m_flowPktIdMap[newFlowId] = 0; + } + else + { + m_flowPktIdMap[insert.first->second] ++; } *out_flowId = insert.first->second; - *out_packetId = ipHeader.GetIdentification (); + *out_packetId = m_flowPktIdMap[*out_flowId]; return true; } diff -Naur ns-3.19/src/flow-monitor/model/ipv4-flow-classifier.h ns-3.20/src/flow-monitor/model/ipv4-flow-classifier.h --- ns-3.19/src/flow-monitor/model/ipv4-flow-classifier.h 2014-06-17 10:34:00.432636708 -0700 +++ ns-3.20/src/flow-monitor/model/ipv4-flow-classifier.h 2014-06-17 10:33:13.750997065 -0700 @@ -52,6 +52,9 @@ Ipv4FlowClassifier (); /// \brief try to classify the packet into flow-id and packet-id + /// + /// \warning: it must be called only once per packet, from SendOutgoingLogger. + /// /// \return true if the packet was classified, false if not (i.e. it /// does not appear to be part of a flow). /// \param ipHeader packet's IP header @@ -72,6 +75,7 @@ /// Map to Flows Identifiers to FlowIds std::map m_flowMap; + std::map m_flowPktIdMap; }; diff -Naur ns-3.19/src/flow-monitor/model/ipv4-flow-probe.cc ns-3.20/src/flow-monitor/model/ipv4-flow-probe.cc --- ns-3.19/src/flow-monitor/model/ipv4-flow-probe.cc 2014-06-17 10:34:00.433636700 -0700 +++ ns-3.20/src/flow-monitor/model/ipv4-flow-probe.cc 2014-06-17 10:33:13.750997065 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv4FlowProbe") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv4FlowProbe"); ////////////////////////////////////// // Ipv4FlowProbeTag class implementation // @@ -197,26 +196,26 @@ { NS_LOG_FUNCTION (this << node->GetId ()); - Ptr ipv4 = node->GetObject (); + m_ipv4 = node->GetObject (); - if (!ipv4->TraceConnectWithoutContext ("SendOutgoing", - MakeCallback (&Ipv4FlowProbe::SendOutgoingLogger, Ptr (this)))) + if (!m_ipv4->TraceConnectWithoutContext ("SendOutgoing", + MakeCallback (&Ipv4FlowProbe::SendOutgoingLogger, Ptr (this)))) { NS_FATAL_ERROR ("trace fail"); } - if (!ipv4->TraceConnectWithoutContext ("UnicastForward", - MakeCallback (&Ipv4FlowProbe::ForwardLogger, Ptr (this)))) + if (!m_ipv4->TraceConnectWithoutContext ("UnicastForward", + MakeCallback (&Ipv4FlowProbe::ForwardLogger, Ptr (this)))) { NS_FATAL_ERROR ("trace fail"); } - if (!ipv4->TraceConnectWithoutContext ("LocalDeliver", - MakeCallback (&Ipv4FlowProbe::ForwardUpLogger, Ptr (this)))) + if (!m_ipv4->TraceConnectWithoutContext ("LocalDeliver", + MakeCallback (&Ipv4FlowProbe::ForwardUpLogger, Ptr (this)))) { NS_FATAL_ERROR ("trace fail"); } - if (!ipv4->TraceConnectWithoutContext ("Drop", - MakeCallback (&Ipv4FlowProbe::DropLogger, Ptr (this)))) + if (!m_ipv4->TraceConnectWithoutContext ("Drop", + MakeCallback (&Ipv4FlowProbe::DropLogger, Ptr (this)))) { NS_FATAL_ERROR ("trace fail"); } @@ -234,6 +233,8 @@ void Ipv4FlowProbe::DoDispose () { + m_ipv4 = 0; + m_classifier = 0; FlowProbe::DoDispose (); } @@ -243,6 +244,12 @@ FlowId flowId; FlowPacketId packetId; + if (!m_ipv4->IsUnicast(ipHeader.GetDestination ())) + { + // we are not prepared to handle broadcast yet + return; + } + if (m_classifier->Classify (ipHeader, ipPayload, &flowId, &packetId)) { uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); @@ -260,31 +267,35 @@ void Ipv4FlowProbe::ForwardLogger (const Ipv4Header &ipHeader, Ptr ipPayload, uint32_t interface) { - FlowId flowId; - FlowPacketId packetId; + // peek the tags that are added by Ipv4FlowProbe::SendOutgoingLogger () + Ipv4FlowProbeTag fTag; - if (m_classifier->Classify (ipHeader, ipPayload, &flowId, &packetId)) + bool found = ipPayload->PeekPacketTag (fTag); + + if (found) { + FlowId flowId = fTag.GetFlowId (); + FlowPacketId packetId = fTag.GetPacketId (); + uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); NS_LOG_DEBUG ("ReportForwarding ("<ReportForwarding (this, flowId, packetId, size); } - } void Ipv4FlowProbe::ForwardUpLogger (const Ipv4Header &ipHeader, Ptr ipPayload, uint32_t interface) { - FlowId flowId; - FlowPacketId packetId; + // remove the tags that are added by Ipv4FlowProbe::SendOutgoingLogger () + Ipv4FlowProbeTag fTag; - if (m_classifier->Classify (ipHeader, ipPayload, &flowId, &packetId)) - { - // remove the tags that are added by Ipv4FlowProbe::SendOutgoingLogger () - Ipv4FlowProbeTag fTag; + // ConstCast: see http://www.nsnam.org/bugzilla/show_bug.cgi?id=904 + bool found = ConstCast (ipPayload)->RemovePacketTag (fTag); - // ConstCast: see http://www.nsnam.org/bugzilla/show_bug.cgi?id=904 - ConstCast (ipPayload)->RemovePacketTag (fTag); + if (found) + { + FlowId flowId = fTag.GetFlowId (); + FlowPacketId packetId = fTag.GetPacketId (); uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); NS_LOG_DEBUG ("ReportLastRx ("<Classify (ipHeader, ipPayload, &flowId, &packetId)) - { - // remove the tags that are added by Ipv4FlowProbe::SendOutgoingLogger () - Ipv4FlowProbeTag fTag; + // ConstCast: see http://www.nsnam.org/bugzilla/show_bug.cgi?id=904 + bool found = ConstCast (ipPayload)->RemovePacketTag (fTag); - // ConstCast: see http://www.nsnam.org/bugzilla/show_bug.cgi?id=904 - ConstCast (ipPayload)->RemovePacketTag (fTag); + if (found) + { + FlowId flowId = fTag.GetFlowId (); + FlowPacketId packetId = fTag.GetPacketId (); uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); NS_LOG_DEBUG ("Drop ("< (ipPayload)->RemovePacketTag (fTag); + bool tagFound = ConstCast (ipPayload)->RemovePacketTag (fTag); if (!tagFound) { return; diff -Naur ns-3.19/src/flow-monitor/model/ipv4-flow-probe.h ns-3.20/src/flow-monitor/model/ipv4-flow-probe.h --- ns-3.19/src/flow-monitor/model/ipv4-flow-probe.h 2014-06-17 10:34:00.433636700 -0700 +++ ns-3.20/src/flow-monitor/model/ipv4-flow-probe.h 2014-06-17 10:33:13.751997058 -0700 @@ -106,6 +106,7 @@ void QueueDropLogger (Ptr ipPayload); Ptr m_classifier; //!< the Ipv4FlowClassifier this probe is associated with + Ptr m_ipv4; //!< the Ipv4L3Protocol this probe is bound to }; diff -Naur ns-3.19/src/flow-monitor/model/ipv6-flow-classifier.cc ns-3.20/src/flow-monitor/model/ipv6-flow-classifier.cc --- ns-3.19/src/flow-monitor/model/ipv6-flow-classifier.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/flow-monitor/model/ipv6-flow-classifier.cc 2014-06-17 10:33:13.751997058 -0700 @@ -0,0 +1,218 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +// +// Copyright (c) 2009 INESC Porto +// +// 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: Gustavo J. A. M. Carneiro +// Modifications: Tommaso Pecorella +// + +#include "ns3/packet.h" + +#include "ipv6-flow-classifier.h" +#include "ns3/udp-header.h" +#include "ns3/tcp-header.h" + +namespace ns3 { + +/* see http://www.iana.org/assignments/protocol-numbers */ +const uint8_t TCP_PROT_NUMBER = 6; //!< TCP Protocol number +const uint8_t UDP_PROT_NUMBER = 17; //!< UDP Protocol number + + + +bool operator < (const Ipv6FlowClassifier::FiveTuple &t1, + const Ipv6FlowClassifier::FiveTuple &t2) +{ + if (t1.sourceAddress < t2.sourceAddress) + { + return true; + } + if (t1.sourceAddress != t2.sourceAddress) + { + return false; + } + + if (t1.destinationAddress < t2.destinationAddress) + { + return true; + } + if (t1.destinationAddress != t2.destinationAddress) + { + return false; + } + + if (t1.protocol < t2.protocol) + { + return true; + } + if (t1.protocol != t2.protocol) + { + return false; + } + + if (t1.sourcePort < t2.sourcePort) + { + return true; + } + if (t1.sourcePort != t2.sourcePort) + { + return false; + } + + if (t1.destinationPort < t2.destinationPort) + { + return true; + } + if (t1.destinationPort != t2.destinationPort) + { + return false; + } + + return false; +} + +bool operator == (const Ipv6FlowClassifier::FiveTuple &t1, + const Ipv6FlowClassifier::FiveTuple &t2) +{ + return (t1.sourceAddress == t2.sourceAddress && + t1.destinationAddress == t2.destinationAddress && + t1.protocol == t2.protocol && + t1.sourcePort == t2.sourcePort && + t1.destinationPort == t2.destinationPort); +} + + + +Ipv6FlowClassifier::Ipv6FlowClassifier () +{ +} + +bool +Ipv6FlowClassifier::Classify (const Ipv6Header &ipHeader, Ptr ipPayload, + uint32_t *out_flowId, uint32_t *out_packetId) +{ + if (ipHeader.GetDestinationAddress ().IsMulticast ()) + { + // we are not prepared to handle multicast yet + return false; + } + + FiveTuple tuple; + tuple.sourceAddress = ipHeader.GetSourceAddress (); + tuple.destinationAddress = ipHeader.GetDestinationAddress (); + tuple.protocol = ipHeader.GetNextHeader (); + + if ((tuple.protocol != UDP_PROT_NUMBER) && (tuple.protocol != TCP_PROT_NUMBER)) + { + return false; + } + + if (ipPayload->GetSize () < 4) + { + // the packet doesn't carry enough bytes + return false; + } + + // we rely on the fact that for both TCP and UDP the ports are + // carried in the first 4 octects. + // This allows to read the ports even on fragmented packets + // not carrying a full TCP or UDP header. + + uint8_t data[4]; + ipPayload->CopyData (data, 4); + + uint16_t srcPort = 0; + srcPort |= data[0]; + srcPort <<= 8; + srcPort |= data[1]; + + uint16_t dstPort = 0; + dstPort |= data[2]; + dstPort <<= 8; + dstPort |= data[3]; + + tuple.sourcePort = srcPort; + tuple.destinationPort = dstPort; + + // try to insert the tuple, but check if it already exists + std::pair::iterator, bool> insert + = m_flowMap.insert (std::pair (tuple, 0)); + + // if the insertion succeeded, we need to assign this tuple a new flow identifier + if (insert.second) + { + FlowId newFlowId = GetNewFlowId (); + insert.first->second = newFlowId; + m_flowPktIdMap[newFlowId] = 0; + } + else + { + m_flowPktIdMap[insert.first->second] ++; + } + + *out_flowId = insert.first->second; + *out_packetId = m_flowPktIdMap[*out_flowId]; + + return true; +} + + +Ipv6FlowClassifier::FiveTuple +Ipv6FlowClassifier::FindFlow (FlowId flowId) const +{ + for (std::map::const_iterator + iter = m_flowMap.begin (); iter != m_flowMap.end (); iter++) + { + if (iter->second == flowId) + { + return iter->first; + } + } + NS_FATAL_ERROR ("Could not find the flow with ID " << flowId); + FiveTuple retval = { Ipv6Address::GetZero (), Ipv6Address::GetZero (), 0, 0, 0 }; + return retval; +} + +void +Ipv6FlowClassifier::SerializeToXmlStream (std::ostream &os, int indent) const +{ +#define INDENT(level) for (int __xpto = 0; __xpto < level; __xpto++) os << ' '; + + INDENT (indent); os << "\n"; + + indent += 2; + for (std::map::const_iterator + iter = m_flowMap.begin (); iter != m_flowMap.end (); iter++) + { + INDENT (indent); + os << "second << "\"" + << " sourceAddress=\"" << iter->first.sourceAddress << "\"" + << " destinationAddress=\"" << iter->first.destinationAddress << "\"" + << " protocol=\"" << int(iter->first.protocol) << "\"" + << " sourcePort=\"" << iter->first.sourcePort << "\"" + << " destinationPort=\"" << iter->first.destinationPort << "\"" + << " />\n"; + } + + indent -= 2; + INDENT (indent); os << "\n"; + +#undef INDENT +} + + +} // namespace ns3 + diff -Naur ns-3.19/src/flow-monitor/model/ipv6-flow-classifier.h ns-3.20/src/flow-monitor/model/ipv6-flow-classifier.h --- ns-3.19/src/flow-monitor/model/ipv6-flow-classifier.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/flow-monitor/model/ipv6-flow-classifier.h 2014-06-17 10:33:13.751997058 -0700 @@ -0,0 +1,104 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +// +// Copyright (c) 2009 INESC Porto +// +// 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: Gustavo J. A. M. Carneiro +// Modifications: Tommaso Pecorella +// + +#ifndef IPV6_FLOW_CLASSIFIER_H +#define IPV6_FLOW_CLASSIFIER_H + +#include +#include + +#include "ns3/ipv6-header.h" +#include "ns3/flow-classifier.h" + +namespace ns3 { + +class Packet; + +/// Classifies packets by looking at their IP and TCP/UDP headers. +/// From these packet headers, a tuple (source-ip, destination-ip, +/// protocol, source-port, destination-port) is created, and a unique +/// flow identifier is assigned for each different tuple combination +class Ipv6FlowClassifier : public FlowClassifier +{ +public: + + /// Structure to classify a packet + struct FiveTuple + { + Ipv6Address sourceAddress; //!< Source address + Ipv6Address destinationAddress; //!< Destination address + uint8_t protocol; //!< Protocol + uint16_t sourcePort; //!< Source port + uint16_t destinationPort; //!< Destination port + }; + + Ipv6FlowClassifier (); + + /// \brief try to classify the packet into flow-id and packet-id + /// + /// \warning: it must be called only once per packet, from SendOutgoingLogger. + /// + /// \return true if the packet was classified, false if not (i.e. it + /// does not appear to be part of a flow). + /// \param ipHeader packet's IP header + /// \param ipPayload packet's IP payload + /// \param out_flowId packet's FlowId + /// \param out_packetId packet's identifier + bool Classify (const Ipv6Header &ipHeader, Ptr ipPayload, + uint32_t *out_flowId, uint32_t *out_packetId); + + /// Searches for the FiveTuple corresponding to the given flowId + /// \param flowId the FlowId to search for + /// \returns the FiveTuple corresponding to flowId + FiveTuple FindFlow (FlowId flowId) const; + + virtual void SerializeToXmlStream (std::ostream &os, int indent) const; + +private: + + /// Map to Flows Identifiers to FlowIds + std::map m_flowMap; + std::map m_flowPktIdMap; + +}; + +/** + * \brief Less than operator. + * + * \param t1 the first operand + * \param t2 the first operand + * \returns true if the operands are equal + */ +bool operator < (const Ipv6FlowClassifier::FiveTuple &t1, const Ipv6FlowClassifier::FiveTuple &t2); + +/** + * \brief Equal to operator. + * + * \param t1 the first operand + * \param t2 the first operand + * \returns true if the operands are equal + */ +bool operator == (const Ipv6FlowClassifier::FiveTuple &t1, const Ipv6FlowClassifier::FiveTuple &t2); + + +} // namespace ns3 + +#endif /* IPV6_FLOW_CLASSIFIER_H */ diff -Naur ns-3.19/src/flow-monitor/model/ipv6-flow-probe.cc ns-3.20/src/flow-monitor/model/ipv6-flow-probe.cc --- ns-3.19/src/flow-monitor/model/ipv6-flow-probe.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/flow-monitor/model/ipv6-flow-probe.cc 2014-06-17 10:33:13.752997050 -0700 @@ -0,0 +1,409 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +// +// Copyright (c) 2009 INESC Porto +// +// 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: Gustavo J. A. M. Carneiro +// Modifications: Tommaso Pecorella +// + +#include "ns3/ipv6-flow-probe.h" +#include "ns3/ipv6-flow-classifier.h" +#include "ns3/node.h" +#include "ns3/packet.h" +#include "ns3/flow-monitor.h" +#include "ns3/log.h" +#include "ns3/pointer.h" +#include "ns3/config.h" +#include "ns3/flow-id-tag.h" + +namespace ns3 { + +NS_LOG_COMPONENT_DEFINE ("Ipv6FlowProbe") + ; + +////////////////////////////////////// +// Ipv6FlowProbeTag class implementation // +////////////////////////////////////// + +/** + * \ingroup flow-monitor + * + * \brief Tag used to allow a fast identification of the packet + * + * This tag is added by FlowMonitor when a packet is seen for + * the first time, and it is then used to classify the packet in + * the following hops. + */ +class Ipv6FlowProbeTag : public Tag +{ +public: + /** + * \brief Get the type ID. + * \return the object TypeId + */ + static TypeId GetTypeId (void); + virtual TypeId GetInstanceTypeId (void) const; + virtual uint32_t GetSerializedSize (void) const; + virtual void Serialize (TagBuffer buf) const; + virtual void Deserialize (TagBuffer buf); + virtual void Print (std::ostream &os) const; + Ipv6FlowProbeTag (); + /** + * \brief Consructor + * \param flowId the flow identifier + * \param packetId the packet identifier + * \param packetSize the packet size + */ + Ipv6FlowProbeTag (uint32_t flowId, uint32_t packetId, uint32_t packetSize); + /** + * \brief Set the flow identifier + * \param flowId the flow identifier + */ + void SetFlowId (uint32_t flowId); + /** + * \brief Set the packet identifier + * \param packetId the packet identifier + */ + void SetPacketId (uint32_t packetId); + /** + * \brief Set the packet size + * \param packetSize the packet size + */ + void SetPacketSize (uint32_t packetSize); + /** + * \brief Set the flow identifier + * \returns the flow identifier + */ + uint32_t GetFlowId (void) const; + /** + * \brief Set the packet identifier + * \returns the packet identifier + */ + uint32_t GetPacketId (void) const; + /** + * \brief Get the packet size + * \returns the packet size + */ + uint32_t GetPacketSize (void) const; +private: + uint32_t m_flowId; //!< flow identifier + uint32_t m_packetId; //!< packet identifier + uint32_t m_packetSize; //!< packet size + +}; + +TypeId +Ipv6FlowProbeTag::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::Ipv6FlowProbeTag") + .SetParent () + .AddConstructor () + ; + return tid; +} +TypeId +Ipv6FlowProbeTag::GetInstanceTypeId (void) const +{ + return GetTypeId (); +} +uint32_t +Ipv6FlowProbeTag::GetSerializedSize (void) const +{ + return 4 + 4 + 4; +} +void +Ipv6FlowProbeTag::Serialize (TagBuffer buf) const +{ + buf.WriteU32 (m_flowId); + buf.WriteU32 (m_packetId); + buf.WriteU32 (m_packetSize); +} +void +Ipv6FlowProbeTag::Deserialize (TagBuffer buf) +{ + m_flowId = buf.ReadU32 (); + m_packetId = buf.ReadU32 (); + m_packetSize = buf.ReadU32 (); +} +void +Ipv6FlowProbeTag::Print (std::ostream &os) const +{ + os << "FlowId=" << m_flowId; + os << "PacketId=" << m_packetId; + os << "PacketSize=" << m_packetSize; +} +Ipv6FlowProbeTag::Ipv6FlowProbeTag () + : Tag () +{ +} + +Ipv6FlowProbeTag::Ipv6FlowProbeTag (uint32_t flowId, uint32_t packetId, uint32_t packetSize) + : Tag (), m_flowId (flowId), m_packetId (packetId), m_packetSize (packetSize) +{ +} + +void +Ipv6FlowProbeTag::SetFlowId (uint32_t id) +{ + m_flowId = id; +} +void +Ipv6FlowProbeTag::SetPacketId (uint32_t id) +{ + m_packetId = id; +} +void +Ipv6FlowProbeTag::SetPacketSize (uint32_t size) +{ + m_packetSize = size; +} +uint32_t +Ipv6FlowProbeTag::GetFlowId (void) const +{ + return m_flowId; +} +uint32_t +Ipv6FlowProbeTag::GetPacketId (void) const +{ + return m_packetId; +} +uint32_t +Ipv6FlowProbeTag::GetPacketSize (void) const +{ + return m_packetSize; +} + +//////////////////////////////////////// +// Ipv6FlowProbe class implementation // +//////////////////////////////////////// + +Ipv6FlowProbe::Ipv6FlowProbe (Ptr monitor, + Ptr classifier, + Ptr node) + : FlowProbe (monitor), + m_classifier (classifier) +{ + NS_LOG_FUNCTION (this << node->GetId ()); + + Ptr ipv6 = node->GetObject (); + + if (!ipv6->TraceConnectWithoutContext ("SendOutgoing", + MakeCallback (&Ipv6FlowProbe::SendOutgoingLogger, Ptr (this)))) + { + NS_FATAL_ERROR ("trace fail"); + } + if (!ipv6->TraceConnectWithoutContext ("UnicastForward", + MakeCallback (&Ipv6FlowProbe::ForwardLogger, Ptr (this)))) + { + NS_FATAL_ERROR ("trace fail"); + } + if (!ipv6->TraceConnectWithoutContext ("LocalDeliver", + MakeCallback (&Ipv6FlowProbe::ForwardUpLogger, Ptr (this)))) + { + NS_FATAL_ERROR ("trace fail"); + } + + if (!ipv6->TraceConnectWithoutContext ("Drop", + MakeCallback (&Ipv6FlowProbe::DropLogger, Ptr (this)))) + { + NS_FATAL_ERROR ("trace fail"); + } + + // code copied from point-to-point-helper.cc + std::ostringstream oss; + oss << "/NodeList/" << node->GetId () << "/DeviceList/*/TxQueue/Drop"; + Config::ConnectWithoutContext (oss.str (), MakeCallback (&Ipv6FlowProbe::QueueDropLogger, Ptr (this))); +} + +Ipv6FlowProbe::~Ipv6FlowProbe () +{ +} + +void +Ipv6FlowProbe::DoDispose () +{ + FlowProbe::DoDispose (); +} + +void +Ipv6FlowProbe::SendOutgoingLogger (const Ipv6Header &ipHeader, Ptr ipPayload, uint32_t interface) +{ + FlowId flowId; + FlowPacketId packetId; + + if (m_classifier->Classify (ipHeader, ipPayload, &flowId, &packetId)) + { + uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); + NS_LOG_DEBUG ("ReportFirstTx ("<ReportFirstTx (this, flowId, packetId, size); + + // tag the packet with the flow id and packet id, so that the packet can be identified even + // when Ipv6Header is not accessible at some non-IPv6 protocol layer + Ipv6FlowProbeTag fTag (flowId, packetId, size); + ipPayload->AddPacketTag (fTag); + } +} + +void +Ipv6FlowProbe::ForwardLogger (const Ipv6Header &ipHeader, Ptr ipPayload, uint32_t interface) +{ + // peek the tags that are added by Ipv6FlowProbe::SendOutgoingLogger () + Ipv6FlowProbeTag fTag; + + bool found = ipPayload->PeekPacketTag (fTag); + + if (found) + { + FlowId flowId = fTag.GetFlowId (); + FlowPacketId packetId = fTag.GetPacketId (); + + uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); + NS_LOG_DEBUG ("ReportForwarding ("<ReportForwarding (this, flowId, packetId, size); + } +} + +void +Ipv6FlowProbe::ForwardUpLogger (const Ipv6Header &ipHeader, Ptr ipPayload, uint32_t interface) +{ + // remove the tags that are added by Ipv6FlowProbe::SendOutgoingLogger () + Ipv6FlowProbeTag fTag; + + // ConstCast: see http://www.nsnam.org/bugzilla/show_bug.cgi?id=904 + bool found = ConstCast (ipPayload)->RemovePacketTag (fTag); + + if (found) + { + FlowId flowId = fTag.GetFlowId (); + FlowPacketId packetId = fTag.GetPacketId (); + + uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); + NS_LOG_DEBUG ("ReportLastRx ("<ReportLastRx (this, flowId, packetId, size); + } +} + +void +Ipv6FlowProbe::DropLogger (const Ipv6Header &ipHeader, Ptr ipPayload, + Ipv6L3Protocol::DropReason reason, Ptr ipv6, uint32_t ifIndex) +{ +#if 0 + switch (reason) + { + case Ipv6L3Protocol::DROP_NO_ROUTE: + break; + + case Ipv6L3Protocol::DROP_TTL_EXPIRED: + case Ipv6L3Protocol::DROP_BAD_CHECKSUM: + Ipv6Address addri = m_ipv6->GetAddress (ifIndex); + Ipv6Mask maski = m_ipv6->GetNetworkMask (ifIndex); + Ipv6Address bcast = addri.GetSubnetDirectedBroadcast (maski); + if (ipHeader.GetDestination () == bcast) // we don't want broadcast packets + { + return; + } + } +#endif + + // remove the tags that are added by Ipv6FlowProbe::SendOutgoingLogger () + Ipv6FlowProbeTag fTag; + + // ConstCast: see http://www.nsnam.org/bugzilla/show_bug.cgi?id=904 + bool found = ConstCast (ipPayload)->RemovePacketTag (fTag); + + if (found) + { + FlowId flowId = fTag.GetFlowId (); + FlowPacketId packetId = fTag.GetPacketId (); + + uint32_t size = (ipPayload->GetSize () + ipHeader.GetSerializedSize ()); + NS_LOG_DEBUG ("Drop ("<ReportDrop (this, flowId, packetId, size, myReason); + } +} + +void +Ipv6FlowProbe::QueueDropLogger (Ptr ipPayload) +{ + // remove the tags that are added by Ipv6FlowProbe::SendOutgoingLogger () + Ipv6FlowProbeTag fTag; + + // ConstCast: see http://www.nsnam.org/bugzilla/show_bug.cgi?id=904 + bool tagFound = ConstCast (ipPayload)->RemovePacketTag (fTag); + if (!tagFound) + { + return; + } + + FlowId flowId = fTag.GetFlowId (); + FlowPacketId packetId = fTag.GetPacketId (); + uint32_t size = fTag.GetPacketSize (); + + NS_LOG_DEBUG ("Drop ("<ReportDrop (this, flowId, packetId, size, DROP_QUEUE); +} + +} // namespace ns3 + + diff -Naur ns-3.19/src/flow-monitor/model/ipv6-flow-probe.h ns-3.20/src/flow-monitor/model/ipv6-flow-probe.h --- ns-3.19/src/flow-monitor/model/ipv6-flow-probe.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/flow-monitor/model/ipv6-flow-probe.h 2014-06-17 10:33:13.752997050 -0700 @@ -0,0 +1,120 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +// +// Copyright (c) 2009 INESC Porto +// +// 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: Gustavo J. A. M. Carneiro +// Modifications: Tommaso Pecorella +// + +#ifndef IPV6_FLOW_PROBE_H +#define IPV6_FLOW_PROBE_H + +#include "ns3/flow-probe.h" +#include "ns3/ipv6-flow-classifier.h" +#include "ns3/ipv6-l3-protocol.h" + +namespace ns3 { + +class FlowMonitor; +class Node; + +/// \ingroup flow-monitor +/// \brief Class that monitors flows at the IPv6 layer of a Node +/// +/// For each node in the simulation, one instance of the class +/// Ipv4FlowProbe is created to monitor that node. Ipv4FlowProbe +/// accomplishes this by connecting callbacks to trace sources in the +/// Ipv6L3Protocol interface of the node. +class Ipv6FlowProbe : public FlowProbe +{ + +public: + /// \brief Constructor + /// \param monitor the FlowMonitor this probe is associated with + /// \param classifier the Ipv4FlowClassifier this probe is associated with + /// \param node the Node this probe is associated with + Ipv6FlowProbe (Ptr monitor, Ptr classifier, Ptr node); + virtual ~Ipv6FlowProbe (); + + /// \brief enumeration of possible reasons why a packet may be dropped + enum DropReason + { + /// Packet dropped due to missing route to the destination + DROP_NO_ROUTE = 0, + + /// Packet dropped due to TTL decremented to zero during IPv4 forwarding + DROP_TTL_EXPIRE, + + /// Packet dropped due to invalid checksum in the IPv4 header + DROP_BAD_CHECKSUM, + + /// Packet dropped due to queue overflow. Note: only works for + /// NetDevices that provide a TxQueue attribute of type Queue + /// with a Drop trace source. It currently works with Csma and + /// PointToPoint devices, but not with WiFi or WiMax. + DROP_QUEUE, + + DROP_INTERFACE_DOWN, /**< Interface is down so can not send packet */ + DROP_ROUTE_ERROR, /**< Route error */ + + DROP_UNKNOWN_PROTOCOL, /**< Unknown L4 protocol */ + DROP_UNKNOWN_OPTION, /**< Unknown option */ + DROP_MALFORMED_HEADER, /**< Malformed header */ + + DROP_FRAGMENT_TIMEOUT, /**< Fragment timeout exceeded */ + + DROP_INVALID_REASON, /**< Fallback reason (no known reason) */ + }; + +protected: + + virtual void DoDispose (void); + +private: + /// Log a packet being sent + /// \param ipHeader IP header + /// \param ipPayload IP payload + /// \param interface outgoing interface + void SendOutgoingLogger (const Ipv6Header &ipHeader, Ptr ipPayload, uint32_t interface); + /// Log a packet being forwarded + /// \param ipHeader IP header + /// \param ipPayload IP payload + /// \param interface incoming interface + void ForwardLogger (const Ipv6Header &ipHeader, Ptr ipPayload, uint32_t interface); + /// Log a packet being received by the destination + /// \param ipHeader IP header + /// \param ipPayload IP payload + /// \param interface incoming interface + void ForwardUpLogger (const Ipv6Header &ipHeader, Ptr ipPayload, uint32_t interface); + /// Log a packet being dropped + /// \param ipHeader IP header + /// \param ipPayload IP payload + /// \param reason drop reason + /// \param ipv6 pointer to the IP object dropping the packet + /// \param ifIndex interface index + void DropLogger (const Ipv6Header &ipHeader, Ptr ipPayload, + Ipv6L3Protocol::DropReason reason, Ptr ipv6, uint32_t ifIndex); + /// Log a packet being dropped by a queue + /// \param ipPayload IP payload + void QueueDropLogger (Ptr ipPayload); + + Ptr m_classifier; //!< the Ipv6FlowClassifier this probe is associated with +}; + + +} // namespace ns3 + +#endif /* IPV6_FLOW_PROBE_H */ diff -Naur ns-3.19/src/flow-monitor/test/histogram-test-suite.cc ns-3.20/src/flow-monitor/test/histogram-test-suite.cc --- ns-3.19/src/flow-monitor/test/histogram-test-suite.cc 2014-06-17 10:34:00.434636692 -0700 +++ ns-3.20/src/flow-monitor/test/histogram-test-suite.cc 2014-06-17 10:33:13.753997042 -0700 @@ -21,7 +21,7 @@ #include "ns3/histogram.h" #include "ns3/test.h" -namespace ns3 { +using namespace ns3; class HistogramTestCase : public ns3::TestCase { private: @@ -78,7 +78,3 @@ AddTestCase (new HistogramTestCase (), TestCase::QUICK); } } g_HistogramTestSuite; - -} // namespace - - diff -Naur ns-3.19/src/flow-monitor/waf ns-3.20/src/flow-monitor/waf --- ns-3.19/src/flow-monitor/waf 2014-06-17 10:34:00.434636692 -0700 +++ ns-3.20/src/flow-monitor/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1,2 +0,0 @@ -#! /bin/sh -exec "`dirname "$0"`"/../../../waf "$@" diff -Naur ns-3.19/src/flow-monitor/wscript ns-3.20/src/flow-monitor/wscript --- ns-3.19/src/flow-monitor/wscript 2014-06-17 10:34:00.434636692 -0700 +++ ns-3.20/src/flow-monitor/wscript 2014-06-17 10:33:13.753997042 -0700 @@ -8,6 +8,8 @@ 'flow-probe.cc', 'ipv4-flow-classifier.cc', 'ipv4-flow-probe.cc', + 'ipv6-flow-classifier.cc', + 'ipv6-flow-probe.cc', 'histogram.cc', ]] obj.source.append("helper/flow-monitor-helper.cc") @@ -25,6 +27,8 @@ 'flow-classifier.h', 'ipv4-flow-classifier.h', 'ipv4-flow-probe.h', + 'ipv6-flow-classifier.h', + 'ipv6-flow-probe.h', 'histogram.h', ]] headers.source.append("helper/flow-monitor-helper.h") diff -Naur ns-3.19/src/internet/bindings/modulegen__gcc_ILP32.py ns-3.20/src/internet/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/internet/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:34:00.446636600 -0700 +++ ns-3.20/src/internet/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.766996942 -0700 @@ -203,13 +203,19 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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') ## internet-trace-helper.h (module 'internet'): ns3::PcapHelperForIpv4 [class] module.add_class('PcapHelperForIpv4', allow_subclassing=True) ## internet-trace-helper.h (module 'internet'): ns3::PcapHelperForIpv6 [class] module.add_class('PcapHelperForIpv6', allow_subclassing=True) + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper [class] + module.add_class('RipNgHelper', parent=root_module['ns3::Ipv6RoutingHelper']) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry [class] + module.add_class('RipNgRoutingTableEntry', parent=root_module['ns3::Ipv6RoutingTableEntry']) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::Status_e [enumeration] + module.add_enum('Status_e', ['RIPNG_VALID', 'RIPNG_INVALID'], outer_class=root_module['ns3::RipNgRoutingTableEntry']) ## rtt-estimator.h (module 'internet'): ns3::RttHistory [class] module.add_class('RttHistory') ## global-route-manager-impl.h (module 'internet'): ns3::SPFVertex [class] @@ -226,6 +232,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -256,6 +264,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## header.h (module 'network'): ns3::Header [class] @@ -360,6 +370,12 @@ module.add_class('PcapFileWrapper', import_from_module='ns.network', parent=root_module['ns3::Object']) ## random-variable-stream.h (module 'core'): ns3::RandomVariableStream [class] module.add_class('RandomVariableStream', import_from_module='ns.core', parent=root_module['ns3::Object']) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader [class] + module.add_class('RipNgHeader', parent=root_module['ns3::Header']) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::Command_e [enumeration] + module.add_enum('Command_e', ['REQUEST', 'RESPONSE'], outer_class=root_module['ns3::RipNgHeader']) + ## ripng-header.h (module 'internet'): ns3::RipNgRte [class] + module.add_class('RipNgRte', parent=root_module['ns3::Header']) ## rtt-estimator.h (module 'internet'): ns3::RttEstimator [class] module.add_class('RttEstimator', parent=root_module['ns3::Object']) ## rtt-estimator.h (module 'internet'): ns3::RttMeanDeviation [class] @@ -597,7 +613,7 @@ ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol [class] module.add_class('Ipv6L3Protocol', parent=root_module['ns3::Ipv6']) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::DropReason [enumeration] - module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL'], outer_class=root_module['ns3::Ipv6L3Protocol']) + module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT'], outer_class=root_module['ns3::Ipv6L3Protocol']) ## ipv6-route.h (module 'internet'): ns3::Ipv6MulticastRoute [class] module.add_class('Ipv6MulticastRoute', parent=root_module['ns3::SimpleRefCount< ns3::Ipv6MulticastRoute, ns3::empty, ns3::DefaultDeleter >']) ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache [class] @@ -646,6 +662,10 @@ module.add_class('ParetoRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## probe.h (module 'stats'): ns3::Probe [class] module.add_class('Probe', import_from_module='ns.stats', parent=root_module['ns3::DataCollectionObject']) + ## ripng.h (module 'internet'): ns3::RipNg [class] + module.add_class('RipNg', parent=root_module['ns3::Ipv6RoutingProtocol']) + ## ripng.h (module 'internet'): ns3::RipNg::SplitHorizonType_e [enumeration] + module.add_enum('SplitHorizonType_e', ['NO_SPLIT_HORIZON', 'SPLIT_HORIZON', 'POISON_REVERSE'], outer_class=root_module['ns3::RipNg']) ## tcp-l4-protocol.h (module 'internet'): ns3::TcpL4Protocol [class] module.add_class('TcpL4Protocol', parent=root_module['ns3::IpL4Protocol']) ## tcp-newreno.h (module 'internet'): ns3::TcpNewReno [class] @@ -690,21 +710,26 @@ module.add_class('Ipv6PacketProbe', parent=root_module['ns3::Probe']) ## loopback-net-device.h (module 'internet'): ns3::LoopbackNetDevice [class] module.add_class('LoopbackNetDevice', parent=root_module['ns3::NetDevice']) - module.add_container('std::vector< unsigned int >', 'unsigned int', container_type='vector') - module.add_container('std::vector< bool >', 'bool', container_type='vector') - module.add_container('std::map< ns3::SequenceNumber< unsigned int, int >, ns3::Ptr< ns3::Packet > >', ('ns3::SequenceNumber< unsigned int, int >', 'ns3::Ptr< ns3::Packet >'), container_type='map') - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') - module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type='vector') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >', 'ns3::SequenceNumber16') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >*', 'ns3::SequenceNumber16*') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >&', 'ns3::SequenceNumber16&') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >', 'ns3::SequenceNumber32') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >*', 'ns3::SequenceNumber32*') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >&', 'ns3::SequenceNumber32&') - typehandlers.add_type_alias('std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >', 'ns3::RttHistory_t') - typehandlers.add_type_alias('std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >*', 'ns3::RttHistory_t*') - typehandlers.add_type_alias('std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >&', 'ns3::RttHistory_t&') + module.add_container('std::vector< unsigned int >', 'unsigned int', container_type=u'vector') + module.add_container('std::vector< bool >', 'bool', container_type=u'vector') + module.add_container('std::list< ns3::RipNgRte >', 'ns3::RipNgRte', container_type=u'list') + module.add_container('std::map< ns3::SequenceNumber< unsigned int, int >, ns3::Ptr< ns3::Packet > >', ('ns3::SequenceNumber< unsigned int, int >', 'ns3::Ptr< ns3::Packet >'), container_type=u'map') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') + module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type=u'vector') + module.add_container('std::set< unsigned int >', 'unsigned int', container_type=u'set') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >', u'ns3::SequenceNumber16') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >*', u'ns3::SequenceNumber16*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >&', u'ns3::SequenceNumber16&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >', u'ns3::SequenceNumber32') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >*', u'ns3::SequenceNumber32*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >&', u'ns3::SequenceNumber32&') + typehandlers.add_type_alias(u'std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >', u'ns3::RttHistory_t') + typehandlers.add_type_alias(u'std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >*', u'ns3::RttHistory_t*') + typehandlers.add_type_alias(u'std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >&', u'ns3::RttHistory_t&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >', u'ns3::SequenceNumber8') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >*', u'ns3::SequenceNumber8*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >&', u'ns3::SequenceNumber8&') ## Register a nested module for the namespace FatalImpl @@ -733,12 +758,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') ## Register a nested module for the namespace Function @@ -835,6 +860,8 @@ register_Ns3PcapHelperForDevice_methods(root_module, root_module['ns3::PcapHelperForDevice']) register_Ns3PcapHelperForIpv4_methods(root_module, root_module['ns3::PcapHelperForIpv4']) register_Ns3PcapHelperForIpv6_methods(root_module, root_module['ns3::PcapHelperForIpv6']) + register_Ns3RipNgHelper_methods(root_module, root_module['ns3::RipNgHelper']) + register_Ns3RipNgRoutingTableEntry_methods(root_module, root_module['ns3::RipNgRoutingTableEntry']) register_Ns3RttHistory_methods(root_module, root_module['ns3::RttHistory']) register_Ns3SPFVertex_methods(root_module, root_module['ns3::SPFVertex']) register_Ns3SequenceNumber32_methods(root_module, root_module['ns3::SequenceNumber32']) @@ -842,6 +869,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TracedValue__Double_methods(root_module, root_module['ns3::TracedValue< double >']) @@ -894,6 +922,8 @@ register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3PcapFileWrapper_methods(root_module, root_module['ns3::PcapFileWrapper']) register_Ns3RandomVariableStream_methods(root_module, root_module['ns3::RandomVariableStream']) + register_Ns3RipNgHeader_methods(root_module, root_module['ns3::RipNgHeader']) + register_Ns3RipNgRte_methods(root_module, root_module['ns3::RipNgRte']) register_Ns3RttEstimator_methods(root_module, root_module['ns3::RttEstimator']) register_Ns3RttMeanDeviation_methods(root_module, root_module['ns3::RttMeanDeviation']) register_Ns3SequentialRandomVariable_methods(root_module, root_module['ns3::SequentialRandomVariable']) @@ -1024,6 +1054,7 @@ register_Ns3Packet_methods(root_module, root_module['ns3::Packet']) register_Ns3ParetoRandomVariable_methods(root_module, root_module['ns3::ParetoRandomVariable']) register_Ns3Probe_methods(root_module, root_module['ns3::Probe']) + register_Ns3RipNg_methods(root_module, root_module['ns3::RipNg']) register_Ns3TcpL4Protocol_methods(root_module, root_module['ns3::TcpL4Protocol']) register_Ns3TcpNewReno_methods(root_module, root_module['ns3::TcpNewReno']) register_Ns3TcpReno_methods(root_module, root_module['ns3::TcpReno']) @@ -1537,6 +1568,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1549,6 +1584,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -3226,6 +3265,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -4322,6 +4366,91 @@ is_pure_virtual=True, is_virtual=True) return +def register_Ns3RipNgHelper_methods(root_module, cls): + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper::RipNgHelper() [constructor] + cls.add_constructor([]) + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper::RipNgHelper(ns3::RipNgHelper const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgHelper const &', 'arg0')]) + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper * ns3::RipNgHelper::Copy() const [member function] + cls.add_method('Copy', + 'ns3::RipNgHelper *', + [], + is_const=True, is_virtual=True) + ## ripng-helper.h (module 'internet'): ns3::Ptr ns3::RipNgHelper::Create(ns3::Ptr node) const [member function] + cls.add_method('Create', + 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', + [param('ns3::Ptr< ns3::Node >', 'node')], + is_const=True, is_virtual=True) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::Set(std::string name, ns3::AttributeValue const & value) [member function] + cls.add_method('Set', + 'void', + [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')]) + ## ripng-helper.h (module 'internet'): int64_t ns3::RipNgHelper::AssignStreams(ns3::NodeContainer c, int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('ns3::NodeContainer', 'c'), param('int64_t', 'stream')]) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::SetDefaultRouter(ns3::Ptr node, ns3::Ipv6Address nextHop, uint32_t interface) [member function] + cls.add_method('SetDefaultRouter', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface')]) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::ExcludeInterface(ns3::Ptr node, uint32_t interface) [member function] + cls.add_method('ExcludeInterface', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node'), param('uint32_t', 'interface')]) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::SetInterfaceMetric(ns3::Ptr node, uint32_t interface, uint8_t metric) [member function] + cls.add_method('SetInterfaceMetric', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node'), param('uint32_t', 'interface'), param('uint8_t', 'metric')]) + return + +def register_Ns3RipNgRoutingTableEntry_methods(root_module, cls): + cls.add_output_stream_operator() + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry(ns3::RipNgRoutingTableEntry const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgRoutingTableEntry const &', 'arg0')]) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry() [constructor] + cls.add_constructor([]) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry(ns3::Ipv6Address network, ns3::Ipv6Prefix networkPrefix, ns3::Ipv6Address nextHop, uint32_t interface, ns3::Ipv6Address prefixToUse) [constructor] + cls.add_constructor([param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'networkPrefix'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'prefixToUse')]) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry(ns3::Ipv6Address network, ns3::Ipv6Prefix networkPrefix, uint32_t interface) [constructor] + cls.add_constructor([param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'networkPrefix'), param('uint32_t', 'interface')]) + ## ripng.h (module 'internet'): uint8_t ns3::RipNgRoutingTableEntry::GetRouteMetric() const [member function] + cls.add_method('GetRouteMetric', + 'uint8_t', + [], + is_const=True) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::Status_e ns3::RipNgRoutingTableEntry::GetRouteStatus() const [member function] + cls.add_method('GetRouteStatus', + 'ns3::RipNgRoutingTableEntry::Status_e', + [], + is_const=True) + ## ripng.h (module 'internet'): uint16_t ns3::RipNgRoutingTableEntry::GetRouteTag() const [member function] + cls.add_method('GetRouteTag', + 'uint16_t', + [], + is_const=True) + ## ripng.h (module 'internet'): bool ns3::RipNgRoutingTableEntry::IsRouteChanged() const [member function] + cls.add_method('IsRouteChanged', + 'bool', + [], + is_const=True) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteChanged(bool changed) [member function] + cls.add_method('SetRouteChanged', + 'void', + [param('bool', 'changed')]) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteMetric(uint8_t routeMetric) [member function] + cls.add_method('SetRouteMetric', + 'void', + [param('uint8_t', 'routeMetric')]) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteStatus(ns3::RipNgRoutingTableEntry::Status_e status) [member function] + cls.add_method('SetRouteStatus', + 'void', + [param('ns3::RipNgRoutingTableEntry::Status_e', 'status')]) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteTag(uint16_t routeTag) [member function] + cls.add_method('SetRouteTag', + 'void', + [param('uint16_t', 'routeTag')]) + return + def register_Ns3RttHistory_methods(root_module, cls): ## rtt-estimator.h (module 'internet'): ns3::RttHistory::RttHistory(ns3::SequenceNumber32 s, uint32_t c, ns3::Time t) [constructor] cls.add_constructor([param('ns3::SequenceNumber32', 's'), param('uint32_t', 'c'), param('ns3::Time', 't')]) @@ -4453,11 +4582,11 @@ def register_Ns3SequenceNumber32_methods(root_module, cls): cls.add_binary_comparison_operator('!=') - cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('ns3::SequenceNumber< unsigned int, int > const &', 'right')) - cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', 'right')) - cls.add_inplace_numeric_operator('+=', param('int', 'right')) - cls.add_binary_numeric_operator('-', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', 'right')) - cls.add_inplace_numeric_operator('-=', param('int', 'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('ns3::SequenceNumber< unsigned int, int > const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', u'right')) + cls.add_inplace_numeric_operator('+=', param('int', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', u'right')) + cls.add_inplace_numeric_operator('-=', param('int', u'right')) cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -4663,6 +4792,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -5082,61 +5219,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -5144,6 +5237,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -5184,6 +5279,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -7524,6 +7621,143 @@ is_const=True, visibility='protected') return +def register_Ns3RipNgHeader_methods(root_module, cls): + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::RipNgHeader(ns3::RipNgHeader const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgHeader const &', 'arg0')]) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::RipNgHeader() [constructor] + cls.add_constructor([]) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::AddRte(ns3::RipNgRte rte) [member function] + cls.add_method('AddRte', + 'void', + [param('ns3::RipNgRte', 'rte')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::ClearRtes() [member function] + cls.add_method('ClearRtes', + 'void', + []) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgHeader::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::Command_e ns3::RipNgHeader::GetCommand() const [member function] + cls.add_method('GetCommand', + 'ns3::RipNgHeader::Command_e', + [], + is_const=True) + ## ripng-header.h (module 'internet'): ns3::TypeId ns3::RipNgHeader::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): std::list > ns3::RipNgHeader::GetRteList() const [member function] + cls.add_method('GetRteList', + 'std::list< ns3::RipNgRte >', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint16_t ns3::RipNgHeader::GetRteNumber() const [member function] + cls.add_method('GetRteNumber', + 'uint16_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgHeader::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): static ns3::TypeId ns3::RipNgHeader::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::SetCommand(ns3::RipNgHeader::Command_e command) [member function] + cls.add_method('SetCommand', + 'void', + [param('ns3::RipNgHeader::Command_e', 'command')]) + return + +def register_Ns3RipNgRte_methods(root_module, cls): + ## ripng-header.h (module 'internet'): ns3::RipNgRte::RipNgRte(ns3::RipNgRte const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgRte const &', 'arg0')]) + ## ripng-header.h (module 'internet'): ns3::RipNgRte::RipNgRte() [constructor] + cls.add_constructor([]) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgRte::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## ripng-header.h (module 'internet'): ns3::TypeId ns3::RipNgRte::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): ns3::Ipv6Address ns3::RipNgRte::GetPrefix() const [member function] + cls.add_method('GetPrefix', + 'ns3::Ipv6Address', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint8_t ns3::RipNgRte::GetPrefixLen() const [member function] + cls.add_method('GetPrefixLen', + 'uint8_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint8_t ns3::RipNgRte::GetRouteMetric() const [member function] + cls.add_method('GetRouteMetric', + 'uint8_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint16_t ns3::RipNgRte::GetRouteTag() const [member function] + cls.add_method('GetRouteTag', + 'uint16_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgRte::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): static ns3::TypeId ns3::RipNgRte::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetPrefix(ns3::Ipv6Address prefix) [member function] + cls.add_method('SetPrefix', + 'void', + [param('ns3::Ipv6Address', 'prefix')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetPrefixLen(uint8_t prefixLen) [member function] + cls.add_method('SetPrefixLen', + 'void', + [param('uint8_t', 'prefixLen')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetRouteMetric(uint8_t routeMetric) [member function] + cls.add_method('SetRouteMetric', + 'void', + [param('uint8_t', 'routeMetric')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetRouteTag(uint16_t routeTag) [member function] + cls.add_method('SetRouteTag', + 'void', + [param('uint16_t', 'routeTag')]) + return + def register_Ns3RttEstimator_methods(root_module, cls): ## rtt-estimator.h (module 'internet'): ns3::RttEstimator::RttEstimator() [constructor] cls.add_constructor([]) @@ -9547,12 +9781,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -9578,6 +9814,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -11746,6 +11987,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -12366,6 +12612,11 @@ 'ns3::Ptr< ns3::NetDevice >', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetRoutingProtocol() const [member function] cls.add_method('GetRoutingProtocol', 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', @@ -12436,6 +12687,11 @@ 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_pure_virtual=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ipv6::IF_ANY [variable] cls.add_static_attribute('IF_ANY', 'uint32_t const', is_const=True) ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetIpForward() const [member function] @@ -12524,15 +12780,15 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_pure_virtual=True, is_virtual=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::ProcessOptions(ns3::Ptr & packet, uint8_t offset, uint8_t length, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::ProcessOptions(ns3::Ptr & packet, uint8_t offset, uint8_t length, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('ProcessOptions', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('uint8_t', 'length'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('uint8_t', 'length'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): void ns3::Ipv6Extension::SetNode(ns3::Ptr node) [member function] cls.add_method('SetNode', @@ -12555,10 +12811,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionAH::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionAH::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionAH::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12649,10 +12905,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionDestination::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionDestination::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionDestination::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12710,10 +12966,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionESP::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionESP::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionESP::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12775,10 +13031,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionFragment::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionFragment::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionFragment::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12868,10 +13124,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionHopByHop::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionHopByHop::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionHopByHop::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12956,10 +13212,10 @@ 'uint8_t', [], is_const=True, is_virtual=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionRouting::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -13169,7 +13425,7 @@ cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber')], - is_const=True) + is_const=True, is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::CreateRawSocket() [member function] cls.add_method('CreateRawSocket', 'ns3::Ptr< ns3::Socket >', @@ -13304,6 +13560,11 @@ 'void', [param('uint32_t', 'i'), param('bool', 'val')], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6L3Protocol::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetNetDevice(uint32_t i) [member function] cls.add_method('GetNetDevice', 'ns3::Ptr< ns3::NetDevice >', @@ -13332,6 +13593,11 @@ 'void', [], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::ReportDrop(ns3::Ipv6Header ipHeader, ns3::Ptr p, ns3::Ipv6L3Protocol::DropReason dropReason) [member function] + cls.add_method('ReportDrop', + 'void', + [param('ns3::Ipv6Header', 'ipHeader'), param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6L3Protocol::DropReason', 'dropReason')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DoDispose() [member function] cls.add_method('DoDispose', 'void', @@ -14596,10 +14862,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): @@ -14672,6 +14938,104 @@ is_const=True, is_virtual=True) return +def register_Ns3RipNg_methods(root_module, cls): + ## ripng.h (module 'internet'): ns3::RipNg::RipNg(ns3::RipNg const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNg const &', 'arg0')]) + ## ripng.h (module 'internet'): ns3::RipNg::RipNg() [constructor] + cls.add_constructor([]) + ## ripng.h (module 'internet'): void ns3::RipNg::AddDefaultRouteTo(ns3::Ipv6Address nextHop, uint32_t interface) [member function] + cls.add_method('AddDefaultRouteTo', + 'void', + [param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface')]) + ## ripng.h (module 'internet'): int64_t ns3::RipNg::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## ripng.h (module 'internet'): std::set, std::allocator > ns3::RipNg::GetInterfaceExclusions() const [member function] + cls.add_method('GetInterfaceExclusions', + 'std::set< unsigned int >', + [], + is_const=True) + ## ripng.h (module 'internet'): uint8_t ns3::RipNg::GetInterfaceMetric(uint32_t interface) const [member function] + cls.add_method('GetInterfaceMetric', + 'uint8_t', + [param('uint32_t', 'interface')], + is_const=True) + ## ripng.h (module 'internet'): static ns3::TypeId ns3::RipNg::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyAddAddress(uint32_t interface, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('NotifyAddAddress', + 'void', + [param('uint32_t', 'interface'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyAddRoute(ns3::Ipv6Address dst, ns3::Ipv6Prefix mask, ns3::Ipv6Address nextHop, uint32_t interface, ns3::Ipv6Address prefixToUse=ns3::Ipv6Address::GetZero( )) [member function] + cls.add_method('NotifyAddRoute', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('ns3::Ipv6Prefix', 'mask'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'prefixToUse', default_value='ns3::Ipv6Address::GetZero( )')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyInterfaceDown(uint32_t interface) [member function] + cls.add_method('NotifyInterfaceDown', + 'void', + [param('uint32_t', 'interface')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyInterfaceUp(uint32_t interface) [member function] + cls.add_method('NotifyInterfaceUp', + 'void', + [param('uint32_t', 'interface')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyRemoveAddress(uint32_t interface, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('NotifyRemoveAddress', + 'void', + [param('uint32_t', 'interface'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyRemoveRoute(ns3::Ipv6Address dst, ns3::Ipv6Prefix mask, ns3::Ipv6Address nextHop, uint32_t interface, ns3::Ipv6Address prefixToUse=ns3::Ipv6Address::GetZero( )) [member function] + cls.add_method('NotifyRemoveRoute', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('ns3::Ipv6Prefix', 'mask'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'prefixToUse', default_value='ns3::Ipv6Address::GetZero( )')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::PrintRoutingTable(ns3::Ptr stream) const [member function] + cls.add_method('PrintRoutingTable', + 'void', + [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], + is_const=True, is_virtual=True) + ## ripng.h (module 'internet'): bool ns3::RipNg::RouteInput(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr idev, ns3::Callback,ns3::Ptr,ns3::Ptr,const ns3::Ipv6Header&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ucb, ns3::Callback,ns3::Ptr,ns3::Ptr,const ns3::Ipv6Header&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> mcb, ns3::Callback,const ns3::Ipv6Header&,unsigned int,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> lcb, ns3::Callback,const ns3::Ipv6Header&,ns3::Socket::SocketErrno,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ecb) [member function] + cls.add_method('RouteInput', + 'bool', + [param('ns3::Ptr< ns3::Packet const >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice const >', 'idev'), param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice const >, ns3::Ptr< ns3::Ipv6Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ucb'), param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice const >, ns3::Ptr< ns3::Ipv6MulticastRoute >, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'mcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'lcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ecb')], + is_virtual=True) + ## ripng.h (module 'internet'): ns3::Ptr ns3::RipNg::RouteOutput(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr oif, ns3::Socket::SocketErrno & sockerr) [member function] + cls.add_method('RouteOutput', + 'ns3::Ptr< ns3::Ipv6Route >', + [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice >', 'oif'), param('ns3::Socket::SocketErrno &', 'sockerr')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::SetInterfaceExclusions(std::set, std::allocator > exceptions) [member function] + cls.add_method('SetInterfaceExclusions', + 'void', + [param('std::set< unsigned int >', 'exceptions')]) + ## ripng.h (module 'internet'): void ns3::RipNg::SetInterfaceMetric(uint32_t interface, uint8_t metric) [member function] + cls.add_method('SetInterfaceMetric', + 'void', + [param('uint32_t', 'interface'), param('uint8_t', 'metric')]) + ## ripng.h (module 'internet'): void ns3::RipNg::SetIpv6(ns3::Ptr ipv6) [member function] + cls.add_method('SetIpv6', + 'void', + [param('ns3::Ptr< ns3::Ipv6 >', 'ipv6')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='protected', is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::DoInitialize() [member function] + cls.add_method('DoInitialize', + 'void', + [], + visibility='protected', is_virtual=True) + return + def register_Ns3TcpL4Protocol_methods(root_module, cls): ## tcp-l4-protocol.h (module 'internet'): ns3::TcpL4Protocol::PROT_NUMBER [variable] cls.add_static_attribute('PROT_NUMBER', 'uint8_t const', is_const=True) @@ -15975,10 +16339,10 @@ 'uint8_t', [], is_const=True, is_virtual=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionLooseRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionLooseRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionLooseRouting::TYPE_ROUTING [variable] cls.add_static_attribute('TYPE_ROUTING', 'uint8_t const', is_const=True) diff -Naur ns-3.19/src/internet/bindings/modulegen__gcc_LP64.py ns-3.20/src/internet/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/internet/bindings/modulegen__gcc_LP64.py 2014-06-17 10:34:00.456636522 -0700 +++ ns-3.20/src/internet/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.777996857 -0700 @@ -203,13 +203,19 @@ ## 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') + module.add_enum('', ['DLT_NULL', 'DLT_EN10MB', 'DLT_PPP', 'DLT_RAW', 'DLT_IEEE802_11', 'DLT_PRISM_HEADER', 'DLT_IEEE802_11_RADIO', 'DLT_IEEE802_15_4'], 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') ## internet-trace-helper.h (module 'internet'): ns3::PcapHelperForIpv4 [class] module.add_class('PcapHelperForIpv4', allow_subclassing=True) ## internet-trace-helper.h (module 'internet'): ns3::PcapHelperForIpv6 [class] module.add_class('PcapHelperForIpv6', allow_subclassing=True) + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper [class] + module.add_class('RipNgHelper', parent=root_module['ns3::Ipv6RoutingHelper']) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry [class] + module.add_class('RipNgRoutingTableEntry', parent=root_module['ns3::Ipv6RoutingTableEntry']) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::Status_e [enumeration] + module.add_enum('Status_e', ['RIPNG_VALID', 'RIPNG_INVALID'], outer_class=root_module['ns3::RipNgRoutingTableEntry']) ## rtt-estimator.h (module 'internet'): ns3::RttHistory [class] module.add_class('RttHistory') ## global-route-manager-impl.h (module 'internet'): ns3::SPFVertex [class] @@ -226,6 +232,8 @@ 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] @@ -256,6 +264,8 @@ 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) ## header.h (module 'network'): ns3::Header [class] @@ -360,6 +370,12 @@ module.add_class('PcapFileWrapper', import_from_module='ns.network', parent=root_module['ns3::Object']) ## random-variable-stream.h (module 'core'): ns3::RandomVariableStream [class] module.add_class('RandomVariableStream', import_from_module='ns.core', parent=root_module['ns3::Object']) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader [class] + module.add_class('RipNgHeader', parent=root_module['ns3::Header']) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::Command_e [enumeration] + module.add_enum('Command_e', ['REQUEST', 'RESPONSE'], outer_class=root_module['ns3::RipNgHeader']) + ## ripng-header.h (module 'internet'): ns3::RipNgRte [class] + module.add_class('RipNgRte', parent=root_module['ns3::Header']) ## rtt-estimator.h (module 'internet'): ns3::RttEstimator [class] module.add_class('RttEstimator', parent=root_module['ns3::Object']) ## rtt-estimator.h (module 'internet'): ns3::RttMeanDeviation [class] @@ -597,7 +613,7 @@ ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol [class] module.add_class('Ipv6L3Protocol', parent=root_module['ns3::Ipv6']) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6L3Protocol::DropReason [enumeration] - module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL'], outer_class=root_module['ns3::Ipv6L3Protocol']) + module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_UNKNOWN_PROTOCOL', 'DROP_UNKNOWN_OPTION', 'DROP_MALFORMED_HEADER', 'DROP_FRAGMENT_TIMEOUT'], outer_class=root_module['ns3::Ipv6L3Protocol']) ## ipv6-route.h (module 'internet'): ns3::Ipv6MulticastRoute [class] module.add_class('Ipv6MulticastRoute', parent=root_module['ns3::SimpleRefCount< ns3::Ipv6MulticastRoute, ns3::empty, ns3::DefaultDeleter >']) ## ipv6-pmtu-cache.h (module 'internet'): ns3::Ipv6PmtuCache [class] @@ -646,6 +662,10 @@ module.add_class('ParetoRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## probe.h (module 'stats'): ns3::Probe [class] module.add_class('Probe', import_from_module='ns.stats', parent=root_module['ns3::DataCollectionObject']) + ## ripng.h (module 'internet'): ns3::RipNg [class] + module.add_class('RipNg', parent=root_module['ns3::Ipv6RoutingProtocol']) + ## ripng.h (module 'internet'): ns3::RipNg::SplitHorizonType_e [enumeration] + module.add_enum('SplitHorizonType_e', ['NO_SPLIT_HORIZON', 'SPLIT_HORIZON', 'POISON_REVERSE'], outer_class=root_module['ns3::RipNg']) ## tcp-l4-protocol.h (module 'internet'): ns3::TcpL4Protocol [class] module.add_class('TcpL4Protocol', parent=root_module['ns3::IpL4Protocol']) ## tcp-newreno.h (module 'internet'): ns3::TcpNewReno [class] @@ -690,21 +710,26 @@ module.add_class('Ipv6PacketProbe', parent=root_module['ns3::Probe']) ## loopback-net-device.h (module 'internet'): ns3::LoopbackNetDevice [class] module.add_class('LoopbackNetDevice', parent=root_module['ns3::NetDevice']) - module.add_container('std::vector< unsigned int >', 'unsigned int', container_type='vector') - module.add_container('std::vector< bool >', 'bool', container_type='vector') - module.add_container('std::map< ns3::SequenceNumber< unsigned int, int >, ns3::Ptr< ns3::Packet > >', ('ns3::SequenceNumber< unsigned int, int >', 'ns3::Ptr< ns3::Packet >'), container_type='map') - module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type='list') - module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type='map') - module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type='vector') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >', 'ns3::SequenceNumber16') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >*', 'ns3::SequenceNumber16*') - typehandlers.add_type_alias('ns3::SequenceNumber< short unsigned int, short int >&', 'ns3::SequenceNumber16&') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >', 'ns3::SequenceNumber32') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >*', 'ns3::SequenceNumber32*') - typehandlers.add_type_alias('ns3::SequenceNumber< unsigned int, int >&', 'ns3::SequenceNumber32&') - typehandlers.add_type_alias('std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >', 'ns3::RttHistory_t') - typehandlers.add_type_alias('std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >*', 'ns3::RttHistory_t*') - typehandlers.add_type_alias('std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >&', 'ns3::RttHistory_t&') + module.add_container('std::vector< unsigned int >', 'unsigned int', container_type=u'vector') + module.add_container('std::vector< bool >', 'bool', container_type=u'vector') + module.add_container('std::list< ns3::RipNgRte >', 'ns3::RipNgRte', container_type=u'list') + module.add_container('std::map< ns3::SequenceNumber< unsigned int, int >, ns3::Ptr< ns3::Packet > >', ('ns3::SequenceNumber< unsigned int, int >', 'ns3::Ptr< ns3::Packet >'), container_type=u'map') + module.add_container('std::list< ns3::Ptr< ns3::Packet > >', 'ns3::Ptr< ns3::Packet >', container_type=u'list') + module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') + module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type=u'vector') + module.add_container('std::set< unsigned int >', 'unsigned int', container_type=u'set') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >', u'ns3::SequenceNumber16') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >*', u'ns3::SequenceNumber16*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >&', u'ns3::SequenceNumber16&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >', u'ns3::SequenceNumber32') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >*', u'ns3::SequenceNumber32*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >&', u'ns3::SequenceNumber32&') + typehandlers.add_type_alias(u'std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >', u'ns3::RttHistory_t') + typehandlers.add_type_alias(u'std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >*', u'ns3::RttHistory_t*') + typehandlers.add_type_alias(u'std::deque< ns3::RttHistory, std::allocator< ns3::RttHistory > >&', u'ns3::RttHistory_t&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >', u'ns3::SequenceNumber8') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >*', u'ns3::SequenceNumber8*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >&', u'ns3::SequenceNumber8&') ## Register a nested module for the namespace FatalImpl @@ -733,12 +758,12 @@ ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash64Function_ptr') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash64Function_ptr*') - typehandlers.add_type_alias('uint64_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash64Function_ptr&') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *', 'ns3::Hash::Hash32Function_ptr') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) **', 'ns3::Hash::Hash32Function_ptr*') - typehandlers.add_type_alias('uint32_t ( * ) ( char const *, size_t ) *&', 'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') ## Register a nested module for the namespace Function @@ -835,6 +860,8 @@ register_Ns3PcapHelperForDevice_methods(root_module, root_module['ns3::PcapHelperForDevice']) register_Ns3PcapHelperForIpv4_methods(root_module, root_module['ns3::PcapHelperForIpv4']) register_Ns3PcapHelperForIpv6_methods(root_module, root_module['ns3::PcapHelperForIpv6']) + register_Ns3RipNgHelper_methods(root_module, root_module['ns3::RipNgHelper']) + register_Ns3RipNgRoutingTableEntry_methods(root_module, root_module['ns3::RipNgRoutingTableEntry']) register_Ns3RttHistory_methods(root_module, root_module['ns3::RttHistory']) register_Ns3SPFVertex_methods(root_module, root_module['ns3::SPFVertex']) register_Ns3SequenceNumber32_methods(root_module, root_module['ns3::SequenceNumber32']) @@ -842,6 +869,7 @@ register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TracedValue__Double_methods(root_module, root_module['ns3::TracedValue< double >']) @@ -894,6 +922,8 @@ register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3PcapFileWrapper_methods(root_module, root_module['ns3::PcapFileWrapper']) register_Ns3RandomVariableStream_methods(root_module, root_module['ns3::RandomVariableStream']) + register_Ns3RipNgHeader_methods(root_module, root_module['ns3::RipNgHeader']) + register_Ns3RipNgRte_methods(root_module, root_module['ns3::RipNgRte']) register_Ns3RttEstimator_methods(root_module, root_module['ns3::RttEstimator']) register_Ns3RttMeanDeviation_methods(root_module, root_module['ns3::RttMeanDeviation']) register_Ns3SequentialRandomVariable_methods(root_module, root_module['ns3::SequentialRandomVariable']) @@ -1024,6 +1054,7 @@ register_Ns3Packet_methods(root_module, root_module['ns3::Packet']) register_Ns3ParetoRandomVariable_methods(root_module, root_module['ns3::ParetoRandomVariable']) register_Ns3Probe_methods(root_module, root_module['ns3::Probe']) + register_Ns3RipNg_methods(root_module, root_module['ns3::RipNg']) register_Ns3TcpL4Protocol_methods(root_module, root_module['ns3::TcpL4Protocol']) register_Ns3TcpNewReno_methods(root_module, root_module['ns3::TcpNewReno']) register_Ns3TcpReno_methods(root_module, root_module['ns3::TcpReno']) @@ -1537,6 +1568,10 @@ cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) + ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', @@ -1549,6 +1584,10 @@ cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) + ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', @@ -3226,6 +3265,11 @@ 'ns3::Ipv6InterfaceAddress::State_e', [], is_const=True) + ## ipv6-interface-address.h (module 'internet'): bool ns3::Ipv6InterfaceAddress::IsInSameSubnet(ns3::Ipv6Address b) const [member function] + cls.add_method('IsInSameSubnet', + 'bool', + [param('ns3::Ipv6Address', 'b')], + is_const=True) ## ipv6-interface-address.h (module 'internet'): void ns3::Ipv6InterfaceAddress::SetAddress(ns3::Ipv6Address address) [member function] cls.add_method('SetAddress', 'void', @@ -4322,6 +4366,91 @@ is_pure_virtual=True, is_virtual=True) return +def register_Ns3RipNgHelper_methods(root_module, cls): + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper::RipNgHelper() [constructor] + cls.add_constructor([]) + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper::RipNgHelper(ns3::RipNgHelper const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgHelper const &', 'arg0')]) + ## ripng-helper.h (module 'internet'): ns3::RipNgHelper * ns3::RipNgHelper::Copy() const [member function] + cls.add_method('Copy', + 'ns3::RipNgHelper *', + [], + is_const=True, is_virtual=True) + ## ripng-helper.h (module 'internet'): ns3::Ptr ns3::RipNgHelper::Create(ns3::Ptr node) const [member function] + cls.add_method('Create', + 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', + [param('ns3::Ptr< ns3::Node >', 'node')], + is_const=True, is_virtual=True) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::Set(std::string name, ns3::AttributeValue const & value) [member function] + cls.add_method('Set', + 'void', + [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')]) + ## ripng-helper.h (module 'internet'): int64_t ns3::RipNgHelper::AssignStreams(ns3::NodeContainer c, int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('ns3::NodeContainer', 'c'), param('int64_t', 'stream')]) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::SetDefaultRouter(ns3::Ptr node, ns3::Ipv6Address nextHop, uint32_t interface) [member function] + cls.add_method('SetDefaultRouter', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface')]) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::ExcludeInterface(ns3::Ptr node, uint32_t interface) [member function] + cls.add_method('ExcludeInterface', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node'), param('uint32_t', 'interface')]) + ## ripng-helper.h (module 'internet'): void ns3::RipNgHelper::SetInterfaceMetric(ns3::Ptr node, uint32_t interface, uint8_t metric) [member function] + cls.add_method('SetInterfaceMetric', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node'), param('uint32_t', 'interface'), param('uint8_t', 'metric')]) + return + +def register_Ns3RipNgRoutingTableEntry_methods(root_module, cls): + cls.add_output_stream_operator() + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry(ns3::RipNgRoutingTableEntry const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgRoutingTableEntry const &', 'arg0')]) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry() [constructor] + cls.add_constructor([]) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry(ns3::Ipv6Address network, ns3::Ipv6Prefix networkPrefix, ns3::Ipv6Address nextHop, uint32_t interface, ns3::Ipv6Address prefixToUse) [constructor] + cls.add_constructor([param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'networkPrefix'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'prefixToUse')]) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::RipNgRoutingTableEntry(ns3::Ipv6Address network, ns3::Ipv6Prefix networkPrefix, uint32_t interface) [constructor] + cls.add_constructor([param('ns3::Ipv6Address', 'network'), param('ns3::Ipv6Prefix', 'networkPrefix'), param('uint32_t', 'interface')]) + ## ripng.h (module 'internet'): uint8_t ns3::RipNgRoutingTableEntry::GetRouteMetric() const [member function] + cls.add_method('GetRouteMetric', + 'uint8_t', + [], + is_const=True) + ## ripng.h (module 'internet'): ns3::RipNgRoutingTableEntry::Status_e ns3::RipNgRoutingTableEntry::GetRouteStatus() const [member function] + cls.add_method('GetRouteStatus', + 'ns3::RipNgRoutingTableEntry::Status_e', + [], + is_const=True) + ## ripng.h (module 'internet'): uint16_t ns3::RipNgRoutingTableEntry::GetRouteTag() const [member function] + cls.add_method('GetRouteTag', + 'uint16_t', + [], + is_const=True) + ## ripng.h (module 'internet'): bool ns3::RipNgRoutingTableEntry::IsRouteChanged() const [member function] + cls.add_method('IsRouteChanged', + 'bool', + [], + is_const=True) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteChanged(bool changed) [member function] + cls.add_method('SetRouteChanged', + 'void', + [param('bool', 'changed')]) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteMetric(uint8_t routeMetric) [member function] + cls.add_method('SetRouteMetric', + 'void', + [param('uint8_t', 'routeMetric')]) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteStatus(ns3::RipNgRoutingTableEntry::Status_e status) [member function] + cls.add_method('SetRouteStatus', + 'void', + [param('ns3::RipNgRoutingTableEntry::Status_e', 'status')]) + ## ripng.h (module 'internet'): void ns3::RipNgRoutingTableEntry::SetRouteTag(uint16_t routeTag) [member function] + cls.add_method('SetRouteTag', + 'void', + [param('uint16_t', 'routeTag')]) + return + def register_Ns3RttHistory_methods(root_module, cls): ## rtt-estimator.h (module 'internet'): ns3::RttHistory::RttHistory(ns3::SequenceNumber32 s, uint32_t c, ns3::Time t) [constructor] cls.add_constructor([param('ns3::SequenceNumber32', 's'), param('uint32_t', 'c'), param('ns3::Time', 't')]) @@ -4453,11 +4582,11 @@ def register_Ns3SequenceNumber32_methods(root_module, cls): cls.add_binary_comparison_operator('!=') - cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('ns3::SequenceNumber< unsigned int, int > const &', 'right')) - cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', 'right')) - cls.add_inplace_numeric_operator('+=', param('int', 'right')) - cls.add_binary_numeric_operator('-', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', 'right')) - cls.add_inplace_numeric_operator('-=', param('int', 'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('ns3::SequenceNumber< unsigned int, int > const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', u'right')) + cls.add_inplace_numeric_operator('+=', param('int', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::SequenceNumber32'], root_module['ns3::SequenceNumber32'], param('int', u'right')) + cls.add_inplace_numeric_operator('-=', param('int', u'right')) cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('==') @@ -4663,6 +4792,14 @@ [param('uint8_t', 'v')]) return +def register_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + return + def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) @@ -5082,61 +5219,17 @@ def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_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_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) 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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -5144,6 +5237,8 @@ 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(long double v) [constructor] + cls.add_constructor([param('long 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] @@ -5184,6 +5279,8 @@ cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3Chunk_methods(root_module, cls): @@ -7524,6 +7621,143 @@ is_const=True, visibility='protected') return +def register_Ns3RipNgHeader_methods(root_module, cls): + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::RipNgHeader(ns3::RipNgHeader const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgHeader const &', 'arg0')]) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::RipNgHeader() [constructor] + cls.add_constructor([]) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::AddRte(ns3::RipNgRte rte) [member function] + cls.add_method('AddRte', + 'void', + [param('ns3::RipNgRte', 'rte')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::ClearRtes() [member function] + cls.add_method('ClearRtes', + 'void', + []) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgHeader::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## ripng-header.h (module 'internet'): ns3::RipNgHeader::Command_e ns3::RipNgHeader::GetCommand() const [member function] + cls.add_method('GetCommand', + 'ns3::RipNgHeader::Command_e', + [], + is_const=True) + ## ripng-header.h (module 'internet'): ns3::TypeId ns3::RipNgHeader::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): std::list > ns3::RipNgHeader::GetRteList() const [member function] + cls.add_method('GetRteList', + 'std::list< ns3::RipNgRte >', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint16_t ns3::RipNgHeader::GetRteNumber() const [member function] + cls.add_method('GetRteNumber', + 'uint16_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgHeader::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): static ns3::TypeId ns3::RipNgHeader::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgHeader::SetCommand(ns3::RipNgHeader::Command_e command) [member function] + cls.add_method('SetCommand', + 'void', + [param('ns3::RipNgHeader::Command_e', 'command')]) + return + +def register_Ns3RipNgRte_methods(root_module, cls): + ## ripng-header.h (module 'internet'): ns3::RipNgRte::RipNgRte(ns3::RipNgRte const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNgRte const &', 'arg0')]) + ## ripng-header.h (module 'internet'): ns3::RipNgRte::RipNgRte() [constructor] + cls.add_constructor([]) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgRte::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## ripng-header.h (module 'internet'): ns3::TypeId ns3::RipNgRte::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): ns3::Ipv6Address ns3::RipNgRte::GetPrefix() const [member function] + cls.add_method('GetPrefix', + 'ns3::Ipv6Address', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint8_t ns3::RipNgRte::GetPrefixLen() const [member function] + cls.add_method('GetPrefixLen', + 'uint8_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint8_t ns3::RipNgRte::GetRouteMetric() const [member function] + cls.add_method('GetRouteMetric', + 'uint8_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint16_t ns3::RipNgRte::GetRouteTag() const [member function] + cls.add_method('GetRouteTag', + 'uint16_t', + [], + is_const=True) + ## ripng-header.h (module 'internet'): uint32_t ns3::RipNgRte::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): static ns3::TypeId ns3::RipNgRte::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetPrefix(ns3::Ipv6Address prefix) [member function] + cls.add_method('SetPrefix', + 'void', + [param('ns3::Ipv6Address', 'prefix')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetPrefixLen(uint8_t prefixLen) [member function] + cls.add_method('SetPrefixLen', + 'void', + [param('uint8_t', 'prefixLen')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetRouteMetric(uint8_t routeMetric) [member function] + cls.add_method('SetRouteMetric', + 'void', + [param('uint8_t', 'routeMetric')]) + ## ripng-header.h (module 'internet'): void ns3::RipNgRte::SetRouteTag(uint16_t routeTag) [member function] + cls.add_method('SetRouteTag', + 'void', + [param('uint16_t', 'routeTag')]) + return + def register_Ns3RttEstimator_methods(root_module, cls): ## rtt-estimator.h (module 'internet'): ns3::RttEstimator::RttEstimator() [constructor] cls.add_constructor([]) @@ -9547,12 +9781,14 @@ def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') - cls.add_inplace_numeric_operator('+=', 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_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', 'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) 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 &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') @@ -9578,6 +9814,11 @@ 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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', @@ -11746,6 +11987,11 @@ 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) + ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] + cls.add_method('IsUnicast', + 'bool', + [param('ns3::Ipv4Address', 'ad')], + is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', @@ -12366,6 +12612,11 @@ 'ns3::Ptr< ns3::NetDevice >', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetProtocol(int protocolNumber) const [member function] + cls.add_method('GetProtocol', + 'ns3::Ptr< ns3::IpL4Protocol >', + [param('int', 'protocolNumber')], + is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ptr ns3::Ipv6::GetRoutingProtocol() const [member function] cls.add_method('GetRoutingProtocol', 'ns3::Ptr< ns3::Ipv6RoutingProtocol >', @@ -12436,6 +12687,11 @@ 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) + ## ipv6.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_pure_virtual=True, is_virtual=True) ## ipv6.h (module 'internet'): ns3::Ipv6::IF_ANY [variable] cls.add_static_attribute('IF_ANY', 'uint32_t const', is_const=True) ## ipv6.h (module 'internet'): bool ns3::Ipv6::GetIpForward() const [member function] @@ -12524,15 +12780,15 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_pure_virtual=True, is_virtual=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::ProcessOptions(ns3::Ptr & packet, uint8_t offset, uint8_t length, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6Extension::ProcessOptions(ns3::Ptr & packet, uint8_t offset, uint8_t length, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('ProcessOptions', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('uint8_t', 'length'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('uint8_t', 'length'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): void ns3::Ipv6Extension::SetNode(ns3::Ptr node) [member function] cls.add_method('SetNode', @@ -12555,10 +12811,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionAH::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionAH::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionAH::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12649,10 +12905,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionDestination::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionDestination::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionDestination::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12710,10 +12966,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionESP::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionESP::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionESP::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12775,10 +13031,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionFragment::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionFragment::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionFragment::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12868,10 +13124,10 @@ 'ns3::TypeId', [], is_static=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionHopByHop::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionHopByHop::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionHopByHop::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -12956,10 +13212,10 @@ 'uint8_t', [], is_const=True, is_virtual=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionRouting::EXT_NUMBER [variable] cls.add_static_attribute('EXT_NUMBER', 'uint8_t const', is_const=True) @@ -13169,7 +13425,7 @@ cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber')], - is_const=True) + is_const=True, is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::CreateRawSocket() [member function] cls.add_method('CreateRawSocket', 'ns3::Ptr< ns3::Socket >', @@ -13304,6 +13560,11 @@ 'void', [param('uint32_t', 'i'), param('bool', 'val')], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): ns3::Ipv6Address ns3::Ipv6L3Protocol::SourceAddressSelection(uint32_t interface, ns3::Ipv6Address dest) [member function] + cls.add_method('SourceAddressSelection', + 'ns3::Ipv6Address', + [param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'dest')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): ns3::Ptr ns3::Ipv6L3Protocol::GetNetDevice(uint32_t i) [member function] cls.add_method('GetNetDevice', 'ns3::Ptr< ns3::NetDevice >', @@ -13332,6 +13593,11 @@ 'void', [], is_virtual=True) + ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::ReportDrop(ns3::Ipv6Header ipHeader, ns3::Ptr p, ns3::Ipv6L3Protocol::DropReason dropReason) [member function] + cls.add_method('ReportDrop', + 'void', + [param('ns3::Ipv6Header', 'ipHeader'), param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6L3Protocol::DropReason', 'dropReason')], + is_virtual=True) ## ipv6-l3-protocol.h (module 'internet'): void ns3::Ipv6L3Protocol::DoDispose() [member function] cls.add_method('DoDispose', 'void', @@ -14596,10 +14862,10 @@ 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) - ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr arg0) [member function] + ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr nixVector) [member function] cls.add_method('SetNixVector', 'void', - [param('ns3::Ptr< ns3::NixVector >', 'arg0')]) + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): @@ -14672,6 +14938,104 @@ is_const=True, is_virtual=True) return +def register_Ns3RipNg_methods(root_module, cls): + ## ripng.h (module 'internet'): ns3::RipNg::RipNg(ns3::RipNg const & arg0) [copy constructor] + cls.add_constructor([param('ns3::RipNg const &', 'arg0')]) + ## ripng.h (module 'internet'): ns3::RipNg::RipNg() [constructor] + cls.add_constructor([]) + ## ripng.h (module 'internet'): void ns3::RipNg::AddDefaultRouteTo(ns3::Ipv6Address nextHop, uint32_t interface) [member function] + cls.add_method('AddDefaultRouteTo', + 'void', + [param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface')]) + ## ripng.h (module 'internet'): int64_t ns3::RipNg::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## ripng.h (module 'internet'): std::set, std::allocator > ns3::RipNg::GetInterfaceExclusions() const [member function] + cls.add_method('GetInterfaceExclusions', + 'std::set< unsigned int >', + [], + is_const=True) + ## ripng.h (module 'internet'): uint8_t ns3::RipNg::GetInterfaceMetric(uint32_t interface) const [member function] + cls.add_method('GetInterfaceMetric', + 'uint8_t', + [param('uint32_t', 'interface')], + is_const=True) + ## ripng.h (module 'internet'): static ns3::TypeId ns3::RipNg::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyAddAddress(uint32_t interface, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('NotifyAddAddress', + 'void', + [param('uint32_t', 'interface'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyAddRoute(ns3::Ipv6Address dst, ns3::Ipv6Prefix mask, ns3::Ipv6Address nextHop, uint32_t interface, ns3::Ipv6Address prefixToUse=ns3::Ipv6Address::GetZero( )) [member function] + cls.add_method('NotifyAddRoute', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('ns3::Ipv6Prefix', 'mask'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'prefixToUse', default_value='ns3::Ipv6Address::GetZero( )')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyInterfaceDown(uint32_t interface) [member function] + cls.add_method('NotifyInterfaceDown', + 'void', + [param('uint32_t', 'interface')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyInterfaceUp(uint32_t interface) [member function] + cls.add_method('NotifyInterfaceUp', + 'void', + [param('uint32_t', 'interface')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyRemoveAddress(uint32_t interface, ns3::Ipv6InterfaceAddress address) [member function] + cls.add_method('NotifyRemoveAddress', + 'void', + [param('uint32_t', 'interface'), param('ns3::Ipv6InterfaceAddress', 'address')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::NotifyRemoveRoute(ns3::Ipv6Address dst, ns3::Ipv6Prefix mask, ns3::Ipv6Address nextHop, uint32_t interface, ns3::Ipv6Address prefixToUse=ns3::Ipv6Address::GetZero( )) [member function] + cls.add_method('NotifyRemoveRoute', + 'void', + [param('ns3::Ipv6Address', 'dst'), param('ns3::Ipv6Prefix', 'mask'), param('ns3::Ipv6Address', 'nextHop'), param('uint32_t', 'interface'), param('ns3::Ipv6Address', 'prefixToUse', default_value='ns3::Ipv6Address::GetZero( )')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::PrintRoutingTable(ns3::Ptr stream) const [member function] + cls.add_method('PrintRoutingTable', + 'void', + [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], + is_const=True, is_virtual=True) + ## ripng.h (module 'internet'): bool ns3::RipNg::RouteInput(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr idev, ns3::Callback,ns3::Ptr,ns3::Ptr,const ns3::Ipv6Header&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ucb, ns3::Callback,ns3::Ptr,ns3::Ptr,const ns3::Ipv6Header&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> mcb, ns3::Callback,const ns3::Ipv6Header&,unsigned int,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> lcb, ns3::Callback,const ns3::Ipv6Header&,ns3::Socket::SocketErrno,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ecb) [member function] + cls.add_method('RouteInput', + 'bool', + [param('ns3::Ptr< ns3::Packet const >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice const >', 'idev'), param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice const >, ns3::Ptr< ns3::Ipv6Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ucb'), param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice const >, ns3::Ptr< ns3::Ipv6MulticastRoute >, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'mcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'lcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv6Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ecb')], + is_virtual=True) + ## ripng.h (module 'internet'): ns3::Ptr ns3::RipNg::RouteOutput(ns3::Ptr p, ns3::Ipv6Header const & header, ns3::Ptr oif, ns3::Socket::SocketErrno & sockerr) [member function] + cls.add_method('RouteOutput', + 'ns3::Ptr< ns3::Ipv6Route >', + [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv6Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice >', 'oif'), param('ns3::Socket::SocketErrno &', 'sockerr')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::SetInterfaceExclusions(std::set, std::allocator > exceptions) [member function] + cls.add_method('SetInterfaceExclusions', + 'void', + [param('std::set< unsigned int >', 'exceptions')]) + ## ripng.h (module 'internet'): void ns3::RipNg::SetInterfaceMetric(uint32_t interface, uint8_t metric) [member function] + cls.add_method('SetInterfaceMetric', + 'void', + [param('uint32_t', 'interface'), param('uint8_t', 'metric')]) + ## ripng.h (module 'internet'): void ns3::RipNg::SetIpv6(ns3::Ptr ipv6) [member function] + cls.add_method('SetIpv6', + 'void', + [param('ns3::Ptr< ns3::Ipv6 >', 'ipv6')], + is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='protected', is_virtual=True) + ## ripng.h (module 'internet'): void ns3::RipNg::DoInitialize() [member function] + cls.add_method('DoInitialize', + 'void', + [], + visibility='protected', is_virtual=True) + return + def register_Ns3TcpL4Protocol_methods(root_module, cls): ## tcp-l4-protocol.h (module 'internet'): ns3::TcpL4Protocol::PROT_NUMBER [variable] cls.add_static_attribute('PROT_NUMBER', 'uint8_t const', is_const=True) @@ -15975,10 +16339,10 @@ 'uint8_t', [], is_const=True, is_virtual=True) - ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionLooseRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & isDropped) [member function] + ## ipv6-extension.h (module 'internet'): uint8_t ns3::Ipv6ExtensionLooseRouting::Process(ns3::Ptr & packet, uint8_t offset, ns3::Ipv6Header const & ipv6Header, ns3::Ipv6Address dst, uint8_t * nextHeader, bool & stopProcessing, bool & isDropped, ns3::Ipv6L3Protocol::DropReason & dropReason) [member function] cls.add_method('Process', 'uint8_t', - [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'isDropped')], + [param('ns3::Ptr< ns3::Packet > &', 'packet'), param('uint8_t', 'offset'), param('ns3::Ipv6Header const &', 'ipv6Header'), param('ns3::Ipv6Address', 'dst'), param('uint8_t *', 'nextHeader'), param('bool &', 'stopProcessing'), param('bool &', 'isDropped'), param('ns3::Ipv6L3Protocol::DropReason &', 'dropReason')], is_virtual=True) ## ipv6-extension.h (module 'internet'): ns3::Ipv6ExtensionLooseRouting::TYPE_ROUTING [variable] cls.add_static_attribute('TYPE_ROUTING', 'uint8_t const', is_const=True) diff -Naur ns-3.19/src/internet/doc/ipv6.rst ns-3.20/src/internet/doc/ipv6.rst --- ns-3.19/src/internet/doc/ipv6.rst 2014-06-17 10:34:00.458636507 -0700 +++ ns-3.20/src/internet/doc/ipv6.rst 2014-06-17 10:33:13.779996841 -0700 @@ -157,6 +157,33 @@ all the nodes will also have a link-local address. Typically the first address on an interface will be the link-local one, with the global address(es) being the following ones. +Note that the global addesses will be derived from the MAC address. As a consequence, expect +to have addresses similar to ``2001:db8::200:ff:fe00:1``. + +It is possible to repeat the above to assign more than one global address to a node. +However, due to the ``Ipv6AddressHelper`` singleton nature, one should first assign all the +adddresses of a network, then change the network base (``SetBase``), then do a new assignment. + +Alternatively, it is possible to assign a specific address to a node: + +:: + + Ptr n0 = CreateObject (); + NodeContainer net (n0); + CsmaHelper csma; + NetDeviceContainer ndc = csma.Install (net); + + NS_LOG_INFO ("Specifically Assign an IPv6 Address."); + Ipv6AddressHelper ipv6; + Ptr device = ndc.Get (0); + Ptr node = device->GetNode (); + Ptr ipv6proto = node->GetObject (); + int32_t ifIndex = 0; + ifIndex = ipv6proto->GetInterfaceForDevice (device); + Ipv6InterfaceAddress ipv6Addr = Ipv6InterfaceAddress (Ipv6Address ("2001:db8:f00d:cafe::42"), Ipv6Prefix (64)); + ipv6proto->AddAddress (ifIndex, ipv6Addr); + + Auto-generated IPv6 adddresses ############################## diff -Naur ns-3.19/src/internet/doc/routing-overview.rst ns-3.20/src/internet/doc/routing-overview.rst --- ns-3.19/src/internet/doc/routing-overview.rst 2014-06-17 10:34:00.459636499 -0700 +++ ns-3.20/src/internet/doc/routing-overview.rst 2014-06-17 10:33:13.780996834 -0700 @@ -215,7 +215,7 @@ Unicast routing *************** -There are presently seven unicast routing protocols defined for IPv4 and two for +There are presently seven unicast routing protocols defined for IPv4 and three for IPv6: * class Ipv4StaticRouting (covering both unicast and multicast) @@ -232,19 +232,20 @@ stores source routes in a packet header field) * class Ipv6ListRouting (used to store a prioritized list of routing protocols) * class Ipv6StaticRouting +* class RipNg - the IPv6 RIPng protocol (:rfc:`2080`) In the future, this architecture should also allow someone to implement a Linux-like implementation with routing cache, or a Click modular router, but those are out of scope for now. -Ipv4ListRouting -+++++++++++++++ +Ipv[4,6]ListRouting ++++++++++++++++++++ -This section describes the current default |ns3| Ipv4RoutingProtocol. Typically, +This section describes the current default |ns3| Ipv[4,6]RoutingProtocol. Typically, multiple routing protocols are supported in user space and coordinate to write a single forwarding table in the kernel. Presently in |ns3|, the implementation instead allows for multiple routing protocols to build/keep their own routing -state, and the IPv4 implementation will query each one of these routing +state, and the IP implementation will query each one of these routing protocols (in some order determined by the simulation author) until a route is found. @@ -254,23 +255,26 @@ (e.g., source routing) is used to determine the next hop, and on-demand routing approaches where packets must be cached. -Ipv4ListRouting::AddRoutingProtocol -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Ipv[4,6]4ListRouting::AddRoutingProtocol +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -Class Ipv4ListRouting provides a pure virtual function declaration for the -method that allows one to add a routing protocol:: +Classes Ipv4ListRouting and Ipv6ListRouting provides a pure virtual function declaration +for the method that allows one to add a routing protocol:: void AddRoutingProtocol (Ptr routingProtocol, int16_t priority); -This method is implemented by class Ipv4ListRoutingImpl in the internet-stack -module. + void AddRoutingProtocol (Ptr routingProtocol, + int16_t priority); + +These methods are implemented respectively by class Ipv4ListRoutingImpl and by class +Ipv6ListRoutingImpl in the internet module. The priority variable above governs the priority in which the routing protocols are inserted. Notice that it is a signed int. By default in |ns3|, the helper -classes will instantiate a Ipv4ListRoutingImpl object, and add to it an -Ipv4StaticRoutingImpl object at priority zero. Internally, a list of -Ipv4RoutingProtocols is stored, and and the routing protocols are each consulted +classes will instantiate a Ipv[4,6]ListRoutingImpl object, and add to it an +Ipv[4,6]StaticRoutingImpl object at priority zero. Internally, a list of +Ipv[4,6]RoutingProtocols is stored, and and the routing protocols are each consulted in decreasing order of priority to see whether a match is found. Therefore, if you want your Ipv4RoutingProtocol to have priority lower than the static routing, insert it with priority less than 0; e.g.:: @@ -330,6 +334,116 @@ notifications; i.e. the topology changes are due to loss/gain of connectivity over a wireless channel. +RIPng ++++++ + +This IPv6 routing protocol (:rfc:`2080`) is the evolution of the well-known +RIPv1 anf RIPv2 (see :rfc:`1058` and :rfc:`1723`) routing protocols for IPv4. + +The protocol is very simple, and it is normally suitable for flat, simple +network topologies. + +RIPng is strongly based on RIPv1 and RIPv2, and it have the very same goals and +limitations. In particular, RIP considers any route with a metric equal or greater +than 16 as unreachable. As a consequence, the maximum number of hops is the +network must be less than 15 (the number of routers is not set). +Users are encouraged to read :rfc:`2080` and :rfc:`1058` to fully understand +RIPng behaviour and limitations. + + +Routing convergence +~~~~~~~~~~~~~~~~~~~ + +RIPng uses a Distance-Vector algorithm, and routes are updated according to +the Bellman-Ford algorithm (sometimes known as Ford-Fulkerson algorithm). +The algorithm has a convergence time of O(\|V\|*\|E\|) where \|V\| and \|E\| +are the number of vertices (routers) and edges (links) respectively. +It should be stressed that the convergence time is the number of steps in +the algorithm, and each step is triggered by a message. +Since Triggered Updates (i.e., when a route is changed) have a 1-5 seconds +cooldown, the toplogy can require some time to be stabilized. + +Users should be aware that, during routing tables construction, the routers +might drop packets. Data traffic should be sent only after a time long +enough to allow RIPng to build the network topology. +Usually 80 seconds should be enough to have a suboptimal (but working) +routing setup. This includes the time needed to propagate the routes to the +most distant router (16 hops) with Triggered Updates. + +If the network topology is changed (e.g., a link is broken), the recovery +time might be quite high, and it might be even higher than the initial +setup time. Moreover, the network topology recovery is affected by +the Split Horizoning strategy. + +The example ``examples/routing/ripng-simple-network.cc`` shows both the +network setup and network recovery phases. + +Split Horizoning +~~~~~~~~~~~~~~~~ + +Split Horizon is a strategy to prevent routing instability. Three options are possible: + +* No Split Horizon +* Split Horizon +* Poison Reverse + +In the first case, routes are advertised on all the router's interfaces. +In the second case, routers will not advertise a route on the interface +from which it was learned. +Poison Reverse will advertise the route on the interface from which it +was learned, but with a metric of 16 (infinity). +For a full analysis of the three techniques, see :rfc:`1058`, section 2.2. + +The example ``ripng-simple-network.cc`` is based on the network toplogy +described in the RFC, but it does not show the effect described there. + +The reason are the Triggered Updates, together with the fact that when a +router invalidates a route, it will immediately propagate the route +unreachability, thus preventing most of the issues described in the RFC. + +However, with complex toplogies, it is still possible to have route +instability phenomena similar to the one described in the RFC after a +link failure. As a consequence, all the considerations about Split Horizon +remanins valid. + + +Default routes +~~~~~~~~~~~~~~ + +RIPng protocol should be installed *only* on routers. As a consequence, +nodes will not know what is the default router. + +To overcome this limitation, users should either install the default route +manually (e.g., by resorting to Ipv6StaticRouting), or by using RADVd. +RADVd is available in |ns3| in the Applications module, and it is strongly +suggested. + +Protocol parameters and options +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The RIPng |ns3| implementation allows to change all the timers associated +with route updates and routes lifetime. + +Moreover, users can change the interface metrics on a per-node basis. + +The type of Split Horizoning (to avoid routes back-propagation) can be +selected on a per-node basis, with the choices being "no split horizon", +"split horizon" and "poison reverse". See :rfc:`2080` for further details, +and :rfc:`1058` for a complete discussion on the split horizoning strategies. + +Limitations +~~~~~~~~~~~ + +There is no support for the Next Hop option (:rfc:`2080`, Section 2.1.1). +The Next Hop option is useful when RIPng is not being run on all of the +routers on a network. +Support for this option may be considered in the future. + +There is no support for CIDR prefix aggregation. As a result, both routing +tables and route advertisements may be larger than necessary. +Prefix aggregation may be added in the future. + + .. _Multicast-routing: Multicast routing diff -Naur ns-3.19/src/internet/helper/ipv6-address-helper.cc ns-3.20/src/internet/helper/ipv6-address-helper.cc --- ns-3.19/src/internet/helper/ipv6-address-helper.cc 2014-06-17 10:34:00.468636430 -0700 +++ ns-3.20/src/internet/helper/ipv6-address-helper.cc 2014-06-17 10:33:13.789996764 -0700 @@ -34,8 +34,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6AddressHelper") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6AddressHelper"); Ipv6AddressHelper::Ipv6AddressHelper () { diff -Naur ns-3.19/src/internet/helper/ripng-helper.cc ns-3.20/src/internet/helper/ripng-helper.cc --- ns-3.19/src/internet/helper/ripng-helper.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/internet/helper/ripng-helper.cc 2014-06-17 10:33:13.793996733 -0700 @@ -0,0 +1,182 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze, Italy + * + * 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: Tommaso Pecorella + */ + +#include "ns3/node.h" +#include "ns3/node-list.h" +#include "ns3/ipv6-list-routing.h" +#include "ns3/ripng.h" +#include "ripng-helper.h" + +namespace ns3 { + +RipNgHelper::RipNgHelper () +{ + m_factory.SetTypeId ("ns3::RipNg"); +} + +RipNgHelper::RipNgHelper (const RipNgHelper &o) + : m_factory (o.m_factory) +{ + m_interfaceExclusions = o.m_interfaceExclusions; + m_interfaceMetrics = o.m_interfaceMetrics; +} + +RipNgHelper::~RipNgHelper () +{ + m_interfaceExclusions.clear (); + m_interfaceMetrics.clear (); +} + +RipNgHelper* +RipNgHelper::Copy (void) const +{ + return new RipNgHelper (*this); +} + +Ptr +RipNgHelper::Create (Ptr node) const +{ + Ptr ripng = m_factory.Create (); + + std::map, std::set >::const_iterator it = m_interfaceExclusions.find (node); + + if(it != m_interfaceExclusions.end ()) + { + ripng->SetInterfaceExclusions (it->second); + } + + std::map< Ptr, std::map >::const_iterator iter = m_interfaceMetrics.find (node); + + if(iter != m_interfaceMetrics.end ()) + { + std::map::const_iterator subiter; + for (subiter = iter->second.begin (); subiter != iter->second.end (); subiter++) + { + ripng->SetInterfaceMetric (subiter->first, subiter->second); + } + } + + node->AggregateObject (ripng); + return ripng; +} + +void +RipNgHelper::Set (std::string name, const AttributeValue &value) +{ + m_factory.Set (name, value); +} + + +int64_t +RipNgHelper::AssignStreams (NodeContainer c, int64_t stream) +{ + int64_t currentStream = stream; + Ptr node; + for (NodeContainer::Iterator i = c.Begin (); i != c.End (); ++i) + { + node = (*i); + Ptr ipv6 = node->GetObject (); + NS_ASSERT_MSG (ipv6, "Ipv6 not installed on node"); + Ptr proto = ipv6->GetRoutingProtocol (); + NS_ASSERT_MSG (proto, "Ipv6 routing not installed on node"); + Ptr ripng = DynamicCast (proto); + if (ripng) + { + currentStream += ripng->AssignStreams (currentStream); + continue; + } + // RIPng may also be in a list + Ptr list = DynamicCast (proto); + if (list) + { + int16_t priority; + Ptr listProto; + Ptr listRipng; + for (uint32_t i = 0; i < list->GetNRoutingProtocols (); i++) + { + listProto = list->GetRoutingProtocol (i, priority); + listRipng = DynamicCast (listProto); + if (listRipng) + { + currentStream += listRipng->AssignStreams (currentStream); + break; + } + } + } + } + return (currentStream - stream); +} + +void RipNgHelper::SetDefaultRouter (Ptr node, Ipv6Address nextHop, uint32_t interface) +{ + Ptr ipv6 = node->GetObject (); + NS_ASSERT_MSG (ipv6, "Ipv6 not installed on node"); + Ptr proto = ipv6->GetRoutingProtocol (); + NS_ASSERT_MSG (proto, "Ipv6 routing not installed on node"); + Ptr ripng = DynamicCast (proto); + if (ripng) + { + ripng->AddDefaultRouteTo (nextHop, interface); + } + // RIPng may also be in a list + Ptr list = DynamicCast (proto); + if (list) + { + int16_t priority; + Ptr listProto; + Ptr listRipng; + for (uint32_t i = 0; i < list->GetNRoutingProtocols (); i++) + { + listProto = list->GetRoutingProtocol (i, priority); + listRipng = DynamicCast (listProto); + if (listRipng) + { + listRipng->AddDefaultRouteTo (nextHop, interface); + break; + } + } + } +} + +void +RipNgHelper::ExcludeInterface (Ptr node, uint32_t interface) +{ + std::map< Ptr, std::set >::iterator it = m_interfaceExclusions.find (node); + + if (it == m_interfaceExclusions.end ()) + { + std::set interfaces; + interfaces.insert (interface); + + m_interfaceExclusions.insert (std::make_pair (node, interfaces)); + } + else + { + it->second.insert (interface); + } +} + +void RipNgHelper::SetInterfaceMetric (Ptr node, uint32_t interface, uint8_t metric) +{ + m_interfaceMetrics[node][interface] = metric; +} + +} + diff -Naur ns-3.19/src/internet/helper/ripng-helper.h ns-3.20/src/internet/helper/ripng-helper.h --- ns-3.19/src/internet/helper/ripng-helper.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/internet/helper/ripng-helper.h 2014-06-17 10:33:13.793996733 -0700 @@ -0,0 +1,148 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze, Italy + * + * 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: Tommaso Pecorella + */ + +#ifndef RIPNG_HELPER_H +#define RIPNG_HELPER_H + +#include "ns3/object-factory.h" +#include "ns3/ipv6-routing-helper.h" +#include "ns3/node-container.h" +#include "ns3/node.h" + +namespace ns3 { + +/** + * \brief Helper class that adds RIPng routing to nodes. + * + * This class is expected to be used in conjunction with + * ns3::InternetStackHelper::SetRoutingHelper + * + */ +class RipNgHelper : public Ipv6RoutingHelper +{ +public: + /* + * Construct an RipngHelper to make life easier while adding RIPng + * routing to nodes. + */ + RipNgHelper (); + + /** + * \brief Construct an RipngHelper from another previously + * initialized instance (Copy Constructor). + */ + RipNgHelper (const RipNgHelper &); + + virtual ~RipNgHelper (); + + /** + * \returns pointer to clone of this Ipv4NixVectorHelper + * + * This method is mainly for internal use by the other helpers; + * clients are expected to free the dynamic memory allocated by this method + */ + RipNgHelper* Copy (void) const; + + /** + * \param node the node on which the routing protocol will run + * \returns a newly-created routing protocol + * + * This method will be called by ns3::InternetStackHelper::Install + */ + virtual Ptr Create (Ptr node) const; + + /** + * \param name the name of the attribute to set + * \param value the value of the attribute to set. + * + * This method controls the attributes of ns3::Ripng + */ + void Set (std::string name, const AttributeValue &value); + + /** + * Assign a fixed random variable stream number to the random variables + * used by this model. Return the number of streams (possibly zero) that + * have been assigned. The Install() method should have previously been + * called by the user. + * + * \param c NetDeviceContainer of the set of net devices for which the + * SixLowPanNetDevice should be modified to use a fixed stream + * \param stream first stream index to use + * \return the number of stream indices assigned by this helper + */ + int64_t AssignStreams (NodeContainer c, int64_t stream); + + /** + * \brief Install a default route in the node. + * + * The traffic will be routed to the nextHop, located on the specified + * interface, unless a more specific route is found. + * + * \param node the node + * \param nextHop the next hop + * \param interface the network interface + */ + void SetDefaultRouter (Ptr node, Ipv6Address nextHop, uint32_t interface); + + /** + * \brief Exclude an interface from RIPng protocol. + * + * You have to call this function \a before installing RIPng in the nodes. + * + * Note: the exclusion means that RIPng will not be propagated on that interface. + * The network prefix on that interface will be still considered in RIPng. + * + * \param node the node + * \param interface the network interface to be excluded + */ + void ExcludeInterface (Ptr node, uint32_t interface); + + /** + * \brief Set a metric for an interface. + * + * You have to call this function \a before installing RIPng in the nodes. + * + * Note: RIPng will apply the metric on route message reception. + * As a consequence, interface metric should be set on the receiver. + * + * \param node the node + * \param interface the network interface + * \param metric the interface metric + */ + void SetInterfaceMetric (Ptr node, uint32_t interface, uint8_t metric); + +private: + /** + * \brief Assignment operator declared private and not implemented to disallow + * assignment and prevent the compiler from happily inserting its own. + */ + RipNgHelper &operator = (const RipNgHelper &o); + + ObjectFactory m_factory; //|< Object Factory + + std::map< Ptr, std::set > m_interfaceExclusions; //!< Interface Exclusion set + std::map< Ptr, std::map > m_interfaceMetrics; //!< Interface Metric set +}; + +} // namespace ns3 + + +#endif /* RIPNG_HELPER_H */ + diff -Naur ns-3.19/src/internet/model/arp-cache.cc ns-3.20/src/internet/model/arp-cache.cc --- ns-3.19/src/internet/model/arp-cache.cc 2014-06-17 10:34:00.472636399 -0700 +++ ns-3.20/src/internet/model/arp-cache.cc 2014-06-17 10:33:13.793996733 -0700 @@ -33,8 +33,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ArpCache) - ; +NS_OBJECT_ENSURE_REGISTERED (ArpCache); TypeId ArpCache::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/arp-header.cc ns-3.20/src/internet/model/arp-header.cc --- ns-3.19/src/internet/model/arp-header.cc 2014-06-17 10:34:00.473636391 -0700 +++ ns-3.20/src/internet/model/arp-header.cc 2014-06-17 10:33:13.794996726 -0700 @@ -27,8 +27,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ArpHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (ArpHeader); void ArpHeader::SetRequest (Address sourceHardwareAddress, diff -Naur ns-3.19/src/internet/model/arp-l3-protocol.cc ns-3.20/src/internet/model/arp-l3-protocol.cc --- ns-3.19/src/internet/model/arp-l3-protocol.cc 2014-06-17 10:34:00.474636383 -0700 +++ ns-3.20/src/internet/model/arp-l3-protocol.cc 2014-06-17 10:33:13.795996718 -0700 @@ -38,8 +38,7 @@ const uint16_t ArpL3Protocol::PROT_NUMBER = 0x0806; -NS_OBJECT_ENSURE_REGISTERED (ArpL3Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (ArpL3Protocol); TypeId ArpL3Protocol::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/global-router-interface.cc ns-3.20/src/internet/model/global-router-interface.cc --- ns-3.19/src/internet/model/global-router-interface.cc 2014-06-17 10:34:00.478636352 -0700 +++ ns-3.20/src/internet/model/global-router-interface.cc 2014-06-17 10:33:13.800996679 -0700 @@ -504,8 +504,7 @@ // // --------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED (GlobalRouter) - ; +NS_OBJECT_ENSURE_REGISTERED (GlobalRouter); TypeId GlobalRouter::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/icmpv4.cc ns-3.20/src/internet/model/icmpv4.cc --- ns-3.19/src/internet/model/icmpv4.cc 2014-06-17 10:34:00.481636330 -0700 +++ ns-3.20/src/internet/model/icmpv4.cc 2014-06-17 10:33:13.802996664 -0700 @@ -30,8 +30,7 @@ * Icmpv4Header ********************************************************/ -NS_OBJECT_ENSURE_REGISTERED (Icmpv4Header) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv4Header); TypeId Icmpv4Header::GetTypeId (void) @@ -134,8 +133,7 @@ * Icmpv4Echo ********************************************************/ -NS_OBJECT_ENSURE_REGISTERED (Icmpv4Echo) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv4Echo); void Icmpv4Echo::SetIdentifier (uint16_t id) @@ -272,8 +270,7 @@ * Icmpv4DestinationUnreachable ********************************************************/ -NS_OBJECT_ENSURE_REGISTERED (Icmpv4DestinationUnreachable) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv4DestinationUnreachable); TypeId Icmpv4DestinationUnreachable::GetTypeId (void) @@ -396,8 +393,7 @@ * Icmpv4TimeExceeded ********************************************************/ -NS_OBJECT_ENSURE_REGISTERED (Icmpv4TimeExceeded) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv4TimeExceeded); TypeId Icmpv4TimeExceeded::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/icmpv4-l4-protocol.cc ns-3.20/src/internet/model/icmpv4-l4-protocol.cc --- ns-3.19/src/internet/model/icmpv4-l4-protocol.cc 2014-06-17 10:34:00.480636337 -0700 +++ ns-3.20/src/internet/model/icmpv4-l4-protocol.cc 2014-06-17 10:33:13.801996672 -0700 @@ -11,11 +11,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Icmpv4L4Protocol") - ; +NS_LOG_COMPONENT_DEFINE ("Icmpv4L4Protocol"); -NS_OBJECT_ENSURE_REGISTERED (Icmpv4L4Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv4L4Protocol); // see rfc 792 const uint8_t Icmpv4L4Protocol::PROT_NUMBER = 1; diff -Naur ns-3.19/src/internet/model/icmpv6-header.cc ns-3.20/src/internet/model/icmpv6-header.cc --- ns-3.19/src/internet/model/icmpv6-header.cc 2014-06-17 10:34:00.482636322 -0700 +++ ns-3.20/src/internet/model/icmpv6-header.cc 2014-06-17 10:33:13.803996656 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Icmpv6Header) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6Header); TypeId Icmpv6Header::GetTypeId () { @@ -173,8 +172,7 @@ m_checksum = ~(it.CalculateIpChecksum (40)); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6NS) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6NS); Icmpv6NS::Icmpv6NS () { @@ -296,8 +294,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6NA) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6NA); TypeId Icmpv6NA::GetTypeId () { @@ -480,8 +477,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6RA) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6RA); TypeId Icmpv6RA::GetTypeId () { @@ -700,8 +696,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6RS) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6RS); TypeId Icmpv6RS::GetTypeId () { @@ -791,8 +786,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6Redirection) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6Redirection); TypeId Icmpv6Redirection::GetTypeId () { @@ -922,8 +916,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6Echo) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6Echo); TypeId Icmpv6Echo::GetTypeId () { @@ -1040,8 +1033,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6DestinationUnreachable) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6DestinationUnreachable); TypeId Icmpv6DestinationUnreachable::GetTypeId () { @@ -1138,8 +1130,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6TooBig) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6TooBig); TypeId Icmpv6TooBig::GetTypeId () { @@ -1249,8 +1240,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6TimeExceeded) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6TimeExceeded); TypeId Icmpv6TimeExceeded::GetTypeId () { @@ -1349,8 +1339,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6ParameterError) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6ParameterError); TypeId Icmpv6ParameterError::GetTypeId () { @@ -1460,8 +1449,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionHeader); TypeId Icmpv6OptionHeader::GetTypeId () { @@ -1539,8 +1527,7 @@ NS_LOG_FUNCTION (this << &start); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionMtu) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionMtu); TypeId Icmpv6OptionMtu::GetTypeId () { @@ -1636,8 +1623,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionPrefixInformation) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionPrefixInformation); TypeId Icmpv6OptionPrefixInformation::GetTypeId () { @@ -1810,8 +1796,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionLinkLayerAddress) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionLinkLayerAddress); TypeId Icmpv6OptionLinkLayerAddress::GetTypeId () { @@ -1910,16 +1895,16 @@ SetType (i.ReadU8 ()); SetLength (i.ReadU8 ()); - NS_ASSERT (GetLength () * 8 - 2 <= 32); + // -fstrict-overflow sensitive, see bug 1868 + NS_ASSERT (GetLength () * 8 <= 32 + 2); i.Read (mac, (GetLength () * 8) - 2); - m_addr.CopyFrom (mac, (GetLength () * 8)-2); + m_addr.CopyFrom (mac, (GetLength () * 8) - 2); return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionRedirected) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6OptionRedirected); TypeId Icmpv6OptionRedirected::GetTypeId () { diff -Naur ns-3.19/src/internet/model/icmpv6-l4-protocol.cc ns-3.20/src/internet/model/icmpv6-l4-protocol.cc --- ns-3.19/src/internet/model/icmpv6-l4-protocol.cc 2014-06-17 10:34:00.484636306 -0700 +++ ns-3.20/src/internet/model/icmpv6-l4-protocol.cc 2014-06-17 10:33:13.805996641 -0700 @@ -39,11 +39,9 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Icmpv6L4Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (Icmpv6L4Protocol); -NS_LOG_COMPONENT_DEFINE ("Icmpv6L4Protocol") - ; +NS_LOG_COMPONENT_DEFINE ("Icmpv6L4Protocol"); const uint8_t Icmpv6L4Protocol::PROT_NUMBER = 58; @@ -272,11 +270,14 @@ uint8_t nextHeader = ipHeader.GetNextHeader (); - Ptr l4 = ipv6->GetProtocol (nextHeader); - if (l4 != 0) + if (nextHeader != Icmpv6L4Protocol::PROT_NUMBER) { - l4->ReceiveIcmp (source, ipHeader.GetHopLimit (), icmp.GetType (), icmp.GetCode (), - info, ipHeader.GetSourceAddress (), ipHeader.GetDestinationAddress (), payload); + Ptr l4 = ipv6->GetProtocol (nextHeader); + if (l4 != 0) + { + l4->ReceiveIcmp (source, ipHeader.GetHopLimit (), icmp.GetType (), icmp.GetCode (), + info, ipHeader.GetSourceAddress (), ipHeader.GetDestinationAddress (), payload); + } } } diff -Naur ns-3.19/src/internet/model/ip-l4-protocol.cc ns-3.20/src/internet/model/ip-l4-protocol.cc --- ns-3.19/src/internet/model/ip-l4-protocol.cc 2014-06-17 10:34:00.484636306 -0700 +++ ns-3.20/src/internet/model/ip-l4-protocol.cc 2014-06-17 10:33:13.806996633 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (IpL4Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (IpL4Protocol); TypeId IpL4Protocol::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ipv4.cc ns-3.20/src/internet/model/ipv4.cc --- ns-3.19/src/internet/model/ipv4.cc 2014-06-17 10:34:00.501636175 -0700 +++ ns-3.20/src/internet/model/ipv4.cc 2014-06-17 10:33:13.823996502 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4); TypeId Ipv4::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ipv4-end-point-demux.cc ns-3.20/src/internet/model/ipv4-end-point-demux.cc --- ns-3.19/src/internet/model/ipv4-end-point-demux.cc 2014-06-17 10:34:00.486636291 -0700 +++ ns-3.20/src/internet/model/ipv4-end-point-demux.cc 2014-06-17 10:33:13.808996618 -0700 @@ -24,8 +24,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv4EndPointDemux") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv4EndPointDemux"); Ipv4EndPointDemux::Ipv4EndPointDemux () : m_ephemeral (49152), m_portLast (65535), m_portFirst (49152) diff -Naur ns-3.19/src/internet/model/ipv4-global-routing.cc ns-3.20/src/internet/model/ipv4-global-routing.cc --- ns-3.19/src/internet/model/ipv4-global-routing.cc 2014-06-17 10:34:00.488636275 -0700 +++ ns-3.20/src/internet/model/ipv4-global-routing.cc 2014-06-17 10:33:13.809996610 -0700 @@ -34,8 +34,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4GlobalRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4GlobalRouting); TypeId Ipv4GlobalRouting::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ipv4.h ns-3.20/src/internet/model/ipv4.h --- ns-3.19/src/internet/model/ipv4.h 2014-06-17 10:34:00.502636167 -0700 +++ ns-3.20/src/internet/model/ipv4.h 2014-06-17 10:33:13.823996502 -0700 @@ -24,7 +24,6 @@ #include "ns3/object.h" #include "ns3/socket.h" #include "ns3/callback.h" -#include "ns3/ip-l4-protocol.h" #include "ns3/ipv4-address.h" #include "ipv4-route.h" #include "ipv4-interface-address.h" @@ -35,6 +34,8 @@ class NetDevice; class Packet; class Ipv4RoutingProtocol; +class IpL4Protocol; +class Ipv4Header; /** * \ingroup internet diff -Naur ns-3.19/src/internet/model/ipv4-header.cc ns-3.20/src/internet/model/ipv4-header.cc --- ns-3.19/src/internet/model/ipv4-header.cc 2014-06-17 10:34:00.489636268 -0700 +++ ns-3.20/src/internet/model/ipv4-header.cc 2014-06-17 10:33:13.810996602 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4Header) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4Header); Ipv4Header::Ipv4Header () : m_calcChecksum (false), @@ -247,7 +246,8 @@ Ipv4Header::GetFragmentOffset (void) const { NS_LOG_FUNCTION (this); - if ((m_fragmentOffset+m_payloadSize+5*4) > 65535) + // -fstrict-overflow sensitive, see bug 1868 + if ( m_fragmentOffset + m_payloadSize > 65535 - 5*4 ) { NS_LOG_WARN("Fragment will exceed the maximum packet size once reassembled"); } diff -Naur ns-3.19/src/internet/model/ipv4-interface.cc ns-3.20/src/internet/model/ipv4-interface.cc --- ns-3.19/src/internet/model/ipv4-interface.cc 2014-06-17 10:34:00.491636252 -0700 +++ ns-3.20/src/internet/model/ipv4-interface.cc 2014-06-17 10:33:13.812996587 -0700 @@ -34,8 +34,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4Interface) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4Interface); TypeId Ipv4Interface::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ipv4-l3-protocol.cc ns-3.20/src/internet/model/ipv4-l3-protocol.cc --- ns-3.19/src/internet/model/ipv4-l3-protocol.cc 2014-06-17 10:34:00.493636237 -0700 +++ ns-3.20/src/internet/model/ipv4-l3-protocol.cc 2014-06-17 10:33:13.814996571 -0700 @@ -46,8 +46,7 @@ const uint16_t Ipv4L3Protocol::PROT_NUMBER = 0x0800; -NS_OBJECT_ENSURE_REGISTERED (Ipv4L3Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4L3Protocol); TypeId Ipv4L3Protocol::GetTypeId (void) @@ -91,8 +90,6 @@ } Ipv4L3Protocol::Ipv4L3Protocol() - : m_identification (0) - { NS_LOG_FUNCTION (this); } @@ -541,6 +538,35 @@ } bool +Ipv4L3Protocol::IsUnicast (Ipv4Address ad) const +{ + NS_LOG_FUNCTION (this << ad); + + if (ad.IsBroadcast () || ad.IsMulticast ()) + { + return false; + } + else + { + // check for subnet-broadcast + for (uint32_t ifaceIndex = 0; ifaceIndex < GetNInterfaces (); ifaceIndex++) + { + for (uint32_t j = 0; j < GetNAddresses (ifaceIndex); j++) + { + Ipv4InterfaceAddress ifAddr = GetAddress (ifaceIndex, j); + NS_LOG_LOGIC ("Testing address " << ad << " with subnet-directed broadcast " << ifAddr.GetBroadcast () ); + if (ad == ifAddr.GetBroadcast () ) + { + return false; + } + } + } + } + + return true; +} + +bool Ipv4L3Protocol::IsUnicast (Ipv4Address ad, Ipv4Mask interfaceMask) const { NS_LOG_FUNCTION (this << ad << interfaceMask); @@ -712,15 +738,18 @@ if (mayFragment == true) { ipHeader.SetMayFragment (); - ipHeader.SetIdentification (m_identification); - m_identification++; + ipHeader.SetIdentification (m_identification[protocol]); + m_identification[protocol]++; } else { ipHeader.SetDontFragment (); - // TBD: set to zero here; will cause traces to change - ipHeader.SetIdentification (m_identification); - m_identification++; + // RFC 6864 does not state anything about atomic datagrams + // identification requirement: + // >> Originating sources MAY set the IPv4 ID field of atomic datagrams + // to any value. + ipHeader.SetIdentification (m_identification[protocol]); + m_identification[protocol]++; } if (Node::ChecksumEnabled ()) { @@ -1290,8 +1319,8 @@ { NS_LOG_FUNCTION (this << packet << ipHeader << iif); - uint64_t addressCombination = uint64_t (ipHeader.GetSource ().Get ()) << 32 & uint64_t (ipHeader.GetDestination ().Get ()); - uint32_t idProto = uint32_t (ipHeader.GetIdentification ()) << 16 & uint32_t (ipHeader.GetProtocol ()); + uint64_t addressCombination = uint64_t (ipHeader.GetSource ().Get ()) << 32 | uint64_t (ipHeader.GetDestination ().Get ()); + uint32_t idProto = uint32_t (ipHeader.GetIdentification ()) << 16 | uint32_t (ipHeader.GetProtocol ()); std::pair key; bool ret = false; Ptr p = packet->Copy (); diff -Naur ns-3.19/src/internet/model/ipv4-l3-protocol.h ns-3.20/src/internet/model/ipv4-l3-protocol.h --- ns-3.19/src/internet/model/ipv4-l3-protocol.h 2014-06-17 10:34:00.493636237 -0700 +++ ns-3.20/src/internet/model/ipv4-l3-protocol.h 2014-06-17 10:33:13.814996571 -0700 @@ -35,6 +35,8 @@ #include "ns3/nstime.h" #include "ns3/simulator.h" +class Ipv4L3ProtocolTestCase; + namespace ns3 { class Packet; @@ -134,7 +136,7 @@ * This method is typically called by lower layers * to forward packets up the stack to the right protocol. */ - Ptr GetProtocol (int protocolNumber) const; + virtual Ptr GetProtocol (int protocolNumber) const; /** * \param protocol protocol to remove from this demux. * @@ -223,6 +225,18 @@ Ptr GetNetDevice (uint32_t i); + /** + * \brief Check if an IPv4 address is unicast according to the node. + * + * This function checks all the node's interfaces and the respective subnet masks. + * An address is considered unicast if it's not broadcast, subnet-broadcast or multicast. + * + * \param ad address + * + * \return true if the address is unicast + */ + bool IsUnicast (Ipv4Address ad) const; + protected: virtual void DoDispose (void); @@ -232,7 +246,7 @@ */ virtual void NotifyNewAggregate (); private: - friend class Ipv4L3ProtocolTestCase; + friend class ::Ipv4L3ProtocolTestCase; /** * \brief Copy constructor. @@ -394,7 +408,7 @@ Ipv4InterfaceList m_interfaces; //!< List of IPv4 interfaces. uint8_t m_defaultTos; //!< Default TOS uint8_t m_defaultTtl; //!< Default TTL - uint16_t m_identification; //!< Identification + std::map m_identification; //!< Identification (for each protocol) Ptr m_node; //!< Node attached to stack. /// Trace of sent packets diff -Naur ns-3.19/src/internet/model/ipv4-list-routing.cc ns-3.20/src/internet/model/ipv4-list-routing.cc --- ns-3.19/src/internet/model/ipv4-list-routing.cc 2014-06-17 10:34:00.494636229 -0700 +++ ns-3.20/src/internet/model/ipv4-list-routing.cc 2014-06-17 10:33:13.815996564 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4ListRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4ListRouting); TypeId Ipv4ListRouting::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ipv4-packet-probe.cc ns-3.20/src/internet/model/ipv4-packet-probe.cc --- ns-3.19/src/internet/model/ipv4-packet-probe.cc 2014-06-17 10:34:00.495636221 -0700 +++ ns-3.20/src/internet/model/ipv4-packet-probe.cc 2014-06-17 10:33:13.816996556 -0700 @@ -32,8 +32,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4PacketProbe) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4PacketProbe); TypeId Ipv4PacketProbe::GetTypeId () diff -Naur ns-3.19/src/internet/model/ipv4-raw-socket-factory.cc ns-3.20/src/internet/model/ipv4-raw-socket-factory.cc --- ns-3.19/src/internet/model/ipv4-raw-socket-factory.cc 2014-06-17 10:34:00.496636214 -0700 +++ ns-3.20/src/internet/model/ipv4-raw-socket-factory.cc 2014-06-17 10:33:13.818996541 -0700 @@ -25,8 +25,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4RawSocketFactory) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4RawSocketFactory); TypeId Ipv4RawSocketFactory::GetTypeId (void) { diff -Naur ns-3.19/src/internet/model/ipv4-raw-socket-impl.cc ns-3.20/src/internet/model/ipv4-raw-socket-impl.cc --- ns-3.19/src/internet/model/ipv4-raw-socket-impl.cc 2014-06-17 10:34:00.497636206 -0700 +++ ns-3.20/src/internet/model/ipv4-raw-socket-impl.cc 2014-06-17 10:33:13.818996541 -0700 @@ -17,8 +17,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4RawSocketImpl) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4RawSocketImpl); TypeId Ipv4RawSocketImpl::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ipv4-routing-protocol.cc ns-3.20/src/internet/model/ipv4-routing-protocol.cc --- ns-3.19/src/internet/model/ipv4-routing-protocol.cc 2014-06-17 10:34:00.499636190 -0700 +++ ns-3.20/src/internet/model/ipv4-routing-protocol.cc 2014-06-17 10:33:13.820996525 -0700 @@ -25,8 +25,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4RoutingProtocol) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4RoutingProtocol); TypeId Ipv4RoutingProtocol::GetTypeId (void) { diff -Naur ns-3.19/src/internet/model/ipv4-static-routing.cc ns-3.20/src/internet/model/ipv4-static-routing.cc --- ns-3.19/src/internet/model/ipv4-static-routing.cc 2014-06-17 10:34:00.501636175 -0700 +++ ns-3.20/src/internet/model/ipv4-static-routing.cc 2014-06-17 10:33:13.822996510 -0700 @@ -40,8 +40,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv4StaticRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv4StaticRouting); TypeId Ipv4StaticRouting::GetTypeId (void) @@ -627,17 +626,16 @@ { NS_LOG_FUNCTION (this << i); // Remove all static routes that are going through this interface - uint32_t j = 0; - while (j < GetNRoutes ()) + for (NetworkRoutesI it = m_networkRoutes.begin (); it != m_networkRoutes.end (); ) { - Ipv4RoutingTableEntry route = GetRoute (j); - if (route.GetInterface () == i) + if (it->first->GetInterface () == i) { - RemoveRoute (j); + delete it->first; + it = m_networkRoutes.erase (it); } else { - j++; + it++; } } } @@ -672,15 +670,19 @@ Ipv4Mask networkMask = address.GetMask (); // Remove all static routes that are going through this interface // which reference this network - for (uint32_t j = 0; j < GetNRoutes (); j++) + for (NetworkRoutesI it = m_networkRoutes.begin (); it != m_networkRoutes.end (); ) { - Ipv4RoutingTableEntry route = GetRoute (j); - if (route.GetInterface () == interface && - route.IsNetwork () && - route.GetDestNetwork () == networkAddress && - route.GetDestNetworkMask () == networkMask) + if (it->first->GetInterface () == interface + && it->first->IsNetwork () + && it->first->GetDestNetwork () == networkAddress + && it->first->GetDestNetworkMask () == networkMask) + { + delete it->first; + it = m_networkRoutes.erase (it); + } + else { - RemoveRoute (j); + it++; } } } diff -Naur ns-3.19/src/internet/model/ipv6.cc ns-3.20/src/internet/model/ipv6.cc --- ns-3.19/src/internet/model/ipv6.cc 2014-06-17 10:34:00.525635990 -0700 +++ ns-3.20/src/internet/model/ipv6.cc 2014-06-17 10:33:13.845996332 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6); TypeId Ipv6::GetTypeId (void) { diff -Naur ns-3.19/src/internet/model/ipv6-end-point.cc ns-3.20/src/internet/model/ipv6-end-point.cc --- ns-3.19/src/internet/model/ipv6-end-point.cc 2014-06-17 10:34:00.505636144 -0700 +++ ns-3.20/src/internet/model/ipv6-end-point.cc 2014-06-17 10:33:13.826996479 -0700 @@ -27,8 +27,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6EndPoint") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6EndPoint"); Ipv6EndPoint::Ipv6EndPoint (Ipv6Address addr, uint16_t port) : m_localAddr (addr), diff -Naur ns-3.19/src/internet/model/ipv6-end-point-demux.cc ns-3.20/src/internet/model/ipv6-end-point-demux.cc --- ns-3.19/src/internet/model/ipv6-end-point-demux.cc 2014-06-17 10:34:00.504636152 -0700 +++ ns-3.20/src/internet/model/ipv6-end-point-demux.cc 2014-06-17 10:33:13.825996486 -0700 @@ -24,8 +24,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6EndPointDemux") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6EndPointDemux"); Ipv6EndPointDemux::Ipv6EndPointDemux () : m_ephemeral (49152), diff -Naur ns-3.19/src/internet/model/ipv6-extension.cc ns-3.20/src/internet/model/ipv6-extension.cc --- ns-3.19/src/internet/model/ipv6-extension.cc 2014-06-17 10:34:00.508636121 -0700 +++ ns-3.20/src/internet/model/ipv6-extension.cc 2014-06-17 10:33:13.829996455 -0700 @@ -44,8 +44,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6Extension) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6Extension); TypeId Ipv6Extension::GetTypeId () { @@ -55,8 +54,6 @@ UintegerValue (0), MakeUintegerAccessor (&Ipv6Extension::GetExtensionNumber), MakeUintegerChecker ()) - .AddTraceSource ("Drop", "Drop IPv6 packet", - MakeTraceSourceAccessor (&Ipv6Extension::m_dropTrace)) ; return tid; } @@ -87,7 +84,15 @@ return m_node; } -uint8_t Ipv6Extension::ProcessOptions (Ptr& packet, uint8_t offset, uint8_t length, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6Extension::ProcessOptions (Ptr& packet, + uint8_t offset, + uint8_t length, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << length << ipv6Header << dst << nextHeader << isDropped); @@ -126,17 +131,19 @@ case 1: NS_LOG_LOGIC ("Unknown Option. Drop!"); - m_dropTrace (packet); optionLength = 0; isDropped = true; + stopProcessing = true; + dropReason = Ipv6L3Protocol::DROP_UNKNOWN_OPTION; break; case 2: NS_LOG_LOGIC ("Unknown Option. Drop!"); icmpv6->SendErrorParameterError (malformedPacket, ipv6Header.GetSourceAddress (), Icmpv6Header::ICMPV6_UNKNOWN_OPTION, offset + processedSize); - m_dropTrace (packet); optionLength = 0; isDropped = true; + stopProcessing = true; + dropReason = Ipv6L3Protocol::DROP_UNKNOWN_OPTION; break; case 3: @@ -145,15 +152,11 @@ if (!ipv6Header.GetDestinationAddress ().IsMulticast ()) { icmpv6->SendErrorParameterError (malformedPacket, ipv6Header.GetSourceAddress (), Icmpv6Header::ICMPV6_UNKNOWN_OPTION, offset + processedSize); - m_dropTrace (packet); - optionLength = 0; - isDropped = true; - break; } - - m_dropTrace (packet); optionLength = 0; isDropped = true; + stopProcessing = true; + dropReason = Ipv6L3Protocol::DROP_UNKNOWN_OPTION; break; default: @@ -183,8 +186,7 @@ return 1; } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionHopByHop) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionHopByHop); TypeId Ipv6ExtensionHopByHop::GetTypeId () { @@ -212,7 +214,14 @@ return EXT_NUMBER; } -uint8_t Ipv6ExtensionHopByHop::Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6ExtensionHopByHop::Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << ipv6Header << dst << nextHeader << isDropped); @@ -230,14 +239,13 @@ offset += processedSize; uint8_t length = hopbyhopHeader.GetLength () - hopbyhopHeader.GetOptionsOffset (); - processedSize += ProcessOptions (packet, offset, length, ipv6Header, dst, nextHeader, isDropped); + processedSize += ProcessOptions (packet, offset, length, ipv6Header, dst, nextHeader, stopProcessing, isDropped, dropReason); return processedSize; } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionDestination) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionDestination); TypeId Ipv6ExtensionDestination::GetTypeId () { @@ -265,7 +273,14 @@ return EXT_NUMBER; } -uint8_t Ipv6ExtensionDestination::Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6ExtensionDestination::Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << ipv6Header << dst << nextHeader << isDropped); @@ -283,14 +298,13 @@ offset += processedSize; uint8_t length = destinationHeader.GetLength () - destinationHeader.GetOptionsOffset (); - processedSize += ProcessOptions (packet, offset, length, ipv6Header, dst, nextHeader, isDropped); + processedSize += ProcessOptions (packet, offset, length, ipv6Header, dst, nextHeader, stopProcessing, isDropped, dropReason); return processedSize; } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionFragment) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionFragment); TypeId Ipv6ExtensionFragment::GetTypeId () { @@ -331,7 +345,14 @@ return EXT_NUMBER; } -uint8_t Ipv6ExtensionFragment::Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6ExtensionFragment::Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << ipv6Header << dst << nextHeader << isDropped); @@ -386,12 +407,11 @@ packet = fragments->GetPacket (); fragments->CancelTimeout (); m_fragments.erase (fragmentsId); - isDropped = false; + stopProcessing = false; } else { - // the fragment is not "dropped", but Ipv6L3Protocol::LocalDeliver must stop processing it. - isDropped = true; + stopProcessing = true; } return 0; @@ -573,7 +593,7 @@ void Ipv6ExtensionFragment::HandleFragmentsTimeout (std::pair fragmentsId, - Ipv6Header & ipHeader) + Ipv6Header ipHeader) { Ptr fragments; @@ -583,15 +603,17 @@ Ptr packet = fragments->GetPartialPacket (); - packet->AddHeader (ipHeader); - // if we have at least 8 bytes, we can send an ICMP. if ( packet->GetSize () > 8 ) { + Ptr p = packet->Copy (); + p->AddHeader (ipHeader); Ptr icmp = GetNode ()->GetObject (); - icmp->SendErrorTimeExceeded (packet, ipHeader.GetSourceAddress (), Icmpv6Header::ICMPV6_FRAGTIME); + icmp->SendErrorTimeExceeded (p, ipHeader.GetSourceAddress (), Icmpv6Header::ICMPV6_FRAGTIME); } - m_dropTrace (packet); + + Ptr ipL3 = GetNode ()->GetObject (); + ipL3->ReportDrop (ipHeader, packet, Ipv6L3Protocol::DROP_FRAGMENT_TIMEOUT); // clear the buffers m_fragments.erase (fragmentsId); @@ -707,8 +729,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionRouting); TypeId Ipv6ExtensionRouting::GetTypeId () { @@ -742,7 +763,14 @@ return 0; } -uint8_t Ipv6ExtensionRouting::Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6ExtensionRouting::Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << ipv6Header << dst << nextHeader << isDropped); @@ -782,19 +810,19 @@ NS_LOG_LOGIC ("Malformed header. Drop!"); icmpv6->SendErrorParameterError (malformedPacket, ipv6Header.GetSourceAddress (), Icmpv6Header::ICMPV6_MALFORMED_HEADER, offset + 1); - m_dropTrace (packet); + dropReason = Ipv6L3Protocol::DROP_MALFORMED_HEADER; isDropped = true; + stopProcessing = true; } return routingLength; } - return ipv6ExtensionRouting->Process (packet, offset, ipv6Header, dst, (uint8_t *)0, isDropped); + return ipv6ExtensionRouting->Process (packet, offset, ipv6Header, dst, (uint8_t *)0, stopProcessing, isDropped, dropReason); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionRoutingDemux) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionRoutingDemux); TypeId Ipv6ExtensionRoutingDemux::GetTypeId () { @@ -856,8 +884,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionLooseRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionLooseRouting); TypeId Ipv6ExtensionLooseRouting::GetTypeId () { @@ -885,7 +912,14 @@ return TYPE_ROUTING; } -uint8_t Ipv6ExtensionLooseRouting::Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6ExtensionLooseRouting::Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << ipv6Header << dst << nextHeader << isDropped); @@ -938,8 +972,9 @@ { NS_LOG_LOGIC ("Malformed header. Drop!"); icmpv6->SendErrorParameterError (malformedPacket, srcAddress, Icmpv6Header::ICMPV6_MALFORMED_HEADER, offset + 1); - m_dropTrace (packet); + dropReason = Ipv6L3Protocol::DROP_MALFORMED_HEADER; isDropped = true; + stopProcessing = true; return routingHeader.GetSerializedSize (); } @@ -947,8 +982,9 @@ { NS_LOG_LOGIC ("Malformed header. Drop!"); icmpv6->SendErrorParameterError (malformedPacket, srcAddress, Icmpv6Header::ICMPV6_MALFORMED_HEADER, offset + 3); - m_dropTrace (packet); + dropReason = Ipv6L3Protocol::DROP_MALFORMED_HEADER; isDropped = true; + stopProcessing = true; return routingHeader.GetSerializedSize (); } @@ -958,8 +994,9 @@ if (nextAddress.IsMulticast () || destAddress.IsMulticast ()) { - m_dropTrace (packet); + dropReason = Ipv6L3Protocol::DROP_MALFORMED_HEADER; isDropped = true; + stopProcessing = true; return routingHeader.GetSerializedSize (); } @@ -970,8 +1007,9 @@ { NS_LOG_LOGIC ("Time Exceeded : Hop Limit <= 1. Drop!"); icmpv6->SendErrorTimeExceeded (malformedPacket, srcAddress, Icmpv6Header::ICMPV6_HOPLIMIT); - m_dropTrace (packet); + dropReason = Ipv6L3Protocol::DROP_MALFORMED_HEADER; isDropped = true; + stopProcessing = true; return routingHeader.GetSerializedSize (); } @@ -1010,8 +1048,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionESP) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionESP); TypeId Ipv6ExtensionESP::GetTypeId () { @@ -1039,7 +1076,14 @@ return EXT_NUMBER; } -uint8_t Ipv6ExtensionESP::Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6ExtensionESP::Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << ipv6Header << dst << nextHeader << isDropped); @@ -1049,8 +1093,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionAH) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionAH); TypeId Ipv6ExtensionAH::GetTypeId () { @@ -1078,7 +1121,14 @@ return EXT_NUMBER; } -uint8_t Ipv6ExtensionAH::Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) +uint8_t Ipv6ExtensionAH::Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) { NS_LOG_FUNCTION (this << packet << offset << ipv6Header << dst << nextHeader << isDropped); diff -Naur ns-3.19/src/internet/model/ipv6-extension-demux.cc ns-3.20/src/internet/model/ipv6-extension-demux.cc --- ns-3.19/src/internet/model/ipv6-extension-demux.cc 2014-06-17 10:34:00.506636137 -0700 +++ ns-3.20/src/internet/model/ipv6-extension-demux.cc 2014-06-17 10:33:13.827996471 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionDemux) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionDemux); TypeId Ipv6ExtensionDemux::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-extension.h ns-3.20/src/internet/model/ipv6-extension.h --- ns-3.19/src/internet/model/ipv6-extension.h 2014-06-17 10:34:00.508636121 -0700 +++ ns-3.20/src/internet/model/ipv6-extension.h 2014-06-17 10:33:13.829996455 -0700 @@ -33,6 +33,7 @@ #include "ns3/packet.h" #include "ns3/random-variable-stream.h" #include "ns3/ipv6-address.h" +#include "ns3/ipv6-l3-protocol.h" #include "ns3/traced-callback.h" @@ -90,10 +91,19 @@ * \param ipv6Header the IPv6 header of packet received * \param dst destination address of the packet received (i.e. us) * \param nextHeader the next header - * \param isDropped if the packet must be dropped + * \param stopProcessing true if the packet must not be further processed + * \param isDropped true if the packet must be dropped + * \param dropReason dropping reason * \return the size processed */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped) = 0; + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason) = 0; /** * \brief Process options @@ -105,10 +115,21 @@ * \param ipv6Header the IPv6 header of packet received * \param dst destination address of the packet received (i.e. us) * \param nextHeader the next header - * \param isDropped if the packet must be dropped + * \param stopProcessing true if the packet must not be further processed + * \param isDropped true if the packet must be dropped + * \param dropReason dropping reason * \return the size processed */ - virtual uint8_t ProcessOptions (Ptr& packet, uint8_t offset, uint8_t length, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t ProcessOptions (Ptr& packet, + uint8_t offset, + uint8_t length, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason + ); /** * Assign a fixed random variable stream number to the random variables @@ -122,11 +143,6 @@ protected: /** - * \brief Drop trace callback. - */ - TracedCallback > m_dropTrace; - - /** * \brief Provides uniform random variables. */ Ptr m_uvar; @@ -172,18 +188,14 @@ */ virtual uint8_t GetExtensionNumber () const; - /** - * \brief Process method - * Called from Ipv6L3Protocol::Receive. - * \param packet the packet - * \param offset the offset of the extension to process - * \param ipv6Header the IPv6 header of packet received - * \param dst destination address of the packet received (i.e. us) - * \param nextHeader the next header - * \param isDropped if the packet must be dropped - * \return the size processed - */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason); }; /** @@ -220,18 +232,14 @@ */ virtual uint8_t GetExtensionNumber () const; - /** - * \brief Process method - * Called from Ipv6L3Protocol::Receive. - * \param packet the packet - * \param offset the offset of the extension to process - * \param ipv6Header the IPv6 header of packet received - * \param dst destination address of the packet received (i.e. us) - * \param nextHeader the next header - * \param isDropped if the packet must be dropped - * \return the size processed - */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason); }; /** @@ -268,18 +276,14 @@ */ virtual uint8_t GetExtensionNumber () const; - /** - * \brief Process method - * Called from Ipv6L3Protocol::Receive. - * \param packet the packet - * \param offset the offset of the extension to process - * \param ipv6Header the IPv6 header of packet received - * \param dst destination address of the packet received (i.e. us) - * \param nextHeader the next header - * \param isDropped if the packet must be dropped - * \return the size processed - */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason); /** * \brief Fragment a packet @@ -382,7 +386,7 @@ * \param key representing the packet fragments * \param ipHeader the IP header of the original packet */ - void HandleFragmentsTimeout (std::pair key, Ipv6Header & ipHeader); + void HandleFragmentsTimeout (std::pair key, Ipv6Header ipHeader); /** * \brief Get the packet parts so far received. @@ -453,19 +457,14 @@ */ virtual uint8_t GetTypeRouting () const; - /** - * \brief Process method - * - * Called from Ipv6L3Protocol::Receive. - * \param packet the packet - * \param offset the offset of the extension to process - * \param ipv6Header the IPv6 header of packet received - * \param dst destination address of the packet received (i.e. us) - * \param nextHeader the next header - * \param isDropped if the packet must be dropped - * \return the size processed - */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason); }; /** @@ -573,20 +572,14 @@ */ virtual uint8_t GetTypeRouting () const; - /** - * \brief Process method - * - * Called from Ipv6L3Protocol::Receive. - * - * \param packet the packet - * \param offset the offset of the extension to process - * \param ipv6Header the IPv6 header of packet received - * \param dst destination address of the packet received (i.e. us) - * \param nextHeader the next header - * \param isDropped if the packet must be dropped - * \return the size processed - */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason); }; /** @@ -623,19 +616,14 @@ */ virtual uint8_t GetExtensionNumber () const; - /** - * \brief Process method - * Called from Ipv6L3Protocol::Receive. - * - * \param packet the packet - * \param offset the offset of the extension to process - * \param ipv6Header the IPv6 header of packet received - * \param dst destination address of the packet received (i.e. us) - * \param nextHeader the next header - * \param isDropped if the packet must be dropped - * \return the size processed - */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason); }; /** @@ -672,19 +660,14 @@ */ virtual uint8_t GetExtensionNumber () const; - /** - * \brief Process method - * Called from Ipv6L3Protocol::Receive. - * - * \param packet the packet - * \param offset the offset of the extension to process - * \param ipv6Header the IPv6 header of packet received - * \param dst destination address of the packet received (i.e. us) - * \param nextHeader the next header - * \param isDropped if the packet must be dropped - * \return the size processed - */ - virtual uint8_t Process (Ptr& packet, uint8_t offset, Ipv6Header const& ipv6Header, Ipv6Address dst, uint8_t *nextHeader, bool& isDropped); + virtual uint8_t Process (Ptr& packet, + uint8_t offset, + Ipv6Header const& ipv6Header, + Ipv6Address dst, + uint8_t *nextHeader, + bool& stopProcessing, + bool& isDropped, + Ipv6L3Protocol::DropReason& dropReason); }; } /* namespace ns3 */ diff -Naur ns-3.19/src/internet/model/ipv6-extension-header.cc ns-3.20/src/internet/model/ipv6-extension-header.cc --- ns-3.19/src/internet/model/ipv6-extension-header.cc 2014-06-17 10:34:00.507636129 -0700 +++ ns-3.20/src/internet/model/ipv6-extension-header.cc 2014-06-17 10:33:13.828996463 -0700 @@ -26,11 +26,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6ExtensionHeader") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6ExtensionHeader"); -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionHeader); TypeId Ipv6ExtensionHeader::GetTypeId () { @@ -201,8 +199,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionHopByHopHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionHopByHopHeader); TypeId Ipv6ExtensionHopByHopHeader::GetTypeId () { @@ -257,8 +254,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionDestinationHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionDestinationHeader); TypeId Ipv6ExtensionDestinationHeader::GetTypeId () { @@ -313,8 +309,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionFragmentHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionFragmentHeader); TypeId Ipv6ExtensionFragmentHeader::GetTypeId () { @@ -407,8 +402,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionRoutingHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionRoutingHeader); TypeId Ipv6ExtensionRoutingHeader::GetTypeId () { @@ -487,8 +481,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionLooseRoutingHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionLooseRoutingHeader); TypeId Ipv6ExtensionLooseRoutingHeader::GetTypeId () { @@ -595,8 +588,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionESPHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionESPHeader); TypeId Ipv6ExtensionESPHeader::GetTypeId () { @@ -642,8 +634,7 @@ return 0; } -NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionAHHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ExtensionAHHeader); TypeId Ipv6ExtensionAHHeader::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6.h ns-3.20/src/internet/model/ipv6.h --- ns-3.19/src/internet/model/ipv6.h 2014-06-17 10:34:00.525635990 -0700 +++ ns-3.20/src/internet/model/ipv6.h 2014-06-17 10:33:13.846996324 -0700 @@ -38,6 +38,7 @@ class NetDevice; class Packet; class Ipv6RoutingProtocol; +class IpL4Protocol; /** * \ingroup internet @@ -304,6 +305,21 @@ virtual void SetForwarding (uint32_t interface, bool val) = 0; /** + * \brief Choose the source address to use with destination address. + * \param interface interface index + * \param dest IPv6 destination address + * \return IPv6 source address to use + */ + virtual Ipv6Address SourceAddressSelection (uint32_t interface, Ipv6Address dest) = 0; + + /** + * \brief Get L4 protocol by protocol number. + * \param protocolNumber protocol number + * \return corresponding Ipv6L4Protocol or 0 if not found + */ + virtual Ptr GetProtocol (int protocolNumber) const = 0; + + /** * \brief Register the IPv6 Extensions. */ virtual void RegisterExtensions () = 0; diff -Naur ns-3.19/src/internet/model/ipv6-header.cc ns-3.20/src/internet/model/ipv6-header.cc --- ns-3.19/src/internet/model/ipv6-header.cc 2014-06-17 10:34:00.509636113 -0700 +++ ns-3.20/src/internet/model/ipv6-header.cc 2014-06-17 10:33:13.830996448 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6Header) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6Header); Ipv6Header::Ipv6Header () : m_version (6), diff -Naur ns-3.19/src/internet/model/ipv6-interface-address.cc ns-3.20/src/internet/model/ipv6-interface-address.cc --- ns-3.19/src/internet/model/ipv6-interface-address.cc 2014-06-17 10:34:00.510636106 -0700 +++ ns-3.20/src/internet/model/ipv6-interface-address.cc 2014-06-17 10:33:13.831996440 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6InterfaceAddress") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6InterfaceAddress"); Ipv6InterfaceAddress::Ipv6InterfaceAddress () : m_address (Ipv6Address ()), @@ -138,6 +137,29 @@ return m_scope; } +bool Ipv6InterfaceAddress::IsInSameSubnet (Ipv6Address b) const +{ + NS_LOG_FUNCTION_NOARGS (); + + Ipv6Address aAddr = m_address; + aAddr = aAddr.CombinePrefix (m_prefix); + Ipv6Address bAddr = b; + bAddr = bAddr.CombinePrefix (m_prefix); + + if (aAddr == bAddr) + { + return true; + } + + if ((bAddr.IsLinkLocalMulticast () && aAddr.IsLinkLocal ()) || + (aAddr.IsLinkLocalMulticast () && bAddr.IsLinkLocal ())) + { + return true; + } + + return false; +} + std::ostream& operator<< (std::ostream& os, const Ipv6InterfaceAddress &addr) { os << "address: " << addr.GetAddress () << addr.GetPrefix () << "; scope: "; diff -Naur ns-3.19/src/internet/model/ipv6-interface-address.h ns-3.20/src/internet/model/ipv6-interface-address.h --- ns-3.19/src/internet/model/ipv6-interface-address.h 2014-06-17 10:34:00.510636106 -0700 +++ ns-3.20/src/internet/model/ipv6-interface-address.h 2014-06-17 10:33:13.831996440 -0700 @@ -134,6 +134,13 @@ Ipv6InterfaceAddress::Scope_e GetScope () const; /** + * \brief Checks if the address is in the same subnet. + * \param b the address to check + * \return true if the address is in the same subnet. + */ + bool IsInSameSubnet (Ipv6Address b) const; + + /** * \brief Set the latest DAD probe packet UID. * \param uid packet uid */ diff -Naur ns-3.19/src/internet/model/ipv6-interface.cc ns-3.20/src/internet/model/ipv6-interface.cc --- ns-3.19/src/internet/model/ipv6-interface.cc 2014-06-17 10:34:00.511636098 -0700 +++ ns-3.20/src/internet/model/ipv6-interface.cc 2014-06-17 10:33:13.832996432 -0700 @@ -34,11 +34,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6Interface") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6Interface"); -NS_OBJECT_ENSURE_REGISTERED (Ipv6Interface) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6Interface); TypeId Ipv6Interface::GetTypeId () { @@ -116,8 +114,13 @@ return; /* no NDISC cache for ip6-localhost */ } - Ptr icmpv6 = m_node->GetObject ()->GetIcmpv6 (); - if (m_device->NeedsArp ()) + Ptr proto = m_node->GetObject ()->GetProtocol (Icmpv6L4Protocol::GetStaticProtocolNumber ()); + Ptr icmpv6; + if (proto) + { + icmpv6 = proto->GetObject (); + } + if (icmpv6) { m_ndCache = icmpv6->CreateCache (m_device, this); } @@ -183,6 +186,7 @@ NS_LOG_FUNCTION_NOARGS (); m_ifup = false; m_addresses.clear (); + m_ndCache->Flush (); } bool Ipv6Interface::IsForwarding () const @@ -218,7 +222,12 @@ if (!addr.IsAny () || !addr.IsLocalhost ()) { /* DAD handling */ - Ptr icmpv6 = m_node->GetObject ()->GetIcmpv6 (); + Ptr proto = m_node->GetObject ()->GetProtocol (Icmpv6L4Protocol::GetStaticProtocolNumber ()); + Ptr icmpv6; + if (proto) + { + icmpv6 = proto->GetObject (); + } if (icmpv6 && icmpv6->IsAlwaysDad ()) { diff -Naur ns-3.19/src/internet/model/ipv6-l3-protocol.cc ns-3.20/src/internet/model/ipv6-l3-protocol.cc --- ns-3.19/src/internet/model/ipv6-l3-protocol.cc 2014-06-17 10:34:00.512636090 -0700 +++ ns-3.20/src/internet/model/ipv6-l3-protocol.cc 2014-06-17 10:33:13.833996425 -0700 @@ -49,11 +49,9 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6L3Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6L3Protocol); -NS_LOG_COMPONENT_DEFINE ("Ipv6L3Protocol") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6L3Protocol"); const uint16_t Ipv6L3Protocol::PROT_NUMBER = 0x86DD; @@ -85,6 +83,13 @@ MakeTraceSourceAccessor (&Ipv6L3Protocol::m_rxTrace)) .AddTraceSource ("Drop", "Drop IPv6 packet", MakeTraceSourceAccessor (&Ipv6L3Protocol::m_dropTrace)) + + .AddTraceSource ("SendOutgoing", "A newly-generated packet by this node is about to be queued for transmission", + MakeTraceSourceAccessor (&Ipv6L3Protocol::m_sendOutgoingTrace)) + .AddTraceSource ("UnicastForward", "A unicast IPv6 packet was received by this node and is being forwarded to another node", + MakeTraceSourceAccessor (&Ipv6L3Protocol::m_unicastForwardTrace)) + .AddTraceSource ("LocalDeliver", "An IPv6 packet was received by/for this node, and it is being forward up the stack", + MakeTraceSourceAccessor (&Ipv6L3Protocol::m_localDeliverTrace)) ; return tid; } @@ -572,6 +577,45 @@ interface->SetForwarding (val); } +Ipv6Address Ipv6L3Protocol::SourceAddressSelection (uint32_t interface, Ipv6Address dest) +{ + NS_LOG_FUNCTION (this << interface << dest); + Ipv6Address ret; + + if (dest.IsLinkLocal () || dest.IsLinkLocalMulticast ()) + { + for (uint32_t i = 0; i < GetNAddresses (interface); i++) + { + Ipv6InterfaceAddress test = GetAddress (interface, i); + if (test.GetScope () == Ipv6InterfaceAddress::LINKLOCAL) + { + return test.GetAddress (); + } + } + NS_ASSERT_MSG (false, "No link-local address found on interface " << interface); + } + + for (uint32_t i = 0; i < GetNAddresses (interface); i++) + { + Ipv6InterfaceAddress test = GetAddress (interface, i); + + if (test.GetScope () == Ipv6InterfaceAddress::GLOBAL) + { + if (test.IsInSameSubnet (dest)) + { + return test.GetAddress (); + } + else + { + ret = test.GetAddress (); + } + } + } + + // no specific match found. Use a global address (any useful is fine). + return ret; +} + void Ipv6L3Protocol::SetIpForward (bool forward) { NS_LOG_FUNCTION (this << forward); @@ -747,6 +791,8 @@ { NS_LOG_LOGIC ("Ipv6L3Protocol::Send case 1: passed in with a route"); hdr = BuildHeader (source, destination, protocol, packet->GetSize (), ttl, tclass); + int32_t interface = GetInterfaceForDevice (route->GetOutputDevice ()); + m_sendOutgoingTrace (hdr, packet, interface); SendRealOut (route, packet, hdr); return; } @@ -757,6 +803,8 @@ NS_LOG_LOGIC ("Ipv6L3Protocol::Send case 1: probably sent to machine on same IPv6 network"); /* NS_FATAL_ERROR ("This case is not yet implemented"); */ hdr = BuildHeader (source, destination, protocol, packet->GetSize (), ttl, tclass); + int32_t interface = GetInterfaceForDevice (route->GetOutputDevice ()); + m_sendOutgoingTrace (hdr, packet, interface); SendRealOut (route, packet, hdr); return; } @@ -786,6 +834,8 @@ if (newRoute) { + int32_t interface = GetInterfaceForDevice (newRoute->GetOutputDevice ()); + m_sendOutgoingTrace (hdr, packet, interface); SendRealOut (newRoute, packet, hdr); } else @@ -845,7 +895,9 @@ Ptr ipv6ExtensionDemux = m_node->GetObject (); Ptr ipv6Extension = 0; uint8_t nextHeader = hdr.GetNextHeader (); + bool stopProcessing = false; bool isDropped = false; + DropReason dropReason; if (nextHeader == Ipv6Header::IPV6_EXT_HOP_BY_HOP) { @@ -853,11 +905,16 @@ if (ipv6Extension) { - ipv6Extension->Process (packet, 0, hdr, hdr.GetDestinationAddress (), (uint8_t *)0, isDropped); + ipv6Extension->Process (packet, 0, hdr, hdr.GetDestinationAddress (), (uint8_t *)0, stopProcessing, isDropped, dropReason); } if (isDropped) { + m_dropTrace (hdr, packet, dropReason, m_node->GetObject (), interface); + } + + if (stopProcessing) + { return; } } @@ -869,6 +926,7 @@ MakeCallback (&Ipv6L3Protocol::RouteInputError, this))) { NS_LOG_WARN ("No route found for forwarding packet. Drop."); + GetIcmpv6 ()->SendErrorDestinationUnreachable (p->Copy (), hdr.GetSourceAddress (), Icmpv6Header::ICMPV6_NO_ROUTE); m_dropTrace (hdr, packet, DROP_NO_ROUTE, m_node->GetObject (), interface); } } @@ -1027,9 +1085,8 @@ { NS_LOG_WARN ("TTL exceeded. Drop."); m_dropTrace (ipHeader, packet, DROP_TTL_EXPIRED, m_node->GetObject (), 0); - // Do not reply to ICMPv6 or to multicast IPv6 address - if (ipHeader.GetNextHeader () != Icmpv6L4Protocol::PROT_NUMBER - && ipHeader.GetDestinationAddress ().IsMulticast () == false) + // Do not reply to multicast IPv6 address + if (ipHeader.GetDestinationAddress ().IsMulticast () == false) { packet->AddHeader (ipHeader); GetIcmpv6 ()->SendErrorTimeExceeded (packet, ipHeader.GetSourceAddress (), Icmpv6Header::ICMPV6_HOPLIMIT); @@ -1076,7 +1133,8 @@ icmpv6->SendRedirection (copy, linkLocal, src, target, dst, Address ()); } } - + int32_t interface = GetInterfaceForDevice (rtentry->GetOutputDevice ()); + m_unicastForwardTrace (ipHeader, packet, interface); SendRealOut (rtentry, packet, ipHeader); } @@ -1124,6 +1182,8 @@ uint8_t nextHeader = ip.GetNextHeader (); uint8_t nextHeaderPosition = 0; bool isDropped = false; + bool stopProcessing = false; + DropReason dropReason; // check for a malformed hop-by-hop extension // this is a common case when forging IPv6 raw packets @@ -1148,11 +1208,16 @@ { uint8_t nextHeaderStep = 0; uint8_t curHeader = nextHeader; - nextHeaderStep = ipv6Extension->Process (p, nextHeaderPosition, ip, dst, &nextHeader, isDropped); + nextHeaderStep = ipv6Extension->Process (p, nextHeaderPosition, ip, dst, &nextHeader, stopProcessing, isDropped, dropReason); nextHeaderPosition += nextHeaderStep; if (isDropped) { + m_dropTrace (ip, packet, dropReason, m_node->GetObject (), iif); + } + + if (stopProcessing) + { return; } NS_ASSERT_MSG (nextHeaderStep != 0 || curHeader == Ipv6Header::IPV6_EXT_FRAGMENTATION, @@ -1187,6 +1252,9 @@ /* L4 protocol */ Ptr copy = p->Copy (); + + m_localDeliverTrace (ip, p, iif); + enum IpL4Protocol::RxStatus status = protocol->Receive (p, ip, GetInterface (iif)); switch (status) @@ -1289,5 +1357,10 @@ m_node->AggregateObject (ipv6OptionDemux); } +void Ipv6L3Protocol::ReportDrop (Ipv6Header ipHeader, Ptr p, DropReason dropReason) +{ + m_dropTrace (ipHeader, p, dropReason, m_node->GetObject (), 0); +} + } /* namespace ns3 */ diff -Naur ns-3.19/src/internet/model/ipv6-l3-protocol.h ns-3.20/src/internet/model/ipv6-l3-protocol.h --- ns-3.19/src/internet/model/ipv6-l3-protocol.h 2014-06-17 10:34:00.513636082 -0700 +++ ns-3.20/src/internet/model/ipv6-l3-protocol.h 2014-06-17 10:33:13.834996417 -0700 @@ -30,6 +30,8 @@ #include "ns3/ipv6-header.h" #include "ns3/ipv6-pmtu-cache.h" +class Ipv6L3ProtocolTestCase; + namespace ns3 { @@ -81,6 +83,9 @@ DROP_INTERFACE_DOWN, /**< Interface is down so can not send packet */ DROP_ROUTE_ERROR, /**< Route error */ DROP_UNKNOWN_PROTOCOL, /**< Unknown L4 protocol */ + DROP_UNKNOWN_OPTION, /**< Unknown option */ + DROP_MALFORMED_HEADER, /**< Malformed header */ + DROP_FRAGMENT_TIMEOUT, /**< Fragment timeout */ }; /** @@ -116,7 +121,7 @@ * \param protocolNumber protocol number * \return corresponding Ipv6L4Protocol or 0 if not found */ - Ptr GetProtocol (int protocolNumber) const; + virtual Ptr GetProtocol (int protocolNumber) const; /** * \brief Create raw IPv6 socket. @@ -321,6 +326,8 @@ */ void SetForwarding (uint32_t i, bool val); + Ipv6Address SourceAddressSelection (uint32_t interface, Ipv6Address dest); + /** * \brief Get device by index. * \param i device index on this stack @@ -367,6 +374,18 @@ */ virtual void RegisterOptions (); + /** + * \brief Report a packet drop + * + * This function is used by Fragment Timeout handling to signal a fragment drop. + * + * \param ipv6Header the IPv6 header of dropped packet + * \param p the packet (if available) + * \param dropReason the drop reason + * + */ + virtual void ReportDrop (Ipv6Header ipHeader, Ptr p, DropReason dropReason); + protected: /** * \brief Dispose object. @@ -382,7 +401,7 @@ private: /* for unit-tests */ - friend class Ipv6L3ProtocolTestCase; + friend class ::Ipv6L3ProtocolTestCase; friend class Ipv6ExtensionLooseRouting; /** @@ -425,6 +444,13 @@ */ TracedCallback, DropReason, Ptr, uint32_t> m_dropTrace; + /// Trace of sent packets + TracedCallback, uint32_t> m_sendOutgoingTrace; + /// Trace of unicast forwarded packets + TracedCallback, uint32_t> m_unicastForwardTrace; + /// Trace of locally delivered packets + TracedCallback, uint32_t> m_localDeliverTrace; + /** * \brief Copy constructor. * diff -Naur ns-3.19/src/internet/model/ipv6-list-routing.cc ns-3.20/src/internet/model/ipv6-list-routing.cc --- ns-3.19/src/internet/model/ipv6-list-routing.cc 2014-06-17 10:34:00.514636075 -0700 +++ ns-3.20/src/internet/model/ipv6-list-routing.cc 2014-06-17 10:33:13.835996409 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6ListRouting) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6ListRouting); TypeId Ipv6ListRouting::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ipv6-option.cc ns-3.20/src/internet/model/ipv6-option.cc --- ns-3.19/src/internet/model/ipv6-option.cc 2014-06-17 10:34:00.516636059 -0700 +++ ns-3.20/src/internet/model/ipv6-option.cc 2014-06-17 10:33:13.837996394 -0700 @@ -29,8 +29,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6Option) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6Option); TypeId Ipv6Option::GetTypeId () { @@ -56,8 +55,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPad1) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPad1); TypeId Ipv6OptionPad1::GetTypeId () { @@ -101,8 +99,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPadn) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPadn); TypeId Ipv6OptionPadn::GetTypeId () { @@ -146,8 +143,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionJumbogram) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionJumbogram); TypeId Ipv6OptionJumbogram::GetTypeId () { @@ -191,8 +187,7 @@ } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionRouterAlert) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionRouterAlert); TypeId Ipv6OptionRouterAlert::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-option-demux.cc ns-3.20/src/internet/model/ipv6-option-demux.cc --- ns-3.19/src/internet/model/ipv6-option-demux.cc 2014-06-17 10:34:00.514636075 -0700 +++ ns-3.20/src/internet/model/ipv6-option-demux.cc 2014-06-17 10:33:13.835996409 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionDemux) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionDemux); TypeId Ipv6OptionDemux::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-option-header.cc ns-3.20/src/internet/model/ipv6-option-header.cc --- ns-3.19/src/internet/model/ipv6-option-header.cc 2014-06-17 10:34:00.515636067 -0700 +++ ns-3.20/src/internet/model/ipv6-option-header.cc 2014-06-17 10:33:13.836996402 -0700 @@ -26,11 +26,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6OptionHeader") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6OptionHeader"); -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionHeader); TypeId Ipv6OptionHeader::GetTypeId () { @@ -118,8 +116,7 @@ return (Alignment){ 1,0}; } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPad1Header) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPad1Header); TypeId Ipv6OptionPad1Header::GetTypeId () { @@ -170,8 +167,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPadnHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionPadnHeader); TypeId Ipv6OptionPadnHeader::GetTypeId () { @@ -231,8 +227,7 @@ return GetSerializedSize (); } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionJumbogramHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionJumbogramHeader); TypeId Ipv6OptionJumbogramHeader::GetTypeId () { @@ -303,8 +298,7 @@ return (Alignment){ 4,2}; //4n+2 } -NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionRouterAlertHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6OptionRouterAlertHeader); TypeId Ipv6OptionRouterAlertHeader::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-packet-probe.cc ns-3.20/src/internet/model/ipv6-packet-probe.cc --- ns-3.19/src/internet/model/ipv6-packet-probe.cc 2014-06-17 10:34:00.517636052 -0700 +++ ns-3.20/src/internet/model/ipv6-packet-probe.cc 2014-06-17 10:33:13.838996386 -0700 @@ -33,8 +33,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6PacketProbe) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6PacketProbe); TypeId Ipv6PacketProbe::GetTypeId () diff -Naur ns-3.19/src/internet/model/ipv6-pmtu-cache.cc ns-3.20/src/internet/model/ipv6-pmtu-cache.cc --- ns-3.19/src/internet/model/ipv6-pmtu-cache.cc 2014-06-17 10:34:00.518636044 -0700 +++ ns-3.20/src/internet/model/ipv6-pmtu-cache.cc 2014-06-17 10:33:13.839996379 -0700 @@ -26,8 +26,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6PmtuCache) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6PmtuCache); TypeId Ipv6PmtuCache::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-raw-socket-factory.cc ns-3.20/src/internet/model/ipv6-raw-socket-factory.cc --- ns-3.19/src/internet/model/ipv6-raw-socket-factory.cc 2014-06-17 10:34:00.519636036 -0700 +++ ns-3.20/src/internet/model/ipv6-raw-socket-factory.cc 2014-06-17 10:33:13.840996371 -0700 @@ -24,8 +24,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6RawSocketFactory) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6RawSocketFactory); TypeId Ipv6RawSocketFactory::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-raw-socket-impl.cc ns-3.20/src/internet/model/ipv6-raw-socket-impl.cc --- ns-3.19/src/internet/model/ipv6-raw-socket-impl.cc 2014-06-17 10:34:00.520636028 -0700 +++ ns-3.20/src/internet/model/ipv6-raw-socket-impl.cc 2014-06-17 10:33:13.841996363 -0700 @@ -38,12 +38,10 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6RawSocketImpl") - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6RawSocketImpl"); -NS_OBJECT_ENSURE_REGISTERED (Ipv6RawSocketImpl) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6RawSocketImpl); TypeId Ipv6RawSocketImpl::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-routing-protocol.cc ns-3.20/src/internet/model/ipv6-routing-protocol.cc --- ns-3.19/src/internet/model/ipv6-routing-protocol.cc 2014-06-17 10:34:00.522636013 -0700 +++ ns-3.20/src/internet/model/ipv6-routing-protocol.cc 2014-06-17 10:33:13.842996355 -0700 @@ -26,8 +26,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (Ipv6RoutingProtocol) - ; +NS_OBJECT_ENSURE_REGISTERED (Ipv6RoutingProtocol); TypeId Ipv6RoutingProtocol::GetTypeId () { diff -Naur ns-3.19/src/internet/model/ipv6-routing-table-entry.h ns-3.20/src/internet/model/ipv6-routing-table-entry.h --- ns-3.19/src/internet/model/ipv6-routing-table-entry.h 2014-06-17 10:34:00.523636005 -0700 +++ ns-3.20/src/internet/model/ipv6-routing-table-entry.h 2014-06-17 10:33:13.844996340 -0700 @@ -57,7 +57,7 @@ /** * \brief Destructor */ - ~Ipv6RoutingTableEntry (); + virtual ~Ipv6RoutingTableEntry (); /** * \brief Is the route entry correspond to a host ? diff -Naur ns-3.19/src/internet/model/ipv6-static-routing.cc ns-3.20/src/internet/model/ipv6-static-routing.cc --- ns-3.19/src/internet/model/ipv6-static-routing.cc 2014-06-17 10:34:00.524635997 -0700 +++ ns-3.20/src/internet/model/ipv6-static-routing.cc 2014-06-17 10:33:13.844996340 -0700 @@ -32,10 +32,8 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("Ipv6StaticRouting") - ; -NS_OBJECT_ENSURE_REGISTERED (Ipv6StaticRouting) - ; +NS_LOG_COMPONENT_DEFINE ("Ipv6StaticRouting"); +NS_OBJECT_ENSURE_REGISTERED (Ipv6StaticRouting); TypeId Ipv6StaticRouting::GetTypeId () { @@ -292,7 +290,7 @@ { NS_ASSERT_MSG (interface, "Try to send on link-local multicast address, and no interface index is given!"); rtentry = Create (); - rtentry->SetSource (SourceAddressSelection (m_ipv6->GetInterfaceForDevice (interface), dst)); + rtentry->SetSource (m_ipv6->SourceAddressSelection (m_ipv6->GetInterfaceForDevice (interface), dst)); rtentry->SetDestination (dst); rtentry->SetGateway (Ipv6Address::GetZero ()); rtentry->SetOutputDevice (interface); @@ -311,7 +309,7 @@ if (mask.IsMatch (dst, entry)) { - NS_LOG_LOGIC ("Found global network route " << j << ", mask length " << maskLen << ", metric " << metric); + NS_LOG_LOGIC ("Found global network route " << *j << ", mask length " << maskLen << ", metric " << metric); /* if interface is given, check the route will output on this interface */ if (!interface || interface == m_ipv6->GetNetDevice (j->GetInterface ())) @@ -341,15 +339,15 @@ if (route->GetGateway ().IsAny ()) { - rtentry->SetSource (SourceAddressSelection (interfaceIdx, route->GetDest ())); + rtentry->SetSource (m_ipv6->SourceAddressSelection (interfaceIdx, route->GetDest ())); } else if (route->GetDest ().IsAny ()) /* default route */ { - rtentry->SetSource (SourceAddressSelection (interfaceIdx, route->GetPrefixToUse ().IsAny () ? dst : route->GetPrefixToUse ())); + rtentry->SetSource (m_ipv6->SourceAddressSelection (interfaceIdx, route->GetPrefixToUse ().IsAny () ? dst : route->GetPrefixToUse ())); } else { - rtentry->SetSource (SourceAddressSelection (interfaceIdx, route->GetGateway ())); + rtentry->SetSource (m_ipv6->SourceAddressSelection (interfaceIdx, route->GetGateway ())); } rtentry->SetDestination (route->GetDest ()); @@ -361,7 +359,7 @@ if (rtentry) { - NS_LOG_LOGIC ("Matching route via " << rtentry->GetDestination () << " (throught " << rtentry->GetGateway () << ") at the end"); + NS_LOG_LOGIC ("Matching route via " << rtentry->GetDestination () << " (Through " << rtentry->GetGateway () << ") at the end"); } return rtentry; } @@ -684,21 +682,18 @@ void Ipv6StaticRouting::NotifyInterfaceDown (uint32_t i) { NS_LOG_FUNCTION (this << i); - uint32_t j = 0; - uint32_t max = GetNRoutes (); /* remove all static routes that are going through this interface */ - while (j < max) + for (NetworkRoutesI it = m_networkRoutes.begin (); it != m_networkRoutes.end (); ) { - Ipv6RoutingTableEntry route = GetRoute (j); - - if (route.GetInterface () == i) + if (it->first->GetInterface () == i) { - RemoveRoute (j); + delete it->first; + it = m_networkRoutes.erase (it); } else { - j++; + it++; } } } @@ -731,16 +726,19 @@ // Remove all static routes that are going through this interface // which reference this network - for (uint32_t j = 0; j < GetNRoutes (); j++) + for (NetworkRoutesI it = m_networkRoutes.begin (); it != m_networkRoutes.end (); ) { - Ipv6RoutingTableEntry route = GetRoute (j); - - if (route.GetInterface () == interface - && route.IsNetwork () - && route.GetDestNetwork () == networkAddress - && route.GetDestNetworkPrefix () == networkMask) + if (it->first->GetInterface () == interface + && it->first->IsNetwork () + && it->first->GetDestNetwork () == networkAddress + && it->first->GetDestNetworkPrefix () == networkMask) + { + delete it->first; + it = m_networkRoutes.erase (it); + } + else { - RemoveRoute (j); + it++; } } } @@ -795,34 +793,5 @@ } } -Ipv6Address Ipv6StaticRouting::SourceAddressSelection (uint32_t interface, Ipv6Address dest) -{ - NS_LOG_FUNCTION (this << interface << dest); - Ipv6Address ret; - - /* first address of an IPv6 interface is link-local ones */ - ret = m_ipv6->GetAddress (interface, 0).GetAddress (); - - if (dest == Ipv6Address::GetAllNodesMulticast () || dest == Ipv6Address::GetAllRoutersMulticast () || dest == Ipv6Address::GetAllHostsMulticast ()) - { - return ret; - } - - /* usually IPv6 interfaces have one link-local address and one global address */ - - for (uint32_t i = 1; i < m_ipv6->GetNAddresses (interface); i++) - { - Ipv6InterfaceAddress test = m_ipv6->GetAddress (interface, i); - Ipv6InterfaceAddress dst(dest); - - if (test.GetScope() == dst.GetScope()) - { - return test.GetAddress (); - } - } - - return ret; -} - } /* namespace ns3 */ diff -Naur ns-3.19/src/internet/model/ipv6-static-routing.h ns-3.20/src/internet/model/ipv6-static-routing.h --- ns-3.19/src/internet/model/ipv6-static-routing.h 2014-06-17 10:34:00.524635997 -0700 +++ ns-3.20/src/internet/model/ipv6-static-routing.h 2014-06-17 10:33:13.845996332 -0700 @@ -293,14 +293,6 @@ Ptr LookupStatic (Ipv6Address origin, Ipv6Address group, uint32_t ifIndex); /** - * \brief Choose the source address to use with destination address. - * \param interface interface index - * \param dest IPv6 destination address - * \return IPv6 source address to use - */ - Ipv6Address SourceAddressSelection (uint32_t interface, Ipv6Address dest); - - /** * \brief the forwarding table for network. */ NetworkRoutes m_networkRoutes; diff -Naur ns-3.19/src/internet/model/loopback-net-device.cc ns-3.20/src/internet/model/loopback-net-device.cc --- ns-3.19/src/internet/model/loopback-net-device.cc 2014-06-17 10:34:00.526635982 -0700 +++ ns-3.20/src/internet/model/loopback-net-device.cc 2014-06-17 10:33:13.846996324 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (LoopbackNetDevice) - ; +NS_OBJECT_ENSURE_REGISTERED (LoopbackNetDevice); TypeId LoopbackNetDevice::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/ndisc-cache.cc ns-3.20/src/internet/model/ndisc-cache.cc --- ns-3.19/src/internet/model/ndisc-cache.cc 2014-06-17 10:34:00.526635982 -0700 +++ ns-3.20/src/internet/model/ndisc-cache.cc 2014-06-17 10:33:13.847996317 -0700 @@ -30,11 +30,9 @@ namespace ns3 { -NS_LOG_COMPONENT_DEFINE ("NdiscCache") - ; +NS_LOG_COMPONENT_DEFINE ("NdiscCache"); -NS_OBJECT_ENSURE_REGISTERED (NdiscCache) - ; +NS_OBJECT_ENSURE_REGISTERED (NdiscCache); TypeId NdiscCache::GetTypeId () { diff -Naur ns-3.19/src/internet/model/nsc-sysctl.cc ns-3.20/src/internet/model/nsc-sysctl.cc --- ns-3.19/src/internet/model/nsc-sysctl.cc 2014-06-17 10:34:00.527635974 -0700 +++ ns-3.20/src/internet/model/nsc-sysctl.cc 2014-06-17 10:33:13.848996309 -0700 @@ -152,8 +152,7 @@ } } -NS_OBJECT_ENSURE_REGISTERED (Ns3NscStack) - ; +NS_OBJECT_ENSURE_REGISTERED (Ns3NscStack); TypeId Ns3NscStack::Ns3NscStack::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/nsc-tcp-l4-protocol.cc ns-3.20/src/internet/model/nsc-tcp-l4-protocol.cc --- ns-3.19/src/internet/model/nsc-tcp-l4-protocol.cc 2014-06-17 10:34:00.528635967 -0700 +++ ns-3.20/src/internet/model/nsc-tcp-l4-protocol.cc 2014-06-17 10:33:13.849996301 -0700 @@ -49,8 +49,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (NscTcpL4Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (NscTcpL4Protocol); /* see http://www.iana.org/assignments/protocol-numbers */ const uint8_t NscTcpL4Protocol::PROT_NUMBER = 6; diff -Naur ns-3.19/src/internet/model/nsc-tcp-socket-impl.cc ns-3.20/src/internet/model/nsc-tcp-socket-impl.cc --- ns-3.19/src/internet/model/nsc-tcp-socket-impl.cc 2014-06-17 10:34:00.530635951 -0700 +++ ns-3.20/src/internet/model/nsc-tcp-socket-impl.cc 2014-06-17 10:33:13.851996286 -0700 @@ -47,8 +47,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (NscTcpSocketImpl) - ; +NS_OBJECT_ENSURE_REGISTERED (NscTcpSocketImpl); TypeId NscTcpSocketImpl::GetTypeId () diff -Naur ns-3.19/src/internet/model/ripng.cc ns-3.20/src/internet/model/ripng.cc --- ns-3.19/src/internet/model/ripng.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/internet/model/ripng.cc 2014-06-17 10:33:13.853996270 -0700 @@ -0,0 +1,1382 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze, Italy + * + * 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: Tommaso Pecorella + */ + +#include +#include "ripng.h" +#include "ns3/log.h" +#include "ns3/abort.h" +#include "ns3/assert.h" +#include "ns3/unused.h" +#include "ns3/random-variable-stream.h" +#include "ns3/ipv6-route.h" +#include "ns3/node.h" +#include "ns3/names.h" +#include "ns3/ripng-header.h" +#include "ns3/udp-header.h" +#include "ns3/enum.h" +#include "ns3/ipv6-packet-info-tag.h" + +#define RIPNG_ALL_NODE "ff02::9" +#define RIPNG_PORT 521 + +NS_LOG_COMPONENT_DEFINE ("RipNg") + ; + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (RipNg) + ; + +RipNg::RipNg () + : m_ipv6 (0), m_splitHorizonStrategy (RipNg::POISON_REVERSE), m_initialized (false) +{ + m_rng = CreateObject (); +} + +RipNg::~RipNg () +{ +} + +TypeId +RipNg::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::RipNg") + .SetParent () + .AddConstructor () + .AddAttribute ("UnsolicitedRoutingUpdate", "The time between two Unsolicited Routing Updates.", + TimeValue (Seconds(30)), + MakeTimeAccessor (&RipNg::m_unsolicitedUpdate), + MakeTimeChecker ()) + .AddAttribute ("StartupDelay", "Maximum random delay for protocol startup (send route requests).", + TimeValue (Seconds(1)), + MakeTimeAccessor (&RipNg::m_startupDelay), + MakeTimeChecker ()) + .AddAttribute ("TimeoutDelay", "The delay to invalidate a route.", + TimeValue (Seconds(180)), + MakeTimeAccessor (&RipNg::m_timeoutDelay), + MakeTimeChecker ()) + .AddAttribute ("GarbageCollectionDelay", "The delay to delete an expired route.", + TimeValue (Seconds(120)), + MakeTimeAccessor (&RipNg::m_garbageCollectionDelay), + MakeTimeChecker ()) + .AddAttribute ("MinTriggeredCooldown", "Min cooldown delay after a Triggered Update.", + TimeValue (Seconds(1)), + MakeTimeAccessor (&RipNg::m_minTriggeredUpdateDelay), + MakeTimeChecker ()) + .AddAttribute ("MaxTriggeredCooldown", "Max cooldown delay after a Triggered Update.", + TimeValue (Seconds(5)), + MakeTimeAccessor (&RipNg::m_maxTriggeredUpdateDelay), + MakeTimeChecker ()) + .AddAttribute ("SplitHorizon", "Split Horizon strategy.", + EnumValue (RipNg::POISON_REVERSE), + MakeEnumAccessor (&RipNg::m_splitHorizonStrategy), + MakeEnumChecker (RipNg::NO_SPLIT_HORIZON, "NoSplitHorizon", + RipNg::SPLIT_HORIZON, "SplitHorizon", + RipNg::POISON_REVERSE, "PoisonReverse")) + ; + return tid; +} + +int64_t RipNg::AssignStreams (int64_t stream) +{ + NS_LOG_FUNCTION (this << stream); + + m_rng->SetStream (stream); + return 1; +} + +void RipNg::DoInitialize () +{ + NS_LOG_FUNCTION (this); + + bool addedGlobal = false; + + m_initialized = true; + + Time delay = m_unsolicitedUpdate + Seconds (m_rng->GetValue (0, 0.5*m_unsolicitedUpdate.GetSeconds ()) ); + m_nextUnsolicitedUpdate = Simulator::Schedule (delay, &RipNg::SendUnsolicitedRouteUpdate, this); + + + for (uint32_t i = 0 ; i < m_ipv6->GetNInterfaces (); i++) + { + bool activeInterface = false; + if (m_interfaceExclusions.find (i) == m_interfaceExclusions.end ()) + { + activeInterface = true; + } + + for (uint32_t j = 0; j < m_ipv6->GetNAddresses (i); j++) + { + Ipv6InterfaceAddress address = m_ipv6->GetAddress (i, j); + if (address.GetScope() == Ipv6InterfaceAddress::LINKLOCAL && activeInterface == true) + { + NS_LOG_LOGIC ("RIPng: adding socket to " << address.GetAddress ()); + TypeId tid = TypeId::LookupByName ("ns3::UdpSocketFactory"); + Ptr theNode = GetObject (); + Ptr socket = Socket::CreateSocket (theNode, tid); + Inet6SocketAddress local = Inet6SocketAddress (address.GetAddress (), RIPNG_PORT); + int ret = socket->Bind (local); + NS_ASSERT_MSG (ret == 0, "Bind unsuccessful"); + socket->BindToNetDevice (m_ipv6->GetNetDevice (i)); + socket->ShutdownRecv (); + socket->SetIpv6RecvHopLimit (true); + m_sendSocketList[socket] = i; + } + else if (m_ipv6->GetAddress (i, j).GetScope() == Ipv6InterfaceAddress::GLOBAL) + { + addedGlobal = true; + } + } + } + + if (!m_recvSocket) + { + NS_LOG_LOGIC ("RIPng: adding receiving socket"); + TypeId tid = TypeId::LookupByName ("ns3::UdpSocketFactory"); + Ptr theNode = GetObject (); + m_recvSocket = Socket::CreateSocket (theNode, tid); + Inet6SocketAddress local = Inet6SocketAddress (Ipv6Address::GetAny (), RIPNG_PORT); + m_recvSocket->Bind (local); + m_recvSocket->SetRecvCallback (MakeCallback (&RipNg::Receive, this)); + m_recvSocket->SetIpv6RecvHopLimit (true); + m_recvSocket->SetRecvPktInfo (true); + } + + + if (addedGlobal) + { + Time delay = Seconds (m_rng->GetValue (m_minTriggeredUpdateDelay.GetSeconds (), m_maxTriggeredUpdateDelay.GetSeconds ())); + m_nextTriggeredUpdate = Simulator::Schedule (delay, &RipNg::DoSendRouteUpdate, this, false); + } + + delay = Seconds (m_rng->GetValue (0.01, m_startupDelay.GetSeconds ())); + m_nextTriggeredUpdate = Simulator::Schedule (delay, &RipNg::SendRouteRequest, this); + + Ipv6RoutingProtocol::DoInitialize (); +} + +Ptr RipNg::RouteOutput (Ptr p, const Ipv6Header &header, Ptr oif, Socket::SocketErrno &sockerr) +{ + NS_LOG_FUNCTION (this << header << oif); + + Ipv6Address destination = header.GetDestinationAddress (); + Ptr rtentry = 0; + + if (destination.IsMulticast ()) + { + // Note: Multicast routes for outbound packets are stored in the + // normal unicast table. An implication of this is that it is not + // possible to source multicast datagrams on multiple interfaces. + // This is a well-known property of sockets implementation on + // many Unix variants. + // So, we just log it and fall through to LookupStatic () + NS_LOG_LOGIC ("RouteOutput (): Multicast destination"); + } + + rtentry = Lookup (destination, oif); + if (rtentry) + { + sockerr = Socket::ERROR_NOTERROR; + } + else + { + sockerr = Socket::ERROR_NOROUTETOHOST; + } + return rtentry; +} + +bool RipNg::RouteInput (Ptr p, const Ipv6Header &header, Ptr idev, + UnicastForwardCallback ucb, MulticastForwardCallback mcb, + LocalDeliverCallback lcb, ErrorCallback ecb) +{ + NS_LOG_FUNCTION (this << p << header << header.GetSourceAddress () << header.GetDestinationAddress () << idev); + + NS_ASSERT (m_ipv6 != 0); + // Check if input device supports IP + NS_ASSERT (m_ipv6->GetInterfaceForDevice (idev) >= 0); + uint32_t iif = m_ipv6->GetInterfaceForDevice (idev); + Ipv6Address dst = header.GetDestinationAddress (); + + if (dst.IsMulticast ()) + { + NS_LOG_LOGIC ("Multicast route not supported by RIPng"); + return false; // Let other routing protocols try to handle this + } + + /// \todo Configurable option to enable \RFC{1222} Strong End System Model + // Right now, we will be permissive and allow a source to send us + // a packet to one of our other interface addresses; that is, the + // destination unicast address does not match one of the iif addresses, + // but we check our other interfaces. This could be an option + // (to remove the outer loop immediately below and just check iif). + for (uint32_t j = 0; j < m_ipv6->GetNInterfaces (); j++) + { + for (uint32_t i = 0; i < m_ipv6->GetNAddresses (j); i++) + { + Ipv6InterfaceAddress iaddr = m_ipv6->GetAddress (j, i); + Ipv6Address addr = iaddr.GetAddress (); + if (addr.IsEqual (header.GetDestinationAddress ())) + { + if (j == iif) + { + NS_LOG_LOGIC ("For me (destination " << addr << " match)"); + } + else + { + NS_LOG_LOGIC ("For me (destination " << addr << " match) on another interface " << header.GetDestinationAddress ()); + } + lcb (p, header, iif); + return true; + } + NS_LOG_LOGIC ("Address " << addr << " not a match"); + } + } + // Check if input device supports IP forwarding + if (m_ipv6->IsForwarding (iif) == false) + { + NS_LOG_LOGIC ("Forwarding disabled for this interface"); + ecb (p, header, Socket::ERROR_NOROUTETOHOST); + return false; + } + // Next, try to find a route + NS_LOG_LOGIC ("Unicast destination"); + Ptr rtentry = Lookup (header.GetDestinationAddress ()); + + if (rtentry != 0) + { + NS_LOG_LOGIC ("Found unicast destination- calling unicast callback"); + ucb (idev, rtentry, p, header); // unicast forwarding callback + return true; + } + else + { + NS_LOG_LOGIC ("Did not find unicast destination- returning false"); + return false; // Let other routing protocols try to handle this + } +} + +void RipNg::NotifyInterfaceUp (uint32_t i) +{ + NS_LOG_FUNCTION (this << i); + + for (uint32_t j = 0; j < m_ipv6->GetNAddresses (i); j++) + { + Ipv6InterfaceAddress address = m_ipv6->GetAddress (i, j); + Ipv6Prefix networkMask = address.GetPrefix (); + Ipv6Address networkAddress = address.GetAddress ().CombinePrefix (networkMask); + + if (address != Ipv6Address () && networkMask != Ipv6Prefix ()) + { + if (networkMask == Ipv6Prefix (128)) + { + /* host route */ + AddNetworkRouteTo (networkAddress, Ipv6Prefix::GetOnes (), 0); + } + else + { + AddNetworkRouteTo (networkAddress, networkMask, i); + } + } + } + + if (!m_initialized) + { + return; + } + + + bool sendSocketFound = false; + for (SocketListI iter = m_sendSocketList.begin (); iter != m_sendSocketList.end (); iter++ ) + { + if (iter->second == i) + { + sendSocketFound = true; + break; + } + } + + bool activeInterface = false; + if (m_interfaceExclusions.find (i) == m_interfaceExclusions.end ()) + { + activeInterface = true; + } + + for (uint32_t j = 0; j < m_ipv6->GetNAddresses (i); j++) + { + Ipv6InterfaceAddress address = m_ipv6->GetAddress (i, j); + + Ipv6Address networkAddress = address.GetAddress ().CombinePrefix (address.GetPrefix ()); + Ipv6Prefix networkMask = address.GetPrefix (); + AddNetworkRouteTo (networkAddress, networkMask, i); + + if (address.GetScope() == Ipv6InterfaceAddress::LINKLOCAL && sendSocketFound == false && activeInterface == true) + { + NS_LOG_LOGIC ("RIPng: adding sending socket to " << address.GetAddress ()); + TypeId tid = TypeId::LookupByName ("ns3::UdpSocketFactory"); + Ptr theNode = GetObject (); + Ptr socket = Socket::CreateSocket (theNode, tid); + Inet6SocketAddress local = Inet6SocketAddress (address.GetAddress (), RIPNG_PORT); + socket->Bind (local); + socket->BindToNetDevice (m_ipv6->GetNetDevice (i)); + socket->ShutdownRecv (); + socket->SetIpv6RecvHopLimit (true); + m_sendSocketList[socket] = i; + } + else if (address.GetScope() == Ipv6InterfaceAddress::GLOBAL) + { + SendTriggeredRouteUpdate (); + } + } + + if (!m_recvSocket) + { + NS_LOG_LOGIC ("RIPng: adding receiving socket"); + TypeId tid = TypeId::LookupByName ("ns3::UdpSocketFactory"); + Ptr theNode = GetObject (); + m_recvSocket = Socket::CreateSocket (theNode, tid); + Inet6SocketAddress local = Inet6SocketAddress (Ipv6Address::GetAny (), RIPNG_PORT); + m_recvSocket->Bind (local); + m_recvSocket->SetRecvCallback (MakeCallback (&RipNg::Receive, this)); + m_recvSocket->SetIpv6RecvHopLimit (true); + m_recvSocket->SetRecvPktInfo (true); + } +} + +void RipNg::NotifyInterfaceDown (uint32_t interface) +{ + NS_LOG_FUNCTION (this << interface); + + /* remove all routes that are going through this interface */ + for (RoutesI it = m_routes.begin (); it != m_routes.end (); it++) + { + if (it->first->GetInterface () == interface) + { + InvalidateRoute (it->first); + } + } + + for (SocketListI iter = m_sendSocketList.begin (); iter != m_sendSocketList.end (); iter++ ) + { + NS_LOG_INFO ("Checking socket for interface " << interface); + if (iter->second == interface) + { + NS_LOG_INFO ("Removed socket for interface " << interface); + iter->first->Close (); + m_sendSocketList.erase (iter); + break; + } + } + + if (m_interfaceExclusions.find (interface) == m_interfaceExclusions.end ()) + { + SendTriggeredRouteUpdate (); + } +} + +void RipNg::NotifyAddAddress (uint32_t interface, Ipv6InterfaceAddress address) +{ + NS_LOG_FUNCTION (this << interface << address); + + if (!m_ipv6->IsUp (interface)) + { + return; + } + + if (m_interfaceExclusions.find (interface) != m_interfaceExclusions.end ()) + { + return; + } + + Ipv6Address networkAddress = address.GetAddress ().CombinePrefix (address.GetPrefix ()); + Ipv6Prefix networkMask = address.GetPrefix (); + + if (address.GetAddress () != Ipv6Address () && address.GetPrefix () != Ipv6Prefix ()) + { + AddNetworkRouteTo (networkAddress, networkMask, interface); + } + + SendTriggeredRouteUpdate (); +} + +void RipNg::NotifyRemoveAddress (uint32_t interface, Ipv6InterfaceAddress address) +{ + NS_LOG_FUNCTION (this << interface << address); + + if (!m_ipv6->IsUp (interface)) + { + return; + } + + if (address.GetScope() != Ipv6InterfaceAddress::GLOBAL) + { + return; + } + + Ipv6Address networkAddress = address.GetAddress ().CombinePrefix (address.GetPrefix ()); + Ipv6Prefix networkMask = address.GetPrefix (); + + // Remove all routes that are going through this interface + // which reference this network + for (RoutesI it = m_routes.begin (); it != m_routes.end (); it++) + { + if (it->first->GetInterface () == interface + && it->first->IsNetwork () + && it->first->GetDestNetwork () == networkAddress + && it->first->GetDestNetworkPrefix () == networkMask) + { + InvalidateRoute (it->first); + } + } + + if (m_interfaceExclusions.find (interface) == m_interfaceExclusions.end ()) + { + SendTriggeredRouteUpdate (); + } + +} + +void RipNg::NotifyAddRoute (Ipv6Address dst, Ipv6Prefix mask, Ipv6Address nextHop, uint32_t interface, Ipv6Address prefixToUse) +{ + NS_LOG_INFO (this << dst << mask << nextHop << interface << prefixToUse); + // \todo this can be used to add delegate routes +} + +void RipNg::NotifyRemoveRoute (Ipv6Address dst, Ipv6Prefix mask, Ipv6Address nextHop, uint32_t interface, Ipv6Address prefixToUse) +{ + NS_LOG_FUNCTION (this << dst << mask << nextHop << interface); + // \todo this can be used to delete delegate routes +} + +void RipNg::SetIpv6 (Ptr ipv6) +{ + NS_LOG_FUNCTION (this << ipv6); + + NS_ASSERT (m_ipv6 == 0 && ipv6 != 0); + uint32_t i = 0; + m_ipv6 = ipv6; + + for (i = 0; i < m_ipv6->GetNInterfaces (); i++) + { + if (m_ipv6->IsUp (i)) + { + NotifyInterfaceUp (i); + } + else + { + NotifyInterfaceDown (i); + } + } +} + +void RipNg::PrintRoutingTable (Ptr stream) const +{ + NS_LOG_FUNCTION (this << stream); + + std::ostream* os = stream->GetStream (); + + *os << "Node: " << m_ipv6->GetObject ()->GetId () + << " Time: " << Simulator::Now ().GetSeconds () << "s " + << "Ipv6 RIPng table" << std::endl; + + if (!m_routes.empty ()) + { + *os << "Destination Next Hop Flag Met Ref Use If" << std::endl; + for (RoutesCI it = m_routes.begin (); it != m_routes.end (); it++) + { + RipNgRoutingTableEntry* route = it->first; + RipNgRoutingTableEntry::Status_e status = route->GetRouteStatus(); + + if (status == RipNgRoutingTableEntry::RIPNG_VALID) + { + std::ostringstream dest, gw, mask, flags; + + dest << route->GetDest () << "/" << int(route->GetDestNetworkPrefix ().GetPrefixLength ()); + *os << std::setiosflags (std::ios::left) << std::setw (31) << dest.str (); + gw << route->GetGateway (); + *os << std::setiosflags (std::ios::left) << std::setw (27) << gw.str (); + flags << "U"; + if (route->IsHost ()) + { + flags << "H"; + } + else if (route->IsGateway ()) + { + flags << "G"; + } + *os << std::setiosflags (std::ios::left) << std::setw (5) << flags.str (); + *os << std::setiosflags (std::ios::left) << std::setw (4) << int(route->GetRouteMetric ()); + // Ref ct not implemented + *os << "-" << " "; + // Use not implemented + *os << "-" << " "; + if (Names::FindName (m_ipv6->GetNetDevice (route->GetInterface ())) != "") + { + *os << Names::FindName (m_ipv6->GetNetDevice (route->GetInterface ())); + } + else + { + *os << route->GetInterface (); + } + *os << std::endl; + } + } + } +} + +void RipNg::DoDispose () +{ + NS_LOG_FUNCTION (this); + + for (RoutesI j = m_routes.begin (); j != m_routes.end (); j = m_routes.erase (j)) + { + delete j->first; + } + m_routes.clear (); + + m_nextTriggeredUpdate.Cancel (); + m_nextUnsolicitedUpdate.Cancel (); + m_nextTriggeredUpdate = EventId (); + m_nextUnsolicitedUpdate = EventId (); + + for (SocketListI iter = m_sendSocketList.begin (); iter != m_sendSocketList.end (); iter++ ) + { + iter->first->Close (); + } + m_sendSocketList.clear (); + + m_recvSocket->Close (); + m_recvSocket = 0; + + m_ipv6 = 0; + + Ipv6RoutingProtocol::DoDispose (); +} + + +Ptr RipNg::Lookup (Ipv6Address dst, Ptr interface) +{ + NS_LOG_FUNCTION (this << dst << interface); + + Ptr rtentry = 0; + uint16_t longestMask = 0; + + /* when sending on link-local multicast, there have to be interface specified */ + if (dst.IsLinkLocalMulticast ()) + { + NS_ASSERT_MSG (interface, "Try to send on link-local multicast address, and no interface index is given!"); + rtentry = Create (); + rtentry->SetSource (m_ipv6->SourceAddressSelection (m_ipv6->GetInterfaceForDevice (interface), dst)); + rtentry->SetDestination (dst); + rtentry->SetGateway (Ipv6Address::GetZero ()); + rtentry->SetOutputDevice (interface); + return rtentry; + } + + for (RoutesI it = m_routes.begin (); it != m_routes.end (); it++) + { + RipNgRoutingTableEntry* j = it->first; + + if (j->GetRouteStatus () == RipNgRoutingTableEntry::RIPNG_VALID) + { + Ipv6Prefix mask = j->GetDestNetworkPrefix (); + uint16_t maskLen = mask.GetPrefixLength (); + Ipv6Address entry = j->GetDestNetwork (); + + NS_LOG_LOGIC ("Searching for route to " << dst << ", mask length " << maskLen); + + if (mask.IsMatch (dst, entry)) + { + NS_LOG_LOGIC ("Found global network route " << j << ", mask length " << maskLen); + + /* if interface is given, check the route will output on this interface */ + if (!interface || interface == m_ipv6->GetNetDevice (j->GetInterface ())) + { + if (maskLen < longestMask) + { + NS_LOG_LOGIC ("Previous match longer, skipping"); + continue; + } + + longestMask = maskLen; + + Ipv6RoutingTableEntry* route = j; + uint32_t interfaceIdx = route->GetInterface (); + rtentry = Create (); + + if (route->GetGateway ().IsAny ()) + { + rtentry->SetSource (m_ipv6->SourceAddressSelection (interfaceIdx, route->GetDest ())); + } + else if (route->GetDest ().IsAny ()) /* default route */ + { + rtentry->SetSource (m_ipv6->SourceAddressSelection (interfaceIdx, route->GetPrefixToUse ().IsAny () ? dst : route->GetPrefixToUse ())); + } + else + { + rtentry->SetSource (m_ipv6->SourceAddressSelection (interfaceIdx, route->GetDest ())); + } + + rtentry->SetDestination (route->GetDest ()); + rtentry->SetGateway (route->GetGateway ()); + rtentry->SetOutputDevice (m_ipv6->GetNetDevice (interfaceIdx)); + } + } + } + } + + if (rtentry) + { + NS_LOG_LOGIC ("Matching route via " << rtentry->GetDestination () << " (through " << rtentry->GetGateway () << ") at the end"); + } + return rtentry; +} + +void RipNg::AddNetworkRouteTo (Ipv6Address network, Ipv6Prefix networkPrefix, Ipv6Address nextHop, uint32_t interface, Ipv6Address prefixToUse) +{ + NS_LOG_FUNCTION (this << network << networkPrefix << nextHop << interface << prefixToUse); + + if (nextHop.IsLinkLocal()) + { + NS_LOG_WARN ("Ripng::AddNetworkRouteTo - Next hop should be link-local"); + } + + RipNgRoutingTableEntry* route = new RipNgRoutingTableEntry (network, networkPrefix, nextHop, interface, prefixToUse); + route->SetRouteMetric (1); + route->SetRouteStatus (RipNgRoutingTableEntry::RIPNG_VALID); + route->SetRouteChanged (true); + + m_routes.push_back (std::make_pair (route, EventId ())); +} + +void RipNg::AddNetworkRouteTo (Ipv6Address network, Ipv6Prefix networkPrefix, uint32_t interface) +{ + NS_LOG_FUNCTION (this << network << networkPrefix << interface); + + RipNgRoutingTableEntry* route = new RipNgRoutingTableEntry (network, networkPrefix, interface); + route->SetRouteMetric (1); + route->SetRouteStatus (RipNgRoutingTableEntry::RIPNG_VALID); + route->SetRouteChanged (true); + + m_routes.push_back (std::make_pair (route, EventId ())); +} + +void RipNg::InvalidateRoute (RipNgRoutingTableEntry *route) +{ + NS_LOG_FUNCTION (this << *route); + + for (RoutesI it = m_routes.begin (); it != m_routes.end (); it++) + { + if (it->first == route) + { + route->SetRouteStatus (RipNgRoutingTableEntry::RIPNG_INVALID); + route->SetRouteMetric (16); + route->SetRouteChanged (true); + if (it->second.IsRunning ()) + { + it->second.Cancel (); + } + it->second = Simulator::Schedule (m_garbageCollectionDelay, &RipNg::DeleteRoute, this, route); + return; + } + } + NS_ABORT_MSG ("Ripng::InvalidateRoute - cannot find the route to update"); +} + +void RipNg::DeleteRoute (RipNgRoutingTableEntry *route) +{ + NS_LOG_FUNCTION (this << *route); + + for (RoutesI it = m_routes.begin (); it != m_routes.end (); it++) + { + if (it->first == route) + { + delete route; + m_routes.erase (it); + return; + } + } + NS_ABORT_MSG ("Ripng::DeleteRoute - cannot find the route to delete"); +} + + +void RipNg::Receive (Ptr socket) +{ + NS_LOG_FUNCTION (this << socket); + + Ptr packet = socket->Recv (); + NS_LOG_INFO ("Received " << *packet); + + Ipv6PacketInfoTag interfaceInfo; + if (!packet->RemovePacketTag (interfaceInfo)) + { + NS_ABORT_MSG ("No incoming interface on RIPng message, aborting."); + } + uint32_t incomingIf = interfaceInfo.GetRecvIf (); + Ptr node = this->GetObject (); + Ptr dev = node->GetDevice (incomingIf); + uint32_t ipInterfaceIndex = m_ipv6->GetInterfaceForDevice (dev); + + SocketIpv6HopLimitTag hoplimitTag; + if (!packet->RemovePacketTag (hoplimitTag)) + { + NS_ABORT_MSG ("No incoming Hop Count on RIPng message, aborting."); + } + uint8_t hopLimit = hoplimitTag.GetHopLimit (); + + SocketAddressTag tag; + if (!packet->RemovePacketTag (tag)) + { + NS_ABORT_MSG ("No incoming sender address on RIPng message, aborting."); + } + Ipv6Address senderAddress = Inet6SocketAddress::ConvertFrom (tag.GetAddress ()).GetIpv6 (); + uint16_t senderPort = Inet6SocketAddress::ConvertFrom (tag.GetAddress ()).GetPort (); + + int32_t interfaceForAddress = m_ipv6->GetInterfaceForAddress (senderAddress); + if (interfaceForAddress != -1) + { + NS_LOG_LOGIC ("Ignoring a packet sent by myself."); + return; + } + + RipNgHeader hdr; + packet->RemoveHeader (hdr); + + if (hdr.GetCommand () == RipNgHeader::RESPONSE) + { + HandleResponses (hdr, senderAddress, ipInterfaceIndex, hopLimit); + } + else if (hdr.GetCommand () == RipNgHeader::REQUEST) + { + HandleRequests (hdr, senderAddress, senderPort, ipInterfaceIndex, hopLimit); + } + else + { + NS_LOG_LOGIC ("Ignoring message with unknown command: " << int (hdr.GetCommand ())); + } + return; +} + +void RipNg::HandleRequests (RipNgHeader requestHdr, Ipv6Address senderAddress, uint16_t senderPort, uint32_t incomingInterface, uint8_t hopLimit) +{ + NS_LOG_FUNCTION (this << senderAddress << int (senderPort) << incomingInterface << int (hopLimit) << requestHdr); + + std::list rtes = requestHdr.GetRteList (); + + if (rtes.empty ()) + { + return; + } + + // check if it's a request for the full table from a neighbor + if (rtes.size () == 1 && senderAddress.IsLinkLocal ()) + { + if (rtes.begin ()->GetPrefix () == Ipv6Address::GetAny () && + rtes.begin ()->GetPrefixLen () == 0 && + rtes.begin ()->GetRouteMetric () == 16) + { + // Output whole thing. Use Split Horizon + if (m_interfaceExclusions.find (incomingInterface) == m_interfaceExclusions.end ()) + { + // we use one of the sending sockets, as they're bound to the right interface + // and the local address might be used on different interfaces. + Ptr sendingSoket; + for (SocketListI iter = m_sendSocketList.begin (); iter != m_sendSocketList.end (); iter++ ) + { + if (iter->second == incomingInterface) + { + sendingSoket = iter->first; + } + } + NS_ASSERT_MSG (sendingSoket, "HandleRequest - Impossible to find a socket to send the reply"); + + uint16_t mtu = m_ipv6->GetMtu (incomingInterface); + uint16_t maxRte = (mtu - Ipv6Header ().GetSerializedSize () - UdpHeader ().GetSerializedSize () - RipNgHeader ().GetSerializedSize ()) / RipNgRte ().GetSerializedSize (); + + Ptr p = Create (); + SocketIpv6HopLimitTag tag; + p->RemovePacketTag (tag); + tag.SetHopLimit (255); + p->AddPacketTag (tag); + + RipNgHeader hdr; + hdr.SetCommand (RipNgHeader::RESPONSE); + + for (RoutesI rtIter = m_routes.begin (); rtIter != m_routes.end (); rtIter++) + { + bool splitHorizoning = (rtIter->first->GetInterface () == incomingInterface); + + Ipv6InterfaceAddress rtDestAddr = Ipv6InterfaceAddress(rtIter->first->GetDestNetwork ()); + + bool isGlobal = (rtDestAddr.GetScope () == Ipv6InterfaceAddress::GLOBAL); + bool isDefaultRoute = ((rtIter->first->GetDestNetwork () == Ipv6Address::GetAny ()) && + (rtIter->first->GetDestNetworkPrefix () == Ipv6Prefix::GetZero ()) && + (rtIter->first->GetInterface () != incomingInterface)); + + if ((isGlobal || isDefaultRoute) && + (rtIter->first->GetRouteStatus () == RipNgRoutingTableEntry::RIPNG_VALID) ) + { + RipNgRte rte; + rte.SetPrefix (rtIter->first->GetDestNetwork ()); + rte.SetPrefixLen (rtIter->first->GetDestNetworkPrefix ().GetPrefixLength ()); + if (m_splitHorizonStrategy == POISON_REVERSE && splitHorizoning) + { + rte.SetRouteMetric (16); + } + else + { + rte.SetRouteMetric (rtIter->first->GetRouteMetric ()); + } + rte.SetRouteTag (rtIter->first->GetRouteTag ()); + if ((m_splitHorizonStrategy != SPLIT_HORIZON) || + (m_splitHorizonStrategy == SPLIT_HORIZON && !splitHorizoning)) + { + hdr.AddRte (rte); + } + } + if (hdr.GetRteNumber () == maxRte) + { + p->AddHeader (hdr); + NS_LOG_DEBUG ("SendTo: " << *p); + sendingSoket->SendTo (p, 0, Inet6SocketAddress (senderAddress, RIPNG_PORT)); + p->RemoveHeader (hdr); + hdr.ClearRtes (); + } + } + if (hdr.GetRteNumber () > 0) + { + p->AddHeader (hdr); + NS_LOG_DEBUG ("SendTo: " << *p); + sendingSoket->SendTo (p, 0, Inet6SocketAddress (senderAddress, RIPNG_PORT)); + } + } + } + } + else + { + // note: we got the request as a single packet, so no check is necessary for MTU limit + + // we use one of the sending sockets, as they're bound to the right interface + // and the local address might be used on different interfaces. + Ptr sendingSoket; + if (senderAddress.IsLinkLocal ()) + { + for (SocketListI iter = m_sendSocketList.begin (); iter != m_sendSocketList.end (); iter++ ) + { + if (iter->second == incomingInterface) + { + sendingSoket = iter->first; + } + } + } + else + { + sendingSoket = m_recvSocket; + } + + Ptr p = Create (); + SocketIpv6HopLimitTag tag; + p->RemovePacketTag (tag); + tag.SetHopLimit (255); + p->AddPacketTag (tag); + + RipNgHeader hdr; + hdr.SetCommand (RipNgHeader::RESPONSE); + + for (std::list::iterator iter = rtes.begin (); + iter != rtes.end (); iter++) + { + bool found = false; + for (RoutesI rtIter = m_routes.begin (); rtIter != m_routes.end (); rtIter++) + { + Ipv6InterfaceAddress rtDestAddr = Ipv6InterfaceAddress(rtIter->first->GetDestNetwork ()); + if ((rtDestAddr.GetScope () == Ipv6InterfaceAddress::GLOBAL) && + (rtIter->first->GetRouteStatus () == RipNgRoutingTableEntry::RIPNG_VALID)) + { + Ipv6Address requestedAddress = iter->GetPrefix (); + requestedAddress.CombinePrefix (Ipv6Prefix (iter->GetPrefixLen ())); + Ipv6Address rtAddress = rtIter->first->GetDestNetwork (); + rtAddress.CombinePrefix (rtIter->first->GetDestNetworkPrefix ()); + + if (requestedAddress == rtAddress) + { + iter->SetRouteMetric (rtIter->first->GetRouteMetric ()); + iter->SetRouteTag (rtIter->first->GetRouteTag ()); + hdr.AddRte (*iter); + found = true; + break; + } + } + } + if (!found) + { + iter->SetRouteMetric (16); + iter->SetRouteTag (0); + hdr.AddRte (*iter); + } + } + p->AddHeader (hdr); + NS_LOG_DEBUG ("SendTo: " << *p); + sendingSoket->SendTo (p, 0, Inet6SocketAddress (senderAddress, senderPort)); + } + +} + +void RipNg::HandleResponses (RipNgHeader hdr, Ipv6Address senderAddress, uint32_t incomingInterface, uint8_t hopLimit) +{ + NS_LOG_FUNCTION (this << senderAddress << incomingInterface << int (hopLimit) << hdr); + + if (m_interfaceExclusions.find (incomingInterface) != m_interfaceExclusions.end ()) + { + NS_LOG_LOGIC ("Ignoring an update message from an excluded interface: " << incomingInterface); + return; + } + + if (!senderAddress.IsLinkLocal ()) + { + NS_LOG_LOGIC ("Ignoring an update message from a non-link-local source: " << senderAddress); + return; + } + + if (hopLimit != 255) + { + NS_LOG_LOGIC ("Ignoring an update message with suspicious hop count: " << int (hopLimit)); + return; + } + + std::list rtes = hdr.GetRteList (); + + // validate the RTEs before processing + for (std::list::iterator iter = rtes.begin (); + iter != rtes.end (); iter++) + { + if (iter->GetRouteMetric () == 0 || iter->GetRouteMetric () > 16) + { + NS_LOG_LOGIC ("Ignoring an update message with malformed metric: " << int (iter->GetRouteMetric ())); + return; + } + if (iter->GetPrefixLen () > 128) + { + NS_LOG_LOGIC ("Ignoring an update message with malformed prefix length: " << int (iter->GetPrefixLen ())); + return; + } + if (iter->GetPrefix ().IsLocalhost () || + iter->GetPrefix ().IsLinkLocal () || + iter->GetPrefix ().IsMulticast ()) + { + NS_LOG_LOGIC ("Ignoring an update message with wrong prefixes: " << iter->GetPrefix ()); + return; + } + } + + bool changed = false; + + for (std::list::iterator iter = rtes.begin (); + iter != rtes.end (); iter++) + { + Ipv6Prefix rtePrefix = Ipv6Prefix (iter->GetPrefixLen ()); + Ipv6Address rteAddr = iter->GetPrefix ().CombinePrefix (rtePrefix); + + NS_LOG_LOGIC ("Processing RTE " << *iter); + + uint8_t interfaceMetric = 1; + if (m_interfaceMetrics.find (incomingInterface) != m_interfaceMetrics.end ()) + { + interfaceMetric = m_interfaceMetrics[incomingInterface]; + } + uint8_t rteMetric = std::min (iter->GetRouteMetric () + interfaceMetric, 16); + RoutesI it; + bool found = false; + for (it = m_routes.begin (); it != m_routes.end (); it++) + { + if (it->first->GetDestNetwork () == rteAddr && + it->first->GetDestNetworkPrefix () == rtePrefix) + { + found = true; + if (rteMetric < it->first->GetRouteMetric ()) + { + if (senderAddress != it->first->GetGateway ()) + { + RipNgRoutingTableEntry* route = new RipNgRoutingTableEntry (rteAddr, rtePrefix, senderAddress, incomingInterface, Ipv6Address::GetAny ()); + delete it->first; + it->first = route; + } + it->first->SetRouteMetric (rteMetric); + it->first->SetRouteStatus (RipNgRoutingTableEntry::RIPNG_VALID); + it->first->SetRouteTag (iter->GetRouteTag ()); + it->first->SetRouteChanged (true); + it->second.Cancel (); + it->second = Simulator::Schedule (m_timeoutDelay, &RipNg::InvalidateRoute, this, it->first); + changed = true; + } + else if (rteMetric == it->first->GetRouteMetric ()) + { + if (senderAddress == it->first->GetGateway ()) + { + it->second.Cancel (); + it->second = Simulator::Schedule (m_timeoutDelay, &RipNg::InvalidateRoute, this, it->first); + } + else + { + if (Simulator::GetDelayLeft (it->second) < m_timeoutDelay/2) + { + RipNgRoutingTableEntry* route = new RipNgRoutingTableEntry (rteAddr, rtePrefix, senderAddress, incomingInterface, Ipv6Address::GetAny ()); + route->SetRouteMetric (rteMetric); + route->SetRouteStatus (RipNgRoutingTableEntry::RIPNG_VALID); + route->SetRouteTag (iter->GetRouteTag ()); + route->SetRouteChanged (true); + delete it->first; + it->first = route; + it->second.Cancel (); + it->second = Simulator::Schedule (m_timeoutDelay, &RipNg::InvalidateRoute, this, route); + changed = true; + } + } + } + else if (rteMetric > it->first->GetRouteMetric () && senderAddress == it->first->GetGateway ()) + { + it->second.Cancel (); + if (rteMetric < 16) + { + it->first->SetRouteMetric (rteMetric); + it->first->SetRouteStatus (RipNgRoutingTableEntry::RIPNG_VALID); + it->first->SetRouteTag (iter->GetRouteTag ()); + it->first->SetRouteChanged (true); + it->second.Cancel (); + it->second = Simulator::Schedule (m_timeoutDelay, &RipNg::InvalidateRoute, this, it->first); + } + else + { + InvalidateRoute (it->first); + } + changed = true; + } + } + } + if (!found && rteMetric != 16) + { + NS_LOG_LOGIC ("Received a RTE with new route, adding."); + + RipNgRoutingTableEntry* route = new RipNgRoutingTableEntry (rteAddr, rtePrefix, senderAddress, incomingInterface, Ipv6Address::GetAny ()); + route->SetRouteMetric (rteMetric); + route->SetRouteStatus (RipNgRoutingTableEntry::RIPNG_VALID); + route->SetRouteChanged (true); + m_routes.push_front (std::make_pair (route, EventId ())); + EventId invalidateEvent = Simulator::Schedule (m_timeoutDelay, &RipNg::InvalidateRoute, this, route); + (m_routes.begin ())->second = invalidateEvent; + changed = true; + } + } + + if (changed) + { + SendTriggeredRouteUpdate (); + } +} + +void RipNg::DoSendRouteUpdate (bool periodic) +{ + NS_LOG_FUNCTION (this << (periodic ? " periodic" : " triggered")); + + for (SocketListI iter = m_sendSocketList.begin (); iter != m_sendSocketList.end (); iter++ ) + { + uint32_t interface = iter->second; + + if (m_interfaceExclusions.find (interface) == m_interfaceExclusions.end ()) + { + uint16_t mtu = m_ipv6->GetMtu (interface); + uint16_t maxRte = (mtu - Ipv6Header ().GetSerializedSize () - UdpHeader ().GetSerializedSize () - RipNgHeader ().GetSerializedSize ()) / RipNgRte ().GetSerializedSize (); + + Ptr p = Create (); + SocketIpv6HopLimitTag tag; + tag.SetHopLimit (255); + p->AddPacketTag (tag); + + RipNgHeader hdr; + hdr.SetCommand (RipNgHeader::RESPONSE); + + for (RoutesI rtIter = m_routes.begin (); rtIter != m_routes.end (); rtIter++) + { + bool splitHorizoning = (rtIter->first->GetInterface () == interface); + Ipv6InterfaceAddress rtDestAddr = Ipv6InterfaceAddress(rtIter->first->GetDestNetwork ()); + + NS_LOG_DEBUG ("Processing RT " << rtDestAddr << " " << int(rtIter->first->IsRouteChanged ())); + + bool isGlobal = (rtDestAddr.GetScope () == Ipv6InterfaceAddress::GLOBAL); + bool isDefaultRoute = ((rtIter->first->GetDestNetwork () == Ipv6Address::GetAny ()) && + (rtIter->first->GetDestNetworkPrefix () == Ipv6Prefix::GetZero ()) && + (rtIter->first->GetInterface () != interface)); + + if ((isGlobal || isDefaultRoute) && + (periodic || rtIter->first->IsRouteChanged ())) + { + RipNgRte rte; + rte.SetPrefix (rtIter->first->GetDestNetwork ()); + rte.SetPrefixLen (rtIter->first->GetDestNetworkPrefix ().GetPrefixLength ()); + if (m_splitHorizonStrategy == POISON_REVERSE && splitHorizoning) + { + rte.SetRouteMetric (16); + } + else + { + rte.SetRouteMetric (rtIter->first->GetRouteMetric ()); + } + rte.SetRouteTag (rtIter->first->GetRouteTag ()); + if (m_splitHorizonStrategy == SPLIT_HORIZON && !splitHorizoning) + { + hdr.AddRte (rte); + } + else if (m_splitHorizonStrategy != SPLIT_HORIZON) + { + hdr.AddRte (rte); + } + } + if (hdr.GetRteNumber () == maxRte) + { + p->AddHeader (hdr); + NS_LOG_DEBUG ("SendTo: " << *p); + iter->first->SendTo (p, 0, Inet6SocketAddress (RIPNG_ALL_NODE, RIPNG_PORT)); + p->RemoveHeader (hdr); + hdr.ClearRtes (); + } + } + if (hdr.GetRteNumber () > 0) + { + p->AddHeader (hdr); + NS_LOG_DEBUG ("SendTo: " << *p); + iter->first->SendTo (p, 0, Inet6SocketAddress (RIPNG_ALL_NODE, RIPNG_PORT)); + } + } + } + for (RoutesI rtIter = m_routes.begin (); rtIter != m_routes.end (); rtIter++) + { + rtIter->first->SetRouteChanged (false); + } +} + +void RipNg::SendTriggeredRouteUpdate () +{ + NS_LOG_FUNCTION (this); + + if (m_nextTriggeredUpdate.IsRunning()) + { + NS_LOG_LOGIC ("Skipping Triggered Update due to cooldown"); + return; + } + + // DoSendRouteUpdate (false); + + // note: The RFC states: + // After a triggered + // update is sent, a timer should be set for a random interval between 1 + // and 5 seconds. If other changes that would trigger updates occur + // before the timer expires, a single update is triggered when the timer + // expires. The timer is then reset to another random value between 1 + // and 5 seconds. Triggered updates may be suppressed if a regular + // update is due by the time the triggered update would be sent. + // Here we rely on this: + // When an update occurs (either Triggered or Periodic) the "IsChanged ()" + // route field will be cleared. + // Hence, the following Triggered Update will be fired, but will not send + // any route update. + + Time delay = Seconds (m_rng->GetValue (m_minTriggeredUpdateDelay.GetSeconds (), m_maxTriggeredUpdateDelay.GetSeconds ())); + m_nextTriggeredUpdate = Simulator::Schedule (delay, &RipNg::DoSendRouteUpdate, this, false); +} + +void RipNg::SendUnsolicitedRouteUpdate () +{ + NS_LOG_FUNCTION (this); + + if (m_nextTriggeredUpdate.IsRunning()) + { + m_nextTriggeredUpdate.Cancel (); + } + + DoSendRouteUpdate (true); + + Time delay = m_unsolicitedUpdate + Seconds (m_rng->GetValue (0, 0.5*m_unsolicitedUpdate.GetSeconds ()) ); + m_nextUnsolicitedUpdate = Simulator::Schedule (delay, &RipNg::SendUnsolicitedRouteUpdate, this); +} + +std::set RipNg::GetInterfaceExclusions () const +{ + return m_interfaceExclusions; +} + +void RipNg::SetInterfaceExclusions (std::set exceptions) +{ + NS_LOG_FUNCTION (this); + + m_interfaceExclusions = exceptions; +} + +uint8_t RipNg::GetInterfaceMetric (uint32_t interface) const +{ + NS_LOG_FUNCTION (this << interface); + + std::map::const_iterator iter = m_interfaceMetrics.find (interface); + if (iter != m_interfaceMetrics.end ()) + { + return iter->second; + } + return 1; +} + +void RipNg::SetInterfaceMetric (uint32_t interface, uint8_t metric) +{ + NS_LOG_FUNCTION (this << interface << int (metric)); + + if (metric < 16) + { + m_interfaceMetrics[interface] = metric; + } +} + +void RipNg::SendRouteRequest () +{ + NS_LOG_FUNCTION (this); + + Ptr p = Create (); + SocketIpv6HopLimitTag tag; + p->RemovePacketTag (tag); + tag.SetHopLimit (255); + p->AddPacketTag (tag); + + RipNgHeader hdr; + hdr.SetCommand (RipNgHeader::REQUEST); + + RipNgRte rte; + rte.SetPrefix (Ipv6Address::GetAny ()); + rte.SetPrefixLen (0); + rte.SetRouteMetric (16); + + hdr.AddRte (rte); + p->AddHeader (hdr); + + for (SocketListI iter = m_sendSocketList.begin (); iter != m_sendSocketList.end (); iter++ ) + { + uint32_t interface = iter->second; + + if (m_interfaceExclusions.find (interface) == m_interfaceExclusions.end ()) + { + NS_LOG_DEBUG ("SendTo: " << *p); + iter->first->SendTo (p, 0, Inet6SocketAddress (RIPNG_ALL_NODE, RIPNG_PORT)); + } + } +} + +void RipNg::AddDefaultRouteTo (Ipv6Address nextHop, uint32_t interface) +{ + NS_LOG_FUNCTION (this << interface); + + AddNetworkRouteTo (Ipv6Address ("::"), Ipv6Prefix::GetZero (), nextHop, interface, Ipv6Address ("::")); +} + + +/* + * RipNgRoutingTableEntry + */ + +RipNgRoutingTableEntry::RipNgRoutingTableEntry () + : m_tag (0), m_metric (16), m_status (RIPNG_INVALID), m_changed (false) +{ +} + +RipNgRoutingTableEntry::RipNgRoutingTableEntry (Ipv6Address network, Ipv6Prefix networkPrefix, Ipv6Address nextHop, uint32_t interface, Ipv6Address prefixToUse) + : Ipv6RoutingTableEntry ( RipNgRoutingTableEntry::CreateNetworkRouteTo (network, networkPrefix, nextHop, interface, prefixToUse) ), + m_tag (0), m_metric (16), m_status (RIPNG_INVALID), m_changed (false) +{ +} + +RipNgRoutingTableEntry::RipNgRoutingTableEntry (Ipv6Address network, Ipv6Prefix networkPrefix, uint32_t interface) + : Ipv6RoutingTableEntry ( Ipv6RoutingTableEntry::CreateNetworkRouteTo (network, networkPrefix, interface) ), + m_tag (0), m_metric (16), m_status (RIPNG_INVALID), m_changed (false) +{ +} + +RipNgRoutingTableEntry::~RipNgRoutingTableEntry () +{ +} + + +void RipNgRoutingTableEntry::SetRouteTag (uint16_t routeTag) +{ + if (m_tag != routeTag) + { + m_tag = routeTag; + m_changed = true; + } +} + +uint16_t RipNgRoutingTableEntry::GetRouteTag () const +{ + return m_tag; +} + +void RipNgRoutingTableEntry::SetRouteMetric (uint8_t routeMetric) +{ + if (m_metric != routeMetric) + { + m_metric = routeMetric; + m_changed = true; + } +} + +uint8_t RipNgRoutingTableEntry::GetRouteMetric () const +{ + return m_metric; +} + +void RipNgRoutingTableEntry::SetRouteStatus (Status_e status) +{ + if (m_status != status) + { + m_status = status; + m_changed = true; + } +} + +RipNgRoutingTableEntry::Status_e RipNgRoutingTableEntry::GetRouteStatus (void) const +{ + return m_status; +} + +void RipNgRoutingTableEntry::SetRouteChanged (bool changed) +{ + m_changed = changed; +} + +bool RipNgRoutingTableEntry::IsRouteChanged (void) const +{ + return m_changed; +} + + +std::ostream & operator << (std::ostream& os, const RipNgRoutingTableEntry& rte) +{ + os << static_cast(rte); + os << ", metric: " << int (rte.GetRouteMetric ()) << ", tag: " << int (rte.GetRouteTag ()); + + return os; +} + + +} + diff -Naur ns-3.19/src/internet/model/ripng.h ns-3.20/src/internet/model/ripng.h --- ns-3.19/src/internet/model/ripng.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/internet/model/ripng.h 2014-06-17 10:33:13.854996262 -0700 @@ -0,0 +1,411 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze, Italy + * + * 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: Tommaso Pecorella + */ + +#ifndef RIPNG_H +#define RIPNG_H + +#include + +#include "ns3/ipv6-routing-protocol.h" +#include "ns3/ipv6-interface.h" +#include "ns3/inet6-socket-address.h" +#include "ns3/ipv6-l3-protocol.h" +#include "ns3/ipv6-routing-table-entry.h" +#include "ns3/random-variable-stream.h" +#include "ns3/ripng-header.h" + +namespace ns3 { + +/** + * \defgroup ripng RIPng + * + * The RIPng protocol (\rfc{2080}) is a unicast-only IPv6 IGP (Interior Gateway Protocol). + * Its convergence time is rather long. As a consequence, it is suggested to + * carefully check the network topology and the route status before sending + * data flows. + * + * RIPng implements the Bellman-Ford algorithm (although the RFC does not state it). + * Bellman-Ford algorithm convergence time is O(|V|*|E|) where |V| and |E| are the + * number of vertices (routers) and edges (links) respectively. Since unsolicited + * updates are exchanged every 30 seconds, the convergence might require a long time. + * + * For the RIPng protocol, the exact convergence time is shorter, thanks to the + * use of triggered updates, which are sent when a route changes. + * Even with triggered updates, the convergence is in the order of magnitude of + * O(|V|*|E|) * 5 seconds, which is still quite long for complex topologies. + * + * \todo: Add routing table compression (CIDR). The most evident result: without + * it a router will announce to be the default router *and* more RTEs, which is silly. + */ + +/** + * \ingroup ripng + * \brief RipNg Routing Table Entry + */ +class RipNgRoutingTableEntry : public Ipv6RoutingTableEntry +{ +public: + + /** + * Route status + */ + enum Status_e { + RIPNG_VALID, + RIPNG_INVALID, + }; + + RipNgRoutingTableEntry (void); + + /** + * \brief Constructor + * \param network network address + * \param networkPrefix network prefix + * \param nextHop next hop address to route the packet + * \param interface interface index + * \param prefixToUse prefix that should be used for source address for this destination + */ + RipNgRoutingTableEntry (Ipv6Address network, Ipv6Prefix networkPrefix, Ipv6Address nextHop, uint32_t interface, Ipv6Address prefixToUse); + + /** + * \brief Constructor + * \param network network address + * \param networkPrefix network prefix + * \param interface interface index + */ + RipNgRoutingTableEntry (Ipv6Address network, Ipv6Prefix networkPrefix, uint32_t interface); + + virtual ~RipNgRoutingTableEntry (); + + /** + * \brief Set the route tag + * \param routeTag the route tag + */ + void SetRouteTag (uint16_t routeTag); + + /** + * \brief Get the route tag + * \returns the route tag + */ + uint16_t GetRouteTag (void) const; + + /** + * \brief Set the route metric + * \param routeMetric the route metric + */ + void SetRouteMetric (uint8_t routeMetric); + + /** + * \brief Get the route metric + * \returns the route metric + */ + uint8_t GetRouteMetric (void) const; + + /** + * \brief Set the route status + * \param status the route status + */ + void SetRouteStatus (Status_e status); + + /** + * \brief Get the route status + * \returns the route status + */ + Status_e GetRouteStatus (void) const; + + /** + * \brief Set the route as changed + * + * The changed routes are scheduled for a Triggered Update. + * After a Triggered Update, all the changed flags are cleared + * from the routing table. + * + * \param true if route is changed + */ + void SetRouteChanged (bool changed); + + /** + * \brief Get the route changed status + * + * \returns true if route is changed + */ + bool IsRouteChanged (void) const; + +private: + uint16_t m_tag; //!< route tag + uint8_t m_metric; //!< route metric + Status_e m_status; //!< route status + bool m_changed; //!< route has been updated +}; + +/** + * \brief Stream insertion operator. + * + * \param os the reference to the output stream + * \param route the Ipv6 routing table entry + * \returns the reference to the output stream + */ +std::ostream& operator<< (std::ostream& os, RipNgRoutingTableEntry const& route); + + + +/** + * \ingroup ripng + * + * \brief RIPng Routing Protocol, defined in \rfc{2080}. + */ +class RipNg : public Ipv6RoutingProtocol +{ +public: + // /< C-tor + RipNg (); + virtual ~RipNg (); + + static TypeId GetTypeId (void); + + // \name From Ipv6RoutingProtocol + // \{ + Ptr RouteOutput (Ptr p, const Ipv6Header &header, Ptr oif, + Socket::SocketErrno &sockerr); + bool RouteInput (Ptr p, const Ipv6Header &header, Ptr idev, + UnicastForwardCallback ucb, MulticastForwardCallback mcb, + LocalDeliverCallback lcb, ErrorCallback ecb); + virtual void NotifyInterfaceUp (uint32_t interface); + virtual void NotifyInterfaceDown (uint32_t interface); + virtual void NotifyAddAddress (uint32_t interface, Ipv6InterfaceAddress address); + virtual void NotifyRemoveAddress (uint32_t interface, Ipv6InterfaceAddress address); + virtual void NotifyAddRoute (Ipv6Address dst, Ipv6Prefix mask, Ipv6Address nextHop, + uint32_t interface, Ipv6Address prefixToUse = Ipv6Address::GetZero ()); + virtual void NotifyRemoveRoute (Ipv6Address dst, Ipv6Prefix mask, Ipv6Address nextHop, + uint32_t interface, Ipv6Address prefixToUse = Ipv6Address::GetZero ()); + virtual void SetIpv6 (Ptr ipv6); + virtual void PrintRoutingTable (Ptr stream) const; + // \} + + enum SplitHorizonType_e { + NO_SPLIT_HORIZON, + SPLIT_HORIZON, + POISON_REVERSE, + }; + + /** + * Assign a fixed random variable stream number to the random variables + * used by this model. Return the number of streams (possibly zero) that + * have been assigned. + * + * \param stream first stream index to use + * \return the number of stream indices assigned by this model + */ + int64_t AssignStreams (int64_t stream); + + /** + * \brief Get the set of interface excluded from the protocol + * \return the set of excluded interfaces + */ + std::set GetInterfaceExclusions () const; + + /** + * \brief Set the set of interface excluded from the protocol + * \param exceptions the set of excluded interfaces + */ + void SetInterfaceExclusions (std::set exceptions); + + /** + * \brief Get the metric for an interface + * \param interface the interface + * \returns the interface metric + */ + uint8_t GetInterfaceMetric (uint32_t interface) const; + + /** + * \brief Set the metric for an interface + * \param interface the interface + * \param metric the interface metric + */ + void SetInterfaceMetric (uint32_t interface, uint8_t metric); + + /** + * \brief Add a default route to the router through the nextHop located on interface. + * + * The default route is usually installed manually, or it is the result of + * some "other" routing protocol (e.g., BGP). + * + * \param nextHop the next hop + * \param interface the interface + */ + void AddDefaultRouteTo (Ipv6Address nextHop, uint32_t interface); + +protected: + /** + * \brief Dispose this object. + */ + virtual void DoDispose (); + + /** + * Start protocol operation + */ + void DoInitialize (); + +private: + /// Container for the network routes - pair RipNgRoutingTableEntry *, EventId (update event) + typedef std::list > Routes; + + /// Const Iterator for container for the network routes + typedef std::list >::const_iterator RoutesCI; + + /// Iterator for container for the network routes + typedef std::list >::iterator RoutesI; + + + /** + * \brief Receive RIPng packets. + * + * \param socket the socket the packet was received to. + */ + void Receive (Ptr socket); + + /** + * \brief Handle RIPng requests. + * + * \param hdr message header (including RTEs) + * \param senderAddress sender address + * \param senderPort sender port + * \param incomingInterface incoming interface + * \param hopLimit packet's hop limit + */ + void HandleRequests (RipNgHeader hdr, Ipv6Address senderAddress, uint16_t senderPort, uint32_t incomingInterface, uint8_t hopLimit); + + /** + * \brief Handle RIPng responses. + * + * \param hdr message header (including RTEs) + * \param senderAddress sender address + * \param incomingInterface incoming interface + * \param hopLimit packet's hop limit + */ + void HandleResponses (RipNgHeader hdr, Ipv6Address senderAddress, uint32_t incomingInterface, uint8_t hopLimit); + + /** + * \brief Lookup in the forwarding table for destination. + * \param dest destination address + * \param interface output interface if any (put 0 otherwise) + * \return Ipv6Route to route the packet to reach dest address + */ + Ptr Lookup (Ipv6Address dest, Ptr = 0); + + /** + * Receive and process unicast packet + * \param socket socket where packet is arrived + */ + void RecvUnicastRipng (Ptr socket); + /** + * Receive and process multicast packet + * \param socket socket where packet is arrived + */ + void RecvMulticastRipng (Ptr socket); + + /** + * \brief Add route to network. + * \param network network address + * \param networkPrefix network prefix* + * \param nextHop next hop address to route the packet. + * \param interface interface index + * \param prefixToUse prefix that should be used for source address for this destination + * \param metric metric of route in case of multiple routes to same destination + */ + void AddNetworkRouteTo (Ipv6Address network, Ipv6Prefix networkPrefix, Ipv6Address nextHop, uint32_t interface, Ipv6Address prefixToUse); + + /** + * \brief Add route to network. + * \param network network address + * \param networkPrefix network prefix + * \param interface interface index + * \param metric metric of route in case of multiple routes to same destination + */ + void AddNetworkRouteTo (Ipv6Address network, Ipv6Prefix networkPrefix, uint32_t interface); + + /** + * \brief Send Routing Updates on all interfaces. + */ + void DoSendRouteUpdate (bool periodic); + + /** + * \brief Send Routing Request on all interfaces. + */ + void SendRouteRequest (); + + /** + * \brief Send Triggered Routing Updates on all interfaces. + */ + void SendTriggeredRouteUpdate (); + + /** + * \brief Send Unsolicited Routing Updates on all interfaces. + */ + void SendUnsolicitedRouteUpdate (void); + + /** + * \brief Invalidate a route. + * \param route the route to be removed + */ + void InvalidateRoute (RipNgRoutingTableEntry *route); + + /** + * \brief Delete a route. + * \param route the route to be removed + */ + void DeleteRoute (RipNgRoutingTableEntry *route); + + Routes m_routes; //!< the forwarding table for network. + Ptr m_ipv6; //!< IPv6 reference + Time m_startupDelay; //!< Random delay before protocol startup. + Time m_minTriggeredUpdateDelay; //!< Min cooldown delay after a Triggered Update. + Time m_maxTriggeredUpdateDelay; //!< Max cooldown delay after a Triggered Update. + Time m_unsolicitedUpdate; //!< time between two Unsolicited Routing Updates + Time m_timeoutDelay; //!< Delay before invalidating a route + Time m_garbageCollectionDelay; //!< Delay before deleting an INVALID route + + // note: we can not trust the result of socket->GetBoundNetDevice ()->GetIfIndex (); + // it is dependent on the interface initialization (i.e., if the loopback is already up). + /// Socket list type + typedef std::map< Ptr, uint32_t> SocketList; + /// Socket list type iterator + typedef std::map, uint32_t>::iterator SocketListI; + /// Socket list type const iterator + typedef std::map, uint32_t>::const_iterator SocketListCI; + + SocketList m_sendSocketList; //!< list of sockets for sending (socket, interface index) + Ptr m_recvSocket; + + EventId m_nextUnsolicitedUpdate; //!< Next Unsolicited Update event + EventId m_nextTriggeredUpdate; //!< Next Triggered Update event + + Ptr m_rng; //!< Rng stream. + + std::set m_interfaceExclusions; // Set of excluded interfaces + std::map m_interfaceMetrics; // Map of interface metrics + + SplitHorizonType_e m_splitHorizonStrategy; // Split Horizon strategy + + bool m_initialized; // flag to allow socket's late-creation. +}; + +} // namespace ns3 +#endif /* RIPNG_H */ + diff -Naur ns-3.19/src/internet/model/ripng-header.cc ns-3.20/src/internet/model/ripng-header.cc --- ns-3.19/src/internet/model/ripng-header.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/internet/model/ripng-header.cc 2014-06-17 10:33:13.852996278 -0700 @@ -0,0 +1,255 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze, Italy + * + * 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: Tommaso Pecorella + */ + +#include "ripng-header.h" + +namespace ns3 { + +/* + * RipNgRte + */ +NS_OBJECT_ENSURE_REGISTERED (RipNgRte) + ; + +RipNgRte::RipNgRte () + : m_prefix ("::"), m_tag (0), m_prefixLen (0), m_metric (16) +{ +} + +TypeId RipNgRte::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::RipNgRte").SetParent
().AddConstructor (); + return tid; +} + +TypeId RipNgRte::GetInstanceTypeId (void) const +{ + return GetTypeId (); +} + +void RipNgRte::Print (std::ostream & os) const +{ + os << "prefix " << m_prefix << "/" << int(m_prefixLen) << " Metric " << int(m_metric) << " Tag " << int(m_tag); +} + +uint32_t RipNgRte::GetSerializedSize () const +{ + return 20; +} + +void RipNgRte::Serialize (Buffer::Iterator i) const +{ + uint8_t tmp[16]; + + m_prefix.Serialize (tmp); + i.Write (tmp, 16); + + i.WriteHtonU16 (m_tag); + i.WriteU8 (m_prefixLen); + i.WriteU8 (m_metric); +} + +uint32_t RipNgRte::Deserialize (Buffer::Iterator i) +{ + uint8_t tmp[16]; + + i.Read (tmp, 16); + m_prefix.Set (tmp); + m_tag = i.ReadNtohU16 (); + m_prefixLen = i.ReadU8 (); + m_metric = i.ReadU8 (); + + return GetSerializedSize (); +} + +void RipNgRte::SetPrefix (Ipv6Address prefix) +{ + m_prefix = prefix; +} + +Ipv6Address RipNgRte::GetPrefix () const +{ + return m_prefix; +} + +void RipNgRte::SetPrefixLen (uint8_t prefixLen) +{ + m_prefixLen = prefixLen; +} + +uint8_t RipNgRte::GetPrefixLen () const +{ + return m_prefixLen; +} + +void RipNgRte::SetRouteTag (uint16_t routeTag) +{ + m_tag = routeTag; +} + +uint16_t RipNgRte::GetRouteTag () const +{ + return m_tag; +} + +void RipNgRte::SetRouteMetric (uint8_t routeMetric) +{ + m_metric = routeMetric; +} + +uint8_t RipNgRte::GetRouteMetric () const +{ + return m_metric; +} + + +std::ostream & operator << (std::ostream & os, const RipNgRte & h) +{ + h.Print (os); + return os; +} + +/* + * RipNgHeader + */ +NS_OBJECT_ENSURE_REGISTERED (RipNgHeader) + ; + +RipNgHeader::RipNgHeader () + : m_command (0) +{ +} + +TypeId RipNgHeader::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::RipNgHeader").SetParent
().AddConstructor (); + return tid; +} + +TypeId RipNgHeader::GetInstanceTypeId (void) const +{ + return GetTypeId (); +} + +void RipNgHeader::Print (std::ostream & os) const +{ + os << "command " << int(m_command); + for (std::list::const_iterator iter = m_rteList.begin (); + iter != m_rteList.end (); iter ++) + { + os << " | "; + iter->Print (os); + } +} + +uint32_t RipNgHeader::GetSerializedSize () const +{ + RipNgRte rte; + return 4 + m_rteList.size () * rte.GetSerializedSize (); +} + +void RipNgHeader::Serialize (Buffer::Iterator start) const +{ + Buffer::Iterator i = start; + + i.WriteU8 (uint8_t (m_command)); + i.WriteU8 (1); + i.WriteU16 (0); + + for (std::list::const_iterator iter = m_rteList.begin (); + iter != m_rteList.end (); iter ++) + { + iter->Serialize (i); + i.Next(iter->GetSerializedSize ()); + } +} + +uint32_t RipNgHeader::Deserialize (Buffer::Iterator start) +{ + Buffer::Iterator i = start; + + uint8_t temp; + temp = i.ReadU8 (); + if ((temp == REQUEST) || (temp == RESPONSE)) + { + m_command = temp; + } + else + { + return 0; + } + + temp = i.ReadU8 (); + NS_ASSERT_MSG (temp == 1, "RipNG received a message with mismatch version, aborting."); + + uint16_t temp16 = i.ReadU16 (); + NS_ASSERT_MSG (temp16 == 0, "RipNG received a message with invalid filled flags, aborting."); + + uint8_t rteNumber = (i.GetSize () - 4)/20; + for (uint8_t n=0; n RipNgHeader::GetRteList (void) const +{ + return m_rteList; +} + + +std::ostream & operator << (std::ostream & os, const RipNgHeader & h) +{ + h.Print (os); + return os; +} + + +} + diff -Naur ns-3.19/src/internet/model/ripng-header.h ns-3.20/src/internet/model/ripng-header.h --- ns-3.19/src/internet/model/ripng-header.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/internet/model/ripng-header.h 2014-06-17 10:33:13.853996270 -0700 @@ -0,0 +1,226 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze, Italy + * + * 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: Tommaso Pecorella + */ + +#ifndef RIPNG_HEADER_H +#define RIPNG_HEADER_H + +#include +#include "ns3/header.h" +#include "ns3/ipv6-address.h" +#include "ns3/packet.h" +#include "ns3/ipv6-header.h" + + +namespace ns3 { + +/** + * \ingroup ripng + * \brief RipNg Routing Table Entry (RTE) - see \RFC{2080} + */ +class RipNgRte : public Header +{ +public: + RipNgRte (void); + + /** + * \brief Get the type ID. + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + /** + * \brief Return the instance type identifier. + * \return instance type ID + */ + virtual TypeId GetInstanceTypeId (void) const; + + virtual void Print (std::ostream& os) const; + + /** + * \brief Get the serialized size of the packet. + * \return size + */ + virtual uint32_t GetSerializedSize (void) const; + + /** + * \brief Serialize the packet. + * \param start Buffer iterator + */ + virtual void Serialize (Buffer::Iterator start) const; + + /** + * \brief Deserialize the packet. + * \param start Buffer iterator + * \return size of the packet + */ + virtual uint32_t Deserialize (Buffer::Iterator start); + + /** + * \brief Set the prefix + * \param prefix the prefix + */ + void SetPrefix (Ipv6Address prefix); + + /** + * \brief Get the prefix + * \returns the prefix + */ + Ipv6Address GetPrefix (void) const; + + /** + * \brief Set the prefix length + * \param prefixLen the prefix length + */ + void SetPrefixLen (uint8_t prefixLen); + + /** + * \brief Get the prefix length + * \returns the prefix length + */ + uint8_t GetPrefixLen (void) const; + + /** + * \brief Set the route tag + * \param routeTag the route tag + */ + void SetRouteTag (uint16_t routeTag); + + /** + * \brief Get the route tag + * \returns the route tag + */ + uint16_t GetRouteTag (void) const; + + /** + * \brief Set the route metric + * \param routeMetric the route metric + */ + void SetRouteMetric (uint8_t routeMetric); + + /** + * \brief Get the route metric + * \returns the route metric + */ + uint8_t GetRouteMetric (void) const; + + +private: + Ipv6Address m_prefix; //!< prefix + uint16_t m_tag; //!< route tag + uint8_t m_prefixLen; //!< prefix length + uint8_t m_metric; //!< route metric +}; + + +/** + * \ingroup ripng + * \brief RipNgHeader - see \RFC{2080} + */ +class RipNgHeader : public Header +{ +public: + RipNgHeader (void); + + /** + * \brief Get the type ID. + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + /** + * \brief Return the instance type identifier. + * \return instance type ID + */ + virtual TypeId GetInstanceTypeId (void) const; + + virtual void Print (std::ostream& os) const; + + /** + * \brief Get the serialized size of the packet. + * \return size + */ + virtual uint32_t GetSerializedSize (void) const; + + /** + * \brief Serialize the packet. + * \param start Buffer iterator + */ + virtual void Serialize (Buffer::Iterator start) const; + + /** + * \brief Deserialize the packet. + * \param start Buffer iterator + * \return size of the packet + */ + virtual uint32_t Deserialize (Buffer::Iterator start); + + /** + * Commands to be used in RipNg headers + */ + enum Command_e + { + REQUEST = 0x1, + RESPONSE = 0x2, + }; + + /** + * \brief Set the command + * \param command the command + */ + void SetCommand (Command_e command); + + /** + * \brief Get the command + * \returns the command + */ + Command_e GetCommand (void) const; + + /** + * \brief Add a RTE to the message + * \param rte the RTE + */ + void AddRte (RipNgRte rte); + + /** + * \brief Clear all the RTEs from the header + */ + void ClearRtes (); + + /** + * \brief Get the number of RTE included in the message + * \returns the number of RTE in the message + */ + uint16_t GetRteNumber (void) const; + + /** + * \brief Get the list of the RTEs included in the message + * \returns the list of the RTEs in the message + */ + std::list GetRteList (void) const; + +private: + uint8_t m_command; //!< command type + std::list m_rteList; //!< list of the RTEs in the message +}; + +} + +#endif /* RIPNG_HEADER_H */ + diff -Naur ns-3.19/src/internet/model/rtt-estimator.cc ns-3.20/src/internet/model/rtt-estimator.cc --- ns-3.19/src/internet/model/rtt-estimator.cc 2014-06-17 10:34:00.532635936 -0700 +++ ns-3.20/src/internet/model/rtt-estimator.cc 2014-06-17 10:33:13.854996262 -0700 @@ -38,8 +38,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (RttEstimator) - ; +NS_OBJECT_ENSURE_REGISTERED (RttEstimator); TypeId RttEstimator::GetTypeId (void) @@ -232,8 +231,7 @@ //----------------------------------------------------------------------------- // Mean-Deviation Estimator -NS_OBJECT_ENSURE_REGISTERED (RttMeanDeviation) - ; +NS_OBJECT_ENSURE_REGISTERED (RttMeanDeviation); TypeId RttMeanDeviation::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/tcp-header.cc ns-3.20/src/internet/model/tcp-header.cc --- ns-3.19/src/internet/model/tcp-header.cc 2014-06-17 10:34:00.533635928 -0700 +++ ns-3.20/src/internet/model/tcp-header.cc 2014-06-17 10:33:13.856996247 -0700 @@ -26,8 +26,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpHeader); TcpHeader::TcpHeader () : m_sourcePort (0), diff -Naur ns-3.19/src/internet/model/tcp-l4-protocol.cc ns-3.20/src/internet/model/tcp-l4-protocol.cc --- ns-3.19/src/internet/model/tcp-l4-protocol.cc 2014-06-17 10:34:00.535635912 -0700 +++ ns-3.20/src/internet/model/tcp-l4-protocol.cc 2014-06-17 10:33:13.857996239 -0700 @@ -51,8 +51,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpL4Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpL4Protocol); //TcpL4Protocol stuff---------------------------------------------------------- diff -Naur ns-3.19/src/internet/model/tcp-newreno.cc ns-3.20/src/internet/model/tcp-newreno.cc --- ns-3.19/src/internet/model/tcp-newreno.cc 2014-06-17 10:34:00.536635905 -0700 +++ ns-3.20/src/internet/model/tcp-newreno.cc 2014-06-17 10:33:13.859996224 -0700 @@ -32,8 +32,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpNewReno) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpNewReno); TypeId TcpNewReno::GetTypeId (void) @@ -128,8 +127,9 @@ m_cWnd -= seq - m_txBuffer.HeadSequence (); m_cWnd += m_segmentSize; // increase cwnd NS_LOG_INFO ("Partial ACK in fast recovery: cwnd set to " << m_cWnd); - TcpSocketBase::NewAck (seq); // update m_nextTxSequence and send new data if allowed by window + m_txBuffer.DiscardUpTo(seq); //Bug 1850: retransmit before newack DoRetransmit (); // Assume the next seq is lost. Retransmit lost packet + TcpSocketBase::NewAck (seq); // update m_nextTxSequence and send new data if allowed by window return; } else if (m_inFastRec && seq >= m_recover) diff -Naur ns-3.19/src/internet/model/tcp-reno.cc ns-3.20/src/internet/model/tcp-reno.cc --- ns-3.19/src/internet/model/tcp-reno.cc 2014-06-17 10:34:00.536635905 -0700 +++ ns-3.20/src/internet/model/tcp-reno.cc 2014-06-17 10:33:13.860996216 -0700 @@ -32,8 +32,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpReno) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpReno); TypeId TcpReno::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/tcp-rfc793.cc ns-3.20/src/internet/model/tcp-rfc793.cc --- ns-3.19/src/internet/model/tcp-rfc793.cc 2014-06-17 10:34:00.537635897 -0700 +++ ns-3.20/src/internet/model/tcp-rfc793.cc 2014-06-17 10:33:13.860996216 -0700 @@ -25,8 +25,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpRfc793) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpRfc793); TypeId TcpRfc793::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/tcp-socket-base.cc ns-3.20/src/internet/model/tcp-socket-base.cc --- ns-3.19/src/internet/model/tcp-socket-base.cc 2014-06-17 10:34:00.540635874 -0700 +++ ns-3.20/src/internet/model/tcp-socket-base.cc 2014-06-17 10:33:13.863996193 -0700 @@ -54,8 +54,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpSocketBase) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpSocketBase); TypeId TcpSocketBase::GetTypeId (void) @@ -265,7 +264,11 @@ m_errno = ERROR_ADDRNOTAVAIL; return -1; } - m_tcp->m_sockets.push_back (this); + + if (std::find(m_tcp->m_sockets.begin(), m_tcp->m_sockets.end(), this) == m_tcp->m_sockets.end()) + { + m_tcp->m_sockets.push_back (this); + } return SetupCallback (); } @@ -279,7 +282,11 @@ m_errno = ERROR_ADDRNOTAVAIL; return -1; } - m_tcp->m_sockets.push_back (this); + + if (std::find(m_tcp->m_sockets.begin(), m_tcp->m_sockets.end(), this) == m_tcp->m_sockets.end()) + { + m_tcp->m_sockets.push_back (this); + } return SetupCallback (); } @@ -347,7 +354,11 @@ m_errno = ERROR_INVAL; return -1; } - m_tcp->m_sockets.push_back (this); + + if (std::find(m_tcp->m_sockets.begin(), m_tcp->m_sockets.end(), this) == m_tcp->m_sockets.end()) + { + m_tcp->m_sockets.push_back (this); + } NS_LOG_LOGIC ("TcpSocketBase " << this << " got an endpoint: " << m_endPoint); return SetupCallback (); @@ -770,10 +781,12 @@ { NotifyNormalClose (); } + if (m_state != TIME_WAIT) { DeallocateEndPoint (); } + m_closeNotified = true; NS_LOG_INFO (TcpStateName[m_state] << " -> CLOSED"); CancelAllTimers (); @@ -2083,7 +2096,7 @@ //nextRtt will be zero for dup acks. Don't want to update lastRtt in that case //but still needed to do list clearing that is done in AckSeq. - if(nextRtt != 0) + if(nextRtt != Time (0)) { m_lastRtt = nextRtt; NS_LOG_FUNCTION(this << m_lastRtt); diff -Naur ns-3.19/src/internet/model/tcp-socket-base.h ns-3.20/src/internet/model/tcp-socket-base.h --- ns-3.19/src/internet/model/tcp-socket-base.h 2014-06-17 10:34:00.540635874 -0700 +++ ns-3.20/src/internet/model/tcp-socket-base.h 2014-06-17 10:33:13.864996186 -0700 @@ -211,7 +211,7 @@ * * \param packet the incoming packet * \param header the packet's IPv4 header - * \param port the incoming port + * \param port the remote port * \param incomingInterface the incoming interface */ void ForwardUp (Ptr packet, Ipv4Header header, uint16_t port, Ptr incomingInterface); @@ -221,7 +221,7 @@ * * \param packet the incoming packet * \param header the packet's IPv6 header - * \param port the incoming port + * \param port the remote port * \param incomingInterface the incoming interface */ void ForwardUp6 (Ptr packet, Ipv6Header header, uint16_t port, Ptr incomingInterface); @@ -231,7 +231,7 @@ * * \param packet the incoming packet * \param header the packet's IPv4 header - * \param port the incoming port + * \param port the remote port * \param incomingInterface the incoming interface */ virtual void DoForwardUp (Ptr packet, Ipv4Header header, uint16_t port, Ptr incomingInterface); //Get a pkt from L3 @@ -241,7 +241,7 @@ * * \param packet the incoming packet * \param header the packet's IPv6 header - * \param port the incoming port + * \param port the remote port */ virtual void DoForwardUp (Ptr packet, Ipv6Header header, uint16_t port); @@ -341,7 +341,7 @@ void Destroy6 (void); /** - * \brief Deallocate m_endPoint + * \brief Deallocate m_endPoint and m_endPoint6 */ void DeallocateEndPoint (void); diff -Naur ns-3.19/src/internet/model/tcp-socket.cc ns-3.20/src/internet/model/tcp-socket.cc --- ns-3.19/src/internet/model/tcp-socket.cc 2014-06-17 10:34:00.542635859 -0700 +++ ns-3.20/src/internet/model/tcp-socket.cc 2014-06-17 10:33:13.865996178 -0700 @@ -31,8 +31,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpSocket) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpSocket); const char* const TcpSocket::TcpStateName[LAST_STATE] = { "CLOSED", "LISTEN", "SYN_SENT", "SYN_RCVD", "ESTABLISHED", "CLOSE_WAIT", "LAST_ACK", "FIN_WAIT_1", "FIN_WAIT_2", "CLOSING", "TIME_WAIT" }; diff -Naur ns-3.19/src/internet/model/tcp-socket-factory.cc ns-3.20/src/internet/model/tcp-socket-factory.cc --- ns-3.19/src/internet/model/tcp-socket-factory.cc 2014-06-17 10:34:00.541635866 -0700 +++ ns-3.20/src/internet/model/tcp-socket-factory.cc 2014-06-17 10:33:13.865996178 -0700 @@ -23,8 +23,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpSocketFactory) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpSocketFactory); TypeId TcpSocketFactory::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/tcp-tahoe.cc ns-3.20/src/internet/model/tcp-tahoe.cc --- ns-3.19/src/internet/model/tcp-tahoe.cc 2014-06-17 10:34:00.543635851 -0700 +++ ns-3.20/src/internet/model/tcp-tahoe.cc 2014-06-17 10:33:13.866996170 -0700 @@ -32,8 +32,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (TcpTahoe) - ; +NS_OBJECT_ENSURE_REGISTERED (TcpTahoe); TypeId TcpTahoe::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/tcp-westwood.cc ns-3.20/src/internet/model/tcp-westwood.cc --- ns-3.19/src/internet/model/tcp-westwood.cc 2014-06-17 10:34:00.544635843 -0700 +++ ns-3.20/src/internet/model/tcp-westwood.cc 2014-06-17 10:33:13.868996155 -0700 @@ -46,8 +46,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED(TcpWestwood) - ; +NS_OBJECT_ENSURE_REGISTERED(TcpWestwood); TypeId TcpWestwood::GetTypeId (void) @@ -329,7 +328,7 @@ TcpSocketBase::EstimateRtt (tcpHeader); // Update minRtt - if (m_minRtt == 0) + if (m_minRtt == Time (0)) { m_minRtt = m_lastRtt; } @@ -345,7 +344,7 @@ // to trigger a new BW sampling event if (m_pType == TcpWestwood::WESTWOODPLUS) { - if(m_lastRtt != 0 && m_state == ESTABLISHED && !m_IsCount) + if(m_lastRtt != Time (0) && m_state == ESTABLISHED && !m_IsCount) { m_IsCount = true; m_bwEstimateEvent.Cancel(); diff -Naur ns-3.19/src/internet/model/udp-header.cc ns-3.20/src/internet/model/udp-header.cc --- ns-3.19/src/internet/model/udp-header.cc 2014-06-17 10:34:00.545635835 -0700 +++ ns-3.20/src/internet/model/udp-header.cc 2014-06-17 10:33:13.868996155 -0700 @@ -23,8 +23,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (UdpHeader) - ; +NS_OBJECT_ENSURE_REGISTERED (UdpHeader); /* The magic values below are used only for debugging. * They can be used to easily detect memory corruption diff -Naur ns-3.19/src/internet/model/udp-l4-protocol.cc ns-3.20/src/internet/model/udp-l4-protocol.cc --- ns-3.19/src/internet/model/udp-l4-protocol.cc 2014-06-17 10:34:00.546635828 -0700 +++ ns-3.20/src/internet/model/udp-l4-protocol.cc 2014-06-17 10:33:13.869996147 -0700 @@ -44,8 +44,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (UdpL4Protocol) - ; +NS_OBJECT_ENSURE_REGISTERED (UdpL4Protocol); /* see http://www.iana.org/assignments/protocol-numbers */ const uint8_t UdpL4Protocol::PROT_NUMBER = 17; diff -Naur ns-3.19/src/internet/model/udp-socket.cc ns-3.20/src/internet/model/udp-socket.cc --- ns-3.19/src/internet/model/udp-socket.cc 2014-06-17 10:34:00.549635804 -0700 +++ ns-3.20/src/internet/model/udp-socket.cc 2014-06-17 10:33:13.873996116 -0700 @@ -30,8 +30,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (UdpSocket) - ; +NS_OBJECT_ENSURE_REGISTERED (UdpSocket); TypeId UdpSocket::GetTypeId (void) diff -Naur ns-3.19/src/internet/model/udp-socket-factory.cc ns-3.20/src/internet/model/udp-socket-factory.cc --- ns-3.19/src/internet/model/udp-socket-factory.cc 2014-06-17 10:34:00.547635820 -0700 +++ ns-3.20/src/internet/model/udp-socket-factory.cc 2014-06-17 10:33:13.871996131 -0700 @@ -22,8 +22,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (UdpSocketFactory) - ; +NS_OBJECT_ENSURE_REGISTERED (UdpSocketFactory); TypeId UdpSocketFactory::GetTypeId (void) { diff -Naur ns-3.19/src/internet/model/udp-socket-impl.cc ns-3.20/src/internet/model/udp-socket-impl.cc --- ns-3.19/src/internet/model/udp-socket-impl.cc 2014-06-17 10:34:00.548635812 -0700 +++ ns-3.20/src/internet/model/udp-socket-impl.cc 2014-06-17 10:33:13.872996124 -0700 @@ -43,8 +43,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (UdpSocketImpl) - ; +NS_OBJECT_ENSURE_REGISTERED (UdpSocketImpl); // The correct maximum UDP message size is 65507, as determined by the following formula: // 0xffff - (sizeof(IP Header) + sizeof(UDP Header)) = 65535-(20+8) = 65507 @@ -180,6 +179,25 @@ m_endPoint6 = 0; } +/* Deallocate the end point and cancel all the timers */ +void +UdpSocketImpl::DeallocateEndPoint (void) +{ + if (m_endPoint != 0) + { + m_endPoint->SetDestroyCallback (MakeNullCallback ()); + m_udp->DeAllocate (m_endPoint); + m_endPoint = 0; + } + if (m_endPoint6 != 0) + { + m_endPoint6->SetDestroyCallback (MakeNullCallback ()); + m_udp->DeAllocate (m_endPoint6); + m_endPoint6 = 0; + } +} + + int UdpSocketImpl::FinishBind (void) { @@ -318,6 +336,7 @@ } m_shutdownRecv = true; m_shutdownSend = true; + DeallocateEndPoint (); return 0; } @@ -853,10 +872,14 @@ { address = InetSocketAddress (m_endPoint->GetLocalAddress (), m_endPoint->GetLocalPort ()); } - else + else if (m_endPoint6 != 0) { - // It is possible to call this method on a socket without a name + address = Inet6SocketAddress (m_endPoint6->GetLocalAddress (), m_endPoint6->GetLocalPort ()); + } + else + { // It is possible to call this method on a socket without a name // in which case, behavior is unspecified + // Should this return an InetSocketAddress or an Inet6SocketAddress? address = InetSocketAddress (Ipv4Address::GetZero (), 0); } return 0; diff -Naur ns-3.19/src/internet/model/udp-socket-impl.h ns-3.20/src/internet/model/udp-socket-impl.h --- ns-3.19/src/internet/model/udp-socket-impl.h 2014-06-17 10:34:00.549635804 -0700 +++ ns-3.20/src/internet/model/udp-socket-impl.h 2014-06-17 10:33:13.872996124 -0700 @@ -38,6 +38,8 @@ class Node; class Packet; class UdpL4Protocol; +class Ipv6Header; +class Ipv6Interface; /** * \ingroup udp @@ -125,7 +127,7 @@ * * \param packet the incoming packet * \param header the packet's IPv4 header - * \param port the incoming port + * \param port the remote port * \param incomingInterface the incoming interface */ void ForwardUp (Ptr packet, Ipv4Header header, uint16_t port, Ptr incomingInterface); @@ -135,7 +137,7 @@ * * \param packet the incoming packet * \param header the packet's IPv6 header - * \param port the incoming port + * \param port the remote port * \param incomingInterface the incoming interface */ void ForwardUp6 (Ptr packet, Ipv6Header header, uint16_t port, Ptr incomingInterface); @@ -157,6 +159,11 @@ void Destroy6 (void); /** + * \brief Deallocate m_endPoint and m_endPoint6 + */ + void DeallocateEndPoint (void); + + /** * \brief Send a packet * \param p packet * \returns 0 on success, -1 on failure diff -Naur ns-3.19/src/internet/test/error-channel.cc ns-3.20/src/internet/test/error-channel.cc --- ns-3.19/src/internet/test/error-channel.cc 2014-06-17 10:34:00.550635797 -0700 +++ ns-3.20/src/internet/test/error-channel.cc 2014-06-17 10:33:13.874996108 -0700 @@ -28,8 +28,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED (ErrorChannel) - ; +NS_OBJECT_ENSURE_REGISTERED (ErrorChannel); TypeId ErrorChannel::GetTypeId (void) @@ -105,8 +104,7 @@ return m_devices[i]; } -NS_OBJECT_ENSURE_REGISTERED (BinaryErrorModel) - ; +NS_OBJECT_ENSURE_REGISTERED (BinaryErrorModel); TypeId BinaryErrorModel::GetTypeId (void) { diff -Naur ns-3.19/src/internet/test/ipv4-fragmentation-test.cc ns-3.20/src/internet/test/ipv4-fragmentation-test.cc --- ns-3.19/src/internet/test/ipv4-fragmentation-test.cc 2014-06-17 10:34:00.553635774 -0700 +++ ns-3.20/src/internet/test/ipv4-fragmentation-test.cc 2014-06-17 10:33:13.876996093 -0700 @@ -54,6 +54,26 @@ class UdpSocketImpl; +/* ---------------------------------------------------------------------------------- + * Tag + --------------------------------------------------------------------------------- */ +class IPv4TestTag : public Tag { +private: + uint64_t token; +public: + static TypeId GetTypeId () { + static TypeId tid = TypeId ("ns3::IPv4TestTag").SetParent ().AddConstructor (); + return tid; + } + virtual TypeId GetInstanceTypeId () const { return GetTypeId (); } + virtual uint32_t GetSerializedSize () const { return sizeof (token); } + virtual void Serialize (TagBuffer buffer) const { buffer.WriteU64 (token); } + virtual void Deserialize (TagBuffer buffer) { token = buffer.ReadU64 (); } + virtual void Print (std::ostream &os) const { os << "token=" << token; } + void setToken (uint64_t token) { this->token = token; } + uint64_t getToken () { return token; } +}; + static void AddInternetStack (Ptr node) { @@ -161,9 +181,6 @@ { if (InetSocketAddress::IsMatchingType (from)) { - packet->RemoveAllPacketTags (); - packet->RemoveAllByteTags (); - m_receivedPacketServer = packet->Copy(); } } @@ -247,6 +264,11 @@ { p = Create (m_size); } + IPv4TestTag tag; + tag.setToken (42); + p->AddPacketTag (tag); + p->AddByteTag (tag); + m_socketClient->Send (p); return p; @@ -398,6 +420,56 @@ NS_TEST_EXPECT_MSG_EQ ((m_icmpType == 11), true, "Client did not receive ICMP::TIME_EXCEEDED"); } + // Fourth test: normal channel, no errors, no delays. + // We check tags + clientDevErrorModel->Disable (); + serverDevErrorModel->Disable (); + for (int i= 0; i<5; i++) + { + uint32_t packetSize = packetSizes[i]; + + SetFill (fillData, 78, packetSize); + + m_receivedPacketServer = Create (); + Simulator::ScheduleWithContext (m_socketClient->GetNode ()->GetId (), Seconds (0), + &Ipv4FragmentationTest::SendClient, this); + Simulator::Run (); + + IPv4TestTag packetTag; + bool found = m_receivedPacketServer->PeekPacketTag (packetTag); + + NS_TEST_EXPECT_MSG_EQ (found, true, "PacketTag not found"); + NS_TEST_EXPECT_MSG_EQ (packetTag.getToken (), 42, "PacketTag value not correct"); + + ByteTagIterator iter = m_receivedPacketServer->GetByteTagIterator (); + + uint32_t end = 0; + uint32_t tagStart = 0; + uint32_t tagEnd = 0; + while (iter.HasNext ()) + { + ByteTagIterator::Item item = iter.Next (); + NS_TEST_EXPECT_MSG_EQ (item.GetTypeId ().GetName (), "ns3::IPv4TestTag", "ByteTag name not correct"); + tagStart = item.GetStart (); + tagEnd = item.GetEnd (); + if (end == 0) + { + NS_TEST_EXPECT_MSG_EQ (tagStart, 0, "First ByteTag Start not correct"); + } + if (end != 0) + { + NS_TEST_EXPECT_MSG_EQ (tagStart, end, "ByteTag End not correct"); + } + end = tagEnd; + IPv4TestTag *byteTag = dynamic_cast (item.GetTypeId ().GetConstructor () ()); + NS_TEST_EXPECT_MSG_NE (byteTag, 0, "ByteTag not found"); + item.GetTag (*byteTag); + NS_TEST_EXPECT_MSG_EQ (byteTag->getToken (), 42, "ByteTag value not correct"); + delete byteTag; + } + NS_TEST_EXPECT_MSG_EQ (end, m_receivedPacketServer->GetSize (), "trivial"); + } + Simulator::Destroy (); } diff -Naur ns-3.19/src/internet/test/ipv4-test.cc ns-3.20/src/internet/test/ipv4-test.cc --- ns-3.19/src/internet/test/ipv4-test.cc 2014-06-17 10:34:00.554635766 -0700 +++ ns-3.20/src/internet/test/ipv4-test.cc 2014-06-17 10:33:13.878996077 -0700 @@ -30,7 +30,7 @@ #include "ns3/ipv4-interface.h" #include "ns3/loopback-net-device.h" -namespace ns3 { +using namespace ns3; class Ipv4L3ProtocolTestCase : public TestCase { @@ -150,5 +150,3 @@ AddTestCase (new Ipv4L3ProtocolTestCase (), TestCase::QUICK); } } g_ipv4protocolTestSuite; - -} // namespace ns3 diff -Naur ns-3.19/src/internet/test/ipv6-fragmentation-test.cc ns-3.20/src/internet/test/ipv6-fragmentation-test.cc --- ns-3.19/src/internet/test/ipv6-fragmentation-test.cc 2014-06-17 10:34:00.557635743 -0700 +++ ns-3.20/src/internet/test/ipv6-fragmentation-test.cc 2014-06-17 10:33:13.881996054 -0700 @@ -18,9 +18,10 @@ * Author: Tommaso Pecorella */ /** + * \file + * * This is the test code for ipv6-l3protocol.cc (only the fragmentation and reassembly part). */ -#define NS3_LOG_ENABLE 1 #include "ns3/test.h" #include "ns3/config.h" @@ -63,6 +64,26 @@ class UdpSocketImpl; +/* ---------------------------------------------------------------------------------- + * Tag + --------------------------------------------------------------------------------- */ +class IPv6TestTag : public Tag { +private: + uint64_t token; +public: + static TypeId GetTypeId () { + static TypeId tid = TypeId ("ns3::IPv6TestTag").SetParent ().AddConstructor (); + return tid; + } + virtual TypeId GetInstanceTypeId () const { return GetTypeId (); } + virtual uint32_t GetSerializedSize () const { return sizeof (token); } + virtual void Serialize (TagBuffer buffer) const { buffer.WriteU64 (token); } + virtual void Deserialize (TagBuffer buffer) { token = buffer.ReadU64 (); } + virtual void Print (std::ostream &os) const { os << "token=" << token; } + void setToken (uint64_t token) { this->token = token; } + uint64_t getToken () { return token; } +}; + static void AddInternetStack (Ptr node) { @@ -170,9 +191,6 @@ { if (Inet6SocketAddress::IsMatchingType (from)) { - packet->RemoveAllPacketTags (); - packet->RemoveAllByteTags (); - m_receivedPacketServer = packet->Copy (); } } @@ -257,6 +275,11 @@ { p = Create (m_size); } + IPv6TestTag tag; + tag.setToken (42); + p->AddPacketTag (tag); + p->AddByteTag (tag); + m_socketClient->Send (p); return p; @@ -409,6 +432,55 @@ true, "Client did not receive ICMPv6::TIME_EXCEEDED " << int(m_icmpType) << int(m_icmpCode) ); } + // Fourth test: normal channel, no errors, no delays. + // We check tags + clientDevErrorModel->Disable (); + serverDevErrorModel->Disable (); + for (int i= 0; i<5; i++) + { + uint32_t packetSize = packetSizes[i]; + + SetFill (fillData, 78, packetSize); + + m_receivedPacketServer = Create (); + Simulator::ScheduleWithContext (m_socketClient->GetNode ()->GetId (), Seconds (0), + &Ipv6FragmentationTest::SendClient, this); + Simulator::Run (); + + IPv6TestTag packetTag; + bool found = m_receivedPacketServer->PeekPacketTag (packetTag); + + NS_TEST_EXPECT_MSG_EQ (found, true, "PacketTag not found"); + NS_TEST_EXPECT_MSG_EQ (packetTag.getToken (), 42, "PacketTag value not correct"); + + ByteTagIterator iter = m_receivedPacketServer->GetByteTagIterator (); + + uint32_t end = 0; + uint32_t tagStart = 0; + uint32_t tagEnd = 0; + while (iter.HasNext ()) + { + ByteTagIterator::Item item = iter.Next (); + NS_TEST_EXPECT_MSG_EQ (item.GetTypeId ().GetName (), "ns3::IPv6TestTag", "ByteTag name not correct"); + tagStart = item.GetStart (); + tagEnd = item.GetEnd (); + if (end == 0) + { + NS_TEST_EXPECT_MSG_EQ (tagStart, 0, "First ByteTag Start not correct"); + } + if (end != 0) + { + NS_TEST_EXPECT_MSG_EQ (tagStart, end, "ByteTag End not correct"); + } + end = tagEnd; + IPv6TestTag *byteTag = dynamic_cast (item.GetTypeId ().GetConstructor () ()); + NS_TEST_EXPECT_MSG_NE (byteTag, 0, "ByteTag not found"); + item.GetTag (*byteTag); + NS_TEST_EXPECT_MSG_EQ (byteTag->getToken (), 42, "ByteTag value not correct"); + delete byteTag; + } + NS_TEST_EXPECT_MSG_EQ (end, m_receivedPacketServer->GetSize (), "trivial"); + } Simulator::Destroy (); } diff -Naur ns-3.19/src/internet/test/ipv6-ripng-test.cc ns-3.20/src/internet/test/ipv6-ripng-test.cc --- ns-3.19/src/internet/test/ipv6-ripng-test.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/internet/test/ipv6-ripng-test.cc 2014-06-17 10:33:13.882996046 -0700 @@ -0,0 +1,652 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2014 Universita' di Firenze + * + * 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: Tommaso Pecorella + */ + +#include "ns3/test.h" +#include "ns3/socket-factory.h" +#include "ns3/udp-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/boolean.h" +#include "ns3/enum.h" + +#include "ns3/log.h" +#include "ns3/node.h" +#include "ns3/inet6-socket-address.h" + +#include "ns3/internet-stack-helper.h" +#include "ns3/ipv6-address-helper.h" +#include "ns3/ipv6-l3-protocol.h" +#include "ns3/icmpv6-l4-protocol.h" +#include "ns3/udp-l4-protocol.h" +#include "ns3/ipv6-static-routing.h" +#include "ns3/ipv6-list-routing.h" +#include "ns3/ipv6-list-routing-helper.h" +#include "ns3/ripng.h" +#include "ns3/ripng-helper.h" +#include "ns3/node-container.h" + +#include +#include + +using namespace ns3; + +// Ipv6RipngTest + +class Ipv6RipngTest : public TestCase +{ + Ptr m_receivedPacket; + void DoSendData (Ptr socket, std::string to); + void SendData (Ptr socket, std::string to); + +public: + virtual void DoRun (void); + Ipv6RipngTest (); + + void ReceivePkt (Ptr socket); +}; + +Ipv6RipngTest::Ipv6RipngTest () + : TestCase ("RIPng") +{ +} + +void Ipv6RipngTest::ReceivePkt (Ptr socket) +{ + uint32_t availableData; + availableData = socket->GetRxAvailable (); + m_receivedPacket = socket->Recv (std::numeric_limits::max (), 0); + NS_ASSERT (availableData == m_receivedPacket->GetSize ()); + //cast availableData to void, to suppress 'availableData' set but not used + //compiler warning + (void) availableData; +} + +void +Ipv6RipngTest::DoSendData (Ptr socket, std::string to) +{ + Address realTo = Inet6SocketAddress (Ipv6Address (to.c_str ()), 1234); + NS_TEST_EXPECT_MSG_EQ (socket->SendTo (Create (123), 0, realTo), + 123, "100"); +} + +void +Ipv6RipngTest::SendData (Ptr socket, std::string to) +{ + m_receivedPacket = Create (); + Simulator::ScheduleWithContext (socket->GetNode ()->GetId (), Seconds (60), + &Ipv6RipngTest::DoSendData, this, socket, to); + Simulator::Stop (Seconds (66)); + Simulator::Run (); +} + +void +Ipv6RipngTest::DoRun (void) +{ + // Create topology + + Ptr txNode = CreateObject (); + Ptr rxNode = CreateObject (); + Ptr routerA = CreateObject (); + Ptr routerB = CreateObject (); + Ptr routerC = CreateObject (); + + NodeContainer nodes (txNode, rxNode); + NodeContainer routers (routerA, routerB, routerC); + NodeContainer all (nodes, routers); + + RipNgHelper ripNgRouting; + Ipv6ListRoutingHelper listRH; + listRH.Add (ripNgRouting, 0); + InternetStackHelper internetv6routers; + internetv6routers.SetRoutingHelper (listRH); + internetv6routers.Install (routers); + + InternetStackHelper internetv6nodes; + internetv6nodes.Install (nodes); + + NetDeviceContainer net1; + NetDeviceContainer net2; + NetDeviceContainer net3; + NetDeviceContainer net4; + + // Sender Node + Ptr txDev; + { + txDev = CreateObject (); + txDev->SetAddress (Mac48Address ("00:00:00:00:00:01")); + txNode->AddDevice (txDev); + } + net1.Add (txDev); + + // Router A + Ptr fwDev1routerA, fwDev2routerA; + { // first interface + fwDev1routerA = CreateObject (); + fwDev1routerA->SetAddress (Mac48Address ("00:00:00:00:00:02")); + routerA->AddDevice (fwDev1routerA); + } + net1.Add (fwDev1routerA); + + { // second interface + fwDev2routerA = CreateObject (); + fwDev2routerA->SetAddress (Mac48Address ("00:00:00:00:00:03")); + routerA->AddDevice (fwDev2routerA); + } + net2.Add (fwDev2routerA); + + // Router B + Ptr fwDev1routerB, fwDev2routerB; + { // first interface + fwDev1routerB = CreateObject (); + fwDev1routerB->SetAddress (Mac48Address ("00:00:00:00:00:04")); + routerB->AddDevice (fwDev1routerB); + } + net2.Add (fwDev1routerB); + + { // second interface + fwDev2routerB = CreateObject (); + fwDev2routerB->SetAddress (Mac48Address ("00:00:00:00:00:05")); + routerB->AddDevice (fwDev2routerB); + } + net3.Add (fwDev2routerB); + + // Router C + Ptr fwDev1routerC, fwDev2routerC; + { // first interface + fwDev1routerC = CreateObject (); + fwDev1routerC->SetAddress (Mac48Address ("00:00:00:00:00:06")); + routerC->AddDevice (fwDev1routerC); + } + net3.Add (fwDev1routerC); + + { // second interface + fwDev2routerC = CreateObject (); + fwDev2routerC->SetAddress (Mac48Address ("00:00:00:00:00:07")); + routerC->AddDevice (fwDev2routerC); + } + net4.Add (fwDev2routerC); + + // Rx node + Ptr rxDev; + { // first interface + rxDev = CreateObject (); + rxDev->SetAddress (Mac48Address ("00:00:00:00:00:08")); + rxNode->AddDevice (rxDev); + } + net4.Add (rxDev); + + // link the channels + Ptr channel1 = CreateObject (); + txDev->SetChannel (channel1); + fwDev1routerA->SetChannel (channel1); + + Ptr channel2 = CreateObject (); + fwDev2routerA->SetChannel (channel2); + fwDev1routerB->SetChannel (channel2); + + Ptr channel3 = CreateObject (); + fwDev2routerB->SetChannel (channel3); + fwDev1routerC->SetChannel (channel3); + + Ptr channel4 = CreateObject (); + fwDev2routerC->SetChannel (channel4); + rxDev->SetChannel (channel4); + + // Setup IPv6 addresses and forwarding + Ipv6AddressHelper ipv6; + + ipv6.SetBase (Ipv6Address ("2001:1::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic1 = ipv6.Assign (net1); + iic1.SetForwarding (1, true); + iic1.SetDefaultRouteInAllNodes (1); + + Ipv6InterfaceContainer iic2 = ipv6.AssignWithoutAddress (net2); + iic2.SetForwarding (0, true); + iic2.SetForwarding (1, true); + + Ipv6InterfaceContainer iic3 = ipv6.AssignWithoutAddress (net3); + iic3.SetForwarding (0, true); + iic3.SetForwarding (1, true); + + ipv6.SetBase (Ipv6Address ("2001:2::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic4 = ipv6.Assign (net4); + iic4.SetForwarding (0, true); + iic4.SetDefaultRouteInAllNodes (0); + + // Create the UDP sockets + Ptr rxSocketFactory = rxNode->GetObject (); + Ptr rxSocket = rxSocketFactory->CreateSocket (); + NS_TEST_EXPECT_MSG_EQ (rxSocket->Bind (Inet6SocketAddress (Ipv6Address ("2001:2::200:ff:fe00:8"), 1234)), 0, "trivial"); + rxSocket->SetRecvCallback (MakeCallback (&Ipv6RipngTest::ReceivePkt, this)); + + Ptr txSocketFactory = txNode->GetObject (); + Ptr txSocket = txSocketFactory->CreateSocket (); + txSocket->SetAllowBroadcast (true); + + // ------ Now the tests ------------ + + // Unicast test + SendData (txSocket, "2001:2::200:ff:fe00:8"); + NS_TEST_EXPECT_MSG_EQ (m_receivedPacket->GetSize (), 123, "IPv6 RIPng should work."); + + m_receivedPacket->RemoveAllByteTags (); + + Simulator::Destroy (); +} + +// Ipv6RipngCountToInfinityTest + +class Ipv6RipngCountToInfinityTest : public TestCase +{ + Ptr m_receivedPacket; + void DoSendData (Ptr socket, std::string to); + void SendData (Ptr socket, std::string to); + +public: + virtual void DoRun (void); + Ipv6RipngCountToInfinityTest (); + + void ReceivePkt (Ptr socket); +}; + +Ipv6RipngCountToInfinityTest::Ipv6RipngCountToInfinityTest () + : TestCase ("RIPng counting to infinity") +{ +} + +void Ipv6RipngCountToInfinityTest::ReceivePkt (Ptr socket) +{ + uint32_t availableData; + availableData = socket->GetRxAvailable (); + m_receivedPacket = socket->Recv (std::numeric_limits::max (), 0); + NS_ASSERT (availableData == m_receivedPacket->GetSize ()); + //cast availableData to void, to suppress 'availableData' set but not used + //compiler warning + (void) availableData; +} + +void +Ipv6RipngCountToInfinityTest::DoSendData (Ptr socket, std::string to) +{ + Address realTo = Inet6SocketAddress (Ipv6Address (to.c_str ()), 1234); + NS_TEST_EXPECT_MSG_EQ (socket->SendTo (Create (123), 0, realTo), + 123, "100"); +} + +void +Ipv6RipngCountToInfinityTest::SendData (Ptr socket, std::string to) +{ + m_receivedPacket = Create (); + Simulator::ScheduleWithContext (socket->GetNode ()->GetId (), Seconds (60), + &Ipv6RipngCountToInfinityTest::DoSendData, this, socket, to); + Simulator::Stop (Seconds (66)); + Simulator::Run (); +} + +void +Ipv6RipngCountToInfinityTest::DoRun (void) +{ + // Create topology + + Ptr txNode = CreateObject (); + Ptr rxNode = CreateObject (); + Ptr routerA = CreateObject (); + Ptr routerB = CreateObject (); + Ptr routerC = CreateObject (); + + NodeContainer nodes (txNode, rxNode); + NodeContainer routers (routerA, routerB, routerC); + NodeContainer all (nodes, routers); + + RipNgHelper ripNgRouting; + // Change the router's interface metric to 10, must not send packets (count to infinity) + // note: Interface 0 is the loopback. + ripNgRouting.SetInterfaceMetric (routerA, 2, 10); + ripNgRouting.SetInterfaceMetric (routerB, 1, 10); + ripNgRouting.SetInterfaceMetric (routerB, 2, 10); + ripNgRouting.SetInterfaceMetric (routerC, 1, 10); + + Ipv6ListRoutingHelper listRH; + listRH.Add (ripNgRouting, 0); + InternetStackHelper internetv6routers; + internetv6routers.SetRoutingHelper (listRH); + internetv6routers.Install (routers); + + InternetStackHelper internetv6nodes; + internetv6nodes.Install (nodes); + + NetDeviceContainer net1; + NetDeviceContainer net2; + NetDeviceContainer net3; + NetDeviceContainer net4; + + // Sender Node + Ptr txDev; + { + txDev = CreateObject (); + txDev->SetAddress (Mac48Address ("00:00:00:00:00:01")); + txNode->AddDevice (txDev); + } + net1.Add (txDev); + + // Router A + Ptr fwDev1routerA, fwDev2routerA; + { // first interface + fwDev1routerA = CreateObject (); + fwDev1routerA->SetAddress (Mac48Address ("00:00:00:00:00:02")); + routerA->AddDevice (fwDev1routerA); + } + net1.Add (fwDev1routerA); + + { // second interface + fwDev2routerA = CreateObject (); + fwDev2routerA->SetAddress (Mac48Address ("00:00:00:00:00:03")); + routerA->AddDevice (fwDev2routerA); + } + net2.Add (fwDev2routerA); + + // Router B + Ptr fwDev1routerB, fwDev2routerB; + { // first interface + fwDev1routerB = CreateObject (); + fwDev1routerB->SetAddress (Mac48Address ("00:00:00:00:00:04")); + routerB->AddDevice (fwDev1routerB); + } + net2.Add (fwDev1routerB); + + { // second interface + fwDev2routerB = CreateObject (); + fwDev2routerB->SetAddress (Mac48Address ("00:00:00:00:00:05")); + routerB->AddDevice (fwDev2routerB); + } + net3.Add (fwDev2routerB); + + // Router C + Ptr fwDev1routerC, fwDev2routerC; + { // first interface + fwDev1routerC = CreateObject (); + fwDev1routerC->SetAddress (Mac48Address ("00:00:00:00:00:06")); + routerC->AddDevice (fwDev1routerC); + } + net3.Add (fwDev1routerC); + + { // second interface + fwDev2routerC = CreateObject (); + fwDev2routerC->SetAddress (Mac48Address ("00:00:00:00:00:07")); + routerC->AddDevice (fwDev2routerC); + } + net4.Add (fwDev2routerC); + + // Rx node + Ptr rxDev; + { // first interface + rxDev = CreateObject (); + rxDev->SetAddress (Mac48Address ("00:00:00:00:00:08")); + rxNode->AddDevice (rxDev); + } + net4.Add (rxDev); + + // link the channels + Ptr channel1 = CreateObject (); + txDev->SetChannel (channel1); + fwDev1routerA->SetChannel (channel1); + + Ptr channel2 = CreateObject (); + fwDev2routerA->SetChannel (channel2); + fwDev1routerB->SetChannel (channel2); + + Ptr channel3 = CreateObject (); + fwDev2routerB->SetChannel (channel3); + fwDev1routerC->SetChannel (channel3); + + Ptr channel4 = CreateObject (); + fwDev2routerC->SetChannel (channel4); + rxDev->SetChannel (channel4); + + // Setup IPv6 addresses and forwarding + Ipv6AddressHelper ipv6; + + ipv6.SetBase (Ipv6Address ("2001:1::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic1 = ipv6.Assign (net1); + iic1.SetForwarding (1, true); + iic1.SetDefaultRouteInAllNodes (1); + + Ipv6InterfaceContainer iic2 = ipv6.AssignWithoutAddress (net2); + iic2.SetForwarding (0, true); + iic2.SetForwarding (1, true); + + Ipv6InterfaceContainer iic3 = ipv6.AssignWithoutAddress (net3); + iic3.SetForwarding (0, true); + iic3.SetForwarding (1, true); + + ipv6.SetBase (Ipv6Address ("2001:2::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic4 = ipv6.Assign (net4); + iic4.SetForwarding (0, true); + iic4.SetDefaultRouteInAllNodes (0); + + // Create the UDP sockets + Ptr rxSocketFactory = rxNode->GetObject (); + Ptr rxSocket = rxSocketFactory->CreateSocket (); + NS_TEST_EXPECT_MSG_EQ (rxSocket->Bind (Inet6SocketAddress (Ipv6Address ("2001:2::200:ff:fe00:8"), 1234)), 0, "trivial"); + rxSocket->SetRecvCallback (MakeCallback (&Ipv6RipngCountToInfinityTest::ReceivePkt, this)); + + Ptr txSocketFactory = txNode->GetObject (); + Ptr txSocket = txSocketFactory->CreateSocket (); + txSocket->SetAllowBroadcast (true); + + // ------ Now the tests ------------ + + SendData (txSocket, "2001:2::200:ff:fe00:8"); + NS_TEST_EXPECT_MSG_EQ (m_receivedPacket->GetSize (), 0, "RIPng counting to infinity."); + + Simulator::Destroy (); +} + +// Ipv6RipngSplitHorizonStrategyTest + +class Ipv6RipngSplitHorizonStrategyTest : public TestCase +{ + RipNg::SplitHorizonType_e m_setStrategy; + RipNg::SplitHorizonType_e m_detectedStrategy; + +public: + virtual void DoRun (void); + Ipv6RipngSplitHorizonStrategyTest (RipNg::SplitHorizonType_e strategy); + + void ReceivePktProbe (Ptr socket); +}; + +Ipv6RipngSplitHorizonStrategyTest::Ipv6RipngSplitHorizonStrategyTest (RipNg::SplitHorizonType_e strategy) + : TestCase ("RIPng Split Horizon strategy") +{ + m_setStrategy = strategy; +} + +void Ipv6RipngSplitHorizonStrategyTest::ReceivePktProbe (Ptr socket) +{ + uint32_t availableData; + availableData = socket->GetRxAvailable (); + Ptr receivedPacketProbe = socket->Recv (std::numeric_limits::max (), 0); + NS_ASSERT (availableData == receivedPacketProbe->GetSize ()); + SocketAddressTag tag; + receivedPacketProbe->RemovePacketTag (tag); + Ipv6Address senderAddress = Inet6SocketAddress::ConvertFrom (tag.GetAddress ()).GetIpv6 (); + + if (senderAddress == "fe80::200:ff:fe00:4") + { + RipNgHeader hdr; + receivedPacketProbe->RemoveHeader (hdr); + std::list rtes = hdr.GetRteList (); + + // validate the RTEs before processing + for (std::list::iterator iter = rtes.begin (); + iter != rtes.end (); iter++) + { + if (iter->GetPrefix () == "2001:1::") + { + bool correct = false; + if (iter->GetRouteMetric () == 16) + { + correct = true; + m_detectedStrategy = RipNg::POISON_REVERSE; + } + else if (iter->GetRouteMetric () == 2) + { + correct = true; + m_detectedStrategy = RipNg::NO_SPLIT_HORIZON; + } + NS_TEST_EXPECT_MSG_EQ (correct, true, "RIPng: unexpected metric value: " << iter->GetRouteMetric ()); + } + } + } + + //cast availableData to void, to suppress 'availableData' set but not used + //compiler warning + (void) availableData; +} + +void +Ipv6RipngSplitHorizonStrategyTest::DoRun (void) +{ + // Create topology + + Ptr fakeNode = CreateObject (); + Ptr listener = CreateObject (); + + Ptr routerA = CreateObject (); + Ptr routerB = CreateObject (); + + NodeContainer listeners (listener, fakeNode); + NodeContainer routers (routerA, routerB); + NodeContainer all (routers, listeners); + + RipNgHelper ripNgRouting; + ripNgRouting.Set ("SplitHorizon", EnumValue (m_setStrategy)); + + Ipv6ListRoutingHelper listRH; + listRH.Add (ripNgRouting, 0); + InternetStackHelper internetv6routers; + internetv6routers.SetRoutingHelper (listRH); + internetv6routers.Install (routers); + + InternetStackHelper internetv6nodes; + internetv6nodes.Install (listeners); + + NetDeviceContainer net0; + NetDeviceContainer net1; + + // Fake Node + Ptr silentDev; + { + silentDev = CreateObject (); + silentDev->SetAddress (Mac48Address ("00:00:00:00:00:01")); + fakeNode->AddDevice (silentDev); + } + net0.Add (silentDev); + + // Router A + Ptr silentDevRouterA, fwDevRouterA; + { // silent interface + silentDevRouterA = CreateObject (); + silentDevRouterA->SetAddress (Mac48Address ("00:00:00:00:00:02")); + routerA->AddDevice (silentDevRouterA); + } + net0.Add (silentDevRouterA); + + { // first interface + fwDevRouterA = CreateObject (); + fwDevRouterA->SetAddress (Mac48Address ("00:00:00:00:00:03")); + routerA->AddDevice (fwDevRouterA); + } + net1.Add (fwDevRouterA); + + // Router B + Ptr fwDevRouterB; + { // first interface + fwDevRouterB = CreateObject (); + fwDevRouterB->SetAddress (Mac48Address ("00:00:00:00:00:04")); + routerB->AddDevice (fwDevRouterB); + } + net1.Add (fwDevRouterB); + + // listener A + Ptr listenerDev; + { + listenerDev = CreateObject (); + listenerDev->SetAddress (Mac48Address ("00:00:00:00:00:05")); + listener->AddDevice (listenerDev); + } + net1.Add (listenerDev); + + // link the channels + Ptr channel0 = CreateObject (); + silentDev->SetChannel (channel0); + silentDevRouterA->SetChannel (channel0); + + Ptr channel1 = CreateObject (); + fwDevRouterA->SetChannel (channel1); + fwDevRouterB->SetChannel (channel1); + listenerDev->SetChannel (channel1); + + // Setup IPv6 addresses and forwarding + Ipv6AddressHelper ipv6; + + ipv6.SetBase (Ipv6Address ("2001:1::"), Ipv6Prefix (64)); + Ipv6InterfaceContainer iic0 = ipv6.Assign (net0); + + Ipv6InterfaceContainer iic1 = ipv6.AssignWithoutAddress (net1); + iic1.SetForwarding (0, true); + iic1.SetForwarding (1, true); + + // Create the UDP sockets + Ptr rxSocketFactory = listener->GetObject (); + Ptr rxSocket = rxSocketFactory->CreateSocket (); + NS_TEST_EXPECT_MSG_EQ (rxSocket->Bind (Inet6SocketAddress (Ipv6Address ("ff02::9"), 521)), 0, "trivial"); + rxSocket->SetRecvCallback (MakeCallback (&Ipv6RipngSplitHorizonStrategyTest::ReceivePktProbe, this)); + + // ------ Now the tests ------------ + + // If the strategy is Split Horizon, then no packet will be received. + m_detectedStrategy = RipNg::SPLIT_HORIZON; + + Simulator::Stop (Seconds (66)); + Simulator::Run (); + NS_TEST_EXPECT_MSG_EQ (m_detectedStrategy, m_setStrategy, "RIPng counting to infinity."); + + Simulator::Destroy (); +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +class Ipv6RipngTestSuite : public TestSuite +{ +public: + Ipv6RipngTestSuite () : TestSuite ("ipv6-ripng", UNIT) + { + AddTestCase (new Ipv6RipngTest, TestCase::QUICK); + AddTestCase (new Ipv6RipngCountToInfinityTest, TestCase::QUICK); + AddTestCase (new Ipv6RipngSplitHorizonStrategyTest (RipNg::POISON_REVERSE), TestCase::QUICK); + AddTestCase (new Ipv6RipngSplitHorizonStrategyTest (RipNg::SPLIT_HORIZON), TestCase::QUICK); + AddTestCase (new Ipv6RipngSplitHorizonStrategyTest (RipNg::NO_SPLIT_HORIZON), TestCase::QUICK); + } +} g_ipv6ripngTestSuite; diff -Naur ns-3.19/src/internet/test/ipv6-test.cc ns-3.20/src/internet/test/ipv6-test.cc --- ns-3.19/src/internet/test/ipv6-test.cc 2014-06-17 10:34:00.558635735 -0700 +++ ns-3.20/src/internet/test/ipv6-test.cc 2014-06-17 10:33:13.883996039 -0700 @@ -30,7 +30,7 @@ #include "ns3/ipv6-l3-protocol.h" #include "ns3/icmpv6-l4-protocol.h" -namespace ns3 { +using namespace ns3; class Ipv6L3ProtocolTestCase : public TestCase { @@ -189,5 +189,3 @@ AddTestCase (new Ipv6L3ProtocolTestCase (), TestCase::QUICK); } } g_ipv6protocolTestSuite; - -} // namespace ns3 diff -Naur ns-3.19/src/internet/test/tcp-test.cc ns-3.20/src/internet/test/tcp-test.cc --- ns-3.19/src/internet/test/tcp-test.cc 2014-06-17 10:34:00.559635727 -0700 +++ ns-3.20/src/internet/test/tcp-test.cc 2014-06-17 10:33:13.883996039 -0700 @@ -108,14 +108,12 @@ return oss.str (); } -#ifdef NS3_LOG_ENABLE -static std::string GetString (Ptr p) +static inline std::string GetString (Ptr p) { std::ostringstream oss; p->CopyData (&oss, p->GetSize ()); return oss.str (); } -#endif /* NS3_LOG_ENABLE */ TcpTestCase::TcpTestCase (uint32_t totalStreamSize, uint32_t sourceWriteSize, diff -Naur ns-3.19/src/internet/waf ns-3.20/src/internet/waf --- ns-3.19/src/internet/waf 2014-06-17 10:34:00.560635719 -0700 +++ ns-3.20/src/internet/waf 1969-12-31 16:00:00.000000000 -0800 @@ -1 +0,0 @@ -exec "`dirname "$0"`"/../../waf "$@" \ No newline at end of file diff -Naur ns-3.19/src/internet/wscript ns-3.20/src/internet/wscript --- ns-3.19/src/internet/wscript 2014-06-17 10:34:00.561635712 -0700 +++ ns-3.20/src/internet/wscript 2014-06-17 10:33:13.885996023 -0700 @@ -192,6 +192,9 @@ 'model/ipv4-packet-probe.cc', 'model/ipv6-packet-probe.cc', 'model/ipv6-pmtu-cache.cc', + 'model/ripng.cc', + 'model/ripng-header.cc', + 'helper/ripng-helper.cc', ] internet_test = bld.create_ns3_module_test_library('internet') @@ -218,7 +221,8 @@ 'test/ipv6-dual-stack-test-suite.cc', 'test/ipv6-fragmentation-test.cc', 'test/ipv6-forwarding-test.cc', - 'test/ipv6-address-helper-test-suite.cc', + 'test/ipv6-ripng-test.cc', + 'test/ipv6-address-helper-test-suite.cc', 'test/rtt-test.cc', ] headers = bld(features='ns3header') @@ -305,6 +309,9 @@ 'model/ipv4-packet-probe.h', 'model/ipv6-packet-probe.h', 'model/ipv6-pmtu-cache.h', + 'model/ripng.h', + 'model/ripng-header.h', + 'helper/ripng-helper.h', ] if bld.env['NSC_ENABLED']: diff -Naur ns-3.19/src/lr-wpan/bindings/callbacks_list.py ns-3.20/src/lr-wpan/bindings/callbacks_list.py --- ns-3.19/src/lr-wpan/bindings/callbacks_list.py 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/bindings/callbacks_list.py 2014-06-17 10:33:13.885996023 -0700 @@ -0,0 +1,12 @@ +callback_classes = [ + ['void', 'ns3::LrWpanPhyEnumeration', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'ns3::LrWpanPhyEnumeration', 'unsigned char', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'unsigned int', 'ns3::Ptr', 'unsigned char', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'ns3::LrWpanMacState', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'ns3::LrWpanPhyEnumeration', 'ns3::LrWpanPibAttributeIdentifier', 'ns3::LrWpanPhyPibAttributes*', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'ns3::McpsDataIndicationParams', 'ns3::Ptr', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'ns3::McpsDataConfirmParams', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'ns3::LrWpanPhyEnumeration', 'ns3::LrWpanPibAttributeIdentifier', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['bool', 'ns3::Ptr', 'ns3::Ptr', 'unsigned short', 'ns3::Address const&', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty', 'ns3::empty'], + ['void', 'ns3::Ptr', 'ns3::Ptr', 'unsigned short', 'ns3::Address const&', 'ns3::Address const&', 'ns3::NetDevice::PacketType', 'ns3::empty', 'ns3::empty', 'ns3::empty'], +] diff -Naur ns-3.19/src/lr-wpan/bindings/modulegen__gcc_ILP32.py ns-3.20/src/lr-wpan/bindings/modulegen__gcc_ILP32.py --- ns-3.19/src/lr-wpan/bindings/modulegen__gcc_ILP32.py 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/bindings/modulegen__gcc_ILP32.py 2014-06-17 10:33:13.888996000 -0700 @@ -0,0 +1,5861 @@ +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.lr_wpan', cpp_namespace='::ns3') + return root_module + +def register_types(module): + root_module = module.get_root() + + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyOption [enumeration] + module.add_enum('LrWpanPhyOption', ['IEEE_802_15_4_868MHZ_BPSK', 'IEEE_802_15_4_915MHZ_BPSK', 'IEEE_802_15_4_868MHZ_ASK', 'IEEE_802_15_4_915MHZ_ASK', 'IEEE_802_15_4_868MHZ_OQPSK', 'IEEE_802_15_4_915MHZ_OQPSK', 'IEEE_802_15_4_2_4GHZ_OQPSK', 'IEEE_802_15_4_INVALID_PHY_OPTION']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanTxOption [enumeration] + module.add_enum('LrWpanTxOption', ['TX_OPTION_NONE', 'TX_OPTION_ACK', 'TX_OPTION_GTS', 'TX_OPTION_INDIRECT']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMcpsDataConfirmStatus [enumeration] + module.add_enum('LrWpanMcpsDataConfirmStatus', ['IEEE_802_15_4_SUCCESS', 'IEEE_802_15_4_TRANSACTION_OVERFLOW', 'IEEE_802_15_4_TRANSACTION_EXPIRED', 'IEEE_802_15_4_CHANNEL_ACCESS_FAILURE', 'IEEE_802_15_4_INVALID_ADDRESS', 'IEEE_802_15_4_INVALID_GTS', 'IEEE_802_15_4_NO_ACK', 'IEEE_802_15_4_COUNTER_ERROR', 'IEEE_802_15_4_FRAME_TOO_LONG', 'IEEE_802_15_4_UNAVAILABLE_KEY', 'IEEE_802_15_4_UNSUPPORTED_SECURITY', 'IEEE_802_15_4_INVALID_PARAMETER']) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyEnumeration [enumeration] + module.add_enum('LrWpanPhyEnumeration', ['IEEE_802_15_4_PHY_BUSY', 'IEEE_802_15_4_PHY_BUSY_RX', 'IEEE_802_15_4_PHY_BUSY_TX', 'IEEE_802_15_4_PHY_FORCE_TRX_OFF', 'IEEE_802_15_4_PHY_IDLE', 'IEEE_802_15_4_PHY_INVALID_PARAMETER', 'IEEE_802_15_4_PHY_RX_ON', 'IEEE_802_15_4_PHY_SUCCESS', 'IEEE_802_15_4_PHY_TRX_OFF', 'IEEE_802_15_4_PHY_TX_ON', 'IEEE_802_15_4_PHY_UNSUPPORTED_ATTRIBUTE', 'IEEE_802_15_4_PHY_READ_ONLY', 'IEEE_802_15_4_PHY_UNSPECIFIED']) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPibAttributeIdentifier [enumeration] + module.add_enum('LrWpanPibAttributeIdentifier', ['phyCurrentChannel', 'phyChannelsSupported', 'phyTransmitPower', 'phyCCAMode', 'phyCurrentPage', 'phyMaxFrameDuration', 'phySHRDuration', 'phySymbolsPerOctet']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanAssociationStatus [enumeration] + module.add_enum('LrWpanAssociationStatus', ['ASSOCIATED', 'PAN_AT_CAPACITY', 'PAN_ACCESS_DENIED', 'ASSOCIATED_WITHOUT_ADDRESS', 'DISASSOCIATED']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMacState [enumeration] + module.add_enum('LrWpanMacState', ['MAC_IDLE', 'MAC_CSMA', 'MAC_SENDING', 'MAC_ACK_PENDING', 'CHANNEL_ACCESS_FAILURE', 'CHANNEL_IDLE', 'SET_PHY_TX_ON']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanAddressMode [enumeration] + module.add_enum('LrWpanAddressMode', ['NO_PANID_ADDR', 'ADDR_MODE_RESERVED', 'SHORT_ADDR', 'EXT_ADDR']) + ## 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') + ## event-id.h (module 'core'): ns3::EventId [class] + module.add_class('EventId', import_from_module='ns.core') + ## hash.h (module 'core'): ns3::Hasher [class] + module.add_class('Hasher', 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') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower [struct] + module.add_class('LrWpanEdPower') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates [struct] + module.add_class('LrWpanPhyDataAndSymbolRates') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes [struct] + module.add_class('LrWpanPhyPibAttributes') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber [struct] + module.add_class('LrWpanPhyPpduHeaderSymbolNumber') + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::LrWpanSpectrumValueHelper [class] + module.add_class('LrWpanSpectrumValueHelper') + ## mac16-address.h (module 'network'): ns3::Mac16Address [class] + module.add_class('Mac16Address', import_from_module='ns.network') + ## mac16-address.h (module 'network'): ns3::Mac16Address [class] + root_module['ns3::Mac16Address'].implicitly_converts_to(root_module['ns3::Address']) + ## mac64-address.h (module 'network'): ns3::Mac64Address [class] + module.add_class('Mac64Address', import_from_module='ns.network') + ## mac64-address.h (module 'network'): ns3::Mac64Address [class] + root_module['ns3::Mac64Address'].implicitly_converts_to(root_module['ns3::Address']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams [struct] + module.add_class('McpsDataConfirmParams') + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams [struct] + module.add_class('McpsDataIndicationParams') + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams [struct] + module.add_class('McpsDataRequestParams') + ## 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']) + ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData_e [enumeration] + module.add_enum('TagData_e', ['MAX_SIZE'], outer_class=root_module['ns3::PacketTagList::TagData'], import_from_module='ns.network') + ## 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', 'DLT_IEEE802_15_4'], 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') + ## sequence-number.h (module 'network'): ns3::SequenceNumber [class] + module.add_class('SequenceNumber8', import_from_module='ns.network') + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount [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') + ## 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') + ## 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) + ## header.h (module 'network'): ns3::Header [class] + module.add_class('Header', import_from_module='ns.network', parent=root_module['ns3::Chunk']) + ## lr-wpan-helper.h (module 'lr-wpan'): ns3::LrWpanHelper [class] + module.add_class('LrWpanHelper', parent=[root_module['ns3::PcapHelperForDevice'], root_module['ns3::AsciiTraceHelperForDevice']]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag [class] + module.add_class('LrWpanLqiTag', parent=root_module['ns3::Tag']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader [class] + module.add_class('LrWpanMacHeader', parent=root_module['ns3::Header']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacType [enumeration] + module.add_enum('LrWpanMacType', ['LRWPAN_MAC_BEACON', 'LRWPAN_MAC_DATA', 'LRWPAN_MAC_ACKNOWLEDGMENT', 'LRWPAN_MAC_COMMAND', 'LRWPAN_MAC_RESERVED'], outer_class=root_module['ns3::LrWpanMacHeader']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::AddrModeType [enumeration] + module.add_enum('AddrModeType', ['NOADDR', 'RESADDR', 'SHORTADDR', 'EXTADDR'], outer_class=root_module['ns3::LrWpanMacHeader']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::KeyIdModeType [enumeration] + module.add_enum('KeyIdModeType', ['IMPLICIT', 'NOKEYSOURCE', 'SHORTKEYSOURCE', 'LONGKEYSOURCE'], outer_class=root_module['ns3::LrWpanMacHeader']) + ## 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeAccessor', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeChecker', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeValue', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::CallbackImplBase', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::EventImpl', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Hash::Implementation', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, template_parameters=['ns3::LrWpanInterferenceHelper', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::NixVector', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::OutputStreamWrapper', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Packet', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::SpectrumSignalParameters', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::TraceSourceAccessor', 'ns3::empty', 'ns3::DefaultDeleter'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) + ## spectrum-phy.h (module 'spectrum'): ns3::SpectrumPhy [class] + module.add_class('SpectrumPhy', import_from_module='ns.spectrum', parent=root_module['ns3::Object']) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters [struct] + module.add_class('SpectrumSignalParameters', import_from_module='ns.spectrum', parent=root_module['ns3::SimpleRefCount< ns3::SpectrumSignalParameters, ns3::empty, ns3::DefaultDeleter >']) + ## 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', ['Y', 'D', 'H', 'MIN', '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 >']) + ## 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 >']) + ## 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 >']) + ## 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 >']) + ## 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 >']) + ## callback.h (module 'core'): ns3::CallbackValue [class] + module.add_class('CallbackValue', import_from_module='ns.core', 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']) + ## 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 >']) + ## 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']) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::LrWpanCsmaCa [class] + module.add_class('LrWpanCsmaCa', parent=root_module['ns3::Object']) + ## lr-wpan-error-model.h (module 'lr-wpan'): ns3::LrWpanErrorModel [class] + module.add_class('LrWpanErrorModel', parent=root_module['ns3::Object']) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::LrWpanInterferenceHelper [class] + module.add_class('LrWpanInterferenceHelper', parent=root_module['ns3::SimpleRefCount< ns3::LrWpanInterferenceHelper, ns3::empty, ns3::DefaultDeleter >']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac [class] + module.add_class('LrWpanMac', parent=root_module['ns3::Object']) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer [class] + module.add_class('LrWpanMacTrailer', parent=root_module['ns3::Trailer']) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy [class] + module.add_class('LrWpanPhy', parent=root_module['ns3::SpectrumPhy']) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters [struct] + module.add_class('LrWpanSpectrumSignalParameters', parent=root_module['ns3::SpectrumSignalParameters']) + ## mac16-address.h (module 'network'): ns3::Mac16AddressChecker [class] + module.add_class('Mac16AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue [class] + module.add_class('Mac16AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) + ## mac64-address.h (module 'network'): ns3::Mac64AddressChecker [class] + module.add_class('Mac64AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue [class] + module.add_class('Mac64AddressValue', 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 >']) + ## 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 >']) + ## 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 >']) + ## 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']) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::LrWpanNetDevice [class] + module.add_class('LrWpanNetDevice', parent=root_module['ns3::NetDevice']) + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeCcaConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeCcaConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeCcaConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeEdConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeEdConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeEdConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, unsigned int, ns3::Ptr< ns3::Packet >, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PdDataIndicationCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, unsigned int, ns3::Ptr< ns3::Packet >, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PdDataIndicationCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, unsigned int, ns3::Ptr< ns3::Packet >, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PdDataIndicationCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >', u'ns3::SequenceNumber16') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >*', u'ns3::SequenceNumber16*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >&', u'ns3::SequenceNumber16&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >', u'ns3::SequenceNumber32') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >*', u'ns3::SequenceNumber32*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >&', u'ns3::SequenceNumber32&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanMacState, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::LrWpanMacStateCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanMacState, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::LrWpanMacStateCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanMacState, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::LrWpanMacStateCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::LrWpanPhyPibAttributes *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeGetAttributeConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::LrWpanPhyPibAttributes *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeGetAttributeConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::LrWpanPhyPibAttributes *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeGetAttributeConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PdDataConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PdDataConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PdDataConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataIndicationParams, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::McpsDataIndicationCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataIndicationParams, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::McpsDataIndicationCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataIndicationParams, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::McpsDataIndicationCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataConfirmParams, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::McpsDataConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataConfirmParams, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::McpsDataConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataConfirmParams, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::McpsDataConfirmCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >', u'ns3::SequenceNumber8') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >*', u'ns3::SequenceNumber8*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >&', u'ns3::SequenceNumber8&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeSetAttributeConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeSetAttributeConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeSetAttributeConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeSetTRXStateConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeSetTRXStateConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeSetTRXStateConfirmCallback&') + + ## Register a nested module for the namespace FatalImpl + + nested_module = module.add_cpp_namespace('FatalImpl') + register_types_ns3_FatalImpl(nested_module) + + + ## Register a nested module for the namespace Hash + + nested_module = module.add_cpp_namespace('Hash') + register_types_ns3_Hash(nested_module) + + +def register_types_ns3_FatalImpl(module): + root_module = module.get_root() + + +def register_types_ns3_Hash(module): + root_module = module.get_root() + + ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] + module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + + ## Register a nested module for the namespace Function + + nested_module = module.add_cpp_namespace('Function') + register_types_ns3_Hash_Function(nested_module) + + +def register_types_ns3_Hash_Function(module): + root_module = module.get_root() + + ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a [class] + module.add_class('Fnv1a', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32 [class] + module.add_class('Hash32', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64 [class] + module.add_class('Hash64', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3 [class] + module.add_class('Murmur3', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + +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_Ns3EventId_methods(root_module, root_module['ns3::EventId']) + register_Ns3Hasher_methods(root_module, root_module['ns3::Hasher']) + 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_Ns3LrWpanEdPower_methods(root_module, root_module['ns3::LrWpanEdPower']) + register_Ns3LrWpanPhyDataAndSymbolRates_methods(root_module, root_module['ns3::LrWpanPhyDataAndSymbolRates']) + register_Ns3LrWpanPhyPibAttributes_methods(root_module, root_module['ns3::LrWpanPhyPibAttributes']) + register_Ns3LrWpanPhyPpduHeaderSymbolNumber_methods(root_module, root_module['ns3::LrWpanPhyPpduHeaderSymbolNumber']) + register_Ns3LrWpanSpectrumValueHelper_methods(root_module, root_module['ns3::LrWpanSpectrumValueHelper']) + register_Ns3Mac16Address_methods(root_module, root_module['ns3::Mac16Address']) + register_Ns3Mac64Address_methods(root_module, root_module['ns3::Mac64Address']) + register_Ns3McpsDataConfirmParams_methods(root_module, root_module['ns3::McpsDataConfirmParams']) + register_Ns3McpsDataIndicationParams_methods(root_module, root_module['ns3::McpsDataIndicationParams']) + register_Ns3McpsDataRequestParams_methods(root_module, root_module['ns3::McpsDataRequestParams']) + 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_Ns3SequenceNumber8_methods(root_module, root_module['ns3::SequenceNumber8']) + 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_Ns3Tag_methods(root_module, root_module['ns3::Tag']) + register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) + 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_Ns3Header_methods(root_module, root_module['ns3::Header']) + register_Ns3LrWpanHelper_methods(root_module, root_module['ns3::LrWpanHelper']) + register_Ns3LrWpanLqiTag_methods(root_module, root_module['ns3::LrWpanLqiTag']) + register_Ns3LrWpanMacHeader_methods(root_module, root_module['ns3::LrWpanMacHeader']) + 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 >']) + register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3LrWpanInterferenceHelper_Ns3Empty_Ns3DefaultDeleter__lt__ns3LrWpanInterferenceHelper__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::LrWpanInterferenceHelper, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3SpectrumSignalParameters_Ns3Empty_Ns3DefaultDeleter__lt__ns3SpectrumSignalParameters__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::SpectrumSignalParameters, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SpectrumPhy_methods(root_module, root_module['ns3::SpectrumPhy']) + register_Ns3SpectrumSignalParameters_methods(root_module, root_module['ns3::SpectrumSignalParameters']) + 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_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue']) + register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) + 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_Ns3LrWpanCsmaCa_methods(root_module, root_module['ns3::LrWpanCsmaCa']) + register_Ns3LrWpanErrorModel_methods(root_module, root_module['ns3::LrWpanErrorModel']) + register_Ns3LrWpanInterferenceHelper_methods(root_module, root_module['ns3::LrWpanInterferenceHelper']) + register_Ns3LrWpanMac_methods(root_module, root_module['ns3::LrWpanMac']) + register_Ns3LrWpanMacTrailer_methods(root_module, root_module['ns3::LrWpanMacTrailer']) + register_Ns3LrWpanPhy_methods(root_module, root_module['ns3::LrWpanPhy']) + register_Ns3LrWpanSpectrumSignalParameters_methods(root_module, root_module['ns3::LrWpanSpectrumSignalParameters']) + register_Ns3Mac16AddressChecker_methods(root_module, root_module['ns3::Mac16AddressChecker']) + register_Ns3Mac16AddressValue_methods(root_module, root_module['ns3::Mac16AddressValue']) + register_Ns3Mac64AddressChecker_methods(root_module, root_module['ns3::Mac64AddressChecker']) + register_Ns3Mac64AddressValue_methods(root_module, root_module['ns3::Mac64AddressValue']) + 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_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_Ns3LrWpanNetDevice_methods(root_module, root_module['ns3::LrWpanNetDevice']) + register_Ns3HashImplementation_methods(root_module, root_module['ns3::Hash::Implementation']) + register_Ns3HashFunctionFnv1a_methods(root_module, root_module['ns3::Hash::Function::Fnv1a']) + register_Ns3HashFunctionHash32_methods(root_module, root_module['ns3::Hash::Function::Hash32']) + register_Ns3HashFunctionHash64_methods(root_module, root_module['ns3::Hash::Function::Hash64']) + register_Ns3HashFunctionMurmur3_methods(root_module, root_module['ns3::Hash::Function::Murmur3']) + 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::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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 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 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 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 stream, ns3::Ptr 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 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 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 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 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 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 stream, std::string prefix, ns3::Ptr 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 checker, ns3::Ptr 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::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::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::AttributeConstructionList::Find(ns3::Ptr 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'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) + ## 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'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), 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::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 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_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 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_Ns3Hasher_methods(root_module, cls): + ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Hasher const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hasher const &', 'arg0')]) + ## hash.h (module 'core'): ns3::Hasher::Hasher() [constructor] + cls.add_constructor([]) + ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Ptr hp) [constructor] + cls.add_constructor([param('ns3::Ptr< ns3::Hash::Implementation >', 'hp')]) + ## hash.h (module 'core'): uint32_t ns3::Hasher::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')]) + ## hash.h (module 'core'): uint32_t ns3::Hasher::GetHash32(std::string const s) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('std::string const', 's')]) + ## hash.h (module 'core'): uint64_t ns3::Hasher::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')]) + ## hash.h (module 'core'): uint64_t ns3::Hasher::GetHash64(std::string const s) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('std::string const', 's')]) + ## hash.h (module 'core'): ns3::Hasher & ns3::Hasher::clear() [member function] + cls.add_method('clear', + 'ns3::Hasher &', + []) + 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::IsDocumentation() const [member function] + cls.add_method('IsDocumentation', + '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() const [member function] + cls.add_method('IsIpv4MappedAddress', + 'bool', + [], + is_const=True) + ## 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::Mac16Address addr, ns3::Ipv6Address prefix) [member function] + cls.add_method('MakeAutoconfiguredAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac16Address', 'addr'), param('ns3::Ipv6Address', 'prefix')], + is_static=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::MakeAutoconfiguredAddress(ns3::Mac64Address addr, ns3::Ipv6Address prefix) [member function] + cls.add_method('MakeAutoconfiguredAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac64Address', 'addr'), param('ns3::Ipv6Address', 'prefix')], + is_static=True) + ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredLinkLocalAddress(ns3::Mac16Address mac) [member function] + cls.add_method('MakeAutoconfiguredLinkLocalAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac16Address', 'mac')], + 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::MakeAutoconfiguredLinkLocalAddress(ns3::Mac64Address mac) [member function] + cls.add_method('MakeAutoconfiguredLinkLocalAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac64Address', '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_Ns3LrWpanEdPower_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::LrWpanEdPower() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::LrWpanEdPower(ns3::LrWpanEdPower const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanEdPower const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::averagePower [variable] + cls.add_instance_attribute('averagePower', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::lastUpdate [variable] + cls.add_instance_attribute('lastUpdate', 'ns3::Time', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::measurementLength [variable] + cls.add_instance_attribute('measurementLength', 'ns3::Time', is_const=False) + return + +def register_Ns3LrWpanPhyDataAndSymbolRates_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::LrWpanPhyDataAndSymbolRates() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::LrWpanPhyDataAndSymbolRates(ns3::LrWpanPhyDataAndSymbolRates const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanPhyDataAndSymbolRates const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::bitRate [variable] + cls.add_instance_attribute('bitRate', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::symbolRate [variable] + cls.add_instance_attribute('symbolRate', 'double', is_const=False) + return + +def register_Ns3LrWpanPhyPibAttributes_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::LrWpanPhyPibAttributes() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::LrWpanPhyPibAttributes(ns3::LrWpanPhyPibAttributes const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanPhyPibAttributes const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyCCAMode [variable] + cls.add_instance_attribute('phyCCAMode', 'uint8_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyChannelsSupported [variable] + cls.add_instance_attribute('phyChannelsSupported', 'uint32_t [ 32 ]', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyCurrentChannel [variable] + cls.add_instance_attribute('phyCurrentChannel', 'uint8_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyCurrentPage [variable] + cls.add_instance_attribute('phyCurrentPage', 'uint32_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyMaxFrameDuration [variable] + cls.add_instance_attribute('phyMaxFrameDuration', 'uint32_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phySHRDuration [variable] + cls.add_instance_attribute('phySHRDuration', 'uint32_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phySymbolsPerOctet [variable] + cls.add_instance_attribute('phySymbolsPerOctet', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyTransmitPower [variable] + cls.add_instance_attribute('phyTransmitPower', 'uint8_t', is_const=False) + return + +def register_Ns3LrWpanPhyPpduHeaderSymbolNumber_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::LrWpanPhyPpduHeaderSymbolNumber() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::LrWpanPhyPpduHeaderSymbolNumber(ns3::LrWpanPhyPpduHeaderSymbolNumber const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanPhyPpduHeaderSymbolNumber const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::phr [variable] + cls.add_instance_attribute('phr', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::shrPreamble [variable] + cls.add_instance_attribute('shrPreamble', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::shrSfd [variable] + cls.add_instance_attribute('shrSfd', 'double', is_const=False) + return + +def register_Ns3LrWpanSpectrumValueHelper_methods(root_module, cls): + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::LrWpanSpectrumValueHelper::LrWpanSpectrumValueHelper(ns3::LrWpanSpectrumValueHelper const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanSpectrumValueHelper const &', 'arg0')]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::LrWpanSpectrumValueHelper::LrWpanSpectrumValueHelper() [constructor] + cls.add_constructor([]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanSpectrumValueHelper::CreateNoisePowerSpectralDensity(uint32_t channel) [member function] + cls.add_method('CreateNoisePowerSpectralDensity', + 'ns3::Ptr< ns3::SpectrumValue >', + [param('uint32_t', 'channel')]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanSpectrumValueHelper::CreateTxPowerSpectralDensity(double txPower, uint32_t channel) [member function] + cls.add_method('CreateTxPowerSpectralDensity', + 'ns3::Ptr< ns3::SpectrumValue >', + [param('double', 'txPower'), param('uint32_t', 'channel')]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): static double ns3::LrWpanSpectrumValueHelper::TotalAvgPower(ns3::Ptr psd) [member function] + cls.add_method('TotalAvgPower', + 'double', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'psd')], + is_static=True) + return + +def register_Ns3Mac16Address_methods(root_module, cls): + cls.add_binary_comparison_operator('<') + cls.add_binary_comparison_operator('!=') + cls.add_output_stream_operator() + cls.add_binary_comparison_operator('==') + ## mac16-address.h (module 'network'): ns3::Mac16Address::Mac16Address(ns3::Mac16Address const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac16Address const &', 'arg0')]) + ## mac16-address.h (module 'network'): ns3::Mac16Address::Mac16Address() [constructor] + cls.add_constructor([]) + ## mac16-address.h (module 'network'): ns3::Mac16Address::Mac16Address(char const * str) [constructor] + cls.add_constructor([param('char const *', 'str')]) + ## mac16-address.h (module 'network'): static ns3::Mac16Address ns3::Mac16Address::Allocate() [member function] + cls.add_method('Allocate', + 'ns3::Mac16Address', + [], + is_static=True) + ## mac16-address.h (module 'network'): static ns3::Mac16Address ns3::Mac16Address::ConvertFrom(ns3::Address const & address) [member function] + cls.add_method('ConvertFrom', + 'ns3::Mac16Address', + [param('ns3::Address const &', 'address')], + is_static=True) + ## mac16-address.h (module 'network'): void ns3::Mac16Address::CopyFrom(uint8_t const * buffer) [member function] + cls.add_method('CopyFrom', + 'void', + [param('uint8_t const *', 'buffer')]) + ## mac16-address.h (module 'network'): void ns3::Mac16Address::CopyTo(uint8_t * buffer) const [member function] + cls.add_method('CopyTo', + 'void', + [param('uint8_t *', 'buffer')], + is_const=True) + ## mac16-address.h (module 'network'): static bool ns3::Mac16Address::IsMatchingType(ns3::Address const & address) [member function] + cls.add_method('IsMatchingType', + 'bool', + [param('ns3::Address const &', 'address')], + is_static=True) + return + +def register_Ns3Mac64Address_methods(root_module, cls): + cls.add_binary_comparison_operator('<') + cls.add_binary_comparison_operator('!=') + cls.add_output_stream_operator() + cls.add_binary_comparison_operator('==') + ## mac64-address.h (module 'network'): ns3::Mac64Address::Mac64Address(ns3::Mac64Address const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac64Address const &', 'arg0')]) + ## mac64-address.h (module 'network'): ns3::Mac64Address::Mac64Address() [constructor] + cls.add_constructor([]) + ## mac64-address.h (module 'network'): ns3::Mac64Address::Mac64Address(char const * str) [constructor] + cls.add_constructor([param('char const *', 'str')]) + ## mac64-address.h (module 'network'): static ns3::Mac64Address ns3::Mac64Address::Allocate() [member function] + cls.add_method('Allocate', + 'ns3::Mac64Address', + [], + is_static=True) + ## mac64-address.h (module 'network'): static ns3::Mac64Address ns3::Mac64Address::ConvertFrom(ns3::Address const & address) [member function] + cls.add_method('ConvertFrom', + 'ns3::Mac64Address', + [param('ns3::Address const &', 'address')], + is_static=True) + ## mac64-address.h (module 'network'): void ns3::Mac64Address::CopyFrom(uint8_t const * buffer) [member function] + cls.add_method('CopyFrom', + 'void', + [param('uint8_t const *', 'buffer')]) + ## mac64-address.h (module 'network'): void ns3::Mac64Address::CopyTo(uint8_t * buffer) const [member function] + cls.add_method('CopyTo', + 'void', + [param('uint8_t *', 'buffer')], + is_const=True) + ## mac64-address.h (module 'network'): static bool ns3::Mac64Address::IsMatchingType(ns3::Address const & address) [member function] + cls.add_method('IsMatchingType', + 'bool', + [param('ns3::Address const &', 'address')], + is_static=True) + return + +def register_Ns3McpsDataConfirmParams_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::McpsDataConfirmParams() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::McpsDataConfirmParams(ns3::McpsDataConfirmParams const & arg0) [copy constructor] + cls.add_constructor([param('ns3::McpsDataConfirmParams const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::m_msduHandle [variable] + cls.add_instance_attribute('m_msduHandle', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::m_status [variable] + cls.add_instance_attribute('m_status', 'ns3::LrWpanMcpsDataConfirmStatus', is_const=False) + return + +def register_Ns3McpsDataIndicationParams_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::McpsDataIndicationParams() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::McpsDataIndicationParams(ns3::McpsDataIndicationParams const & arg0) [copy constructor] + cls.add_constructor([param('ns3::McpsDataIndicationParams const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dsn [variable] + cls.add_instance_attribute('m_dsn', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dstAddr [variable] + cls.add_instance_attribute('m_dstAddr', 'ns3::Mac16Address', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dstAddrMode [variable] + cls.add_instance_attribute('m_dstAddrMode', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dstPanId [variable] + cls.add_instance_attribute('m_dstPanId', 'uint16_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_mpduLinkQuality [variable] + cls.add_instance_attribute('m_mpduLinkQuality', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_srcAddr [variable] + cls.add_instance_attribute('m_srcAddr', 'ns3::Mac16Address', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_srcAddrMode [variable] + cls.add_instance_attribute('m_srcAddrMode', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_srcPanId [variable] + cls.add_instance_attribute('m_srcPanId', 'uint16_t', is_const=False) + return + +def register_Ns3McpsDataRequestParams_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::McpsDataRequestParams(ns3::McpsDataRequestParams const & arg0) [copy constructor] + cls.add_constructor([param('ns3::McpsDataRequestParams const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::McpsDataRequestParams() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_dstAddr [variable] + cls.add_instance_attribute('m_dstAddr', 'ns3::Mac16Address', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_dstAddrMode [variable] + cls.add_instance_attribute('m_dstAddrMode', 'ns3::LrWpanAddressMode', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_dstPanId [variable] + cls.add_instance_attribute('m_dstPanId', 'uint16_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_msduHandle [variable] + cls.add_instance_attribute('m_msduHandle', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_srcAddrMode [variable] + cls.add_instance_attribute('m_srcAddrMode', 'ns3::LrWpanAddressMode', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_txOptions [variable] + cls.add_instance_attribute('m_txOptions', 'uint8_t', is_const=False) + 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 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 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*,std::vector, std::allocator > > > 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*,std::vector, std::allocator > > > 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::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 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 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*,std::vector, std::allocator > > > 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*,std::vector, std::allocator > > > 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::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::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', + []) + ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Replace(ns3::Tag & tag) [member function] + cls.add_method('Replace', + 'bool', + [param('ns3::Tag &', 'tag')]) + 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 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 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::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 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 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 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 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_Ns3SequenceNumber8_methods(root_module, cls): + cls.add_binary_comparison_operator('!=') + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber8'], root_module['ns3::SequenceNumber8'], param('ns3::SequenceNumber< unsigned char, signed char > const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber8'], root_module['ns3::SequenceNumber8'], param('signed char', u'right')) + cls.add_inplace_numeric_operator('+=', param('signed char', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::SequenceNumber8'], root_module['ns3::SequenceNumber8'], param('signed char', u'right')) + cls.add_inplace_numeric_operator('-=', param('signed char', u'right')) + 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('>=') + ## sequence-number.h (module 'network'): ns3::SequenceNumber::SequenceNumber() [constructor] + cls.add_constructor([]) + ## sequence-number.h (module 'network'): ns3::SequenceNumber::SequenceNumber(unsigned char value) [constructor] + cls.add_constructor([param('unsigned char', 'value')]) + ## sequence-number.h (module 'network'): ns3::SequenceNumber::SequenceNumber(ns3::SequenceNumber const & value) [copy constructor] + cls.add_constructor([param('ns3::SequenceNumber< unsigned char, signed char > const &', 'value')]) + ## sequence-number.h (module 'network'): unsigned char ns3::SequenceNumber::GetValue() const [member function] + cls.add_method('GetValue', + 'unsigned char', + [], + is_const=True) + return + +def register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount::SimpleRefCount(ns3::SimpleRefCount 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::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::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 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_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_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + 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 accessor, ns3::Ptr 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 accessor, ns3::Ptr 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 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::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'): uint32_t ns3::TypeId::GetHash() const [member function] + cls.add_method('GetHash', + 'uint32_t', + [], + 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::LookupByHash(uint32_t hash) [member function] + cls.add_method('LookupByHash', + 'ns3::TypeId', + [param('uint32_t', 'hash')], + is_static=True) + ## type-id.h (module 'core'): static bool ns3::TypeId::LookupByHashFailSafe(uint32_t hash, ns3::TypeId * tid) [member function] + cls.add_method('LookupByHashFailSafe', + 'bool', + [param('uint32_t', 'hash'), param('ns3::TypeId *', 'tid')], + is_static=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::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 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('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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 &', u'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 &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'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(long double v) [constructor] + cls.add_constructor([param('long 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')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) + 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_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_Ns3LrWpanHelper_methods(root_module, cls): + ## lr-wpan-helper.h (module 'lr-wpan'): ns3::LrWpanHelper::LrWpanHelper() [constructor] + cls.add_constructor([]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::AddMobility(ns3::Ptr phy, ns3::Ptr m) [member function] + cls.add_method('AddMobility', + 'void', + [param('ns3::Ptr< ns3::LrWpanPhy >', 'phy'), param('ns3::Ptr< ns3::MobilityModel >', 'm')]) + ## lr-wpan-helper.h (module 'lr-wpan'): ns3::NetDeviceContainer ns3::LrWpanHelper::Install(ns3::NodeContainer c) [member function] + cls.add_method('Install', + 'ns3::NetDeviceContainer', + [param('ns3::NodeContainer', 'c')]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::AssociateToPan(ns3::NetDeviceContainer c, uint16_t panId) [member function] + cls.add_method('AssociateToPan', + 'void', + [param('ns3::NetDeviceContainer', 'c'), param('uint16_t', 'panId')]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::EnableLogComponents() [member function] + cls.add_method('EnableLogComponents', + 'void', + []) + ## lr-wpan-helper.h (module 'lr-wpan'): static std::string ns3::LrWpanHelper::LrWpanPhyEnumerationPrinter(ns3::LrWpanPhyEnumeration arg0) [member function] + cls.add_method('LrWpanPhyEnumerationPrinter', + 'std::string', + [param('ns3::LrWpanPhyEnumeration', 'arg0')], + is_static=True) + ## lr-wpan-helper.h (module 'lr-wpan'): static std::string ns3::LrWpanHelper::LrWpanMacStatePrinter(ns3::LrWpanMacState e) [member function] + cls.add_method('LrWpanMacStatePrinter', + 'std::string', + [param('ns3::LrWpanMacState', 'e')], + is_static=True) + ## lr-wpan-helper.h (module 'lr-wpan'): int64_t ns3::LrWpanHelper::AssignStreams(ns3::NetDeviceContainer c, int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('ns3::NetDeviceContainer', 'c'), param('int64_t', 'stream')]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::EnablePcapInternal(std::string prefix, ns3::Ptr 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) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::EnableAsciiInternal(ns3::Ptr stream, std::string prefix, ns3::Ptr 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) + return + +def register_Ns3LrWpanLqiTag_methods(root_module, cls): + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag::LrWpanLqiTag(ns3::LrWpanLqiTag const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanLqiTag const &', 'arg0')]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag::LrWpanLqiTag() [constructor] + cls.add_constructor([]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag::LrWpanLqiTag(uint8_t lqi) [constructor] + cls.add_constructor([param('uint8_t', 'lqi')]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Deserialize(ns3::TagBuffer i) [member function] + cls.add_method('Deserialize', + 'void', + [param('ns3::TagBuffer', 'i')], + is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): uint8_t ns3::LrWpanLqiTag::Get() const [member function] + cls.add_method('Get', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::TypeId ns3::LrWpanLqiTag::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): uint32_t ns3::LrWpanLqiTag::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanLqiTag::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Serialize(ns3::TagBuffer i) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::TagBuffer', 'i')], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Set(uint8_t lqi) [member function] + cls.add_method('Set', + 'void', + [param('uint8_t', 'lqi')]) + return + +def register_Ns3LrWpanMacHeader_methods(root_module, cls): + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacHeader(ns3::LrWpanMacHeader const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanMacHeader const &', 'arg0')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacHeader() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacHeader(ns3::LrWpanMacHeader::LrWpanMacType wpanMacType, uint8_t seqNum) [constructor] + cls.add_constructor([param('ns3::LrWpanMacHeader::LrWpanMacType', 'wpanMacType'), param('uint8_t', 'seqNum')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetDstAddrMode() const [member function] + cls.add_method('GetDstAddrMode', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacHeader::GetDstPanId() const [member function] + cls.add_method('GetDstPanId', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac64Address ns3::LrWpanMacHeader::GetExtDstAddr() const [member function] + cls.add_method('GetExtDstAddr', + 'ns3::Mac64Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac64Address ns3::LrWpanMacHeader::GetExtSrcAddr() const [member function] + cls.add_method('GetExtSrcAddr', + 'ns3::Mac64Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacHeader::GetFrameControl() const [member function] + cls.add_method('GetFrameControl', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetFrameVer() const [member function] + cls.add_method('GetFrameVer', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::GetFrmCounter() const [member function] + cls.add_method('GetFrmCounter', + 'uint32_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetFrmCtrlRes() const [member function] + cls.add_method('GetFrmCtrlRes', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::TypeId ns3::LrWpanMacHeader::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetKeyIdIndex() const [member function] + cls.add_method('GetKeyIdIndex', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetKeyIdMode() const [member function] + cls.add_method('GetKeyIdMode', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::GetKeyIdSrc32() const [member function] + cls.add_method('GetKeyIdSrc32', + 'uint32_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint64_t ns3::LrWpanMacHeader::GetKeyIdSrc64() const [member function] + cls.add_method('GetKeyIdSrc64', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): std::string ns3::LrWpanMacHeader::GetName() const [member function] + cls.add_method('GetName', + 'std::string', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSecControl() const [member function] + cls.add_method('GetSecControl', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSecLevel() const [member function] + cls.add_method('GetSecLevel', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSeqNum() const [member function] + cls.add_method('GetSeqNum', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac16Address ns3::LrWpanMacHeader::GetShortDstAddr() const [member function] + cls.add_method('GetShortDstAddr', + 'ns3::Mac16Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac16Address ns3::LrWpanMacHeader::GetShortSrcAddr() const [member function] + cls.add_method('GetShortSrcAddr', + 'ns3::Mac16Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSrcAddrMode() const [member function] + cls.add_method('GetSrcAddrMode', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacHeader::GetSrcPanId() const [member function] + cls.add_method('GetSrcPanId', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacType ns3::LrWpanMacHeader::GetType() const [member function] + cls.add_method('GetType', + 'ns3::LrWpanMacHeader::LrWpanMacType', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanMacHeader::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetsecctrlReserved() const [member function] + cls.add_method('GetsecctrlReserved', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsAckReq() const [member function] + cls.add_method('IsAckReq', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsAcknowledgment() const [member function] + cls.add_method('IsAcknowledgment', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsBeacon() const [member function] + cls.add_method('IsBeacon', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsCommand() const [member function] + cls.add_method('IsCommand', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsData() const [member function] + cls.add_method('IsData', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsFrmPend() const [member function] + cls.add_method('IsFrmPend', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsNoAckReq() const [member function] + cls.add_method('IsNoAckReq', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsNoFrmPend() const [member function] + cls.add_method('IsNoFrmPend', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsNoPanIdComp() const [member function] + cls.add_method('IsNoPanIdComp', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsPanIdComp() const [member function] + cls.add_method('IsPanIdComp', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsSecDisable() const [member function] + cls.add_method('IsSecDisable', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsSecEnable() const [member function] + cls.add_method('IsSecEnable', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::PrintFrameControl(std::ostream & os) const [member function] + cls.add_method('PrintFrameControl', + 'void', + [param('std::ostream &', 'os')], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetAckReq() [member function] + cls.add_method('SetAckReq', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetDstAddrFields(uint16_t panId, ns3::Mac16Address addr) [member function] + cls.add_method('SetDstAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac16Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetDstAddrFields(uint16_t panId, ns3::Mac64Address addr) [member function] + cls.add_method('SetDstAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac64Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetDstAddrMode(uint8_t addrMode) [member function] + cls.add_method('SetDstAddrMode', + 'void', + [param('uint8_t', 'addrMode')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrameControl(uint16_t frameControl) [member function] + cls.add_method('SetFrameControl', + 'void', + [param('uint16_t', 'frameControl')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrameVer(uint8_t ver) [member function] + cls.add_method('SetFrameVer', + 'void', + [param('uint8_t', 'ver')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrmCounter(uint32_t frmCntr) [member function] + cls.add_method('SetFrmCounter', + 'void', + [param('uint32_t', 'frmCntr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrmCtrlRes(uint8_t res) [member function] + cls.add_method('SetFrmCtrlRes', + 'void', + [param('uint8_t', 'res')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrmPend() [member function] + cls.add_method('SetFrmPend', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyId(uint8_t keyIndex) [member function] + cls.add_method('SetKeyId', + 'void', + [param('uint8_t', 'keyIndex')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyId(uint32_t keySrc, uint8_t keyIndex) [member function] + cls.add_method('SetKeyId', + 'void', + [param('uint32_t', 'keySrc'), param('uint8_t', 'keyIndex')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyId(uint64_t keySrc, uint8_t keyIndex) [member function] + cls.add_method('SetKeyId', + 'void', + [param('uint64_t', 'keySrc'), param('uint8_t', 'keyIndex')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyIdMode(uint8_t keyIdMode) [member function] + cls.add_method('SetKeyIdMode', + 'void', + [param('uint8_t', 'keyIdMode')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetNoAckReq() [member function] + cls.add_method('SetNoAckReq', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetNoFrmPend() [member function] + cls.add_method('SetNoFrmPend', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetNoPanIdComp() [member function] + cls.add_method('SetNoPanIdComp', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetPanIdComp() [member function] + cls.add_method('SetPanIdComp', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecControl(uint8_t secLevel) [member function] + cls.add_method('SetSecControl', + 'void', + [param('uint8_t', 'secLevel')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecDisable() [member function] + cls.add_method('SetSecDisable', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecEnable() [member function] + cls.add_method('SetSecEnable', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecLevel(uint8_t secLevel) [member function] + cls.add_method('SetSecLevel', + 'void', + [param('uint8_t', 'secLevel')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSeqNum(uint8_t seqNum) [member function] + cls.add_method('SetSeqNum', + 'void', + [param('uint8_t', 'seqNum')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSrcAddrFields(uint16_t panId, ns3::Mac16Address addr) [member function] + cls.add_method('SetSrcAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac16Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSrcAddrFields(uint16_t panId, ns3::Mac64Address addr) [member function] + cls.add_method('SetSrcAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac64Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSrcAddrMode(uint8_t addrMode) [member function] + cls.add_method('SetSrcAddrMode', + 'void', + [param('uint8_t', 'addrMode')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetType(ns3::LrWpanMacHeader::LrWpanMacType wpanMacType) [member function] + cls.add_method('SetType', + 'void', + [param('ns3::LrWpanMacHeader::LrWpanMacType', 'wpanMacType')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetsecctrlReserved(uint8_t res) [member function] + cls.add_method('SetsecctrlReserved', + 'void', + [param('uint8_t', 'res')]) + 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 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::Initialize() [member function] + cls.add_method('Initialize', + '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::DoInitialize() [member function] + cls.add_method('DoInitialize', + '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::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::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::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 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 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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > const & o) [copy constructor] + cls.add_constructor([param('ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter< ns3::Hash::Implementation > > const &', 'o')]) + ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SimpleRefCount__Ns3LrWpanInterferenceHelper_Ns3Empty_Ns3DefaultDeleter__lt__ns3LrWpanInterferenceHelper__gt___methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > const & o) [copy constructor] + cls.add_constructor([param('ns3::SimpleRefCount< ns3::LrWpanInterferenceHelper, ns3::empty, ns3::DefaultDeleter< ns3::LrWpanInterferenceHelper > > const &', 'o')]) + ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SimpleRefCount__Ns3SpectrumSignalParameters_Ns3Empty_Ns3DefaultDeleter__lt__ns3SpectrumSignalParameters__gt___methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > const & o) [copy constructor] + cls.add_constructor([param('ns3::SimpleRefCount< ns3::SpectrumSignalParameters, ns3::empty, ns3::DefaultDeleter< ns3::SpectrumSignalParameters > > const &', 'o')]) + ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SpectrumPhy_methods(root_module, cls): + ## spectrum-phy.h (module 'spectrum'): ns3::SpectrumPhy::SpectrumPhy() [constructor] + cls.add_constructor([]) + ## spectrum-phy.h (module 'spectrum'): static ns3::TypeId ns3::SpectrumPhy::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::SetDevice(ns3::Ptr d) [member function] + cls.add_method('SetDevice', + 'void', + [param('ns3::Ptr< ns3::NetDevice >', 'd')], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetDevice() [member function] + cls.add_method('GetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::SetMobility(ns3::Ptr m) [member function] + cls.add_method('SetMobility', + 'void', + [param('ns3::Ptr< ns3::MobilityModel >', 'm')], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetMobility() [member function] + cls.add_method('GetMobility', + 'ns3::Ptr< ns3::MobilityModel >', + [], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::SetChannel(ns3::Ptr c) [member function] + cls.add_method('SetChannel', + 'void', + [param('ns3::Ptr< ns3::SpectrumChannel >', 'c')], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetRxSpectrumModel() const [member function] + cls.add_method('GetRxSpectrumModel', + 'ns3::Ptr< ns3::SpectrumModel const >', + [], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetRxAntenna() [member function] + cls.add_method('GetRxAntenna', + 'ns3::Ptr< ns3::AntennaModel >', + [], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::StartRx(ns3::Ptr params) [member function] + cls.add_method('StartRx', + 'void', + [param('ns3::Ptr< ns3::SpectrumSignalParameters >', 'params')], + is_pure_virtual=True, is_virtual=True) + return + +def register_Ns3SpectrumSignalParameters_methods(root_module, cls): + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::SpectrumSignalParameters() [constructor] + cls.add_constructor([]) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::SpectrumSignalParameters(ns3::SpectrumSignalParameters const & p) [copy constructor] + cls.add_constructor([param('ns3::SpectrumSignalParameters const &', 'p')]) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::Ptr ns3::SpectrumSignalParameters::Copy() [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::SpectrumSignalParameters >', + [], + is_virtual=True) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::duration [variable] + cls.add_instance_attribute('duration', 'ns3::Time', is_const=False) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::psd [variable] + cls.add_instance_attribute('psd', 'ns3::Ptr< ns3::SpectrumValue >', is_const=False) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::txAntenna [variable] + cls.add_instance_attribute('txAntenna', 'ns3::Ptr< ns3::AntennaModel >', is_const=False) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::txPhy [variable] + cls.add_instance_attribute('txPhy', 'ns3::Ptr< ns3::SpectrumPhy >', is_const=False) + return + +def register_Ns3Time_methods(root_module, cls): + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) + ## 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::GetDays() const [member function] + cls.add_method('GetDays', + 'double', + [], + is_const=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'): double ns3::Time::GetHours() const [member function] + cls.add_method('GetHours', + 'double', + [], + 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'): double ns3::Time::GetMinutes() const [member function] + cls.add_method('GetMinutes', + 'double', + [], + 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'): double ns3::Time::GetYears() const [member function] + cls.add_method('GetYears', + 'double', + [], + 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 ns3::Time ns3::Time::Max() [member function] + cls.add_method('Max', + 'ns3::Time', + [], + is_static=True) + ## nstime.h (module 'core'): static ns3::Time ns3::Time::Min() [member function] + cls.add_method('Min', + 'ns3::Time', + [], + is_static=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'): static bool ns3::Time::StaticInit() [member function] + cls.add_method('StaticInit', + 'bool', + [], + 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::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::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::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 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 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 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::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 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 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_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::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 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 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_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_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::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 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 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::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 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 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::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 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 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::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 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 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_Ns3LrWpanCsmaCa_methods(root_module, cls): + ## lr-wpan-csmaca.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanCsmaCa::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::LrWpanCsmaCa::LrWpanCsmaCa() [constructor] + cls.add_constructor([]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMac(ns3::Ptr mac) [member function] + cls.add_method('SetMac', + 'void', + [param('ns3::Ptr< ns3::LrWpanMac >', 'mac')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanCsmaCa::GetMac() const [member function] + cls.add_method('GetMac', + 'ns3::Ptr< ns3::LrWpanMac >', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetSlottedCsmaCa() [member function] + cls.add_method('SetSlottedCsmaCa', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetUnSlottedCsmaCa() [member function] + cls.add_method('SetUnSlottedCsmaCa', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): bool ns3::LrWpanCsmaCa::IsSlottedCsmaCa() const [member function] + cls.add_method('IsSlottedCsmaCa', + 'bool', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): bool ns3::LrWpanCsmaCa::IsUnSlottedCsmaCa() const [member function] + cls.add_method('IsUnSlottedCsmaCa', + 'bool', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMacMinBE(uint8_t macMinBE) [member function] + cls.add_method('SetMacMinBE', + 'void', + [param('uint8_t', 'macMinBE')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetMacMinBE() const [member function] + cls.add_method('GetMacMinBE', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMacMaxBE(uint8_t macMaxBE) [member function] + cls.add_method('SetMacMaxBE', + 'void', + [param('uint8_t', 'macMaxBE')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetMacMaxBE() const [member function] + cls.add_method('GetMacMaxBE', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMacMaxCSMABackoffs(uint8_t macMaxCSMABackoffs) [member function] + cls.add_method('SetMacMaxCSMABackoffs', + 'void', + [param('uint8_t', 'macMaxCSMABackoffs')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetMacMaxCSMABackoffs() const [member function] + cls.add_method('GetMacMaxCSMABackoffs', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetUnitBackoffPeriod(uint64_t unitBackoffPeriod) [member function] + cls.add_method('SetUnitBackoffPeriod', + 'void', + [param('uint64_t', 'unitBackoffPeriod')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint64_t ns3::LrWpanCsmaCa::GetUnitBackoffPeriod() const [member function] + cls.add_method('GetUnitBackoffPeriod', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::Time ns3::LrWpanCsmaCa::GetTimeToNextSlot() const [member function] + cls.add_method('GetTimeToNextSlot', + 'ns3::Time', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::Start() [member function] + cls.add_method('Start', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::Cancel() [member function] + cls.add_method('Cancel', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::RandomBackoffDelay() [member function] + cls.add_method('RandomBackoffDelay', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::CanProceed() [member function] + cls.add_method('CanProceed', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::RequestCCA() [member function] + cls.add_method('RequestCCA', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::PlmeCcaConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PlmeCcaConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetLrWpanMacStateCallback(ns3::LrWpanMacStateCallback macState) [member function] + cls.add_method('SetLrWpanMacStateCallback', + 'void', + [param('ns3::LrWpanMacStateCallback', 'macState')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): int64_t ns3::LrWpanCsmaCa::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetNB() [member function] + cls.add_method('GetNB', + 'uint8_t', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='private', is_virtual=True) + return + +def register_Ns3LrWpanErrorModel_methods(root_module, cls): + ## lr-wpan-error-model.h (module 'lr-wpan'): ns3::LrWpanErrorModel::LrWpanErrorModel(ns3::LrWpanErrorModel const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanErrorModel const &', 'arg0')]) + ## lr-wpan-error-model.h (module 'lr-wpan'): ns3::LrWpanErrorModel::LrWpanErrorModel() [constructor] + cls.add_constructor([]) + ## lr-wpan-error-model.h (module 'lr-wpan'): double ns3::LrWpanErrorModel::GetChunkSuccessRate(double snr, uint32_t nbits) const [member function] + cls.add_method('GetChunkSuccessRate', + 'double', + [param('double', 'snr'), param('uint32_t', 'nbits')], + is_const=True) + ## lr-wpan-error-model.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanErrorModel::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + return + +def register_Ns3LrWpanInterferenceHelper_methods(root_module, cls): + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::LrWpanInterferenceHelper::LrWpanInterferenceHelper(ns3::Ptr spectrumModel) [constructor] + cls.add_constructor([param('ns3::Ptr< ns3::SpectrumModel const >', 'spectrumModel')]) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): bool ns3::LrWpanInterferenceHelper::AddSignal(ns3::Ptr signal) [member function] + cls.add_method('AddSignal', + 'bool', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'signal')]) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): bool ns3::LrWpanInterferenceHelper::RemoveSignal(ns3::Ptr signal) [member function] + cls.add_method('RemoveSignal', + 'bool', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'signal')]) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): void ns3::LrWpanInterferenceHelper::ClearSignals() [member function] + cls.add_method('ClearSignals', + 'void', + []) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanInterferenceHelper::GetSignalPsd() const [member function] + cls.add_method('GetSignalPsd', + 'ns3::Ptr< ns3::SpectrumValue >', + [], + is_const=True) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanInterferenceHelper::GetSpectrumModel() const [member function] + cls.add_method('GetSpectrumModel', + 'ns3::Ptr< ns3::SpectrumModel const >', + [], + is_const=True) + return + +def register_Ns3LrWpanMac_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::LrWpanMac(ns3::LrWpanMac const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanMac const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::LrWpanMac() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanAssociationStatus ns3::LrWpanMac::GetAssociationStatus() const [member function] + cls.add_method('GetAssociationStatus', + 'ns3::LrWpanAssociationStatus', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::Mac64Address ns3::LrWpanMac::GetExtendedAddress() const [member function] + cls.add_method('GetExtendedAddress', + 'ns3::Mac64Address', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): uint64_t ns3::LrWpanMac::GetMacAckWaitDuration() const [member function] + cls.add_method('GetMacAckWaitDuration', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): uint8_t ns3::LrWpanMac::GetMacMaxFrameRetries() const [member function] + cls.add_method('GetMacMaxFrameRetries', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): uint16_t ns3::LrWpanMac::GetPanId() const [member function] + cls.add_method('GetPanId', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanMac::GetPhy() [member function] + cls.add_method('GetPhy', + 'ns3::Ptr< ns3::LrWpanPhy >', + []) + ## lr-wpan-mac.h (module 'lr-wpan'): bool ns3::LrWpanMac::GetRxOnWhenIdle() [member function] + cls.add_method('GetRxOnWhenIdle', + 'bool', + []) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::Mac16Address ns3::LrWpanMac::GetShortAddress() const [member function] + cls.add_method('GetShortAddress', + 'ns3::Mac16Address', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanMac::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::McpsDataRequest(ns3::McpsDataRequestParams params, ns3::Ptr p) [member function] + cls.add_method('McpsDataRequest', + 'void', + [param('ns3::McpsDataRequestParams', 'params'), param('ns3::Ptr< ns3::Packet >', 'p')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PdDataConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PdDataConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PdDataIndication(uint32_t psduLength, ns3::Ptr p, uint8_t lqi) [member function] + cls.add_method('PdDataIndication', + 'void', + [param('uint32_t', 'psduLength'), param('ns3::Ptr< ns3::Packet >', 'p'), param('uint8_t', 'lqi')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeCcaConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PlmeCcaConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeEdConfirm(ns3::LrWpanPhyEnumeration status, uint8_t energyLevel) [member function] + cls.add_method('PlmeEdConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status'), param('uint8_t', 'energyLevel')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeGetAttributeConfirm(ns3::LrWpanPhyEnumeration status, ns3::LrWpanPibAttributeIdentifier id, ns3::LrWpanPhyPibAttributes * attribute) [member function] + cls.add_method('PlmeGetAttributeConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status'), param('ns3::LrWpanPibAttributeIdentifier', 'id'), param('ns3::LrWpanPhyPibAttributes *', 'attribute')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeSetAttributeConfirm(ns3::LrWpanPhyEnumeration status, ns3::LrWpanPibAttributeIdentifier id) [member function] + cls.add_method('PlmeSetAttributeConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status'), param('ns3::LrWpanPibAttributeIdentifier', 'id')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeSetTRXStateConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PlmeSetTRXStateConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetAssociationStatus(ns3::LrWpanAssociationStatus status) [member function] + cls.add_method('SetAssociationStatus', + 'void', + [param('ns3::LrWpanAssociationStatus', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetCsmaCa(ns3::Ptr csmaCa) [member function] + cls.add_method('SetCsmaCa', + 'void', + [param('ns3::Ptr< ns3::LrWpanCsmaCa >', 'csmaCa')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetExtendedAddress(ns3::Mac64Address address) [member function] + cls.add_method('SetExtendedAddress', + 'void', + [param('ns3::Mac64Address', 'address')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetLrWpanMacState(ns3::LrWpanMacState macState) [member function] + cls.add_method('SetLrWpanMacState', + 'void', + [param('ns3::LrWpanMacState', 'macState')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetMacMaxFrameRetries(uint8_t retries) [member function] + cls.add_method('SetMacMaxFrameRetries', + 'void', + [param('uint8_t', 'retries')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetMcpsDataConfirmCallback(ns3::McpsDataConfirmCallback c) [member function] + cls.add_method('SetMcpsDataConfirmCallback', + 'void', + [param('ns3::McpsDataConfirmCallback', 'c')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetMcpsDataIndicationCallback(ns3::McpsDataIndicationCallback c) [member function] + cls.add_method('SetMcpsDataIndicationCallback', + 'void', + [param('ns3::McpsDataIndicationCallback', 'c')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetPanId(uint16_t panId) [member function] + cls.add_method('SetPanId', + 'void', + [param('uint16_t', 'panId')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetPhy(ns3::Ptr phy) [member function] + cls.add_method('SetPhy', + 'void', + [param('ns3::Ptr< ns3::LrWpanPhy >', 'phy')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetRxOnWhenIdle(bool rxOnWhenIdle) [member function] + cls.add_method('SetRxOnWhenIdle', + 'void', + [param('bool', 'rxOnWhenIdle')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetShortAddress(ns3::Mac16Address address) [member function] + cls.add_method('SetShortAddress', + 'void', + [param('ns3::Mac16Address', 'address')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::aMinMPDUOverhead [variable] + cls.add_static_attribute('aMinMPDUOverhead', 'uint32_t const', is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_aBaseSlotDuration [variable] + cls.add_instance_attribute('m_aBaseSlotDuration', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_aBaseSuperframeDuration [variable] + cls.add_instance_attribute('m_aBaseSuperframeDuration', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_aNumSuperframeSlots [variable] + cls.add_instance_attribute('m_aNumSuperframeSlots', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macBeaconOrder [variable] + cls.add_instance_attribute('m_macBeaconOrder', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macBeaconTxTime [variable] + cls.add_instance_attribute('m_macBeaconTxTime', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macDsn [variable] + cls.add_instance_attribute('m_macDsn', 'ns3::SequenceNumber8', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macMaxFrameRetries [variable] + cls.add_instance_attribute('m_macMaxFrameRetries', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macPanId [variable] + cls.add_instance_attribute('m_macPanId', 'uint16_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macPromiscuousMode [variable] + cls.add_instance_attribute('m_macPromiscuousMode', 'bool', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macRxOnWhenIdle [variable] + cls.add_instance_attribute('m_macRxOnWhenIdle', 'bool', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macSuperframeOrder [variable] + cls.add_instance_attribute('m_macSuperframeOrder', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macSyncSymbolOffset [variable] + cls.add_instance_attribute('m_macSyncSymbolOffset', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='protected', is_virtual=True) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::DoInitialize() [member function] + cls.add_method('DoInitialize', + 'void', + [], + visibility='protected', is_virtual=True) + return + +def register_Ns3LrWpanMacTrailer_methods(root_module, cls): + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer::LrWpanMacTrailer(ns3::LrWpanMacTrailer const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanMacTrailer const &', 'arg0')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer::LrWpanMacTrailer() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): bool ns3::LrWpanMacTrailer::CheckFcs(ns3::Ptr p) [member function] + cls.add_method('CheckFcs', + 'bool', + [param('ns3::Ptr< ns3::Packet const >', 'p')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacTrailer::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::EnableFcs(bool enable) [member function] + cls.add_method('EnableFcs', + 'void', + [param('bool', 'enable')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacTrailer::GetFcs() const [member function] + cls.add_method('GetFcs', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::TypeId ns3::LrWpanMacTrailer::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacTrailer::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanMacTrailer::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): bool ns3::LrWpanMacTrailer::IsFcsEnabled() [member function] + cls.add_method('IsFcsEnabled', + 'bool', + []) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::SetFcs(ns3::Ptr p) [member function] + cls.add_method('SetFcs', + 'void', + [param('ns3::Ptr< ns3::Packet const >', 'p')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer::LR_WPAN_MAC_FCS_LENGTH [variable] + cls.add_static_attribute('LR_WPAN_MAC_FCS_LENGTH', 'uint16_t const', is_const=True) + return + +def register_Ns3LrWpanPhy_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy::aMaxPhyPacketSize [variable] + cls.add_static_attribute('aMaxPhyPacketSize', 'uint32_t const', is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy::aTurnaroundTime [variable] + cls.add_static_attribute('aTurnaroundTime', 'uint32_t const', is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanPhy::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy::LrWpanPhy() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetMobility(ns3::Ptr m) [member function] + cls.add_method('SetMobility', + 'void', + [param('ns3::Ptr< ns3::MobilityModel >', 'm')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetMobility() [member function] + cls.add_method('GetMobility', + 'ns3::Ptr< ns3::MobilityModel >', + [], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetChannel(ns3::Ptr c) [member function] + cls.add_method('SetChannel', + 'void', + [param('ns3::Ptr< ns3::SpectrumChannel >', 'c')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetChannel() [member function] + cls.add_method('GetChannel', + 'ns3::Ptr< ns3::SpectrumChannel >', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetDevice(ns3::Ptr d) [member function] + cls.add_method('SetDevice', + 'void', + [param('ns3::Ptr< ns3::NetDevice >', 'd')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetDevice() [member function] + cls.add_method('GetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetAntenna(ns3::Ptr a) [member function] + cls.add_method('SetAntenna', + 'void', + [param('ns3::Ptr< ns3::AntennaModel >', 'a')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetRxAntenna() [member function] + cls.add_method('GetRxAntenna', + 'ns3::Ptr< ns3::AntennaModel >', + [], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetRxSpectrumModel() const [member function] + cls.add_method('GetRxSpectrumModel', + 'ns3::Ptr< ns3::SpectrumModel const >', + [], + is_const=True, is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetTxPowerSpectralDensity(ns3::Ptr txPsd) [member function] + cls.add_method('SetTxPowerSpectralDensity', + 'void', + [param('ns3::Ptr< ns3::SpectrumValue >', 'txPsd')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetNoisePowerSpectralDensity(ns3::Ptr noisePsd) [member function] + cls.add_method('SetNoisePowerSpectralDensity', + 'void', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'noisePsd')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetNoisePowerSpectralDensity() [member function] + cls.add_method('GetNoisePowerSpectralDensity', + 'ns3::Ptr< ns3::SpectrumValue const >', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::StartRx(ns3::Ptr params) [member function] + cls.add_method('StartRx', + 'void', + [param('ns3::Ptr< ns3::SpectrumSignalParameters >', 'params')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PdDataRequest(uint32_t const psduLength, ns3::Ptr p) [member function] + cls.add_method('PdDataRequest', + 'void', + [param('uint32_t const', 'psduLength'), param('ns3::Ptr< ns3::Packet >', 'p')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeCcaRequest() [member function] + cls.add_method('PlmeCcaRequest', + 'void', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeEdRequest() [member function] + cls.add_method('PlmeEdRequest', + 'void', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeGetAttributeRequest(ns3::LrWpanPibAttributeIdentifier id) [member function] + cls.add_method('PlmeGetAttributeRequest', + 'void', + [param('ns3::LrWpanPibAttributeIdentifier', 'id')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeSetTRXStateRequest(ns3::LrWpanPhyEnumeration state) [member function] + cls.add_method('PlmeSetTRXStateRequest', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'state')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeSetAttributeRequest(ns3::LrWpanPibAttributeIdentifier id, ns3::LrWpanPhyPibAttributes * attribute) [member function] + cls.add_method('PlmeSetAttributeRequest', + 'void', + [param('ns3::LrWpanPibAttributeIdentifier', 'id'), param('ns3::LrWpanPhyPibAttributes *', 'attribute')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPdDataIndicationCallback(ns3::PdDataIndicationCallback c) [member function] + cls.add_method('SetPdDataIndicationCallback', + 'void', + [param('ns3::PdDataIndicationCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPdDataConfirmCallback(ns3::PdDataConfirmCallback c) [member function] + cls.add_method('SetPdDataConfirmCallback', + 'void', + [param('ns3::PdDataConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeCcaConfirmCallback(ns3::PlmeCcaConfirmCallback c) [member function] + cls.add_method('SetPlmeCcaConfirmCallback', + 'void', + [param('ns3::PlmeCcaConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeEdConfirmCallback(ns3::PlmeEdConfirmCallback c) [member function] + cls.add_method('SetPlmeEdConfirmCallback', + 'void', + [param('ns3::PlmeEdConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeGetAttributeConfirmCallback(ns3::PlmeGetAttributeConfirmCallback c) [member function] + cls.add_method('SetPlmeGetAttributeConfirmCallback', + 'void', + [param('ns3::PlmeGetAttributeConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeSetTRXStateConfirmCallback(ns3::PlmeSetTRXStateConfirmCallback c) [member function] + cls.add_method('SetPlmeSetTRXStateConfirmCallback', + 'void', + [param('ns3::PlmeSetTRXStateConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeSetAttributeConfirmCallback(ns3::PlmeSetAttributeConfirmCallback c) [member function] + cls.add_method('SetPlmeSetAttributeConfirmCallback', + 'void', + [param('ns3::PlmeSetAttributeConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): double ns3::LrWpanPhy::GetDataOrSymbolRate(bool isData) [member function] + cls.add_method('GetDataOrSymbolRate', + 'double', + [param('bool', 'isData')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetErrorModel(ns3::Ptr e) [member function] + cls.add_method('SetErrorModel', + 'void', + [param('ns3::Ptr< ns3::LrWpanErrorModel >', 'e')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetErrorModel() const [member function] + cls.add_method('GetErrorModel', + 'ns3::Ptr< ns3::LrWpanErrorModel >', + [], + is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): uint64_t ns3::LrWpanPhy::GetPhySHRDuration() const [member function] + cls.add_method('GetPhySHRDuration', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): double ns3::LrWpanPhy::GetPhySymbolsPerOctet() const [member function] + cls.add_method('GetPhySymbolsPerOctet', + 'double', + [], + is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): int64_t ns3::LrWpanPhy::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='private', is_virtual=True) + return + +def register_Ns3LrWpanSpectrumSignalParameters_methods(root_module, cls): + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters::LrWpanSpectrumSignalParameters() [constructor] + cls.add_constructor([]) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters::LrWpanSpectrumSignalParameters(ns3::LrWpanSpectrumSignalParameters const & p) [copy constructor] + cls.add_constructor([param('ns3::LrWpanSpectrumSignalParameters const &', 'p')]) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanSpectrumSignalParameters::Copy() [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::SpectrumSignalParameters >', + [], + is_virtual=True) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters::packetBurst [variable] + cls.add_instance_attribute('packetBurst', 'ns3::Ptr< ns3::PacketBurst >', is_const=False) + return + +def register_Ns3Mac16AddressChecker_methods(root_module, cls): + ## mac16-address.h (module 'network'): ns3::Mac16AddressChecker::Mac16AddressChecker() [constructor] + cls.add_constructor([]) + ## mac16-address.h (module 'network'): ns3::Mac16AddressChecker::Mac16AddressChecker(ns3::Mac16AddressChecker const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac16AddressChecker const &', 'arg0')]) + return + +def register_Ns3Mac16AddressValue_methods(root_module, cls): + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue::Mac16AddressValue() [constructor] + cls.add_constructor([]) + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue::Mac16AddressValue(ns3::Mac16AddressValue const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac16AddressValue const &', 'arg0')]) + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue::Mac16AddressValue(ns3::Mac16Address const & value) [constructor] + cls.add_constructor([param('ns3::Mac16Address const &', 'value')]) + ## mac16-address.h (module 'network'): ns3::Ptr ns3::Mac16AddressValue::Copy() const [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::AttributeValue >', + [], + is_const=True, is_virtual=True) + ## mac16-address.h (module 'network'): bool ns3::Mac16AddressValue::DeserializeFromString(std::string value, ns3::Ptr checker) [member function] + cls.add_method('DeserializeFromString', + 'bool', + [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_virtual=True) + ## mac16-address.h (module 'network'): ns3::Mac16Address ns3::Mac16AddressValue::Get() const [member function] + cls.add_method('Get', + 'ns3::Mac16Address', + [], + is_const=True) + ## mac16-address.h (module 'network'): std::string ns3::Mac16AddressValue::SerializeToString(ns3::Ptr checker) const [member function] + cls.add_method('SerializeToString', + 'std::string', + [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_const=True, is_virtual=True) + ## mac16-address.h (module 'network'): void ns3::Mac16AddressValue::Set(ns3::Mac16Address const & value) [member function] + cls.add_method('Set', + 'void', + [param('ns3::Mac16Address const &', 'value')]) + return + +def register_Ns3Mac64AddressChecker_methods(root_module, cls): + ## mac64-address.h (module 'network'): ns3::Mac64AddressChecker::Mac64AddressChecker() [constructor] + cls.add_constructor([]) + ## mac64-address.h (module 'network'): ns3::Mac64AddressChecker::Mac64AddressChecker(ns3::Mac64AddressChecker const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac64AddressChecker const &', 'arg0')]) + return + +def register_Ns3Mac64AddressValue_methods(root_module, cls): + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue::Mac64AddressValue() [constructor] + cls.add_constructor([]) + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue::Mac64AddressValue(ns3::Mac64AddressValue const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac64AddressValue const &', 'arg0')]) + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue::Mac64AddressValue(ns3::Mac64Address const & value) [constructor] + cls.add_constructor([param('ns3::Mac64Address const &', 'value')]) + ## mac64-address.h (module 'network'): ns3::Ptr ns3::Mac64AddressValue::Copy() const [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::AttributeValue >', + [], + is_const=True, is_virtual=True) + ## mac64-address.h (module 'network'): bool ns3::Mac64AddressValue::DeserializeFromString(std::string value, ns3::Ptr checker) [member function] + cls.add_method('DeserializeFromString', + 'bool', + [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_virtual=True) + ## mac64-address.h (module 'network'): ns3::Mac64Address ns3::Mac64AddressValue::Get() const [member function] + cls.add_method('Get', + 'ns3::Mac64Address', + [], + is_const=True) + ## mac64-address.h (module 'network'): std::string ns3::Mac64AddressValue::SerializeToString(ns3::Ptr checker) const [member function] + cls.add_method('SerializeToString', + 'std::string', + [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_const=True, is_virtual=True) + ## mac64-address.h (module 'network'): void ns3::Mac64AddressValue::Set(ns3::Mac64Address const & value) [member function] + cls.add_method('Set', + 'void', + [param('ns3::Mac64Address 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 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::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::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 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 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 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,ns3::Ptr,short unsigned int,const ns3::Address&,const ns3::Address&,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 >, short unsigned int, 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, ns3::Ptr, 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::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 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 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::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::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,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, ns3::Ptr, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler, uint16_t protocolType, ns3::Ptr 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,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, ns3::Ptr, 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::DoInitialize() [member function] + cls.add_method('DoInitialize', + '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::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 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 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 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::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::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::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'): bool ns3::Packet::ReplacePacketTag(ns3::Tag & tag) [member function] + cls.add_method('ReplacePacketTag', + 'bool', + [param('ns3::Tag &', 'tag')]) + ## 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 nixVector) [member function] + cls.add_method('SetNixVector', + 'void', + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) + 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::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 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 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::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 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 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::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 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 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_Ns3LrWpanNetDevice_methods(root_module, cls): + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::LrWpanNetDevice::LrWpanNetDevice(ns3::LrWpanNetDevice const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanNetDevice const &', 'arg0')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::LrWpanNetDevice::LrWpanNetDevice() [constructor] + cls.add_constructor([]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::AddLinkChangeCallback(ns3::Callback 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): int64_t ns3::LrWpanNetDevice::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetAddress() const [member function] + cls.add_method('GetAddress', + 'ns3::Address', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetBroadcast() const [member function] + cls.add_method('GetBroadcast', + 'ns3::Address', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetChannel() const [member function] + cls.add_method('GetChannel', + 'ns3::Ptr< ns3::Channel >', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetCsmaCa() const [member function] + cls.add_method('GetCsmaCa', + 'ns3::Ptr< ns3::LrWpanCsmaCa >', + [], + is_const=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): uint32_t ns3::LrWpanNetDevice::GetIfIndex() const [member function] + cls.add_method('GetIfIndex', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetMac() const [member function] + cls.add_method('GetMac', + 'ns3::Ptr< ns3::LrWpanMac >', + [], + is_const=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): uint16_t ns3::LrWpanNetDevice::GetMtu() const [member function] + cls.add_method('GetMtu', + 'uint16_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetMulticast(ns3::Ipv4Address multicastGroup) const [member function] + cls.add_method('GetMulticast', + 'ns3::Address', + [param('ns3::Ipv4Address', 'multicastGroup')], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetMulticast(ns3::Ipv6Address addr) const [member function] + cls.add_method('GetMulticast', + 'ns3::Address', + [param('ns3::Ipv6Address', 'addr')], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetNode() const [member function] + cls.add_method('GetNode', + 'ns3::Ptr< ns3::Node >', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetPhy() const [member function] + cls.add_method('GetPhy', + 'ns3::Ptr< ns3::LrWpanPhy >', + [], + is_const=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanNetDevice::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsBridge() const [member function] + cls.add_method('IsBridge', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsBroadcast() const [member function] + cls.add_method('IsBroadcast', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsLinkUp() const [member function] + cls.add_method('IsLinkUp', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsMulticast() const [member function] + cls.add_method('IsMulticast', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsPointToPoint() const [member function] + cls.add_method('IsPointToPoint', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::McpsDataIndication(ns3::McpsDataIndicationParams params, ns3::Ptr pkt) [member function] + cls.add_method('McpsDataIndication', + 'void', + [param('ns3::McpsDataIndicationParams', 'params'), param('ns3::Ptr< ns3::Packet >', 'pkt')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::NeedsArp() const [member function] + cls.add_method('NeedsArp', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::Send(ns3::Ptr 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::SendFrom(ns3::Ptr 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetAddress(ns3::Address address) [member function] + cls.add_method('SetAddress', + 'void', + [param('ns3::Address', 'address')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetChannel(ns3::Ptr channel) [member function] + cls.add_method('SetChannel', + 'void', + [param('ns3::Ptr< ns3::SpectrumChannel >', 'channel')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetCsmaCa(ns3::Ptr csmaca) [member function] + cls.add_method('SetCsmaCa', + 'void', + [param('ns3::Ptr< ns3::LrWpanCsmaCa >', 'csmaca')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetIfIndex(uint32_t const index) [member function] + cls.add_method('SetIfIndex', + 'void', + [param('uint32_t const', 'index')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetMac(ns3::Ptr mac) [member function] + cls.add_method('SetMac', + 'void', + [param('ns3::Ptr< ns3::LrWpanMac >', 'mac')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::SetMtu(uint16_t const mtu) [member function] + cls.add_method('SetMtu', + 'bool', + [param('uint16_t const', 'mtu')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetNode(ns3::Ptr node) [member function] + cls.add_method('SetNode', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetPhy(ns3::Ptr phy) [member function] + cls.add_method('SetPhy', + 'void', + [param('ns3::Ptr< ns3::LrWpanPhy >', 'phy')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetPromiscReceiveCallback(ns3::Callback,ns3::Ptr,short unsigned int,const ns3::Address&,const ns3::Address&,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 >, short unsigned int, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'cb')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetReceiveCallback(ns3::Callback, ns3::Ptr, 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::SupportsSendFrom() const [member function] + cls.add_method('SupportsSendFrom', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='private', is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::DoInitialize() [member function] + cls.add_method('DoInitialize', + 'void', + [], + visibility='private', is_virtual=True) + return + +def register_Ns3HashImplementation_methods(root_module, cls): + ## hash-function.h (module 'core'): ns3::Hash::Implementation::Implementation(ns3::Hash::Implementation const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Implementation const &', 'arg0')]) + ## hash-function.h (module 'core'): ns3::Hash::Implementation::Implementation() [constructor] + cls.add_constructor([]) + ## hash-function.h (module 'core'): uint32_t ns3::Hash::Implementation::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_pure_virtual=True, is_virtual=True) + ## hash-function.h (module 'core'): uint64_t ns3::Hash::Implementation::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): void ns3::Hash::Implementation::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_pure_virtual=True, is_virtual=True) + return + +def register_Ns3HashFunctionFnv1a_methods(root_module, cls): + ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a::Fnv1a(ns3::Hash::Function::Fnv1a const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Fnv1a const &', 'arg0')]) + ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a::Fnv1a() [constructor] + cls.add_constructor([]) + ## hash-fnv.h (module 'core'): uint32_t ns3::Hash::Function::Fnv1a::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-fnv.h (module 'core'): uint64_t ns3::Hash::Function::Fnv1a::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-fnv.h (module 'core'): void ns3::Hash::Function::Fnv1a::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_Ns3HashFunctionHash32_methods(root_module, cls): + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32::Hash32(ns3::Hash::Function::Hash32 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Hash32 const &', 'arg0')]) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32::Hash32(ns3::Hash::Hash32Function_ptr hp) [constructor] + cls.add_constructor([param('ns3::Hash::Hash32Function_ptr', 'hp')]) + ## hash-function.h (module 'core'): uint32_t ns3::Hash::Function::Hash32::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): void ns3::Hash::Function::Hash32::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_Ns3HashFunctionHash64_methods(root_module, cls): + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64::Hash64(ns3::Hash::Function::Hash64 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Hash64 const &', 'arg0')]) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64::Hash64(ns3::Hash::Hash64Function_ptr hp) [constructor] + cls.add_constructor([param('ns3::Hash::Hash64Function_ptr', 'hp')]) + ## hash-function.h (module 'core'): uint32_t ns3::Hash::Function::Hash64::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): uint64_t ns3::Hash::Function::Hash64::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): void ns3::Hash::Function::Hash64::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_Ns3HashFunctionMurmur3_methods(root_module, cls): + ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3::Murmur3(ns3::Hash::Function::Murmur3 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Murmur3 const &', 'arg0')]) + ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3::Murmur3() [constructor] + cls.add_constructor([]) + ## hash-murmur3.h (module 'core'): uint32_t ns3::Hash::Function::Murmur3::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-murmur3.h (module 'core'): uint64_t ns3::Hash::Function::Murmur3::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-murmur3.h (module 'core'): void ns3::Hash::Function::Murmur3::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_functions(root_module): + module = root_module + register_functions_ns3_FatalImpl(module.get_submodule('FatalImpl'), root_module) + register_functions_ns3_Hash(module.get_submodule('Hash'), root_module) + return + +def register_functions_ns3_FatalImpl(module, root_module): + return + +def register_functions_ns3_Hash(module, root_module): + register_functions_ns3_Hash_Function(module.get_submodule('Function'), root_module) + return + +def register_functions_ns3_Hash_Function(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() + diff -Naur ns-3.19/src/lr-wpan/bindings/modulegen__gcc_LP64.py ns-3.20/src/lr-wpan/bindings/modulegen__gcc_LP64.py --- ns-3.19/src/lr-wpan/bindings/modulegen__gcc_LP64.py 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/bindings/modulegen__gcc_LP64.py 2014-06-17 10:33:13.892995969 -0700 @@ -0,0 +1,5861 @@ +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.lr_wpan', cpp_namespace='::ns3') + return root_module + +def register_types(module): + root_module = module.get_root() + + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyEnumeration [enumeration] + module.add_enum('LrWpanPhyEnumeration', ['IEEE_802_15_4_PHY_BUSY', 'IEEE_802_15_4_PHY_BUSY_RX', 'IEEE_802_15_4_PHY_BUSY_TX', 'IEEE_802_15_4_PHY_FORCE_TRX_OFF', 'IEEE_802_15_4_PHY_IDLE', 'IEEE_802_15_4_PHY_INVALID_PARAMETER', 'IEEE_802_15_4_PHY_RX_ON', 'IEEE_802_15_4_PHY_SUCCESS', 'IEEE_802_15_4_PHY_TRX_OFF', 'IEEE_802_15_4_PHY_TX_ON', 'IEEE_802_15_4_PHY_UNSUPPORTED_ATTRIBUTE', 'IEEE_802_15_4_PHY_READ_ONLY', 'IEEE_802_15_4_PHY_UNSPECIFIED']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanTxOption [enumeration] + module.add_enum('LrWpanTxOption', ['TX_OPTION_NONE', 'TX_OPTION_ACK', 'TX_OPTION_GTS', 'TX_OPTION_INDIRECT']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMcpsDataConfirmStatus [enumeration] + module.add_enum('LrWpanMcpsDataConfirmStatus', ['IEEE_802_15_4_SUCCESS', 'IEEE_802_15_4_TRANSACTION_OVERFLOW', 'IEEE_802_15_4_TRANSACTION_EXPIRED', 'IEEE_802_15_4_CHANNEL_ACCESS_FAILURE', 'IEEE_802_15_4_INVALID_ADDRESS', 'IEEE_802_15_4_INVALID_GTS', 'IEEE_802_15_4_NO_ACK', 'IEEE_802_15_4_COUNTER_ERROR', 'IEEE_802_15_4_FRAME_TOO_LONG', 'IEEE_802_15_4_UNAVAILABLE_KEY', 'IEEE_802_15_4_UNSUPPORTED_SECURITY', 'IEEE_802_15_4_INVALID_PARAMETER']) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPibAttributeIdentifier [enumeration] + module.add_enum('LrWpanPibAttributeIdentifier', ['phyCurrentChannel', 'phyChannelsSupported', 'phyTransmitPower', 'phyCCAMode', 'phyCurrentPage', 'phyMaxFrameDuration', 'phySHRDuration', 'phySymbolsPerOctet']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMacState [enumeration] + module.add_enum('LrWpanMacState', ['MAC_IDLE', 'MAC_CSMA', 'MAC_SENDING', 'MAC_ACK_PENDING', 'CHANNEL_ACCESS_FAILURE', 'CHANNEL_IDLE', 'SET_PHY_TX_ON']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanAssociationStatus [enumeration] + module.add_enum('LrWpanAssociationStatus', ['ASSOCIATED', 'PAN_AT_CAPACITY', 'PAN_ACCESS_DENIED', 'ASSOCIATED_WITHOUT_ADDRESS', 'DISASSOCIATED']) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyOption [enumeration] + module.add_enum('LrWpanPhyOption', ['IEEE_802_15_4_868MHZ_BPSK', 'IEEE_802_15_4_915MHZ_BPSK', 'IEEE_802_15_4_868MHZ_ASK', 'IEEE_802_15_4_915MHZ_ASK', 'IEEE_802_15_4_868MHZ_OQPSK', 'IEEE_802_15_4_915MHZ_OQPSK', 'IEEE_802_15_4_2_4GHZ_OQPSK', 'IEEE_802_15_4_INVALID_PHY_OPTION']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanAddressMode [enumeration] + module.add_enum('LrWpanAddressMode', ['NO_PANID_ADDR', 'ADDR_MODE_RESERVED', 'SHORT_ADDR', 'EXT_ADDR']) + ## 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') + ## event-id.h (module 'core'): ns3::EventId [class] + module.add_class('EventId', import_from_module='ns.core') + ## hash.h (module 'core'): ns3::Hasher [class] + module.add_class('Hasher', 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') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower [struct] + module.add_class('LrWpanEdPower') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates [struct] + module.add_class('LrWpanPhyDataAndSymbolRates') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes [struct] + module.add_class('LrWpanPhyPibAttributes') + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber [struct] + module.add_class('LrWpanPhyPpduHeaderSymbolNumber') + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::LrWpanSpectrumValueHelper [class] + module.add_class('LrWpanSpectrumValueHelper') + ## mac16-address.h (module 'network'): ns3::Mac16Address [class] + module.add_class('Mac16Address', import_from_module='ns.network') + ## mac16-address.h (module 'network'): ns3::Mac16Address [class] + root_module['ns3::Mac16Address'].implicitly_converts_to(root_module['ns3::Address']) + ## mac64-address.h (module 'network'): ns3::Mac64Address [class] + module.add_class('Mac64Address', import_from_module='ns.network') + ## mac64-address.h (module 'network'): ns3::Mac64Address [class] + root_module['ns3::Mac64Address'].implicitly_converts_to(root_module['ns3::Address']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams [struct] + module.add_class('McpsDataConfirmParams') + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams [struct] + module.add_class('McpsDataIndicationParams') + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams [struct] + module.add_class('McpsDataRequestParams') + ## 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']) + ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData_e [enumeration] + module.add_enum('TagData_e', ['MAX_SIZE'], outer_class=root_module['ns3::PacketTagList::TagData'], import_from_module='ns.network') + ## 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', 'DLT_IEEE802_15_4'], 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') + ## sequence-number.h (module 'network'): ns3::SequenceNumber [class] + module.add_class('SequenceNumber8', import_from_module='ns.network') + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount [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') + ## 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') + ## nstime.h (module 'core'): ns3::TimeWithUnit [class] + module.add_class('TimeWithUnit', import_from_module='ns.core') + ## 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') + ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] + module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::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']) + ## header.h (module 'network'): ns3::Header [class] + module.add_class('Header', import_from_module='ns.network', parent=root_module['ns3::Chunk']) + ## lr-wpan-helper.h (module 'lr-wpan'): ns3::LrWpanHelper [class] + module.add_class('LrWpanHelper', parent=[root_module['ns3::PcapHelperForDevice'], root_module['ns3::AsciiTraceHelperForDevice']]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag [class] + module.add_class('LrWpanLqiTag', parent=root_module['ns3::Tag']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader [class] + module.add_class('LrWpanMacHeader', parent=root_module['ns3::Header']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacType [enumeration] + module.add_enum('LrWpanMacType', ['LRWPAN_MAC_BEACON', 'LRWPAN_MAC_DATA', 'LRWPAN_MAC_ACKNOWLEDGMENT', 'LRWPAN_MAC_COMMAND', 'LRWPAN_MAC_RESERVED'], outer_class=root_module['ns3::LrWpanMacHeader']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::AddrModeType [enumeration] + module.add_enum('AddrModeType', ['NOADDR', 'RESADDR', 'SHORTADDR', 'EXTADDR'], outer_class=root_module['ns3::LrWpanMacHeader']) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::KeyIdModeType [enumeration] + module.add_enum('KeyIdModeType', ['IMPLICIT', 'NOKEYSOURCE', 'SHORTKEYSOURCE', 'LONGKEYSOURCE'], outer_class=root_module['ns3::LrWpanMacHeader']) + ## 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeAccessor', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeChecker', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeValue', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::CallbackImplBase', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::EventImpl', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Hash::Implementation', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, template_parameters=['ns3::LrWpanInterferenceHelper', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::NixVector', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::OutputStreamWrapper', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Packet', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::SpectrumSignalParameters', 'ns3::empty', 'ns3::DefaultDeleter'], 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 > [class] + module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::TraceSourceAccessor', 'ns3::empty', 'ns3::DefaultDeleter'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) + ## spectrum-phy.h (module 'spectrum'): ns3::SpectrumPhy [class] + module.add_class('SpectrumPhy', import_from_module='ns.spectrum', parent=root_module['ns3::Object']) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters [struct] + module.add_class('SpectrumSignalParameters', import_from_module='ns.spectrum', parent=root_module['ns3::SimpleRefCount< ns3::SpectrumSignalParameters, ns3::empty, ns3::DefaultDeleter >']) + ## 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', ['Y', 'D', 'H', 'MIN', '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 >']) + ## 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 >']) + ## 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 >']) + ## 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 >']) + ## 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 >']) + ## callback.h (module 'core'): ns3::CallbackValue [class] + module.add_class('CallbackValue', import_from_module='ns.core', 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']) + ## 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 >']) + ## 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']) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::LrWpanCsmaCa [class] + module.add_class('LrWpanCsmaCa', parent=root_module['ns3::Object']) + ## lr-wpan-error-model.h (module 'lr-wpan'): ns3::LrWpanErrorModel [class] + module.add_class('LrWpanErrorModel', parent=root_module['ns3::Object']) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::LrWpanInterferenceHelper [class] + module.add_class('LrWpanInterferenceHelper', parent=root_module['ns3::SimpleRefCount< ns3::LrWpanInterferenceHelper, ns3::empty, ns3::DefaultDeleter >']) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac [class] + module.add_class('LrWpanMac', parent=root_module['ns3::Object']) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer [class] + module.add_class('LrWpanMacTrailer', parent=root_module['ns3::Trailer']) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy [class] + module.add_class('LrWpanPhy', parent=root_module['ns3::SpectrumPhy']) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters [struct] + module.add_class('LrWpanSpectrumSignalParameters', parent=root_module['ns3::SpectrumSignalParameters']) + ## mac16-address.h (module 'network'): ns3::Mac16AddressChecker [class] + module.add_class('Mac16AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue [class] + module.add_class('Mac16AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) + ## mac64-address.h (module 'network'): ns3::Mac64AddressChecker [class] + module.add_class('Mac64AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue [class] + module.add_class('Mac64AddressValue', 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 >']) + ## 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 >']) + ## 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 >']) + ## 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']) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::LrWpanNetDevice [class] + module.add_class('LrWpanNetDevice', parent=root_module['ns3::NetDevice']) + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeCcaConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeCcaConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeCcaConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeEdConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeEdConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeEdConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, unsigned int, ns3::Ptr< ns3::Packet >, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PdDataIndicationCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, unsigned int, ns3::Ptr< ns3::Packet >, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PdDataIndicationCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, unsigned int, ns3::Ptr< ns3::Packet >, unsigned char, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PdDataIndicationCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >', u'ns3::SequenceNumber16') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >*', u'ns3::SequenceNumber16*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< short unsigned int, short int >&', u'ns3::SequenceNumber16&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >', u'ns3::SequenceNumber32') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >*', u'ns3::SequenceNumber32*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned int, int >&', u'ns3::SequenceNumber32&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanMacState, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::LrWpanMacStateCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanMacState, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::LrWpanMacStateCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanMacState, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::LrWpanMacStateCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::LrWpanPhyPibAttributes *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeGetAttributeConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::LrWpanPhyPibAttributes *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeGetAttributeConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::LrWpanPhyPibAttributes *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeGetAttributeConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PdDataConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PdDataConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PdDataConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataIndicationParams, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::McpsDataIndicationCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataIndicationParams, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::McpsDataIndicationCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataIndicationParams, ns3::Ptr< ns3::Packet >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::McpsDataIndicationCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataConfirmParams, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::McpsDataConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataConfirmParams, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::McpsDataConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::McpsDataConfirmParams, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::McpsDataConfirmCallback&') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >', u'ns3::SequenceNumber8') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >*', u'ns3::SequenceNumber8*') + typehandlers.add_type_alias(u'ns3::SequenceNumber< unsigned char, signed char >&', u'ns3::SequenceNumber8&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeSetAttributeConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeSetAttributeConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::LrWpanPibAttributeIdentifier, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeSetAttributeConfirmCallback&') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', u'ns3::PlmeSetTRXStateConfirmCallback') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >*', u'ns3::PlmeSetTRXStateConfirmCallback*') + typehandlers.add_type_alias(u'ns3::Callback< void, ns3::LrWpanPhyEnumeration, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >&', u'ns3::PlmeSetTRXStateConfirmCallback&') + + ## Register a nested module for the namespace FatalImpl + + nested_module = module.add_cpp_namespace('FatalImpl') + register_types_ns3_FatalImpl(nested_module) + + + ## Register a nested module for the namespace Hash + + nested_module = module.add_cpp_namespace('Hash') + register_types_ns3_Hash(nested_module) + + +def register_types_ns3_FatalImpl(module): + root_module = module.get_root() + + +def register_types_ns3_Hash(module): + root_module = module.get_root() + + ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] + module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') + typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') + typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') + + ## Register a nested module for the namespace Function + + nested_module = module.add_cpp_namespace('Function') + register_types_ns3_Hash_Function(nested_module) + + +def register_types_ns3_Hash_Function(module): + root_module = module.get_root() + + ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a [class] + module.add_class('Fnv1a', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32 [class] + module.add_class('Hash32', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64 [class] + module.add_class('Hash64', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3 [class] + module.add_class('Murmur3', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) + +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_Ns3EventId_methods(root_module, root_module['ns3::EventId']) + register_Ns3Hasher_methods(root_module, root_module['ns3::Hasher']) + 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_Ns3LrWpanEdPower_methods(root_module, root_module['ns3::LrWpanEdPower']) + register_Ns3LrWpanPhyDataAndSymbolRates_methods(root_module, root_module['ns3::LrWpanPhyDataAndSymbolRates']) + register_Ns3LrWpanPhyPibAttributes_methods(root_module, root_module['ns3::LrWpanPhyPibAttributes']) + register_Ns3LrWpanPhyPpduHeaderSymbolNumber_methods(root_module, root_module['ns3::LrWpanPhyPpduHeaderSymbolNumber']) + register_Ns3LrWpanSpectrumValueHelper_methods(root_module, root_module['ns3::LrWpanSpectrumValueHelper']) + register_Ns3Mac16Address_methods(root_module, root_module['ns3::Mac16Address']) + register_Ns3Mac64Address_methods(root_module, root_module['ns3::Mac64Address']) + register_Ns3McpsDataConfirmParams_methods(root_module, root_module['ns3::McpsDataConfirmParams']) + register_Ns3McpsDataIndicationParams_methods(root_module, root_module['ns3::McpsDataIndicationParams']) + register_Ns3McpsDataRequestParams_methods(root_module, root_module['ns3::McpsDataRequestParams']) + 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_Ns3SequenceNumber8_methods(root_module, root_module['ns3::SequenceNumber8']) + 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_Ns3Tag_methods(root_module, root_module['ns3::Tag']) + register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) + register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) + 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_Ns3Header_methods(root_module, root_module['ns3::Header']) + register_Ns3LrWpanHelper_methods(root_module, root_module['ns3::LrWpanHelper']) + register_Ns3LrWpanLqiTag_methods(root_module, root_module['ns3::LrWpanLqiTag']) + register_Ns3LrWpanMacHeader_methods(root_module, root_module['ns3::LrWpanMacHeader']) + 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 >']) + register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3LrWpanInterferenceHelper_Ns3Empty_Ns3DefaultDeleter__lt__ns3LrWpanInterferenceHelper__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::LrWpanInterferenceHelper, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3SpectrumSignalParameters_Ns3Empty_Ns3DefaultDeleter__lt__ns3SpectrumSignalParameters__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::SpectrumSignalParameters, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter >']) + register_Ns3SpectrumPhy_methods(root_module, root_module['ns3::SpectrumPhy']) + register_Ns3SpectrumSignalParameters_methods(root_module, root_module['ns3::SpectrumSignalParameters']) + 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_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue']) + register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) + 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_Ns3LrWpanCsmaCa_methods(root_module, root_module['ns3::LrWpanCsmaCa']) + register_Ns3LrWpanErrorModel_methods(root_module, root_module['ns3::LrWpanErrorModel']) + register_Ns3LrWpanInterferenceHelper_methods(root_module, root_module['ns3::LrWpanInterferenceHelper']) + register_Ns3LrWpanMac_methods(root_module, root_module['ns3::LrWpanMac']) + register_Ns3LrWpanMacTrailer_methods(root_module, root_module['ns3::LrWpanMacTrailer']) + register_Ns3LrWpanPhy_methods(root_module, root_module['ns3::LrWpanPhy']) + register_Ns3LrWpanSpectrumSignalParameters_methods(root_module, root_module['ns3::LrWpanSpectrumSignalParameters']) + register_Ns3Mac16AddressChecker_methods(root_module, root_module['ns3::Mac16AddressChecker']) + register_Ns3Mac16AddressValue_methods(root_module, root_module['ns3::Mac16AddressValue']) + register_Ns3Mac64AddressChecker_methods(root_module, root_module['ns3::Mac64AddressChecker']) + register_Ns3Mac64AddressValue_methods(root_module, root_module['ns3::Mac64AddressValue']) + 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_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_Ns3LrWpanNetDevice_methods(root_module, root_module['ns3::LrWpanNetDevice']) + register_Ns3HashImplementation_methods(root_module, root_module['ns3::Hash::Implementation']) + register_Ns3HashFunctionFnv1a_methods(root_module, root_module['ns3::Hash::Function::Fnv1a']) + register_Ns3HashFunctionHash32_methods(root_module, root_module['ns3::Hash::Function::Hash32']) + register_Ns3HashFunctionHash64_methods(root_module, root_module['ns3::Hash::Function::Hash64']) + register_Ns3HashFunctionMurmur3_methods(root_module, root_module['ns3::Hash::Function::Murmur3']) + 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::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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 file, std::string context, ns3::Ptr 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 file, ns3::Ptr 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 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 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 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 stream, ns3::Ptr 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 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 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 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 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 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 stream, std::string prefix, ns3::Ptr 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 checker, ns3::Ptr 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::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::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::AttributeConstructionList::Find(ns3::Ptr 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'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] + cls.add_method('PeekU8', + 'uint8_t', + []) + ## 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'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] + cls.add_method('Read', + 'void', + [param('ns3::Buffer::Iterator', 'start'), 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::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 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_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 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_Ns3Hasher_methods(root_module, cls): + ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Hasher const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hasher const &', 'arg0')]) + ## hash.h (module 'core'): ns3::Hasher::Hasher() [constructor] + cls.add_constructor([]) + ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Ptr hp) [constructor] + cls.add_constructor([param('ns3::Ptr< ns3::Hash::Implementation >', 'hp')]) + ## hash.h (module 'core'): uint32_t ns3::Hasher::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')]) + ## hash.h (module 'core'): uint32_t ns3::Hasher::GetHash32(std::string const s) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('std::string const', 's')]) + ## hash.h (module 'core'): uint64_t ns3::Hasher::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')]) + ## hash.h (module 'core'): uint64_t ns3::Hasher::GetHash64(std::string const s) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('std::string const', 's')]) + ## hash.h (module 'core'): ns3::Hasher & ns3::Hasher::clear() [member function] + cls.add_method('clear', + 'ns3::Hasher &', + []) + 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::IsDocumentation() const [member function] + cls.add_method('IsDocumentation', + '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() const [member function] + cls.add_method('IsIpv4MappedAddress', + 'bool', + [], + is_const=True) + ## 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::Mac16Address addr, ns3::Ipv6Address prefix) [member function] + cls.add_method('MakeAutoconfiguredAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac16Address', 'addr'), param('ns3::Ipv6Address', 'prefix')], + is_static=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::MakeAutoconfiguredAddress(ns3::Mac64Address addr, ns3::Ipv6Address prefix) [member function] + cls.add_method('MakeAutoconfiguredAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac64Address', 'addr'), param('ns3::Ipv6Address', 'prefix')], + is_static=True) + ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredLinkLocalAddress(ns3::Mac16Address mac) [member function] + cls.add_method('MakeAutoconfiguredLinkLocalAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac16Address', 'mac')], + 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::MakeAutoconfiguredLinkLocalAddress(ns3::Mac64Address mac) [member function] + cls.add_method('MakeAutoconfiguredLinkLocalAddress', + 'ns3::Ipv6Address', + [param('ns3::Mac64Address', '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_Ns3LrWpanEdPower_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::LrWpanEdPower(ns3::LrWpanEdPower const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanEdPower const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::LrWpanEdPower() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::averagePower [variable] + cls.add_instance_attribute('averagePower', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::lastUpdate [variable] + cls.add_instance_attribute('lastUpdate', 'ns3::Time', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanEdPower::measurementLength [variable] + cls.add_instance_attribute('measurementLength', 'ns3::Time', is_const=False) + return + +def register_Ns3LrWpanPhyDataAndSymbolRates_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::LrWpanPhyDataAndSymbolRates() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::LrWpanPhyDataAndSymbolRates(ns3::LrWpanPhyDataAndSymbolRates const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanPhyDataAndSymbolRates const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::bitRate [variable] + cls.add_instance_attribute('bitRate', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyDataAndSymbolRates::symbolRate [variable] + cls.add_instance_attribute('symbolRate', 'double', is_const=False) + return + +def register_Ns3LrWpanPhyPibAttributes_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::LrWpanPhyPibAttributes() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::LrWpanPhyPibAttributes(ns3::LrWpanPhyPibAttributes const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanPhyPibAttributes const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyCCAMode [variable] + cls.add_instance_attribute('phyCCAMode', 'uint8_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyChannelsSupported [variable] + cls.add_instance_attribute('phyChannelsSupported', 'uint32_t [ 32 ]', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyCurrentChannel [variable] + cls.add_instance_attribute('phyCurrentChannel', 'uint8_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyCurrentPage [variable] + cls.add_instance_attribute('phyCurrentPage', 'uint32_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyMaxFrameDuration [variable] + cls.add_instance_attribute('phyMaxFrameDuration', 'uint32_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phySHRDuration [variable] + cls.add_instance_attribute('phySHRDuration', 'uint32_t', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phySymbolsPerOctet [variable] + cls.add_instance_attribute('phySymbolsPerOctet', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPibAttributes::phyTransmitPower [variable] + cls.add_instance_attribute('phyTransmitPower', 'uint8_t', is_const=False) + return + +def register_Ns3LrWpanPhyPpduHeaderSymbolNumber_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::LrWpanPhyPpduHeaderSymbolNumber() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::LrWpanPhyPpduHeaderSymbolNumber(ns3::LrWpanPhyPpduHeaderSymbolNumber const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanPhyPpduHeaderSymbolNumber const &', 'arg0')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::phr [variable] + cls.add_instance_attribute('phr', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::shrPreamble [variable] + cls.add_instance_attribute('shrPreamble', 'double', is_const=False) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhyPpduHeaderSymbolNumber::shrSfd [variable] + cls.add_instance_attribute('shrSfd', 'double', is_const=False) + return + +def register_Ns3LrWpanSpectrumValueHelper_methods(root_module, cls): + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::LrWpanSpectrumValueHelper::LrWpanSpectrumValueHelper(ns3::LrWpanSpectrumValueHelper const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanSpectrumValueHelper const &', 'arg0')]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::LrWpanSpectrumValueHelper::LrWpanSpectrumValueHelper() [constructor] + cls.add_constructor([]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanSpectrumValueHelper::CreateNoisePowerSpectralDensity(uint32_t channel) [member function] + cls.add_method('CreateNoisePowerSpectralDensity', + 'ns3::Ptr< ns3::SpectrumValue >', + [param('uint32_t', 'channel')]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanSpectrumValueHelper::CreateTxPowerSpectralDensity(double txPower, uint32_t channel) [member function] + cls.add_method('CreateTxPowerSpectralDensity', + 'ns3::Ptr< ns3::SpectrumValue >', + [param('double', 'txPower'), param('uint32_t', 'channel')]) + ## lr-wpan-spectrum-value-helper.h (module 'lr-wpan'): static double ns3::LrWpanSpectrumValueHelper::TotalAvgPower(ns3::Ptr psd) [member function] + cls.add_method('TotalAvgPower', + 'double', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'psd')], + is_static=True) + return + +def register_Ns3Mac16Address_methods(root_module, cls): + cls.add_binary_comparison_operator('<') + cls.add_binary_comparison_operator('!=') + cls.add_output_stream_operator() + cls.add_binary_comparison_operator('==') + ## mac16-address.h (module 'network'): ns3::Mac16Address::Mac16Address(ns3::Mac16Address const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac16Address const &', 'arg0')]) + ## mac16-address.h (module 'network'): ns3::Mac16Address::Mac16Address() [constructor] + cls.add_constructor([]) + ## mac16-address.h (module 'network'): ns3::Mac16Address::Mac16Address(char const * str) [constructor] + cls.add_constructor([param('char const *', 'str')]) + ## mac16-address.h (module 'network'): static ns3::Mac16Address ns3::Mac16Address::Allocate() [member function] + cls.add_method('Allocate', + 'ns3::Mac16Address', + [], + is_static=True) + ## mac16-address.h (module 'network'): static ns3::Mac16Address ns3::Mac16Address::ConvertFrom(ns3::Address const & address) [member function] + cls.add_method('ConvertFrom', + 'ns3::Mac16Address', + [param('ns3::Address const &', 'address')], + is_static=True) + ## mac16-address.h (module 'network'): void ns3::Mac16Address::CopyFrom(uint8_t const * buffer) [member function] + cls.add_method('CopyFrom', + 'void', + [param('uint8_t const *', 'buffer')]) + ## mac16-address.h (module 'network'): void ns3::Mac16Address::CopyTo(uint8_t * buffer) const [member function] + cls.add_method('CopyTo', + 'void', + [param('uint8_t *', 'buffer')], + is_const=True) + ## mac16-address.h (module 'network'): static bool ns3::Mac16Address::IsMatchingType(ns3::Address const & address) [member function] + cls.add_method('IsMatchingType', + 'bool', + [param('ns3::Address const &', 'address')], + is_static=True) + return + +def register_Ns3Mac64Address_methods(root_module, cls): + cls.add_binary_comparison_operator('<') + cls.add_binary_comparison_operator('!=') + cls.add_output_stream_operator() + cls.add_binary_comparison_operator('==') + ## mac64-address.h (module 'network'): ns3::Mac64Address::Mac64Address(ns3::Mac64Address const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac64Address const &', 'arg0')]) + ## mac64-address.h (module 'network'): ns3::Mac64Address::Mac64Address() [constructor] + cls.add_constructor([]) + ## mac64-address.h (module 'network'): ns3::Mac64Address::Mac64Address(char const * str) [constructor] + cls.add_constructor([param('char const *', 'str')]) + ## mac64-address.h (module 'network'): static ns3::Mac64Address ns3::Mac64Address::Allocate() [member function] + cls.add_method('Allocate', + 'ns3::Mac64Address', + [], + is_static=True) + ## mac64-address.h (module 'network'): static ns3::Mac64Address ns3::Mac64Address::ConvertFrom(ns3::Address const & address) [member function] + cls.add_method('ConvertFrom', + 'ns3::Mac64Address', + [param('ns3::Address const &', 'address')], + is_static=True) + ## mac64-address.h (module 'network'): void ns3::Mac64Address::CopyFrom(uint8_t const * buffer) [member function] + cls.add_method('CopyFrom', + 'void', + [param('uint8_t const *', 'buffer')]) + ## mac64-address.h (module 'network'): void ns3::Mac64Address::CopyTo(uint8_t * buffer) const [member function] + cls.add_method('CopyTo', + 'void', + [param('uint8_t *', 'buffer')], + is_const=True) + ## mac64-address.h (module 'network'): static bool ns3::Mac64Address::IsMatchingType(ns3::Address const & address) [member function] + cls.add_method('IsMatchingType', + 'bool', + [param('ns3::Address const &', 'address')], + is_static=True) + return + +def register_Ns3McpsDataConfirmParams_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::McpsDataConfirmParams() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::McpsDataConfirmParams(ns3::McpsDataConfirmParams const & arg0) [copy constructor] + cls.add_constructor([param('ns3::McpsDataConfirmParams const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::m_msduHandle [variable] + cls.add_instance_attribute('m_msduHandle', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataConfirmParams::m_status [variable] + cls.add_instance_attribute('m_status', 'ns3::LrWpanMcpsDataConfirmStatus', is_const=False) + return + +def register_Ns3McpsDataIndicationParams_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::McpsDataIndicationParams() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::McpsDataIndicationParams(ns3::McpsDataIndicationParams const & arg0) [copy constructor] + cls.add_constructor([param('ns3::McpsDataIndicationParams const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dsn [variable] + cls.add_instance_attribute('m_dsn', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dstAddr [variable] + cls.add_instance_attribute('m_dstAddr', 'ns3::Mac16Address', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dstAddrMode [variable] + cls.add_instance_attribute('m_dstAddrMode', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_dstPanId [variable] + cls.add_instance_attribute('m_dstPanId', 'uint16_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_mpduLinkQuality [variable] + cls.add_instance_attribute('m_mpduLinkQuality', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_srcAddr [variable] + cls.add_instance_attribute('m_srcAddr', 'ns3::Mac16Address', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_srcAddrMode [variable] + cls.add_instance_attribute('m_srcAddrMode', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataIndicationParams::m_srcPanId [variable] + cls.add_instance_attribute('m_srcPanId', 'uint16_t', is_const=False) + return + +def register_Ns3McpsDataRequestParams_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::McpsDataRequestParams(ns3::McpsDataRequestParams const & arg0) [copy constructor] + cls.add_constructor([param('ns3::McpsDataRequestParams const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::McpsDataRequestParams() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_dstAddr [variable] + cls.add_instance_attribute('m_dstAddr', 'ns3::Mac16Address', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_dstAddrMode [variable] + cls.add_instance_attribute('m_dstAddrMode', 'ns3::LrWpanAddressMode', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_dstPanId [variable] + cls.add_instance_attribute('m_dstPanId', 'uint16_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_msduHandle [variable] + cls.add_instance_attribute('m_msduHandle', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_srcAddrMode [variable] + cls.add_instance_attribute('m_srcAddrMode', 'ns3::LrWpanAddressMode', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::McpsDataRequestParams::m_txOptions [variable] + cls.add_instance_attribute('m_txOptions', 'uint8_t', is_const=False) + 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 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 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*,std::vector, std::allocator > > > 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*,std::vector, std::allocator > > > 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::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 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 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*,std::vector, std::allocator > > > 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*,std::vector, std::allocator > > > 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::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::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', + []) + ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Replace(ns3::Tag & tag) [member function] + cls.add_method('Replace', + 'bool', + [param('ns3::Tag &', 'tag')]) + 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 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 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::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 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 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 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 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_Ns3SequenceNumber8_methods(root_module, cls): + cls.add_binary_comparison_operator('!=') + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber8'], root_module['ns3::SequenceNumber8'], param('ns3::SequenceNumber< unsigned char, signed char > const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::SequenceNumber8'], root_module['ns3::SequenceNumber8'], param('signed char', u'right')) + cls.add_inplace_numeric_operator('+=', param('signed char', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::SequenceNumber8'], root_module['ns3::SequenceNumber8'], param('signed char', u'right')) + cls.add_inplace_numeric_operator('-=', param('signed char', u'right')) + 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('>=') + ## sequence-number.h (module 'network'): ns3::SequenceNumber::SequenceNumber() [constructor] + cls.add_constructor([]) + ## sequence-number.h (module 'network'): ns3::SequenceNumber::SequenceNumber(unsigned char value) [constructor] + cls.add_constructor([param('unsigned char', 'value')]) + ## sequence-number.h (module 'network'): ns3::SequenceNumber::SequenceNumber(ns3::SequenceNumber const & value) [copy constructor] + cls.add_constructor([param('ns3::SequenceNumber< unsigned char, signed char > const &', 'value')]) + ## sequence-number.h (module 'network'): unsigned char ns3::SequenceNumber::GetValue() const [member function] + cls.add_method('GetValue', + 'unsigned char', + [], + is_const=True) + return + +def register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount::SimpleRefCount(ns3::SimpleRefCount 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::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::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 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_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_Ns3TimeWithUnit_methods(root_module, cls): + cls.add_output_stream_operator() + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] + cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) + ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] + cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) + 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 accessor, ns3::Ptr 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 accessor, ns3::Ptr 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 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::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'): uint32_t ns3::TypeId::GetHash() const [member function] + cls.add_method('GetHash', + 'uint32_t', + [], + 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::LookupByHash(uint32_t hash) [member function] + cls.add_method('LookupByHash', + 'ns3::TypeId', + [param('uint32_t', 'hash')], + is_static=True) + ## type-id.h (module 'core'): static bool ns3::TypeId::LookupByHashFailSafe(uint32_t hash, ns3::TypeId * tid) [member function] + cls.add_method('LookupByHashFailSafe', + 'bool', + [param('uint32_t', 'hash'), param('ns3::TypeId *', 'tid')], + is_static=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::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 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('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'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 &', u'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 &', u'right')) + cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) + cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'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(long double v) [constructor] + cls.add_constructor([param('long 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')]) + ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] + cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) + 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_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_Ns3LrWpanHelper_methods(root_module, cls): + ## lr-wpan-helper.h (module 'lr-wpan'): ns3::LrWpanHelper::LrWpanHelper() [constructor] + cls.add_constructor([]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::AddMobility(ns3::Ptr phy, ns3::Ptr m) [member function] + cls.add_method('AddMobility', + 'void', + [param('ns3::Ptr< ns3::LrWpanPhy >', 'phy'), param('ns3::Ptr< ns3::MobilityModel >', 'm')]) + ## lr-wpan-helper.h (module 'lr-wpan'): ns3::NetDeviceContainer ns3::LrWpanHelper::Install(ns3::NodeContainer c) [member function] + cls.add_method('Install', + 'ns3::NetDeviceContainer', + [param('ns3::NodeContainer', 'c')]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::AssociateToPan(ns3::NetDeviceContainer c, uint16_t panId) [member function] + cls.add_method('AssociateToPan', + 'void', + [param('ns3::NetDeviceContainer', 'c'), param('uint16_t', 'panId')]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::EnableLogComponents() [member function] + cls.add_method('EnableLogComponents', + 'void', + []) + ## lr-wpan-helper.h (module 'lr-wpan'): static std::string ns3::LrWpanHelper::LrWpanPhyEnumerationPrinter(ns3::LrWpanPhyEnumeration arg0) [member function] + cls.add_method('LrWpanPhyEnumerationPrinter', + 'std::string', + [param('ns3::LrWpanPhyEnumeration', 'arg0')], + is_static=True) + ## lr-wpan-helper.h (module 'lr-wpan'): static std::string ns3::LrWpanHelper::LrWpanMacStatePrinter(ns3::LrWpanMacState e) [member function] + cls.add_method('LrWpanMacStatePrinter', + 'std::string', + [param('ns3::LrWpanMacState', 'e')], + is_static=True) + ## lr-wpan-helper.h (module 'lr-wpan'): int64_t ns3::LrWpanHelper::AssignStreams(ns3::NetDeviceContainer c, int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('ns3::NetDeviceContainer', 'c'), param('int64_t', 'stream')]) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::EnablePcapInternal(std::string prefix, ns3::Ptr 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) + ## lr-wpan-helper.h (module 'lr-wpan'): void ns3::LrWpanHelper::EnableAsciiInternal(ns3::Ptr stream, std::string prefix, ns3::Ptr 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) + return + +def register_Ns3LrWpanLqiTag_methods(root_module, cls): + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag::LrWpanLqiTag(ns3::LrWpanLqiTag const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanLqiTag const &', 'arg0')]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag::LrWpanLqiTag() [constructor] + cls.add_constructor([]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::LrWpanLqiTag::LrWpanLqiTag(uint8_t lqi) [constructor] + cls.add_constructor([param('uint8_t', 'lqi')]) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Deserialize(ns3::TagBuffer i) [member function] + cls.add_method('Deserialize', + 'void', + [param('ns3::TagBuffer', 'i')], + is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): uint8_t ns3::LrWpanLqiTag::Get() const [member function] + cls.add_method('Get', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): ns3::TypeId ns3::LrWpanLqiTag::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): uint32_t ns3::LrWpanLqiTag::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanLqiTag::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Serialize(ns3::TagBuffer i) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::TagBuffer', 'i')], + is_const=True, is_virtual=True) + ## lr-wpan-lqi-tag.h (module 'lr-wpan'): void ns3::LrWpanLqiTag::Set(uint8_t lqi) [member function] + cls.add_method('Set', + 'void', + [param('uint8_t', 'lqi')]) + return + +def register_Ns3LrWpanMacHeader_methods(root_module, cls): + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacHeader(ns3::LrWpanMacHeader const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanMacHeader const &', 'arg0')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacHeader() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacHeader(ns3::LrWpanMacHeader::LrWpanMacType wpanMacType, uint8_t seqNum) [constructor] + cls.add_constructor([param('ns3::LrWpanMacHeader::LrWpanMacType', 'wpanMacType'), param('uint8_t', 'seqNum')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetDstAddrMode() const [member function] + cls.add_method('GetDstAddrMode', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacHeader::GetDstPanId() const [member function] + cls.add_method('GetDstPanId', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac64Address ns3::LrWpanMacHeader::GetExtDstAddr() const [member function] + cls.add_method('GetExtDstAddr', + 'ns3::Mac64Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac64Address ns3::LrWpanMacHeader::GetExtSrcAddr() const [member function] + cls.add_method('GetExtSrcAddr', + 'ns3::Mac64Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacHeader::GetFrameControl() const [member function] + cls.add_method('GetFrameControl', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetFrameVer() const [member function] + cls.add_method('GetFrameVer', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::GetFrmCounter() const [member function] + cls.add_method('GetFrmCounter', + 'uint32_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetFrmCtrlRes() const [member function] + cls.add_method('GetFrmCtrlRes', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::TypeId ns3::LrWpanMacHeader::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetKeyIdIndex() const [member function] + cls.add_method('GetKeyIdIndex', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetKeyIdMode() const [member function] + cls.add_method('GetKeyIdMode', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::GetKeyIdSrc32() const [member function] + cls.add_method('GetKeyIdSrc32', + 'uint32_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint64_t ns3::LrWpanMacHeader::GetKeyIdSrc64() const [member function] + cls.add_method('GetKeyIdSrc64', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): std::string ns3::LrWpanMacHeader::GetName() const [member function] + cls.add_method('GetName', + 'std::string', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSecControl() const [member function] + cls.add_method('GetSecControl', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSecLevel() const [member function] + cls.add_method('GetSecLevel', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSeqNum() const [member function] + cls.add_method('GetSeqNum', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacHeader::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac16Address ns3::LrWpanMacHeader::GetShortDstAddr() const [member function] + cls.add_method('GetShortDstAddr', + 'ns3::Mac16Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::Mac16Address ns3::LrWpanMacHeader::GetShortSrcAddr() const [member function] + cls.add_method('GetShortSrcAddr', + 'ns3::Mac16Address', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetSrcAddrMode() const [member function] + cls.add_method('GetSrcAddrMode', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacHeader::GetSrcPanId() const [member function] + cls.add_method('GetSrcPanId', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): ns3::LrWpanMacHeader::LrWpanMacType ns3::LrWpanMacHeader::GetType() const [member function] + cls.add_method('GetType', + 'ns3::LrWpanMacHeader::LrWpanMacType', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanMacHeader::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): uint8_t ns3::LrWpanMacHeader::GetsecctrlReserved() const [member function] + cls.add_method('GetsecctrlReserved', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsAckReq() const [member function] + cls.add_method('IsAckReq', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsAcknowledgment() const [member function] + cls.add_method('IsAcknowledgment', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsBeacon() const [member function] + cls.add_method('IsBeacon', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsCommand() const [member function] + cls.add_method('IsCommand', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsData() const [member function] + cls.add_method('IsData', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsFrmPend() const [member function] + cls.add_method('IsFrmPend', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsNoAckReq() const [member function] + cls.add_method('IsNoAckReq', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsNoFrmPend() const [member function] + cls.add_method('IsNoFrmPend', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsNoPanIdComp() const [member function] + cls.add_method('IsNoPanIdComp', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsPanIdComp() const [member function] + cls.add_method('IsPanIdComp', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsSecDisable() const [member function] + cls.add_method('IsSecDisable', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): bool ns3::LrWpanMacHeader::IsSecEnable() const [member function] + cls.add_method('IsSecEnable', + 'bool', + [], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::PrintFrameControl(std::ostream & os) const [member function] + cls.add_method('PrintFrameControl', + 'void', + [param('std::ostream &', 'os')], + is_const=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetAckReq() [member function] + cls.add_method('SetAckReq', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetDstAddrFields(uint16_t panId, ns3::Mac16Address addr) [member function] + cls.add_method('SetDstAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac16Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetDstAddrFields(uint16_t panId, ns3::Mac64Address addr) [member function] + cls.add_method('SetDstAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac64Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetDstAddrMode(uint8_t addrMode) [member function] + cls.add_method('SetDstAddrMode', + 'void', + [param('uint8_t', 'addrMode')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrameControl(uint16_t frameControl) [member function] + cls.add_method('SetFrameControl', + 'void', + [param('uint16_t', 'frameControl')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrameVer(uint8_t ver) [member function] + cls.add_method('SetFrameVer', + 'void', + [param('uint8_t', 'ver')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrmCounter(uint32_t frmCntr) [member function] + cls.add_method('SetFrmCounter', + 'void', + [param('uint32_t', 'frmCntr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrmCtrlRes(uint8_t res) [member function] + cls.add_method('SetFrmCtrlRes', + 'void', + [param('uint8_t', 'res')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetFrmPend() [member function] + cls.add_method('SetFrmPend', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyId(uint8_t keyIndex) [member function] + cls.add_method('SetKeyId', + 'void', + [param('uint8_t', 'keyIndex')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyId(uint32_t keySrc, uint8_t keyIndex) [member function] + cls.add_method('SetKeyId', + 'void', + [param('uint32_t', 'keySrc'), param('uint8_t', 'keyIndex')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyId(uint64_t keySrc, uint8_t keyIndex) [member function] + cls.add_method('SetKeyId', + 'void', + [param('uint64_t', 'keySrc'), param('uint8_t', 'keyIndex')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetKeyIdMode(uint8_t keyIdMode) [member function] + cls.add_method('SetKeyIdMode', + 'void', + [param('uint8_t', 'keyIdMode')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetNoAckReq() [member function] + cls.add_method('SetNoAckReq', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetNoFrmPend() [member function] + cls.add_method('SetNoFrmPend', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetNoPanIdComp() [member function] + cls.add_method('SetNoPanIdComp', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetPanIdComp() [member function] + cls.add_method('SetPanIdComp', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecControl(uint8_t secLevel) [member function] + cls.add_method('SetSecControl', + 'void', + [param('uint8_t', 'secLevel')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecDisable() [member function] + cls.add_method('SetSecDisable', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecEnable() [member function] + cls.add_method('SetSecEnable', + 'void', + []) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSecLevel(uint8_t secLevel) [member function] + cls.add_method('SetSecLevel', + 'void', + [param('uint8_t', 'secLevel')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSeqNum(uint8_t seqNum) [member function] + cls.add_method('SetSeqNum', + 'void', + [param('uint8_t', 'seqNum')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSrcAddrFields(uint16_t panId, ns3::Mac16Address addr) [member function] + cls.add_method('SetSrcAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac16Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSrcAddrFields(uint16_t panId, ns3::Mac64Address addr) [member function] + cls.add_method('SetSrcAddrFields', + 'void', + [param('uint16_t', 'panId'), param('ns3::Mac64Address', 'addr')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetSrcAddrMode(uint8_t addrMode) [member function] + cls.add_method('SetSrcAddrMode', + 'void', + [param('uint8_t', 'addrMode')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetType(ns3::LrWpanMacHeader::LrWpanMacType wpanMacType) [member function] + cls.add_method('SetType', + 'void', + [param('ns3::LrWpanMacHeader::LrWpanMacType', 'wpanMacType')]) + ## lr-wpan-mac-header.h (module 'lr-wpan'): void ns3::LrWpanMacHeader::SetsecctrlReserved(uint8_t res) [member function] + cls.add_method('SetsecctrlReserved', + 'void', + [param('uint8_t', 'res')]) + 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 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::Initialize() [member function] + cls.add_method('Initialize', + '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::DoInitialize() [member function] + cls.add_method('DoInitialize', + '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::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::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::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 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 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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > const & o) [copy constructor] + cls.add_constructor([param('ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter< ns3::Hash::Implementation > > const &', 'o')]) + ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SimpleRefCount__Ns3LrWpanInterferenceHelper_Ns3Empty_Ns3DefaultDeleter__lt__ns3LrWpanInterferenceHelper__gt___methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > const & o) [copy constructor] + cls.add_constructor([param('ns3::SimpleRefCount< ns3::LrWpanInterferenceHelper, ns3::empty, ns3::DefaultDeleter< ns3::LrWpanInterferenceHelper > > const &', 'o')]) + ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SimpleRefCount__Ns3SpectrumSignalParameters_Ns3Empty_Ns3DefaultDeleter__lt__ns3SpectrumSignalParameters__gt___methods(root_module, cls): + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > const & o) [copy constructor] + cls.add_constructor([param('ns3::SimpleRefCount< ns3::SpectrumSignalParameters, ns3::empty, ns3::DefaultDeleter< ns3::SpectrumSignalParameters > > const &', 'o')]) + ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount >::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 >::SimpleRefCount() [constructor] + cls.add_constructor([]) + ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount >::SimpleRefCount(ns3::SimpleRefCount > 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 >::Cleanup() [member function] + cls.add_method('Cleanup', + 'void', + [], + is_static=True) + return + +def register_Ns3SpectrumPhy_methods(root_module, cls): + ## spectrum-phy.h (module 'spectrum'): ns3::SpectrumPhy::SpectrumPhy() [constructor] + cls.add_constructor([]) + ## spectrum-phy.h (module 'spectrum'): static ns3::TypeId ns3::SpectrumPhy::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::SetDevice(ns3::Ptr d) [member function] + cls.add_method('SetDevice', + 'void', + [param('ns3::Ptr< ns3::NetDevice >', 'd')], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetDevice() [member function] + cls.add_method('GetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::SetMobility(ns3::Ptr m) [member function] + cls.add_method('SetMobility', + 'void', + [param('ns3::Ptr< ns3::MobilityModel >', 'm')], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetMobility() [member function] + cls.add_method('GetMobility', + 'ns3::Ptr< ns3::MobilityModel >', + [], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::SetChannel(ns3::Ptr c) [member function] + cls.add_method('SetChannel', + 'void', + [param('ns3::Ptr< ns3::SpectrumChannel >', 'c')], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetRxSpectrumModel() const [member function] + cls.add_method('GetRxSpectrumModel', + 'ns3::Ptr< ns3::SpectrumModel const >', + [], + is_pure_virtual=True, is_const=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): ns3::Ptr ns3::SpectrumPhy::GetRxAntenna() [member function] + cls.add_method('GetRxAntenna', + 'ns3::Ptr< ns3::AntennaModel >', + [], + is_pure_virtual=True, is_virtual=True) + ## spectrum-phy.h (module 'spectrum'): void ns3::SpectrumPhy::StartRx(ns3::Ptr params) [member function] + cls.add_method('StartRx', + 'void', + [param('ns3::Ptr< ns3::SpectrumSignalParameters >', 'params')], + is_pure_virtual=True, is_virtual=True) + return + +def register_Ns3SpectrumSignalParameters_methods(root_module, cls): + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::SpectrumSignalParameters() [constructor] + cls.add_constructor([]) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::SpectrumSignalParameters(ns3::SpectrumSignalParameters const & p) [copy constructor] + cls.add_constructor([param('ns3::SpectrumSignalParameters const &', 'p')]) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::Ptr ns3::SpectrumSignalParameters::Copy() [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::SpectrumSignalParameters >', + [], + is_virtual=True) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::duration [variable] + cls.add_instance_attribute('duration', 'ns3::Time', is_const=False) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::psd [variable] + cls.add_instance_attribute('psd', 'ns3::Ptr< ns3::SpectrumValue >', is_const=False) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::txAntenna [variable] + cls.add_instance_attribute('txAntenna', 'ns3::Ptr< ns3::AntennaModel >', is_const=False) + ## spectrum-signal-parameters.h (module 'spectrum'): ns3::SpectrumSignalParameters::txPhy [variable] + cls.add_instance_attribute('txPhy', 'ns3::Ptr< ns3::SpectrumPhy >', is_const=False) + return + +def register_Ns3Time_methods(root_module, cls): + cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) + cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) + cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'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 &', u'right')) + cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'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'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] + cls.add_method('As', + 'ns3::TimeWithUnit', + [param('ns3::Time::Unit const', 'unit')], + is_const=True) + ## 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::GetDays() const [member function] + cls.add_method('GetDays', + 'double', + [], + is_const=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'): double ns3::Time::GetHours() const [member function] + cls.add_method('GetHours', + 'double', + [], + 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'): double ns3::Time::GetMinutes() const [member function] + cls.add_method('GetMinutes', + 'double', + [], + 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'): double ns3::Time::GetYears() const [member function] + cls.add_method('GetYears', + 'double', + [], + 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 ns3::Time ns3::Time::Max() [member function] + cls.add_method('Max', + 'ns3::Time', + [], + is_static=True) + ## nstime.h (module 'core'): static ns3::Time ns3::Time::Min() [member function] + cls.add_method('Min', + 'ns3::Time', + [], + is_static=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'): static bool ns3::Time::StaticInit() [member function] + cls.add_method('StaticInit', + 'bool', + [], + 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::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::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::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 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 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 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::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 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 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_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::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 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 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_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_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::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 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 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::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 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 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::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 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 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::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 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 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_Ns3LrWpanCsmaCa_methods(root_module, cls): + ## lr-wpan-csmaca.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanCsmaCa::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::LrWpanCsmaCa::LrWpanCsmaCa() [constructor] + cls.add_constructor([]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMac(ns3::Ptr mac) [member function] + cls.add_method('SetMac', + 'void', + [param('ns3::Ptr< ns3::LrWpanMac >', 'mac')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanCsmaCa::GetMac() const [member function] + cls.add_method('GetMac', + 'ns3::Ptr< ns3::LrWpanMac >', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetSlottedCsmaCa() [member function] + cls.add_method('SetSlottedCsmaCa', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetUnSlottedCsmaCa() [member function] + cls.add_method('SetUnSlottedCsmaCa', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): bool ns3::LrWpanCsmaCa::IsSlottedCsmaCa() const [member function] + cls.add_method('IsSlottedCsmaCa', + 'bool', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): bool ns3::LrWpanCsmaCa::IsUnSlottedCsmaCa() const [member function] + cls.add_method('IsUnSlottedCsmaCa', + 'bool', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMacMinBE(uint8_t macMinBE) [member function] + cls.add_method('SetMacMinBE', + 'void', + [param('uint8_t', 'macMinBE')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetMacMinBE() const [member function] + cls.add_method('GetMacMinBE', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMacMaxBE(uint8_t macMaxBE) [member function] + cls.add_method('SetMacMaxBE', + 'void', + [param('uint8_t', 'macMaxBE')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetMacMaxBE() const [member function] + cls.add_method('GetMacMaxBE', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetMacMaxCSMABackoffs(uint8_t macMaxCSMABackoffs) [member function] + cls.add_method('SetMacMaxCSMABackoffs', + 'void', + [param('uint8_t', 'macMaxCSMABackoffs')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetMacMaxCSMABackoffs() const [member function] + cls.add_method('GetMacMaxCSMABackoffs', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetUnitBackoffPeriod(uint64_t unitBackoffPeriod) [member function] + cls.add_method('SetUnitBackoffPeriod', + 'void', + [param('uint64_t', 'unitBackoffPeriod')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint64_t ns3::LrWpanCsmaCa::GetUnitBackoffPeriod() const [member function] + cls.add_method('GetUnitBackoffPeriod', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): ns3::Time ns3::LrWpanCsmaCa::GetTimeToNextSlot() const [member function] + cls.add_method('GetTimeToNextSlot', + 'ns3::Time', + [], + is_const=True) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::Start() [member function] + cls.add_method('Start', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::Cancel() [member function] + cls.add_method('Cancel', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::RandomBackoffDelay() [member function] + cls.add_method('RandomBackoffDelay', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::CanProceed() [member function] + cls.add_method('CanProceed', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::RequestCCA() [member function] + cls.add_method('RequestCCA', + 'void', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::PlmeCcaConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PlmeCcaConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::SetLrWpanMacStateCallback(ns3::LrWpanMacStateCallback macState) [member function] + cls.add_method('SetLrWpanMacStateCallback', + 'void', + [param('ns3::LrWpanMacStateCallback', 'macState')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): int64_t ns3::LrWpanCsmaCa::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## lr-wpan-csmaca.h (module 'lr-wpan'): uint8_t ns3::LrWpanCsmaCa::GetNB() [member function] + cls.add_method('GetNB', + 'uint8_t', + []) + ## lr-wpan-csmaca.h (module 'lr-wpan'): void ns3::LrWpanCsmaCa::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='private', is_virtual=True) + return + +def register_Ns3LrWpanErrorModel_methods(root_module, cls): + ## lr-wpan-error-model.h (module 'lr-wpan'): ns3::LrWpanErrorModel::LrWpanErrorModel(ns3::LrWpanErrorModel const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanErrorModel const &', 'arg0')]) + ## lr-wpan-error-model.h (module 'lr-wpan'): ns3::LrWpanErrorModel::LrWpanErrorModel() [constructor] + cls.add_constructor([]) + ## lr-wpan-error-model.h (module 'lr-wpan'): double ns3::LrWpanErrorModel::GetChunkSuccessRate(double snr, uint32_t nbits) const [member function] + cls.add_method('GetChunkSuccessRate', + 'double', + [param('double', 'snr'), param('uint32_t', 'nbits')], + is_const=True) + ## lr-wpan-error-model.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanErrorModel::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + return + +def register_Ns3LrWpanInterferenceHelper_methods(root_module, cls): + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::LrWpanInterferenceHelper::LrWpanInterferenceHelper(ns3::Ptr spectrumModel) [constructor] + cls.add_constructor([param('ns3::Ptr< ns3::SpectrumModel const >', 'spectrumModel')]) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): bool ns3::LrWpanInterferenceHelper::AddSignal(ns3::Ptr signal) [member function] + cls.add_method('AddSignal', + 'bool', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'signal')]) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): bool ns3::LrWpanInterferenceHelper::RemoveSignal(ns3::Ptr signal) [member function] + cls.add_method('RemoveSignal', + 'bool', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'signal')]) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): void ns3::LrWpanInterferenceHelper::ClearSignals() [member function] + cls.add_method('ClearSignals', + 'void', + []) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanInterferenceHelper::GetSignalPsd() const [member function] + cls.add_method('GetSignalPsd', + 'ns3::Ptr< ns3::SpectrumValue >', + [], + is_const=True) + ## lr-wpan-interference-helper.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanInterferenceHelper::GetSpectrumModel() const [member function] + cls.add_method('GetSpectrumModel', + 'ns3::Ptr< ns3::SpectrumModel const >', + [], + is_const=True) + return + +def register_Ns3LrWpanMac_methods(root_module, cls): + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::LrWpanMac(ns3::LrWpanMac const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanMac const &', 'arg0')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::LrWpanMac() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanAssociationStatus ns3::LrWpanMac::GetAssociationStatus() const [member function] + cls.add_method('GetAssociationStatus', + 'ns3::LrWpanAssociationStatus', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::Mac64Address ns3::LrWpanMac::GetExtendedAddress() const [member function] + cls.add_method('GetExtendedAddress', + 'ns3::Mac64Address', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): uint64_t ns3::LrWpanMac::GetMacAckWaitDuration() const [member function] + cls.add_method('GetMacAckWaitDuration', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): uint8_t ns3::LrWpanMac::GetMacMaxFrameRetries() const [member function] + cls.add_method('GetMacMaxFrameRetries', + 'uint8_t', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): uint16_t ns3::LrWpanMac::GetPanId() const [member function] + cls.add_method('GetPanId', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanMac::GetPhy() [member function] + cls.add_method('GetPhy', + 'ns3::Ptr< ns3::LrWpanPhy >', + []) + ## lr-wpan-mac.h (module 'lr-wpan'): bool ns3::LrWpanMac::GetRxOnWhenIdle() [member function] + cls.add_method('GetRxOnWhenIdle', + 'bool', + []) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::Mac16Address ns3::LrWpanMac::GetShortAddress() const [member function] + cls.add_method('GetShortAddress', + 'ns3::Mac16Address', + [], + is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanMac::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::McpsDataRequest(ns3::McpsDataRequestParams params, ns3::Ptr p) [member function] + cls.add_method('McpsDataRequest', + 'void', + [param('ns3::McpsDataRequestParams', 'params'), param('ns3::Ptr< ns3::Packet >', 'p')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PdDataConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PdDataConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PdDataIndication(uint32_t psduLength, ns3::Ptr p, uint8_t lqi) [member function] + cls.add_method('PdDataIndication', + 'void', + [param('uint32_t', 'psduLength'), param('ns3::Ptr< ns3::Packet >', 'p'), param('uint8_t', 'lqi')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeCcaConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PlmeCcaConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeEdConfirm(ns3::LrWpanPhyEnumeration status, uint8_t energyLevel) [member function] + cls.add_method('PlmeEdConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status'), param('uint8_t', 'energyLevel')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeGetAttributeConfirm(ns3::LrWpanPhyEnumeration status, ns3::LrWpanPibAttributeIdentifier id, ns3::LrWpanPhyPibAttributes * attribute) [member function] + cls.add_method('PlmeGetAttributeConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status'), param('ns3::LrWpanPibAttributeIdentifier', 'id'), param('ns3::LrWpanPhyPibAttributes *', 'attribute')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeSetAttributeConfirm(ns3::LrWpanPhyEnumeration status, ns3::LrWpanPibAttributeIdentifier id) [member function] + cls.add_method('PlmeSetAttributeConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status'), param('ns3::LrWpanPibAttributeIdentifier', 'id')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::PlmeSetTRXStateConfirm(ns3::LrWpanPhyEnumeration status) [member function] + cls.add_method('PlmeSetTRXStateConfirm', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetAssociationStatus(ns3::LrWpanAssociationStatus status) [member function] + cls.add_method('SetAssociationStatus', + 'void', + [param('ns3::LrWpanAssociationStatus', 'status')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetCsmaCa(ns3::Ptr csmaCa) [member function] + cls.add_method('SetCsmaCa', + 'void', + [param('ns3::Ptr< ns3::LrWpanCsmaCa >', 'csmaCa')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetExtendedAddress(ns3::Mac64Address address) [member function] + cls.add_method('SetExtendedAddress', + 'void', + [param('ns3::Mac64Address', 'address')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetLrWpanMacState(ns3::LrWpanMacState macState) [member function] + cls.add_method('SetLrWpanMacState', + 'void', + [param('ns3::LrWpanMacState', 'macState')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetMacMaxFrameRetries(uint8_t retries) [member function] + cls.add_method('SetMacMaxFrameRetries', + 'void', + [param('uint8_t', 'retries')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetMcpsDataConfirmCallback(ns3::McpsDataConfirmCallback c) [member function] + cls.add_method('SetMcpsDataConfirmCallback', + 'void', + [param('ns3::McpsDataConfirmCallback', 'c')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetMcpsDataIndicationCallback(ns3::McpsDataIndicationCallback c) [member function] + cls.add_method('SetMcpsDataIndicationCallback', + 'void', + [param('ns3::McpsDataIndicationCallback', 'c')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetPanId(uint16_t panId) [member function] + cls.add_method('SetPanId', + 'void', + [param('uint16_t', 'panId')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetPhy(ns3::Ptr phy) [member function] + cls.add_method('SetPhy', + 'void', + [param('ns3::Ptr< ns3::LrWpanPhy >', 'phy')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetRxOnWhenIdle(bool rxOnWhenIdle) [member function] + cls.add_method('SetRxOnWhenIdle', + 'void', + [param('bool', 'rxOnWhenIdle')]) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::SetShortAddress(ns3::Mac16Address address) [member function] + cls.add_method('SetShortAddress', + 'void', + [param('ns3::Mac16Address', 'address')]) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::aMinMPDUOverhead [variable] + cls.add_static_attribute('aMinMPDUOverhead', 'uint32_t const', is_const=True) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_aBaseSlotDuration [variable] + cls.add_instance_attribute('m_aBaseSlotDuration', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_aBaseSuperframeDuration [variable] + cls.add_instance_attribute('m_aBaseSuperframeDuration', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_aNumSuperframeSlots [variable] + cls.add_instance_attribute('m_aNumSuperframeSlots', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macBeaconOrder [variable] + cls.add_instance_attribute('m_macBeaconOrder', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macBeaconTxTime [variable] + cls.add_instance_attribute('m_macBeaconTxTime', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macDsn [variable] + cls.add_instance_attribute('m_macDsn', 'ns3::SequenceNumber8', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macMaxFrameRetries [variable] + cls.add_instance_attribute('m_macMaxFrameRetries', 'uint8_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macPanId [variable] + cls.add_instance_attribute('m_macPanId', 'uint16_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macPromiscuousMode [variable] + cls.add_instance_attribute('m_macPromiscuousMode', 'bool', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macRxOnWhenIdle [variable] + cls.add_instance_attribute('m_macRxOnWhenIdle', 'bool', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macSuperframeOrder [variable] + cls.add_instance_attribute('m_macSuperframeOrder', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): ns3::LrWpanMac::m_macSyncSymbolOffset [variable] + cls.add_instance_attribute('m_macSyncSymbolOffset', 'uint64_t', is_const=False) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='protected', is_virtual=True) + ## lr-wpan-mac.h (module 'lr-wpan'): void ns3::LrWpanMac::DoInitialize() [member function] + cls.add_method('DoInitialize', + 'void', + [], + visibility='protected', is_virtual=True) + return + +def register_Ns3LrWpanMacTrailer_methods(root_module, cls): + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer::LrWpanMacTrailer(ns3::LrWpanMacTrailer const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanMacTrailer const &', 'arg0')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer::LrWpanMacTrailer() [constructor] + cls.add_constructor([]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): bool ns3::LrWpanMacTrailer::CheckFcs(ns3::Ptr p) [member function] + cls.add_method('CheckFcs', + 'bool', + [param('ns3::Ptr< ns3::Packet const >', 'p')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacTrailer::Deserialize(ns3::Buffer::Iterator start) [member function] + cls.add_method('Deserialize', + 'uint32_t', + [param('ns3::Buffer::Iterator', 'start')], + is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::EnableFcs(bool enable) [member function] + cls.add_method('EnableFcs', + 'void', + [param('bool', 'enable')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): uint16_t ns3::LrWpanMacTrailer::GetFcs() const [member function] + cls.add_method('GetFcs', + 'uint16_t', + [], + is_const=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::TypeId ns3::LrWpanMacTrailer::GetInstanceTypeId() const [member function] + cls.add_method('GetInstanceTypeId', + 'ns3::TypeId', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): uint32_t ns3::LrWpanMacTrailer::GetSerializedSize() const [member function] + cls.add_method('GetSerializedSize', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanMacTrailer::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): bool ns3::LrWpanMacTrailer::IsFcsEnabled() [member function] + cls.add_method('IsFcsEnabled', + 'bool', + []) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::Print(std::ostream & os) const [member function] + cls.add_method('Print', + 'void', + [param('std::ostream &', 'os')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::Serialize(ns3::Buffer::Iterator start) const [member function] + cls.add_method('Serialize', + 'void', + [param('ns3::Buffer::Iterator', 'start')], + is_const=True, is_virtual=True) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): void ns3::LrWpanMacTrailer::SetFcs(ns3::Ptr p) [member function] + cls.add_method('SetFcs', + 'void', + [param('ns3::Ptr< ns3::Packet const >', 'p')]) + ## lr-wpan-mac-trailer.h (module 'lr-wpan'): ns3::LrWpanMacTrailer::LR_WPAN_MAC_FCS_LENGTH [variable] + cls.add_static_attribute('LR_WPAN_MAC_FCS_LENGTH', 'uint16_t const', is_const=True) + return + +def register_Ns3LrWpanPhy_methods(root_module, cls): + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy::aMaxPhyPacketSize [variable] + cls.add_static_attribute('aMaxPhyPacketSize', 'uint32_t const', is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy::aTurnaroundTime [variable] + cls.add_static_attribute('aTurnaroundTime', 'uint32_t const', is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanPhy::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::LrWpanPhy::LrWpanPhy() [constructor] + cls.add_constructor([]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetMobility(ns3::Ptr m) [member function] + cls.add_method('SetMobility', + 'void', + [param('ns3::Ptr< ns3::MobilityModel >', 'm')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetMobility() [member function] + cls.add_method('GetMobility', + 'ns3::Ptr< ns3::MobilityModel >', + [], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetChannel(ns3::Ptr c) [member function] + cls.add_method('SetChannel', + 'void', + [param('ns3::Ptr< ns3::SpectrumChannel >', 'c')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetChannel() [member function] + cls.add_method('GetChannel', + 'ns3::Ptr< ns3::SpectrumChannel >', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetDevice(ns3::Ptr d) [member function] + cls.add_method('SetDevice', + 'void', + [param('ns3::Ptr< ns3::NetDevice >', 'd')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetDevice() [member function] + cls.add_method('GetDevice', + 'ns3::Ptr< ns3::NetDevice >', + [], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetAntenna(ns3::Ptr a) [member function] + cls.add_method('SetAntenna', + 'void', + [param('ns3::Ptr< ns3::AntennaModel >', 'a')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetRxAntenna() [member function] + cls.add_method('GetRxAntenna', + 'ns3::Ptr< ns3::AntennaModel >', + [], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetRxSpectrumModel() const [member function] + cls.add_method('GetRxSpectrumModel', + 'ns3::Ptr< ns3::SpectrumModel const >', + [], + is_const=True, is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetTxPowerSpectralDensity(ns3::Ptr txPsd) [member function] + cls.add_method('SetTxPowerSpectralDensity', + 'void', + [param('ns3::Ptr< ns3::SpectrumValue >', 'txPsd')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetNoisePowerSpectralDensity(ns3::Ptr noisePsd) [member function] + cls.add_method('SetNoisePowerSpectralDensity', + 'void', + [param('ns3::Ptr< ns3::SpectrumValue const >', 'noisePsd')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetNoisePowerSpectralDensity() [member function] + cls.add_method('GetNoisePowerSpectralDensity', + 'ns3::Ptr< ns3::SpectrumValue const >', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::StartRx(ns3::Ptr params) [member function] + cls.add_method('StartRx', + 'void', + [param('ns3::Ptr< ns3::SpectrumSignalParameters >', 'params')], + is_virtual=True) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PdDataRequest(uint32_t const psduLength, ns3::Ptr p) [member function] + cls.add_method('PdDataRequest', + 'void', + [param('uint32_t const', 'psduLength'), param('ns3::Ptr< ns3::Packet >', 'p')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeCcaRequest() [member function] + cls.add_method('PlmeCcaRequest', + 'void', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeEdRequest() [member function] + cls.add_method('PlmeEdRequest', + 'void', + []) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeGetAttributeRequest(ns3::LrWpanPibAttributeIdentifier id) [member function] + cls.add_method('PlmeGetAttributeRequest', + 'void', + [param('ns3::LrWpanPibAttributeIdentifier', 'id')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeSetTRXStateRequest(ns3::LrWpanPhyEnumeration state) [member function] + cls.add_method('PlmeSetTRXStateRequest', + 'void', + [param('ns3::LrWpanPhyEnumeration', 'state')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::PlmeSetAttributeRequest(ns3::LrWpanPibAttributeIdentifier id, ns3::LrWpanPhyPibAttributes * attribute) [member function] + cls.add_method('PlmeSetAttributeRequest', + 'void', + [param('ns3::LrWpanPibAttributeIdentifier', 'id'), param('ns3::LrWpanPhyPibAttributes *', 'attribute')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPdDataIndicationCallback(ns3::PdDataIndicationCallback c) [member function] + cls.add_method('SetPdDataIndicationCallback', + 'void', + [param('ns3::PdDataIndicationCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPdDataConfirmCallback(ns3::PdDataConfirmCallback c) [member function] + cls.add_method('SetPdDataConfirmCallback', + 'void', + [param('ns3::PdDataConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeCcaConfirmCallback(ns3::PlmeCcaConfirmCallback c) [member function] + cls.add_method('SetPlmeCcaConfirmCallback', + 'void', + [param('ns3::PlmeCcaConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeEdConfirmCallback(ns3::PlmeEdConfirmCallback c) [member function] + cls.add_method('SetPlmeEdConfirmCallback', + 'void', + [param('ns3::PlmeEdConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeGetAttributeConfirmCallback(ns3::PlmeGetAttributeConfirmCallback c) [member function] + cls.add_method('SetPlmeGetAttributeConfirmCallback', + 'void', + [param('ns3::PlmeGetAttributeConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeSetTRXStateConfirmCallback(ns3::PlmeSetTRXStateConfirmCallback c) [member function] + cls.add_method('SetPlmeSetTRXStateConfirmCallback', + 'void', + [param('ns3::PlmeSetTRXStateConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetPlmeSetAttributeConfirmCallback(ns3::PlmeSetAttributeConfirmCallback c) [member function] + cls.add_method('SetPlmeSetAttributeConfirmCallback', + 'void', + [param('ns3::PlmeSetAttributeConfirmCallback', 'c')]) + ## lr-wpan-phy.h (module 'lr-wpan'): double ns3::LrWpanPhy::GetDataOrSymbolRate(bool isData) [member function] + cls.add_method('GetDataOrSymbolRate', + 'double', + [param('bool', 'isData')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::SetErrorModel(ns3::Ptr e) [member function] + cls.add_method('SetErrorModel', + 'void', + [param('ns3::Ptr< ns3::LrWpanErrorModel >', 'e')]) + ## lr-wpan-phy.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanPhy::GetErrorModel() const [member function] + cls.add_method('GetErrorModel', + 'ns3::Ptr< ns3::LrWpanErrorModel >', + [], + is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): uint64_t ns3::LrWpanPhy::GetPhySHRDuration() const [member function] + cls.add_method('GetPhySHRDuration', + 'uint64_t', + [], + is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): double ns3::LrWpanPhy::GetPhySymbolsPerOctet() const [member function] + cls.add_method('GetPhySymbolsPerOctet', + 'double', + [], + is_const=True) + ## lr-wpan-phy.h (module 'lr-wpan'): int64_t ns3::LrWpanPhy::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## lr-wpan-phy.h (module 'lr-wpan'): void ns3::LrWpanPhy::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='private', is_virtual=True) + return + +def register_Ns3LrWpanSpectrumSignalParameters_methods(root_module, cls): + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters::LrWpanSpectrumSignalParameters() [constructor] + cls.add_constructor([]) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters::LrWpanSpectrumSignalParameters(ns3::LrWpanSpectrumSignalParameters const & p) [copy constructor] + cls.add_constructor([param('ns3::LrWpanSpectrumSignalParameters const &', 'p')]) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanSpectrumSignalParameters::Copy() [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::SpectrumSignalParameters >', + [], + is_virtual=True) + ## lr-wpan-spectrum-signal-parameters.h (module 'lr-wpan'): ns3::LrWpanSpectrumSignalParameters::packetBurst [variable] + cls.add_instance_attribute('packetBurst', 'ns3::Ptr< ns3::PacketBurst >', is_const=False) + return + +def register_Ns3Mac16AddressChecker_methods(root_module, cls): + ## mac16-address.h (module 'network'): ns3::Mac16AddressChecker::Mac16AddressChecker() [constructor] + cls.add_constructor([]) + ## mac16-address.h (module 'network'): ns3::Mac16AddressChecker::Mac16AddressChecker(ns3::Mac16AddressChecker const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac16AddressChecker const &', 'arg0')]) + return + +def register_Ns3Mac16AddressValue_methods(root_module, cls): + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue::Mac16AddressValue() [constructor] + cls.add_constructor([]) + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue::Mac16AddressValue(ns3::Mac16AddressValue const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac16AddressValue const &', 'arg0')]) + ## mac16-address.h (module 'network'): ns3::Mac16AddressValue::Mac16AddressValue(ns3::Mac16Address const & value) [constructor] + cls.add_constructor([param('ns3::Mac16Address const &', 'value')]) + ## mac16-address.h (module 'network'): ns3::Ptr ns3::Mac16AddressValue::Copy() const [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::AttributeValue >', + [], + is_const=True, is_virtual=True) + ## mac16-address.h (module 'network'): bool ns3::Mac16AddressValue::DeserializeFromString(std::string value, ns3::Ptr checker) [member function] + cls.add_method('DeserializeFromString', + 'bool', + [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_virtual=True) + ## mac16-address.h (module 'network'): ns3::Mac16Address ns3::Mac16AddressValue::Get() const [member function] + cls.add_method('Get', + 'ns3::Mac16Address', + [], + is_const=True) + ## mac16-address.h (module 'network'): std::string ns3::Mac16AddressValue::SerializeToString(ns3::Ptr checker) const [member function] + cls.add_method('SerializeToString', + 'std::string', + [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_const=True, is_virtual=True) + ## mac16-address.h (module 'network'): void ns3::Mac16AddressValue::Set(ns3::Mac16Address const & value) [member function] + cls.add_method('Set', + 'void', + [param('ns3::Mac16Address const &', 'value')]) + return + +def register_Ns3Mac64AddressChecker_methods(root_module, cls): + ## mac64-address.h (module 'network'): ns3::Mac64AddressChecker::Mac64AddressChecker() [constructor] + cls.add_constructor([]) + ## mac64-address.h (module 'network'): ns3::Mac64AddressChecker::Mac64AddressChecker(ns3::Mac64AddressChecker const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac64AddressChecker const &', 'arg0')]) + return + +def register_Ns3Mac64AddressValue_methods(root_module, cls): + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue::Mac64AddressValue() [constructor] + cls.add_constructor([]) + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue::Mac64AddressValue(ns3::Mac64AddressValue const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Mac64AddressValue const &', 'arg0')]) + ## mac64-address.h (module 'network'): ns3::Mac64AddressValue::Mac64AddressValue(ns3::Mac64Address const & value) [constructor] + cls.add_constructor([param('ns3::Mac64Address const &', 'value')]) + ## mac64-address.h (module 'network'): ns3::Ptr ns3::Mac64AddressValue::Copy() const [member function] + cls.add_method('Copy', + 'ns3::Ptr< ns3::AttributeValue >', + [], + is_const=True, is_virtual=True) + ## mac64-address.h (module 'network'): bool ns3::Mac64AddressValue::DeserializeFromString(std::string value, ns3::Ptr checker) [member function] + cls.add_method('DeserializeFromString', + 'bool', + [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_virtual=True) + ## mac64-address.h (module 'network'): ns3::Mac64Address ns3::Mac64AddressValue::Get() const [member function] + cls.add_method('Get', + 'ns3::Mac64Address', + [], + is_const=True) + ## mac64-address.h (module 'network'): std::string ns3::Mac64AddressValue::SerializeToString(ns3::Ptr checker) const [member function] + cls.add_method('SerializeToString', + 'std::string', + [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], + is_const=True, is_virtual=True) + ## mac64-address.h (module 'network'): void ns3::Mac64AddressValue::Set(ns3::Mac64Address const & value) [member function] + cls.add_method('Set', + 'void', + [param('ns3::Mac64Address 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 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::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::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 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 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 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,ns3::Ptr,short unsigned int,const ns3::Address&,const ns3::Address&,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 >, short unsigned int, 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, ns3::Ptr, 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::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 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 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::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::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,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, ns3::Ptr, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler, uint16_t protocolType, ns3::Ptr 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,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, ns3::Ptr, 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::DoInitialize() [member function] + cls.add_method('DoInitialize', + '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::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 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 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 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::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::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::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'): bool ns3::Packet::ReplacePacketTag(ns3::Tag & tag) [member function] + cls.add_method('ReplacePacketTag', + 'bool', + [param('ns3::Tag &', 'tag')]) + ## 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 nixVector) [member function] + cls.add_method('SetNixVector', + 'void', + [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) + 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::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 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 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::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 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 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::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 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 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_Ns3LrWpanNetDevice_methods(root_module, cls): + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::LrWpanNetDevice::LrWpanNetDevice(ns3::LrWpanNetDevice const & arg0) [copy constructor] + cls.add_constructor([param('ns3::LrWpanNetDevice const &', 'arg0')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::LrWpanNetDevice::LrWpanNetDevice() [constructor] + cls.add_constructor([]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::AddLinkChangeCallback(ns3::Callback 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): int64_t ns3::LrWpanNetDevice::AssignStreams(int64_t stream) [member function] + cls.add_method('AssignStreams', + 'int64_t', + [param('int64_t', 'stream')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetAddress() const [member function] + cls.add_method('GetAddress', + 'ns3::Address', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetBroadcast() const [member function] + cls.add_method('GetBroadcast', + 'ns3::Address', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetChannel() const [member function] + cls.add_method('GetChannel', + 'ns3::Ptr< ns3::Channel >', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetCsmaCa() const [member function] + cls.add_method('GetCsmaCa', + 'ns3::Ptr< ns3::LrWpanCsmaCa >', + [], + is_const=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): uint32_t ns3::LrWpanNetDevice::GetIfIndex() const [member function] + cls.add_method('GetIfIndex', + 'uint32_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetMac() const [member function] + cls.add_method('GetMac', + 'ns3::Ptr< ns3::LrWpanMac >', + [], + is_const=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): uint16_t ns3::LrWpanNetDevice::GetMtu() const [member function] + cls.add_method('GetMtu', + 'uint16_t', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetMulticast(ns3::Ipv4Address multicastGroup) const [member function] + cls.add_method('GetMulticast', + 'ns3::Address', + [param('ns3::Ipv4Address', 'multicastGroup')], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Address ns3::LrWpanNetDevice::GetMulticast(ns3::Ipv6Address addr) const [member function] + cls.add_method('GetMulticast', + 'ns3::Address', + [param('ns3::Ipv6Address', 'addr')], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetNode() const [member function] + cls.add_method('GetNode', + 'ns3::Ptr< ns3::Node >', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): ns3::Ptr ns3::LrWpanNetDevice::GetPhy() const [member function] + cls.add_method('GetPhy', + 'ns3::Ptr< ns3::LrWpanPhy >', + [], + is_const=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): static ns3::TypeId ns3::LrWpanNetDevice::GetTypeId() [member function] + cls.add_method('GetTypeId', + 'ns3::TypeId', + [], + is_static=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsBridge() const [member function] + cls.add_method('IsBridge', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsBroadcast() const [member function] + cls.add_method('IsBroadcast', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsLinkUp() const [member function] + cls.add_method('IsLinkUp', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsMulticast() const [member function] + cls.add_method('IsMulticast', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::IsPointToPoint() const [member function] + cls.add_method('IsPointToPoint', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::McpsDataIndication(ns3::McpsDataIndicationParams params, ns3::Ptr pkt) [member function] + cls.add_method('McpsDataIndication', + 'void', + [param('ns3::McpsDataIndicationParams', 'params'), param('ns3::Ptr< ns3::Packet >', 'pkt')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::NeedsArp() const [member function] + cls.add_method('NeedsArp', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::Send(ns3::Ptr 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::SendFrom(ns3::Ptr 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetAddress(ns3::Address address) [member function] + cls.add_method('SetAddress', + 'void', + [param('ns3::Address', 'address')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetChannel(ns3::Ptr channel) [member function] + cls.add_method('SetChannel', + 'void', + [param('ns3::Ptr< ns3::SpectrumChannel >', 'channel')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetCsmaCa(ns3::Ptr csmaca) [member function] + cls.add_method('SetCsmaCa', + 'void', + [param('ns3::Ptr< ns3::LrWpanCsmaCa >', 'csmaca')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetIfIndex(uint32_t const index) [member function] + cls.add_method('SetIfIndex', + 'void', + [param('uint32_t const', 'index')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetMac(ns3::Ptr mac) [member function] + cls.add_method('SetMac', + 'void', + [param('ns3::Ptr< ns3::LrWpanMac >', 'mac')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::SetMtu(uint16_t const mtu) [member function] + cls.add_method('SetMtu', + 'bool', + [param('uint16_t const', 'mtu')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetNode(ns3::Ptr node) [member function] + cls.add_method('SetNode', + 'void', + [param('ns3::Ptr< ns3::Node >', 'node')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetPhy(ns3::Ptr phy) [member function] + cls.add_method('SetPhy', + 'void', + [param('ns3::Ptr< ns3::LrWpanPhy >', 'phy')]) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetPromiscReceiveCallback(ns3::Callback,ns3::Ptr,short unsigned int,const ns3::Address&,const ns3::Address&,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 >, short unsigned int, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'cb')], + is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::SetReceiveCallback(ns3::Callback, ns3::Ptr, 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) + ## lr-wpan-net-device.h (module 'lr-wpan'): bool ns3::LrWpanNetDevice::SupportsSendFrom() const [member function] + cls.add_method('SupportsSendFrom', + 'bool', + [], + is_const=True, is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::DoDispose() [member function] + cls.add_method('DoDispose', + 'void', + [], + visibility='private', is_virtual=True) + ## lr-wpan-net-device.h (module 'lr-wpan'): void ns3::LrWpanNetDevice::DoInitialize() [member function] + cls.add_method('DoInitialize', + 'void', + [], + visibility='private', is_virtual=True) + return + +def register_Ns3HashImplementation_methods(root_module, cls): + ## hash-function.h (module 'core'): ns3::Hash::Implementation::Implementation(ns3::Hash::Implementation const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Implementation const &', 'arg0')]) + ## hash-function.h (module 'core'): ns3::Hash::Implementation::Implementation() [constructor] + cls.add_constructor([]) + ## hash-function.h (module 'core'): uint32_t ns3::Hash::Implementation::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_pure_virtual=True, is_virtual=True) + ## hash-function.h (module 'core'): uint64_t ns3::Hash::Implementation::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): void ns3::Hash::Implementation::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_pure_virtual=True, is_virtual=True) + return + +def register_Ns3HashFunctionFnv1a_methods(root_module, cls): + ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a::Fnv1a(ns3::Hash::Function::Fnv1a const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Fnv1a const &', 'arg0')]) + ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a::Fnv1a() [constructor] + cls.add_constructor([]) + ## hash-fnv.h (module 'core'): uint32_t ns3::Hash::Function::Fnv1a::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-fnv.h (module 'core'): uint64_t ns3::Hash::Function::Fnv1a::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-fnv.h (module 'core'): void ns3::Hash::Function::Fnv1a::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_Ns3HashFunctionHash32_methods(root_module, cls): + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32::Hash32(ns3::Hash::Function::Hash32 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Hash32 const &', 'arg0')]) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32::Hash32(ns3::Hash::Hash32Function_ptr hp) [constructor] + cls.add_constructor([param('ns3::Hash::Hash32Function_ptr', 'hp')]) + ## hash-function.h (module 'core'): uint32_t ns3::Hash::Function::Hash32::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): void ns3::Hash::Function::Hash32::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_Ns3HashFunctionHash64_methods(root_module, cls): + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64::Hash64(ns3::Hash::Function::Hash64 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Hash64 const &', 'arg0')]) + ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64::Hash64(ns3::Hash::Hash64Function_ptr hp) [constructor] + cls.add_constructor([param('ns3::Hash::Hash64Function_ptr', 'hp')]) + ## hash-function.h (module 'core'): uint32_t ns3::Hash::Function::Hash64::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): uint64_t ns3::Hash::Function::Hash64::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-function.h (module 'core'): void ns3::Hash::Function::Hash64::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_Ns3HashFunctionMurmur3_methods(root_module, cls): + ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3::Murmur3(ns3::Hash::Function::Murmur3 const & arg0) [copy constructor] + cls.add_constructor([param('ns3::Hash::Function::Murmur3 const &', 'arg0')]) + ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3::Murmur3() [constructor] + cls.add_constructor([]) + ## hash-murmur3.h (module 'core'): uint32_t ns3::Hash::Function::Murmur3::GetHash32(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash32', + 'uint32_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-murmur3.h (module 'core'): uint64_t ns3::Hash::Function::Murmur3::GetHash64(char const * buffer, size_t const size) [member function] + cls.add_method('GetHash64', + 'uint64_t', + [param('char const *', 'buffer'), param('size_t const', 'size')], + is_virtual=True) + ## hash-murmur3.h (module 'core'): void ns3::Hash::Function::Murmur3::clear() [member function] + cls.add_method('clear', + 'void', + [], + is_virtual=True) + return + +def register_functions(root_module): + module = root_module + register_functions_ns3_FatalImpl(module.get_submodule('FatalImpl'), root_module) + register_functions_ns3_Hash(module.get_submodule('Hash'), root_module) + return + +def register_functions_ns3_FatalImpl(module, root_module): + return + +def register_functions_ns3_Hash(module, root_module): + register_functions_ns3_Hash_Function(module.get_submodule('Function'), root_module) + return + +def register_functions_ns3_Hash_Function(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() + diff -Naur ns-3.19/src/lr-wpan/doc/802-15-4-ber.eps ns-3.20/src/lr-wpan/doc/802-15-4-ber.eps --- ns-3.19/src/lr-wpan/doc/802-15-4-ber.eps 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/doc/802-15-4-ber.eps 2014-06-17 10:33:13.892995969 -0700 @@ -0,0 +1,1030 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: 802.15.4-ber.eps +%%Creator: gnuplot 4.4 patchlevel 2 +%%CreationDate: Tue Oct 4 14:51:04 2011 +%%DocumentFonts: (atend) +%%BoundingBox: 50 50 410 302 +%%EndComments +%%BeginProlog +/gnudict 256 dict def +gnudict begin +% +% The following true/false flags may be edited by hand if desired. +% The unit line width and grayscale image gamma correction may also be changed. +% +/Color true def +/Blacktext false def +/Solid false def +/Dashlength 1 def +/Landscape false def +/Level1 false def +/Rounded false def +/ClipToBoundingBox false def +/TransparentPatterns false def +/gnulinewidth 5.000 def +/userlinewidth gnulinewidth def +/Gamma 1.0 def +% +/vshift -46 def +/dl1 { + 10.0 Dashlength mul mul + Rounded { currentlinewidth 0.75 mul sub dup 0 le { pop 0.01 } if } if +} def +/dl2 { + 10.0 Dashlength mul mul + Rounded { currentlinewidth 0.75 mul add } if +} def +/hpt_ 31.5 def +/vpt_ 31.5 def +/hpt hpt_ def +/vpt vpt_ def +Level1 {} { +/SDict 10 dict def +systemdict /pdfmark known not { + userdict /pdfmark systemdict /cleartomark get put +} if +SDict begin [ + /Title (802.15.4-ber.eps) + /Subject (gnuplot plot) + /Creator (gnuplot 4.4 patchlevel 2) + /Author (tomh) +% /Producer (gnuplot) +% /Keywords () + /CreationDate (Tue Oct 4 14:51:04 2011) + /DOCINFO pdfmark +end +} ifelse +/doclip { + ClipToBoundingBox { + newpath 50 50 moveto 410 50 lineto 410 302 lineto 50 302 lineto closepath + clip + } if +} def +% +% Gnuplot Prolog Version 4.4 (August 2010) +% +%/SuppressPDFMark true def +% +/M {moveto} bind def +/L {lineto} bind def +/R {rmoveto} bind def +/V {rlineto} bind def +/N {newpath moveto} bind def +/Z {closepath} bind def +/C {setrgbcolor} bind def +/f {rlineto fill} bind def +/g {setgray} bind def +/Gshow {show} def % May be redefined later in the file to support UTF-8 +/vpt2 vpt 2 mul def +/hpt2 hpt 2 mul def +/Lshow {currentpoint stroke M 0 vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/Rshow {currentpoint stroke M dup stringwidth pop neg vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/Cshow {currentpoint stroke M dup stringwidth pop -2 div vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/UP {dup vpt_ mul /vpt exch def hpt_ mul /hpt exch def + /hpt2 hpt 2 mul def /vpt2 vpt 2 mul def} def +/DL {Color {setrgbcolor Solid {pop []} if 0 setdash} + {pop pop pop 0 setgray Solid {pop []} if 0 setdash} ifelse} def +/BL {stroke userlinewidth 2 mul setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +/AL {stroke userlinewidth 2 div setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +/UL {dup gnulinewidth mul /userlinewidth exch def + dup 1 lt {pop 1} if 10 mul /udl exch def} def +/PL {stroke userlinewidth setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +3.8 setmiterlimit +% Default Line colors +/LCw {1 1 1} def +/LCb {0 0 0} def +/LCa {0 0 0} def +/LC0 {1 0 0} def +/LC1 {0 1 0} def +/LC2 {0 0 1} def +/LC3 {1 0 1} def +/LC4 {0 1 1} def +/LC5 {1 1 0} def +/LC6 {0 0 0} def +/LC7 {1 0.3 0} def +/LC8 {0.5 0.5 0.5} def +% Default Line Types +/LTw {PL [] 1 setgray} def +/LTb {BL [] LCb DL} def +/LTa {AL [1 udl mul 2 udl mul] 0 setdash LCa setrgbcolor} def +/LT0 {PL [] LC0 DL} def +/LT1 {PL [4 dl1 2 dl2] LC1 DL} def +/LT2 {PL [2 dl1 3 dl2] LC2 DL} def +/LT3 {PL [1 dl1 1.5 dl2] LC3 DL} def +/LT4 {PL [6 dl1 2 dl2 1 dl1 2 dl2] LC4 DL} def +/LT5 {PL [3 dl1 3 dl2 1 dl1 3 dl2] LC5 DL} def +/LT6 {PL [2 dl1 2 dl2 2 dl1 6 dl2] LC6 DL} def +/LT7 {PL [1 dl1 2 dl2 6 dl1 2 dl2 1 dl1 2 dl2] LC7 DL} def +/LT8 {PL [2 dl1 2 dl2 2 dl1 2 dl2 2 dl1 2 dl2 2 dl1 4 dl2] LC8 DL} def +/Pnt {stroke [] 0 setdash gsave 1 setlinecap M 0 0 V stroke grestore} def +/Dia {stroke [] 0 setdash 2 copy vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath stroke + Pnt} def +/Pls {stroke [] 0 setdash vpt sub M 0 vpt2 V + currentpoint stroke M + hpt neg vpt neg R hpt2 0 V stroke + } def +/Box {stroke [] 0 setdash 2 copy exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath stroke + Pnt} def +/Crs {stroke [] 0 setdash exch hpt sub exch vpt add M + hpt2 vpt2 neg V currentpoint stroke M + hpt2 neg 0 R hpt2 vpt2 V stroke} def +/TriU {stroke [] 0 setdash 2 copy vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath stroke + Pnt} def +/Star {2 copy Pls Crs} def +/BoxF {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath fill} def +/TriUF {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath fill} def +/TriD {stroke [] 0 setdash 2 copy vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath stroke + Pnt} def +/TriDF {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath fill} def +/DiaF {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath fill} def +/Pent {stroke [] 0 setdash 2 copy gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath stroke grestore Pnt} def +/PentF {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath fill grestore} def +/Circle {stroke [] 0 setdash 2 copy + hpt 0 360 arc stroke Pnt} def +/CircleF {stroke [] 0 setdash hpt 0 360 arc fill} def +/C0 {BL [] 0 setdash 2 copy moveto vpt 90 450 arc} bind def +/C1 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc closepath fill + vpt 0 360 arc closepath} bind def +/C2 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C3 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C4 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 180 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C5 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc + 2 copy moveto + 2 copy vpt 180 270 arc closepath fill + vpt 0 360 arc} bind def +/C6 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C7 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C8 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 270 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C9 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 270 450 arc closepath fill + vpt 0 360 arc closepath} bind def +/C10 {BL [] 0 setdash 2 copy 2 copy moveto vpt 270 360 arc closepath fill + 2 copy moveto + 2 copy vpt 90 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C11 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 180 arc closepath fill + 2 copy moveto + 2 copy vpt 270 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C12 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 180 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C13 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc closepath fill + 2 copy moveto + 2 copy vpt 180 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C14 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 360 arc closepath fill + vpt 0 360 arc} bind def +/C15 {BL [] 0 setdash 2 copy vpt 0 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/Rec {newpath 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto + neg 0 rlineto closepath} bind def +/Square {dup Rec} bind def +/Bsquare {vpt sub exch vpt sub exch vpt2 Square} bind def +/S0 {BL [] 0 setdash 2 copy moveto 0 vpt rlineto BL Bsquare} bind def +/S1 {BL [] 0 setdash 2 copy vpt Square fill Bsquare} bind def +/S2 {BL [] 0 setdash 2 copy exch vpt sub exch vpt Square fill Bsquare} bind def +/S3 {BL [] 0 setdash 2 copy exch vpt sub exch vpt2 vpt Rec fill Bsquare} bind def +/S4 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt Square fill Bsquare} bind def +/S5 {BL [] 0 setdash 2 copy 2 copy vpt Square fill + exch vpt sub exch vpt sub vpt Square fill Bsquare} bind def +/S6 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill Bsquare} bind def +/S7 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill + 2 copy vpt Square fill Bsquare} bind def +/S8 {BL [] 0 setdash 2 copy vpt sub vpt Square fill Bsquare} bind def +/S9 {BL [] 0 setdash 2 copy vpt sub vpt vpt2 Rec fill Bsquare} bind def +/S10 {BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt Square fill + Bsquare} bind def +/S11 {BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt2 vpt Rec fill + Bsquare} bind def +/S12 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill Bsquare} bind def +/S13 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill + 2 copy vpt Square fill Bsquare} bind def +/S14 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill + 2 copy exch vpt sub exch vpt Square fill Bsquare} bind def +/S15 {BL [] 0 setdash 2 copy Bsquare fill Bsquare} bind def +/D0 {gsave translate 45 rotate 0 0 S0 stroke grestore} bind def +/D1 {gsave translate 45 rotate 0 0 S1 stroke grestore} bind def +/D2 {gsave translate 45 rotate 0 0 S2 stroke grestore} bind def +/D3 {gsave translate 45 rotate 0 0 S3 stroke grestore} bind def +/D4 {gsave translate 45 rotate 0 0 S4 stroke grestore} bind def +/D5 {gsave translate 45 rotate 0 0 S5 stroke grestore} bind def +/D6 {gsave translate 45 rotate 0 0 S6 stroke grestore} bind def +/D7 {gsave translate 45 rotate 0 0 S7 stroke grestore} bind def +/D8 {gsave translate 45 rotate 0 0 S8 stroke grestore} bind def +/D9 {gsave translate 45 rotate 0 0 S9 stroke grestore} bind def +/D10 {gsave translate 45 rotate 0 0 S10 stroke grestore} bind def +/D11 {gsave translate 45 rotate 0 0 S11 stroke grestore} bind def +/D12 {gsave translate 45 rotate 0 0 S12 stroke grestore} bind def +/D13 {gsave translate 45 rotate 0 0 S13 stroke grestore} bind def +/D14 {gsave translate 45 rotate 0 0 S14 stroke grestore} bind def +/D15 {gsave translate 45 rotate 0 0 S15 stroke grestore} bind def +/DiaE {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath stroke} def +/BoxE {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath stroke} def +/TriUE {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath stroke} def +/TriDE {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath stroke} def +/PentE {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath stroke grestore} def +/CircE {stroke [] 0 setdash + hpt 0 360 arc stroke} def +/Opaque {gsave closepath 1 setgray fill grestore 0 setgray closepath} def +/DiaW {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V Opaque stroke} def +/BoxW {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V Opaque stroke} def +/TriUW {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V Opaque stroke} def +/TriDW {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V Opaque stroke} def +/PentW {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + Opaque stroke grestore} def +/CircW {stroke [] 0 setdash + hpt 0 360 arc Opaque stroke} def +/BoxFill {gsave Rec 1 setgray fill grestore} def +/Density { + /Fillden exch def + currentrgbcolor + /ColB exch def /ColG exch def /ColR exch def + /ColR ColR Fillden mul Fillden sub 1 add def + /ColG ColG Fillden mul Fillden sub 1 add def + /ColB ColB Fillden mul Fillden sub 1 add def + ColR ColG ColB setrgbcolor} def +/BoxColFill {gsave Rec PolyFill} def +/PolyFill {gsave Density fill grestore grestore} def +/h {rlineto rlineto rlineto gsave closepath fill grestore} bind def +% +% PostScript Level 1 Pattern Fill routine for rectangles +% Usage: x y w h s a XX PatternFill +% x,y = lower left corner of box to be filled +% w,h = width and height of box +% a = angle in degrees between lines and x-axis +% XX = 0/1 for no/yes cross-hatch +% +/PatternFill {gsave /PFa [ 9 2 roll ] def + PFa 0 get PFa 2 get 2 div add PFa 1 get PFa 3 get 2 div add translate + PFa 2 get -2 div PFa 3 get -2 div PFa 2 get PFa 3 get Rec + gsave 1 setgray fill grestore clip + currentlinewidth 0.5 mul setlinewidth + /PFs PFa 2 get dup mul PFa 3 get dup mul add sqrt def + 0 0 M PFa 5 get rotate PFs -2 div dup translate + 0 1 PFs PFa 4 get div 1 add floor cvi + {PFa 4 get mul 0 M 0 PFs V} for + 0 PFa 6 get ne { + 0 1 PFs PFa 4 get div 1 add floor cvi + {PFa 4 get mul 0 2 1 roll M PFs 0 V} for + } if + stroke grestore} def +% +/languagelevel where + {pop languagelevel} {1} ifelse + 2 lt + {/InterpretLevel1 true def} + {/InterpretLevel1 Level1 def} + ifelse +% +% PostScript level 2 pattern fill definitions +% +/Level2PatternFill { +/Tile8x8 {/PaintType 2 /PatternType 1 /TilingType 1 /BBox [0 0 8 8] /XStep 8 /YStep 8} + bind def +/KeepColor {currentrgbcolor [/Pattern /DeviceRGB] setcolorspace} bind def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 8 8 L 0 8 M 8 0 L stroke} +>> matrix makepattern +/Pat1 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 8 8 L 0 8 M 8 0 L stroke + 0 4 M 4 8 L 8 4 L 4 0 L 0 4 L stroke} +>> matrix makepattern +/Pat2 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 0 8 L + 8 8 L 8 0 L 0 0 L fill} +>> matrix makepattern +/Pat3 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -4 8 M 8 -4 L + 0 12 M 12 0 L stroke} +>> matrix makepattern +/Pat4 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -4 0 M 8 12 L + 0 -4 M 12 8 L stroke} +>> matrix makepattern +/Pat5 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -2 8 M 4 -4 L + 0 12 M 8 -4 L 4 12 M 10 0 L stroke} +>> matrix makepattern +/Pat6 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -2 0 M 4 12 L + 0 -4 M 8 12 L 4 -4 M 10 8 L stroke} +>> matrix makepattern +/Pat7 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 8 -2 M -4 4 L + 12 0 M -4 8 L 12 4 M 0 10 L stroke} +>> matrix makepattern +/Pat8 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 -2 M 12 4 L + -4 0 M 12 8 L -4 4 M 8 10 L stroke} +>> matrix makepattern +/Pat9 exch def +/Pattern1 {PatternBgnd KeepColor Pat1 setpattern} bind def +/Pattern2 {PatternBgnd KeepColor Pat2 setpattern} bind def +/Pattern3 {PatternBgnd KeepColor Pat3 setpattern} bind def +/Pattern4 {PatternBgnd KeepColor Landscape {Pat5} {Pat4} ifelse setpattern} bind def +/Pattern5 {PatternBgnd KeepColor Landscape {Pat4} {Pat5} ifelse setpattern} bind def +/Pattern6 {PatternBgnd KeepColor Landscape {Pat9} {Pat6} ifelse setpattern} bind def +/Pattern7 {PatternBgnd KeepColor Landscape {Pat8} {Pat7} ifelse setpattern} bind def +} def +% +% +%End of PostScript Level 2 code +% +/PatternBgnd { + TransparentPatterns {} {gsave 1 setgray fill grestore} ifelse +} def +% +% Substitute for Level 2 pattern fill codes with +% grayscale if Level 2 support is not selected. +% +/Level1PatternFill { +/Pattern1 {0.250 Density} bind def +/Pattern2 {0.500 Density} bind def +/Pattern3 {0.750 Density} bind def +/Pattern4 {0.125 Density} bind def +/Pattern5 {0.375 Density} bind def +/Pattern6 {0.625 Density} bind def +/Pattern7 {0.875 Density} bind def +} def +% +% Now test for support of Level 2 code +% +Level1 {Level1PatternFill} {Level2PatternFill} ifelse +% +/Symbol-Oblique /Symbol findfont [1 0 .167 1 0 0] makefont +dup length dict begin {1 index /FID eq {pop pop} {def} ifelse} forall +currentdict end definefont pop +/MFshow { + { dup 5 get 3 ge + { 5 get 3 eq {gsave} {grestore} ifelse } + {dup dup 0 get findfont exch 1 get scalefont setfont + [ currentpoint ] exch dup 2 get 0 exch R dup 5 get 2 ne {dup dup 6 + get exch 4 get {Gshow} {stringwidth pop 0 R} ifelse }if dup 5 get 0 eq + {dup 3 get {2 get neg 0 exch R pop} {pop aload pop M} ifelse} {dup 5 + get 1 eq {dup 2 get exch dup 3 get exch 6 get stringwidth pop -2 div + dup 0 R} {dup 6 get stringwidth pop -2 div 0 R 6 get + show 2 index {aload pop M neg 3 -1 roll neg R pop pop} {pop pop pop + pop aload pop M} ifelse }ifelse }ifelse } + ifelse } + forall} def +/Gswidth {dup type /stringtype eq {stringwidth} {pop (n) stringwidth} ifelse} def +/MFwidth {0 exch { dup 5 get 3 ge { 5 get 3 eq { 0 } { pop } ifelse } + {dup 3 get{dup dup 0 get findfont exch 1 get scalefont setfont + 6 get Gswidth pop add} {pop} ifelse} ifelse} forall} def +/MLshow { currentpoint stroke M + 0 exch R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/MRshow { currentpoint stroke M + exch dup MFwidth neg 3 -1 roll R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/MCshow { currentpoint stroke M + exch dup MFwidth -2 div 3 -1 roll R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/XYsave { [( ) 1 2 true false 3 ()] } bind def +/XYrestore { [( ) 1 2 true false 4 ()] } bind def +end +%%EndProlog +gnudict begin +gsave +doclip +50 50 translate +0.050 0.050 scale +0 setgray +newpath +(Times-BoldItalic) findfont 140 scalefont setfont +1.000 UL +LTb +1.000 UL +LTa +938 448 M +6009 0 V +stroke +LTb +938 448 M +63 0 V +5946 0 R +-63 0 V +stroke +854 448 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-09)] +] -46.7 MRshow +1.000 UL +LTb +938 596 M +31 0 V +5978 0 R +-31 0 V +938 792 M +31 0 V +5978 0 R +-31 0 V +938 892 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 939 M +6009 0 V +stroke +LTb +938 939 M +63 0 V +5946 0 R +-63 0 V +stroke +854 939 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-08)] +] -46.7 MRshow +1.000 UL +LTb +938 1087 M +31 0 V +5978 0 R +-31 0 V +938 1283 M +31 0 V +5978 0 R +-31 0 V +938 1383 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 1431 M +6009 0 V +stroke +LTb +938 1431 M +63 0 V +5946 0 R +-63 0 V +stroke +854 1431 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-07)] +] -46.7 MRshow +1.000 UL +LTb +938 1579 M +31 0 V +5978 0 R +-31 0 V +938 1774 M +31 0 V +5978 0 R +-31 0 V +938 1875 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 1922 M +6009 0 V +stroke +LTb +938 1922 M +63 0 V +5946 0 R +-63 0 V +stroke +854 1922 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-06)] +] -46.7 MRshow +1.000 UL +LTb +938 2070 M +31 0 V +5978 0 R +-31 0 V +938 2266 M +31 0 V +5978 0 R +-31 0 V +938 2366 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 2414 M +6009 0 V +stroke +LTb +938 2414 M +63 0 V +5946 0 R +-63 0 V +stroke +854 2414 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-05)] +] -46.7 MRshow +1.000 UL +LTb +938 2562 M +31 0 V +5978 0 R +-31 0 V +938 2757 M +31 0 V +5978 0 R +-31 0 V +938 2858 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 2905 M +6009 0 V +stroke +LTb +938 2905 M +63 0 V +5946 0 R +-63 0 V +stroke +854 2905 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.0001)] +] -46.7 MRshow +1.000 UL +LTb +938 3053 M +31 0 V +5978 0 R +-31 0 V +938 3249 M +31 0 V +5978 0 R +-31 0 V +938 3349 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 3397 M +6009 0 V +stroke +LTb +938 3397 M +63 0 V +5946 0 R +-63 0 V +stroke +854 3397 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.001)] +] -46.7 MRshow +1.000 UL +LTb +938 3545 M +31 0 V +5978 0 R +-31 0 V +938 3740 M +31 0 V +5978 0 R +-31 0 V +938 3840 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 3888 M +6009 0 V +stroke +LTb +938 3888 M +63 0 V +5946 0 R +-63 0 V +stroke +854 3888 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.01)] +] -46.7 MRshow +1.000 UL +LTb +938 4036 M +31 0 V +5978 0 R +-31 0 V +938 4232 M +31 0 V +5978 0 R +-31 0 V +938 4332 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 4380 M +6009 0 V +stroke +LTb +938 4380 M +63 0 V +5946 0 R +-63 0 V +stroke +854 4380 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.1)] +] -46.7 MRshow +1.000 UL +LTb +938 4527 M +31 0 V +5978 0 R +-31 0 V +938 4723 M +31 0 V +5978 0 R +-31 0 V +938 4823 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +938 4871 M +6009 0 V +stroke +LTb +938 4871 M +63 0 V +5946 0 R +-63 0 V +stroke +854 4871 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1)] +] -46.7 MRshow +1.000 UL +LTb +1.000 UL +LTa +938 448 M +0 4423 V +stroke +LTb +938 448 M +0 63 V +0 4360 R +0 -63 V +stroke +938 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-10)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +2140 448 M +0 4423 V +stroke +LTb +2140 448 M +0 63 V +0 4360 R +0 -63 V +stroke +2140 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-5)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +3342 448 M +0 4423 V +stroke +LTb +3342 448 M +0 63 V +0 4360 R +0 -63 V +stroke +3342 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +4543 448 M +0 4423 V +stroke +LTb +4543 448 M +0 63 V +0 4360 R +0 -63 V +stroke +4543 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 5)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +5745 448 M +0 4220 V +0 140 R +0 63 V +stroke +LTb +5745 448 M +0 63 V +0 4360 R +0 -63 V +stroke +5745 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 10)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +6947 448 M +0 4423 V +stroke +LTb +6947 448 M +0 63 V +0 4360 R +0 -63 V +stroke +6947 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 15)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTb +938 4871 N +938 448 L +6009 0 V +0 4423 V +-6009 0 V +Z stroke +LCb setrgbcolor +112 2659 M +currentpoint gsave translate -270 rotate 0 0 moveto +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (Bit Error Rate \(BER\))] +] -46.7 MCshow +grestore +LTb +LCb setrgbcolor +3942 98 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (SNR \(dB\))] +] -46.7 MCshow +LTb +1.000 UP +1.000 UL +LTb +% Begin plot #1 +5.000 UL +LT0 +LCb setrgbcolor +6296 4738 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (802.15.4)] +] -46.7 MRshow +LT0 +6380 4738 M +399 0 V +938 4629 M +24 -3 V +24 -2 V +24 -3 V +24 -3 V +24 -3 V +24 -3 V +24 -4 V +24 -3 V +24 -3 V +24 -4 V +24 -3 V +24 -4 V +24 -4 V +25 -4 V +24 -4 V +24 -4 V +24 -5 V +24 -4 V +24 -5 V +24 -5 V +24 -5 V +24 -5 V +24 -5 V +24 -6 V +24 -5 V +24 -6 V +24 -6 V +24 -6 V +24 -6 V +24 -7 V +24 -6 V +24 -7 V +24 -7 V +24 -8 V +24 -7 V +24 -8 V +24 -8 V +24 -8 V +24 -9 V +24 -9 V +24 -9 V +25 -9 V +24 -10 V +24 -9 V +24 -11 V +24 -10 V +24 -11 V +24 -11 V +24 -12 V +24 -11 V +24 -13 V +24 -12 V +24 -13 V +24 -13 V +24 -14 V +24 -14 V +24 -14 V +24 -15 V +24 -16 V +24 -16 V +24 -16 V +24 -17 V +24 -17 V +24 -17 V +24 -19 V +24 -18 V +24 -20 V +24 -20 V +24 -20 V +25 -21 V +24 -22 V +24 -22 V +24 -23 V +24 -23 V +24 -24 V +24 -25 V +24 -26 V +24 -26 V +24 -27 V +24 -28 V +24 -28 V +24 -29 V +24 -30 V +24 -31 V +24 -32 V +24 -32 V +24 -34 V +24 -34 V +24 -35 V +24 -37 V +24 -37 V +24 -38 V +24 -39 V +24 -40 V +24 -42 V +24 -42 V +24 -43 V +25 -45 V +24 -46 V +24 -46 V +24 -49 V +24 -49 V +stroke 3390 2910 M +24 -50 V +24 -52 V +24 -53 V +24 -55 V +24 -56 V +24 -57 V +24 -59 V +24 -60 V +24 -61 V +24 -63 V +24 -65 V +24 -66 V +24 -68 V +24 -70 V +24 -71 V +24 -73 V +24 -75 V +24 -76 V +24 -78 V +24 -81 V +24 -82 V +24 -84 V +25 -86 V +24 -88 V +24 -90 V +24 -93 V +24 -94 V +24 -97 V +24 -99 V +24 -101 V +24 -104 V +24 -106 V +11 -49 V +% End plot #1 +stroke +1.000 UL +LTb +938 4871 N +938 448 L +6009 0 V +0 4423 V +-6009 0 V +Z stroke +1.000 UP +1.000 UL +LTb +stroke +grestore +end +showpage +%%Trailer +%%DocumentFonts: Times-BoldItalic diff -Naur ns-3.19/src/lr-wpan/doc/802-15-4-per-sens.eps ns-3.20/src/lr-wpan/doc/802-15-4-per-sens.eps --- ns-3.19/src/lr-wpan/doc/802-15-4-per-sens.eps 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/doc/802-15-4-per-sens.eps 2014-06-17 10:33:13.893995962 -0700 @@ -0,0 +1,3773 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: 802.15.4-per-sens.eps +%%Creator: gnuplot 4.6 patchlevel 4 (Gentoo revision r2) +%%CreationDate: Wed Apr 23 12:42:53 2014 +%%DocumentFonts: (atend) +%%BoundingBox: 50 50 410 302 +%%EndComments +%%BeginProlog +/gnudict 256 dict def +gnudict begin +% +% The following true/false flags may be edited by hand if desired. +% The unit line width and grayscale image gamma correction may also be changed. +% +/Color true def +/Blacktext false def +/Solid false def +/Dashlength 1 def +/Landscape false def +/Level1 false def +/Rounded false def +/ClipToBoundingBox false def +/SuppressPDFMark false def +/TransparentPatterns false def +/gnulinewidth 5.000 def +/userlinewidth gnulinewidth def +/Gamma 1.0 def +/BackgroundColor {-1.000 -1.000 -1.000} def +% +/vshift -46 def +/dl1 { + 10.0 Dashlength mul mul + Rounded { currentlinewidth 0.75 mul sub dup 0 le { pop 0.01 } if } if +} def +/dl2 { + 10.0 Dashlength mul mul + Rounded { currentlinewidth 0.75 mul add } if +} def +/hpt_ 31.5 def +/vpt_ 31.5 def +/hpt hpt_ def +/vpt vpt_ def +/doclip { + ClipToBoundingBox { + newpath 50 50 moveto 410 50 lineto 410 302 lineto 50 302 lineto closepath + clip + } if +} def +% +% Gnuplot Prolog Version 4.6 (September 2012) +% +%/SuppressPDFMark true def +% +/M {moveto} bind def +/L {lineto} bind def +/R {rmoveto} bind def +/V {rlineto} bind def +/N {newpath moveto} bind def +/Z {closepath} bind def +/C {setrgbcolor} bind def +/f {rlineto fill} bind def +/g {setgray} bind def +/Gshow {show} def % May be redefined later in the file to support UTF-8 +/vpt2 vpt 2 mul def +/hpt2 hpt 2 mul def +/Lshow {currentpoint stroke M 0 vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/Rshow {currentpoint stroke M dup stringwidth pop neg vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/Cshow {currentpoint stroke M dup stringwidth pop -2 div vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/UP {dup vpt_ mul /vpt exch def hpt_ mul /hpt exch def + /hpt2 hpt 2 mul def /vpt2 vpt 2 mul def} def +/DL {Color {setrgbcolor Solid {pop []} if 0 setdash} + {pop pop pop 0 setgray Solid {pop []} if 0 setdash} ifelse} def +/BL {stroke userlinewidth 2 mul setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +/AL {stroke userlinewidth 2 div setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +/UL {dup gnulinewidth mul /userlinewidth exch def + dup 1 lt {pop 1} if 10 mul /udl exch def} def +/PL {stroke userlinewidth setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +3.8 setmiterlimit +% Default Line colors +/LCw {1 1 1} def +/LCb {0 0 0} def +/LCa {0 0 0} def +/LC0 {1 0 0} def +/LC1 {0 1 0} def +/LC2 {0 0 1} def +/LC3 {1 0 1} def +/LC4 {0 1 1} def +/LC5 {1 1 0} def +/LC6 {0 0 0} def +/LC7 {1 0.3 0} def +/LC8 {0.5 0.5 0.5} def +% Default Line Types +/LTw {PL [] 1 setgray} def +/LTb {BL [] LCb DL} def +/LTa {AL [1 udl mul 2 udl mul] 0 setdash LCa setrgbcolor} def +/LT0 {PL [] LC0 DL} def +/LT1 {PL [4 dl1 2 dl2] LC1 DL} def +/LT2 {PL [2 dl1 3 dl2] LC2 DL} def +/LT3 {PL [1 dl1 1.5 dl2] LC3 DL} def +/LT4 {PL [6 dl1 2 dl2 1 dl1 2 dl2] LC4 DL} def +/LT5 {PL [3 dl1 3 dl2 1 dl1 3 dl2] LC5 DL} def +/LT6 {PL [2 dl1 2 dl2 2 dl1 6 dl2] LC6 DL} def +/LT7 {PL [1 dl1 2 dl2 6 dl1 2 dl2 1 dl1 2 dl2] LC7 DL} def +/LT8 {PL [2 dl1 2 dl2 2 dl1 2 dl2 2 dl1 2 dl2 2 dl1 4 dl2] LC8 DL} def +/Pnt {stroke [] 0 setdash gsave 1 setlinecap M 0 0 V stroke grestore} def +/Dia {stroke [] 0 setdash 2 copy vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath stroke + Pnt} def +/Pls {stroke [] 0 setdash vpt sub M 0 vpt2 V + currentpoint stroke M + hpt neg vpt neg R hpt2 0 V stroke + } def +/Box {stroke [] 0 setdash 2 copy exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath stroke + Pnt} def +/Crs {stroke [] 0 setdash exch hpt sub exch vpt add M + hpt2 vpt2 neg V currentpoint stroke M + hpt2 neg 0 R hpt2 vpt2 V stroke} def +/TriU {stroke [] 0 setdash 2 copy vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath stroke + Pnt} def +/Star {2 copy Pls Crs} def +/BoxF {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath fill} def +/TriUF {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath fill} def +/TriD {stroke [] 0 setdash 2 copy vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath stroke + Pnt} def +/TriDF {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath fill} def +/DiaF {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath fill} def +/Pent {stroke [] 0 setdash 2 copy gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath stroke grestore Pnt} def +/PentF {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath fill grestore} def +/Circle {stroke [] 0 setdash 2 copy + hpt 0 360 arc stroke Pnt} def +/CircleF {stroke [] 0 setdash hpt 0 360 arc fill} def +/C0 {BL [] 0 setdash 2 copy moveto vpt 90 450 arc} bind def +/C1 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc closepath fill + vpt 0 360 arc closepath} bind def +/C2 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C3 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C4 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 180 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C5 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc + 2 copy moveto + 2 copy vpt 180 270 arc closepath fill + vpt 0 360 arc} bind def +/C6 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C7 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C8 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 270 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C9 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 270 450 arc closepath fill + vpt 0 360 arc closepath} bind def +/C10 {BL [] 0 setdash 2 copy 2 copy moveto vpt 270 360 arc closepath fill + 2 copy moveto + 2 copy vpt 90 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C11 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 180 arc closepath fill + 2 copy moveto + 2 copy vpt 270 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C12 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 180 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C13 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc closepath fill + 2 copy moveto + 2 copy vpt 180 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C14 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 360 arc closepath fill + vpt 0 360 arc} bind def +/C15 {BL [] 0 setdash 2 copy vpt 0 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/Rec {newpath 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto + neg 0 rlineto closepath} bind def +/Square {dup Rec} bind def +/Bsquare {vpt sub exch vpt sub exch vpt2 Square} bind def +/S0 {BL [] 0 setdash 2 copy moveto 0 vpt rlineto BL Bsquare} bind def +/S1 {BL [] 0 setdash 2 copy vpt Square fill Bsquare} bind def +/S2 {BL [] 0 setdash 2 copy exch vpt sub exch vpt Square fill Bsquare} bind def +/S3 {BL [] 0 setdash 2 copy exch vpt sub exch vpt2 vpt Rec fill Bsquare} bind def +/S4 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt Square fill Bsquare} bind def +/S5 {BL [] 0 setdash 2 copy 2 copy vpt Square fill + exch vpt sub exch vpt sub vpt Square fill Bsquare} bind def +/S6 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill Bsquare} bind def +/S7 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill + 2 copy vpt Square fill Bsquare} bind def +/S8 {BL [] 0 setdash 2 copy vpt sub vpt Square fill Bsquare} bind def +/S9 {BL [] 0 setdash 2 copy vpt sub vpt vpt2 Rec fill Bsquare} bind def +/S10 {BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt Square fill + Bsquare} bind def +/S11 {BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt2 vpt Rec fill + Bsquare} bind def +/S12 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill Bsquare} bind def +/S13 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill + 2 copy vpt Square fill Bsquare} bind def +/S14 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill + 2 copy exch vpt sub exch vpt Square fill Bsquare} bind def +/S15 {BL [] 0 setdash 2 copy Bsquare fill Bsquare} bind def +/D0 {gsave translate 45 rotate 0 0 S0 stroke grestore} bind def +/D1 {gsave translate 45 rotate 0 0 S1 stroke grestore} bind def +/D2 {gsave translate 45 rotate 0 0 S2 stroke grestore} bind def +/D3 {gsave translate 45 rotate 0 0 S3 stroke grestore} bind def +/D4 {gsave translate 45 rotate 0 0 S4 stroke grestore} bind def +/D5 {gsave translate 45 rotate 0 0 S5 stroke grestore} bind def +/D6 {gsave translate 45 rotate 0 0 S6 stroke grestore} bind def +/D7 {gsave translate 45 rotate 0 0 S7 stroke grestore} bind def +/D8 {gsave translate 45 rotate 0 0 S8 stroke grestore} bind def +/D9 {gsave translate 45 rotate 0 0 S9 stroke grestore} bind def +/D10 {gsave translate 45 rotate 0 0 S10 stroke grestore} bind def +/D11 {gsave translate 45 rotate 0 0 S11 stroke grestore} bind def +/D12 {gsave translate 45 rotate 0 0 S12 stroke grestore} bind def +/D13 {gsave translate 45 rotate 0 0 S13 stroke grestore} bind def +/D14 {gsave translate 45 rotate 0 0 S14 stroke grestore} bind def +/D15 {gsave translate 45 rotate 0 0 S15 stroke grestore} bind def +/DiaE {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath stroke} def +/BoxE {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath stroke} def +/TriUE {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath stroke} def +/TriDE {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath stroke} def +/PentE {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath stroke grestore} def +/CircE {stroke [] 0 setdash + hpt 0 360 arc stroke} def +/Opaque {gsave closepath 1 setgray fill grestore 0 setgray closepath} def +/DiaW {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V Opaque stroke} def +/BoxW {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V Opaque stroke} def +/TriUW {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V Opaque stroke} def +/TriDW {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V Opaque stroke} def +/PentW {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + Opaque stroke grestore} def +/CircW {stroke [] 0 setdash + hpt 0 360 arc Opaque stroke} def +/BoxFill {gsave Rec 1 setgray fill grestore} def +/Density { + /Fillden exch def + currentrgbcolor + /ColB exch def /ColG exch def /ColR exch def + /ColR ColR Fillden mul Fillden sub 1 add def + /ColG ColG Fillden mul Fillden sub 1 add def + /ColB ColB Fillden mul Fillden sub 1 add def + ColR ColG ColB setrgbcolor} def +/BoxColFill {gsave Rec PolyFill} def +/PolyFill {gsave Density fill grestore grestore} def +/h {rlineto rlineto rlineto gsave closepath fill grestore} bind def +% +% PostScript Level 1 Pattern Fill routine for rectangles +% Usage: x y w h s a XX PatternFill +% x,y = lower left corner of box to be filled +% w,h = width and height of box +% a = angle in degrees between lines and x-axis +% XX = 0/1 for no/yes cross-hatch +% +/PatternFill {gsave /PFa [ 9 2 roll ] def + PFa 0 get PFa 2 get 2 div add PFa 1 get PFa 3 get 2 div add translate + PFa 2 get -2 div PFa 3 get -2 div PFa 2 get PFa 3 get Rec + TransparentPatterns {} {gsave 1 setgray fill grestore} ifelse + clip + currentlinewidth 0.5 mul setlinewidth + /PFs PFa 2 get dup mul PFa 3 get dup mul add sqrt def + 0 0 M PFa 5 get rotate PFs -2 div dup translate + 0 1 PFs PFa 4 get div 1 add floor cvi + {PFa 4 get mul 0 M 0 PFs V} for + 0 PFa 6 get ne { + 0 1 PFs PFa 4 get div 1 add floor cvi + {PFa 4 get mul 0 2 1 roll M PFs 0 V} for + } if + stroke grestore} def +% +/languagelevel where + {pop languagelevel} {1} ifelse + 2 lt + {/InterpretLevel1 true def} + {/InterpretLevel1 Level1 def} + ifelse +% +% PostScript level 2 pattern fill definitions +% +/Level2PatternFill { +/Tile8x8 {/PaintType 2 /PatternType 1 /TilingType 1 /BBox [0 0 8 8] /XStep 8 /YStep 8} + bind def +/KeepColor {currentrgbcolor [/Pattern /DeviceRGB] setcolorspace} bind def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 8 8 L 0 8 M 8 0 L stroke} +>> matrix makepattern +/Pat1 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 8 8 L 0 8 M 8 0 L stroke + 0 4 M 4 8 L 8 4 L 4 0 L 0 4 L stroke} +>> matrix makepattern +/Pat2 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 0 8 L + 8 8 L 8 0 L 0 0 L fill} +>> matrix makepattern +/Pat3 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -4 8 M 8 -4 L + 0 12 M 12 0 L stroke} +>> matrix makepattern +/Pat4 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -4 0 M 8 12 L + 0 -4 M 12 8 L stroke} +>> matrix makepattern +/Pat5 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -2 8 M 4 -4 L + 0 12 M 8 -4 L 4 12 M 10 0 L stroke} +>> matrix makepattern +/Pat6 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -2 0 M 4 12 L + 0 -4 M 8 12 L 4 -4 M 10 8 L stroke} +>> matrix makepattern +/Pat7 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 8 -2 M -4 4 L + 12 0 M -4 8 L 12 4 M 0 10 L stroke} +>> matrix makepattern +/Pat8 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 -2 M 12 4 L + -4 0 M 12 8 L -4 4 M 8 10 L stroke} +>> matrix makepattern +/Pat9 exch def +/Pattern1 {PatternBgnd KeepColor Pat1 setpattern} bind def +/Pattern2 {PatternBgnd KeepColor Pat2 setpattern} bind def +/Pattern3 {PatternBgnd KeepColor Pat3 setpattern} bind def +/Pattern4 {PatternBgnd KeepColor Landscape {Pat5} {Pat4} ifelse setpattern} bind def +/Pattern5 {PatternBgnd KeepColor Landscape {Pat4} {Pat5} ifelse setpattern} bind def +/Pattern6 {PatternBgnd KeepColor Landscape {Pat9} {Pat6} ifelse setpattern} bind def +/Pattern7 {PatternBgnd KeepColor Landscape {Pat8} {Pat7} ifelse setpattern} bind def +} def +% +% +%End of PostScript Level 2 code +% +/PatternBgnd { + TransparentPatterns {} {gsave 1 setgray fill grestore} ifelse +} def +% +% Substitute for Level 2 pattern fill codes with +% grayscale if Level 2 support is not selected. +% +/Level1PatternFill { +/Pattern1 {0.250 Density} bind def +/Pattern2 {0.500 Density} bind def +/Pattern3 {0.750 Density} bind def +/Pattern4 {0.125 Density} bind def +/Pattern5 {0.375 Density} bind def +/Pattern6 {0.625 Density} bind def +/Pattern7 {0.875 Density} bind def +} def +% +% Now test for support of Level 2 code +% +Level1 {Level1PatternFill} {Level2PatternFill} ifelse +% +/Symbol-Oblique /Symbol findfont [1 0 .167 1 0 0] makefont +dup length dict begin {1 index /FID eq {pop pop} {def} ifelse} forall +currentdict end definefont pop +/MFshow { + { dup 5 get 3 ge + { 5 get 3 eq {gsave} {grestore} ifelse } + {dup dup 0 get findfont exch 1 get scalefont setfont + [ currentpoint ] exch dup 2 get 0 exch R dup 5 get 2 ne {dup dup 6 + get exch 4 get {Gshow} {stringwidth pop 0 R} ifelse }if dup 5 get 0 eq + {dup 3 get {2 get neg 0 exch R pop} {pop aload pop M} ifelse} {dup 5 + get 1 eq {dup 2 get exch dup 3 get exch 6 get stringwidth pop -2 div + dup 0 R} {dup 6 get stringwidth pop -2 div 0 R 6 get + show 2 index {aload pop M neg 3 -1 roll neg R pop pop} {pop pop pop + pop aload pop M} ifelse }ifelse }ifelse } + ifelse } + forall} def +/Gswidth {dup type /stringtype eq {stringwidth} {pop (n) stringwidth} ifelse} def +/MFwidth {0 exch { dup 5 get 3 ge { 5 get 3 eq { 0 } { pop } ifelse } + {dup 3 get{dup dup 0 get findfont exch 1 get scalefont setfont + 6 get Gswidth pop add} {pop} ifelse} ifelse} forall} def +/MLshow { currentpoint stroke M + 0 exch R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/MRshow { currentpoint stroke M + exch dup MFwidth neg 3 -1 roll R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/MCshow { currentpoint stroke M + exch dup MFwidth -2 div 3 -1 roll R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/XYsave { [( ) 1 2 true false 3 ()] } bind def +/XYrestore { [( ) 1 2 true false 4 ()] } bind def +Level1 SuppressPDFMark or +{} { +/SDict 10 dict def +systemdict /pdfmark known not { + userdict /pdfmark systemdict /cleartomark get put +} if +SDict begin [ + /Title (802.15.4-per-sens.eps) + /Subject (gnuplot plot) + /Creator (gnuplot 4.6 patchlevel 4 (Gentoo revision r2)) + /Author (jopen) +% /Producer (gnuplot) +% /Keywords () + /CreationDate (Wed Apr 23 12:42:53 2014) + /DOCINFO pdfmark +end +} ifelse +end +%%EndProlog +%%Page: 1 1 +gnudict begin +gsave +doclip +50 50 translate +0.050 0.050 scale +0 setgray +newpath +(Times-BoldItalic) findfont 140 scalefont setfont +BackgroundColor 0 lt 3 1 roll 0 lt exch 0 lt or or not {BackgroundColor C 1.000 0 0 7200.00 5040.00 BoxColFill} if +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +938 448 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 448 M +63 0 V +5946 0 R +-63 0 V +stroke +854 448 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-12)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +938 764 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +LCa setrgbcolor +938 1080 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 1080 M +63 0 V +5946 0 R +-63 0 V +stroke +854 1080 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-10)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +938 1396 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +LCa setrgbcolor +938 1712 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 1712 M +63 0 V +5946 0 R +-63 0 V +stroke +854 1712 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-08)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +938 2028 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +LCa setrgbcolor +938 2344 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 2344 M +63 0 V +5946 0 R +-63 0 V +stroke +854 2344 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1e-06)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +938 2660 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +LCa setrgbcolor +938 2975 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 2975 M +63 0 V +5946 0 R +-63 0 V +stroke +854 2975 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.0001)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +938 3291 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +LCa setrgbcolor +938 3607 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 3607 M +63 0 V +5946 0 R +-63 0 V +stroke +854 3607 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.01)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +938 3923 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +LCa setrgbcolor +938 4239 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 4239 M +63 0 V +5946 0 R +-63 0 V +stroke +854 4239 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +938 4555 M +31 0 V +5978 0 R +-31 0 V +stroke +LTa +LCa setrgbcolor +938 4871 M +6009 0 V +stroke +LTb +LCb setrgbcolor +938 4871 M +63 0 V +5946 0 R +-63 0 V +stroke +854 4871 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 100)] +] -46.7 MRshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +938 448 M +0 4423 V +stroke +LTb +LCb setrgbcolor +938 448 M +0 63 V +0 4360 R +0 -63 V +stroke +938 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-130)] +] -46.7 MCshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +1940 448 M +0 4423 V +stroke +LTb +LCb setrgbcolor +1940 448 M +0 63 V +0 4360 R +0 -63 V +stroke +1940 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-125)] +] -46.7 MCshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +2941 448 M +0 4423 V +stroke +LTb +LCb setrgbcolor +2941 448 M +0 63 V +0 4360 R +0 -63 V +stroke +2941 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-120)] +] -46.7 MCshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +3943 448 M +0 4423 V +stroke +LTb +LCb setrgbcolor +3943 448 M +0 63 V +0 4360 R +0 -63 V +stroke +3943 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-115)] +] -46.7 MCshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +4944 448 M +0 4423 V +stroke +LTb +LCb setrgbcolor +4944 448 M +0 63 V +0 4360 R +0 -63 V +stroke +4944 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-110)] +] -46.7 MCshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +5946 448 M +0 4220 V +0 140 R +0 63 V +stroke +LTb +LCb setrgbcolor +5946 448 M +0 63 V +0 4360 R +0 -63 V +stroke +5946 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-105)] +] -46.7 MCshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTa +LCa setrgbcolor +6947 448 M +0 4423 V +stroke +LTb +LCb setrgbcolor +6947 448 M +0 63 V +0 4360 R +0 -63 V +stroke +6947 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (-100)] +] -46.7 MCshow +1.000 UL +LTb +LCb setrgbcolor +1.000 UL +LTb +LCb setrgbcolor +938 4871 N +938 448 L +6009 0 V +0 4423 V +-6009 0 V +Z stroke +LCb setrgbcolor +112 2659 M +currentpoint gsave translate -270 rotate 0 0 moveto +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (Packet Error Rate \(PER\))] +] -46.7 MCshow +grestore +LTb +LCb setrgbcolor +3942 98 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (RxPower \(dBm\))] +] -46.7 MCshow +LTb +1.000 UP +1.000 UL +LTb +LCb setrgbcolor +% Begin plot #1 +5.000 UL +LT0 +LC0 setrgbcolor +LCb setrgbcolor +6296 4738 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (802.15.4)] +] -46.7 MRshow +LT0 +6380 4738 M +399 0 V +938 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 1142 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +3 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 1351 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 1559 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 1767 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +3 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 1976 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 2184 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 2392 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 2600 4871 M +2 0 V +2 0 V +2 0 V +3 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 2809 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 3017 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 3225 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +3 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 3434 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 3642 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 3850 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +3 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 4059 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 4267 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 4475 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +3 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 4684 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 4892 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +stroke 5100 4871 M +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 0 V +2 -1 V +2 0 V +2 -1 V +2 0 V +2 -1 V +2 0 V +2 -1 V +2 0 V +2 -1 V +2 0 V +2 -1 V +2 0 V +2 -1 V +2 0 V +2 -1 V +2 -1 V +2 0 V +3 -1 V +2 0 V +2 -1 V +2 -1 V +2 -1 V +2 0 V +2 -1 V +2 -1 V +2 -1 V +2 0 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 0 V +stroke 5309 4841 M +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -2 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -1 V +2 -2 V +2 -1 V +2 -1 V +2 -1 V +2 -2 V +2 -1 V +2 -1 V +2 -2 V +2 -1 V +2 -2 V +2 -1 V +2 -1 V +2 -2 V +2 -1 V +2 -2 V +2 -1 V +2 -2 V +2 -1 V +2 -2 V +2 -1 V +2 -2 V +2 -2 V +2 -1 V +2 -2 V +2 -2 V +2 -1 V +2 -2 V +2 -2 V +2 -1 V +2 -2 V +2 -2 V +2 -2 V +2 -1 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -1 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -3 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -2 V +2 -3 V +2 -2 V +2 -2 V +2 -2 V +2 -3 V +2 -2 V +2 -2 V +2 -2 V +2 -3 V +2 -2 V +2 -2 V +2 -3 V +2 -2 V +2 -2 V +2 -3 V +2 -2 V +2 -3 V +2 -2 V +2 -3 V +2 -2 V +2 -3 V +2 -2 V +2 -3 V +2 -2 V +2 -3 V +2 -2 V +2 -3 V +2 -2 V +2 -3 V +2 -2 V +stroke 5517 4654 M +2 -3 V +2 -3 V +2 -2 V +2 -3 V +2 -3 V +2 -2 V +2 -3 V +2 -3 V +2 -2 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -2 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -2 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -4 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -3 V +2 -4 V +2 -3 V +2 -3 V +2 -3 V +2 -4 V +2 -3 V +2 -3 V +2 -3 V +2 -4 V +2 -3 V +2 -3 V +2 -4 V +2 -3 V +2 -3 V +2 -4 V +2 -3 V +2 -4 V +2 -3 V +2 -3 V +2 -4 V +2 -3 V +2 -4 V +2 -3 V +2 -4 V +2 -3 V +2 -4 V +2 -3 V +2 -3 V +2 -4 V +2 -4 V +2 -3 V +2 -4 V +2 -3 V +2 -4 V +2 -3 V +2 -4 V +2 -3 V +2 -4 V +2 -4 V +2 -3 V +2 -4 V +2 -4 V +2 -3 V +2 -4 V +2 -4 V +2 -3 V +2 -4 V +2 -4 V +2 -3 V +2 -4 V +2 -4 V +2 -4 V +2 -3 V +2 -4 V +stroke 5725 4319 M +2 -4 V +2 -4 V +2 -3 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -3 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -4 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -5 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -5 V +2 -4 V +2 -4 V +2 -5 V +2 -4 V +2 -5 V +2 -4 V +2 -5 V +2 -4 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -4 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -5 V +stroke 5933 3870 M +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +3 -5 V +2 -4 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -6 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -6 V +2 -5 V +2 -5 V +2 -5 V +2 -5 V +2 -6 V +2 -5 V +2 -5 V +2 -5 V +2 -6 V +2 -5 V +2 -5 V +2 -5 V +2 -6 V +2 -5 V +2 -5 V +2 -6 V +2 -5 V +2 -5 V +2 -6 V +2 -5 V +2 -6 V +2 -5 V +2 -6 V +2 -5 V +2 -6 V +2 -5 V +2 -5 V +2 -6 V +2 -6 V +2 -5 V +2 -6 V +2 -5 V +2 -6 V +2 -5 V +2 -6 V +2 -6 V +2 -5 V +2 -6 V +2 -5 V +2 -6 V +2 -6 V +2 -6 V +2 -5 V +2 -6 V +2 -6 V +2 -5 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -5 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -5 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -7 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -6 V +2 -7 V +2 -6 V +2 -6 V +2 -6 V +stroke 6142 3294 M +2 -7 V +2 -6 V +2 -6 V +2 -6 V +2 -7 V +2 -6 V +2 -6 V +2 -7 V +2 -6 V +2 -6 V +2 -7 V +2 -6 V +2 -7 V +2 -6 V +2 -7 V +2 -6 V +2 -7 V +2 -6 V +2 -7 V +2 -6 V +2 -7 V +2 -6 V +2 -7 V +2 -6 V +2 -7 V +2 -7 V +2 -6 V +2 -7 V +2 -7 V +2 -6 V +2 -7 V +2 -7 V +2 -6 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -6 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -6 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -8 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -7 V +2 -8 V +2 -7 V +2 -7 V +2 -7 V +2 -8 V +2 -7 V +2 -7 V +2 -8 V +2 -7 V +2 -7 V +2 -8 V +2 -7 V +2 -7 V +2 -8 V +2 -7 V +2 -8 V +2 -7 V +2 -8 V +2 -7 V +2 -8 V +2 -7 V +2 -8 V +2 -7 V +2 -8 V +2 -8 V +2 -7 V +2 -8 V +2 -8 V +2 -7 V +2 -8 V +2 -8 V +2 -7 V +2 -8 V +2 -8 V +2 -8 V +2 -7 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +stroke 6350 2559 M +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -9 V +2 -8 V +2 -8 V +2 -8 V +2 -8 V +2 -9 V +2 -8 V +2 -8 V +2 -9 V +2 -8 V +2 -8 V +2 -9 V +2 -8 V +2 -9 V +2 -8 V +2 -8 V +2 -9 V +2 -8 V +2 -9 V +2 -9 V +2 -8 V +2 -9 V +2 -8 V +2 -9 V +2 -9 V +2 -8 V +2 -9 V +2 -9 V +2 -8 V +2 -9 V +2 -9 V +2 -9 V +2 -8 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -9 V +2 -10 V +2 -9 V +2 -9 V +2 -9 V +2 -10 V +2 -9 V +2 -9 V +2 -10 V +2 -9 V +2 -9 V +2 -10 V +2 -9 V +2 -10 V +2 -9 V +2 -10 V +2 -9 V +2 -10 V +2 -9 V +2 -10 V +2 -9 V +2 -10 V +2 -10 V +2 -9 V +2 -10 V +2 -10 V +2 -10 V +2 -9 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -9 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +stroke 6558 1626 M +2 -11 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -11 V +2 -10 V +2 -10 V +2 -10 V +2 -10 V +2 -11 V +2 -10 V +2 -11 V +2 -10 V +2 -10 V +2 -11 V +2 -11 V +2 -10 V +2 -11 V +2 -10 V +2 -11 V +2 -10 V +2 -11 V +2 -11 V +2 -11 V +2 -10 V +2 -11 V +3 -11 V +2 -10 V +2 -11 V +2 -12 V +2 -10 V +2 -10 V +2 -12 V +2 -12 V +2 -9 V +2 -9 V +2 -16 V +2 -11 V +2 -6 V +2 -14 V +2 -14 V +2 -8 V +2 -8 V +2 -18 V +2 -11 V +2 -11 V +2 -12 V +2 -13 V +2 0 V +2 -14 V +2 -16 V +2 -19 V +2 0 V +2 -21 V +2 0 V +2 -25 V +2 0 V +2 0 V +2 -30 V +2 0 V +2 0 V +2 -40 V +2 0 V +2 0 V +2 -55 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 -96 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +2 0 V +0 -332 V +% End plot #1 +stroke +1.000 UL +LTb +LCb setrgbcolor +938 4871 N +938 448 L +6009 0 V +0 4423 V +-6009 0 V +Z stroke +1.000 UP +1.000 UL +LTb +LCb setrgbcolor +stroke +grestore +end +showpage +%%Trailer +%%DocumentFonts: Times-BoldItalic diff -Naur ns-3.19/src/lr-wpan/doc/802-15-4-psr-distance.eps ns-3.20/src/lr-wpan/doc/802-15-4-psr-distance.eps --- ns-3.19/src/lr-wpan/doc/802-15-4-psr-distance.eps 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/doc/802-15-4-psr-distance.eps 2014-06-17 10:33:13.893995962 -0700 @@ -0,0 +1,908 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: 802.15.4-psr-distance.eps +%%Creator: gnuplot 4.4 patchlevel 2 +%%CreationDate: Tue Oct 4 13:04:05 2011 +%%DocumentFonts: (atend) +%%BoundingBox: 50 50 410 302 +%%EndComments +%%BeginProlog +/gnudict 256 dict def +gnudict begin +% +% The following true/false flags may be edited by hand if desired. +% The unit line width and grayscale image gamma correction may also be changed. +% +/Color true def +/Blacktext false def +/Solid false def +/Dashlength 1 def +/Landscape false def +/Level1 false def +/Rounded false def +/ClipToBoundingBox false def +/TransparentPatterns false def +/gnulinewidth 5.000 def +/userlinewidth gnulinewidth def +/Gamma 1.0 def +% +/vshift -46 def +/dl1 { + 10.0 Dashlength mul mul + Rounded { currentlinewidth 0.75 mul sub dup 0 le { pop 0.01 } if } if +} def +/dl2 { + 10.0 Dashlength mul mul + Rounded { currentlinewidth 0.75 mul add } if +} def +/hpt_ 31.5 def +/vpt_ 31.5 def +/hpt hpt_ def +/vpt vpt_ def +Level1 {} { +/SDict 10 dict def +systemdict /pdfmark known not { + userdict /pdfmark systemdict /cleartomark get put +} if +SDict begin [ + /Title (802.15.4-psr-distance.eps) + /Subject (gnuplot plot) + /Creator (gnuplot 4.4 patchlevel 2) + /Author (tomh) +% /Producer (gnuplot) +% /Keywords () + /CreationDate (Tue Oct 4 13:04:05 2011) + /DOCINFO pdfmark +end +} ifelse +/doclip { + ClipToBoundingBox { + newpath 50 50 moveto 410 50 lineto 410 302 lineto 50 302 lineto closepath + clip + } if +} def +% +% Gnuplot Prolog Version 4.4 (August 2010) +% +%/SuppressPDFMark true def +% +/M {moveto} bind def +/L {lineto} bind def +/R {rmoveto} bind def +/V {rlineto} bind def +/N {newpath moveto} bind def +/Z {closepath} bind def +/C {setrgbcolor} bind def +/f {rlineto fill} bind def +/g {setgray} bind def +/Gshow {show} def % May be redefined later in the file to support UTF-8 +/vpt2 vpt 2 mul def +/hpt2 hpt 2 mul def +/Lshow {currentpoint stroke M 0 vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/Rshow {currentpoint stroke M dup stringwidth pop neg vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/Cshow {currentpoint stroke M dup stringwidth pop -2 div vshift R + Blacktext {gsave 0 setgray show grestore} {show} ifelse} def +/UP {dup vpt_ mul /vpt exch def hpt_ mul /hpt exch def + /hpt2 hpt 2 mul def /vpt2 vpt 2 mul def} def +/DL {Color {setrgbcolor Solid {pop []} if 0 setdash} + {pop pop pop 0 setgray Solid {pop []} if 0 setdash} ifelse} def +/BL {stroke userlinewidth 2 mul setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +/AL {stroke userlinewidth 2 div setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +/UL {dup gnulinewidth mul /userlinewidth exch def + dup 1 lt {pop 1} if 10 mul /udl exch def} def +/PL {stroke userlinewidth setlinewidth + Rounded {1 setlinejoin 1 setlinecap} if} def +3.8 setmiterlimit +% Default Line colors +/LCw {1 1 1} def +/LCb {0 0 0} def +/LCa {0 0 0} def +/LC0 {1 0 0} def +/LC1 {0 1 0} def +/LC2 {0 0 1} def +/LC3 {1 0 1} def +/LC4 {0 1 1} def +/LC5 {1 1 0} def +/LC6 {0 0 0} def +/LC7 {1 0.3 0} def +/LC8 {0.5 0.5 0.5} def +% Default Line Types +/LTw {PL [] 1 setgray} def +/LTb {BL [] LCb DL} def +/LTa {AL [1 udl mul 2 udl mul] 0 setdash LCa setrgbcolor} def +/LT0 {PL [] LC0 DL} def +/LT1 {PL [4 dl1 2 dl2] LC1 DL} def +/LT2 {PL [2 dl1 3 dl2] LC2 DL} def +/LT3 {PL [1 dl1 1.5 dl2] LC3 DL} def +/LT4 {PL [6 dl1 2 dl2 1 dl1 2 dl2] LC4 DL} def +/LT5 {PL [3 dl1 3 dl2 1 dl1 3 dl2] LC5 DL} def +/LT6 {PL [2 dl1 2 dl2 2 dl1 6 dl2] LC6 DL} def +/LT7 {PL [1 dl1 2 dl2 6 dl1 2 dl2 1 dl1 2 dl2] LC7 DL} def +/LT8 {PL [2 dl1 2 dl2 2 dl1 2 dl2 2 dl1 2 dl2 2 dl1 4 dl2] LC8 DL} def +/Pnt {stroke [] 0 setdash gsave 1 setlinecap M 0 0 V stroke grestore} def +/Dia {stroke [] 0 setdash 2 copy vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath stroke + Pnt} def +/Pls {stroke [] 0 setdash vpt sub M 0 vpt2 V + currentpoint stroke M + hpt neg vpt neg R hpt2 0 V stroke + } def +/Box {stroke [] 0 setdash 2 copy exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath stroke + Pnt} def +/Crs {stroke [] 0 setdash exch hpt sub exch vpt add M + hpt2 vpt2 neg V currentpoint stroke M + hpt2 neg 0 R hpt2 vpt2 V stroke} def +/TriU {stroke [] 0 setdash 2 copy vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath stroke + Pnt} def +/Star {2 copy Pls Crs} def +/BoxF {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath fill} def +/TriUF {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath fill} def +/TriD {stroke [] 0 setdash 2 copy vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath stroke + Pnt} def +/TriDF {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath fill} def +/DiaF {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath fill} def +/Pent {stroke [] 0 setdash 2 copy gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath stroke grestore Pnt} def +/PentF {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath fill grestore} def +/Circle {stroke [] 0 setdash 2 copy + hpt 0 360 arc stroke Pnt} def +/CircleF {stroke [] 0 setdash hpt 0 360 arc fill} def +/C0 {BL [] 0 setdash 2 copy moveto vpt 90 450 arc} bind def +/C1 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc closepath fill + vpt 0 360 arc closepath} bind def +/C2 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C3 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C4 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 180 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C5 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc + 2 copy moveto + 2 copy vpt 180 270 arc closepath fill + vpt 0 360 arc} bind def +/C6 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C7 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 270 arc closepath fill + vpt 0 360 arc closepath} bind def +/C8 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 270 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C9 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 270 450 arc closepath fill + vpt 0 360 arc closepath} bind def +/C10 {BL [] 0 setdash 2 copy 2 copy moveto vpt 270 360 arc closepath fill + 2 copy moveto + 2 copy vpt 90 180 arc closepath fill + vpt 0 360 arc closepath} bind def +/C11 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 180 arc closepath fill + 2 copy moveto + 2 copy vpt 270 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C12 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 180 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C13 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 0 90 arc closepath fill + 2 copy moveto + 2 copy vpt 180 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/C14 {BL [] 0 setdash 2 copy moveto + 2 copy vpt 90 360 arc closepath fill + vpt 0 360 arc} bind def +/C15 {BL [] 0 setdash 2 copy vpt 0 360 arc closepath fill + vpt 0 360 arc closepath} bind def +/Rec {newpath 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto + neg 0 rlineto closepath} bind def +/Square {dup Rec} bind def +/Bsquare {vpt sub exch vpt sub exch vpt2 Square} bind def +/S0 {BL [] 0 setdash 2 copy moveto 0 vpt rlineto BL Bsquare} bind def +/S1 {BL [] 0 setdash 2 copy vpt Square fill Bsquare} bind def +/S2 {BL [] 0 setdash 2 copy exch vpt sub exch vpt Square fill Bsquare} bind def +/S3 {BL [] 0 setdash 2 copy exch vpt sub exch vpt2 vpt Rec fill Bsquare} bind def +/S4 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt Square fill Bsquare} bind def +/S5 {BL [] 0 setdash 2 copy 2 copy vpt Square fill + exch vpt sub exch vpt sub vpt Square fill Bsquare} bind def +/S6 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill Bsquare} bind def +/S7 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill + 2 copy vpt Square fill Bsquare} bind def +/S8 {BL [] 0 setdash 2 copy vpt sub vpt Square fill Bsquare} bind def +/S9 {BL [] 0 setdash 2 copy vpt sub vpt vpt2 Rec fill Bsquare} bind def +/S10 {BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt Square fill + Bsquare} bind def +/S11 {BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt2 vpt Rec fill + Bsquare} bind def +/S12 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill Bsquare} bind def +/S13 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill + 2 copy vpt Square fill Bsquare} bind def +/S14 {BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill + 2 copy exch vpt sub exch vpt Square fill Bsquare} bind def +/S15 {BL [] 0 setdash 2 copy Bsquare fill Bsquare} bind def +/D0 {gsave translate 45 rotate 0 0 S0 stroke grestore} bind def +/D1 {gsave translate 45 rotate 0 0 S1 stroke grestore} bind def +/D2 {gsave translate 45 rotate 0 0 S2 stroke grestore} bind def +/D3 {gsave translate 45 rotate 0 0 S3 stroke grestore} bind def +/D4 {gsave translate 45 rotate 0 0 S4 stroke grestore} bind def +/D5 {gsave translate 45 rotate 0 0 S5 stroke grestore} bind def +/D6 {gsave translate 45 rotate 0 0 S6 stroke grestore} bind def +/D7 {gsave translate 45 rotate 0 0 S7 stroke grestore} bind def +/D8 {gsave translate 45 rotate 0 0 S8 stroke grestore} bind def +/D9 {gsave translate 45 rotate 0 0 S9 stroke grestore} bind def +/D10 {gsave translate 45 rotate 0 0 S10 stroke grestore} bind def +/D11 {gsave translate 45 rotate 0 0 S11 stroke grestore} bind def +/D12 {gsave translate 45 rotate 0 0 S12 stroke grestore} bind def +/D13 {gsave translate 45 rotate 0 0 S13 stroke grestore} bind def +/D14 {gsave translate 45 rotate 0 0 S14 stroke grestore} bind def +/D15 {gsave translate 45 rotate 0 0 S15 stroke grestore} bind def +/DiaE {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V closepath stroke} def +/BoxE {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V closepath stroke} def +/TriUE {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V closepath stroke} def +/TriDE {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V closepath stroke} def +/PentE {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + closepath stroke grestore} def +/CircE {stroke [] 0 setdash + hpt 0 360 arc stroke} def +/Opaque {gsave closepath 1 setgray fill grestore 0 setgray closepath} def +/DiaW {stroke [] 0 setdash vpt add M + hpt neg vpt neg V hpt vpt neg V + hpt vpt V hpt neg vpt V Opaque stroke} def +/BoxW {stroke [] 0 setdash exch hpt sub exch vpt add M + 0 vpt2 neg V hpt2 0 V 0 vpt2 V + hpt2 neg 0 V Opaque stroke} def +/TriUW {stroke [] 0 setdash vpt 1.12 mul add M + hpt neg vpt -1.62 mul V + hpt 2 mul 0 V + hpt neg vpt 1.62 mul V Opaque stroke} def +/TriDW {stroke [] 0 setdash vpt 1.12 mul sub M + hpt neg vpt 1.62 mul V + hpt 2 mul 0 V + hpt neg vpt -1.62 mul V Opaque stroke} def +/PentW {stroke [] 0 setdash gsave + translate 0 hpt M 4 {72 rotate 0 hpt L} repeat + Opaque stroke grestore} def +/CircW {stroke [] 0 setdash + hpt 0 360 arc Opaque stroke} def +/BoxFill {gsave Rec 1 setgray fill grestore} def +/Density { + /Fillden exch def + currentrgbcolor + /ColB exch def /ColG exch def /ColR exch def + /ColR ColR Fillden mul Fillden sub 1 add def + /ColG ColG Fillden mul Fillden sub 1 add def + /ColB ColB Fillden mul Fillden sub 1 add def + ColR ColG ColB setrgbcolor} def +/BoxColFill {gsave Rec PolyFill} def +/PolyFill {gsave Density fill grestore grestore} def +/h {rlineto rlineto rlineto gsave closepath fill grestore} bind def +% +% PostScript Level 1 Pattern Fill routine for rectangles +% Usage: x y w h s a XX PatternFill +% x,y = lower left corner of box to be filled +% w,h = width and height of box +% a = angle in degrees between lines and x-axis +% XX = 0/1 for no/yes cross-hatch +% +/PatternFill {gsave /PFa [ 9 2 roll ] def + PFa 0 get PFa 2 get 2 div add PFa 1 get PFa 3 get 2 div add translate + PFa 2 get -2 div PFa 3 get -2 div PFa 2 get PFa 3 get Rec + gsave 1 setgray fill grestore clip + currentlinewidth 0.5 mul setlinewidth + /PFs PFa 2 get dup mul PFa 3 get dup mul add sqrt def + 0 0 M PFa 5 get rotate PFs -2 div dup translate + 0 1 PFs PFa 4 get div 1 add floor cvi + {PFa 4 get mul 0 M 0 PFs V} for + 0 PFa 6 get ne { + 0 1 PFs PFa 4 get div 1 add floor cvi + {PFa 4 get mul 0 2 1 roll M PFs 0 V} for + } if + stroke grestore} def +% +/languagelevel where + {pop languagelevel} {1} ifelse + 2 lt + {/InterpretLevel1 true def} + {/InterpretLevel1 Level1 def} + ifelse +% +% PostScript level 2 pattern fill definitions +% +/Level2PatternFill { +/Tile8x8 {/PaintType 2 /PatternType 1 /TilingType 1 /BBox [0 0 8 8] /XStep 8 /YStep 8} + bind def +/KeepColor {currentrgbcolor [/Pattern /DeviceRGB] setcolorspace} bind def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 8 8 L 0 8 M 8 0 L stroke} +>> matrix makepattern +/Pat1 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 8 8 L 0 8 M 8 0 L stroke + 0 4 M 4 8 L 8 4 L 4 0 L 0 4 L stroke} +>> matrix makepattern +/Pat2 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 0 M 0 8 L + 8 8 L 8 0 L 0 0 L fill} +>> matrix makepattern +/Pat3 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -4 8 M 8 -4 L + 0 12 M 12 0 L stroke} +>> matrix makepattern +/Pat4 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -4 0 M 8 12 L + 0 -4 M 12 8 L stroke} +>> matrix makepattern +/Pat5 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -2 8 M 4 -4 L + 0 12 M 8 -4 L 4 12 M 10 0 L stroke} +>> matrix makepattern +/Pat6 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop -2 0 M 4 12 L + 0 -4 M 8 12 L 4 -4 M 10 8 L stroke} +>> matrix makepattern +/Pat7 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 8 -2 M -4 4 L + 12 0 M -4 8 L 12 4 M 0 10 L stroke} +>> matrix makepattern +/Pat8 exch def +<< Tile8x8 + /PaintProc {0.5 setlinewidth pop 0 -2 M 12 4 L + -4 0 M 12 8 L -4 4 M 8 10 L stroke} +>> matrix makepattern +/Pat9 exch def +/Pattern1 {PatternBgnd KeepColor Pat1 setpattern} bind def +/Pattern2 {PatternBgnd KeepColor Pat2 setpattern} bind def +/Pattern3 {PatternBgnd KeepColor Pat3 setpattern} bind def +/Pattern4 {PatternBgnd KeepColor Landscape {Pat5} {Pat4} ifelse setpattern} bind def +/Pattern5 {PatternBgnd KeepColor Landscape {Pat4} {Pat5} ifelse setpattern} bind def +/Pattern6 {PatternBgnd KeepColor Landscape {Pat9} {Pat6} ifelse setpattern} bind def +/Pattern7 {PatternBgnd KeepColor Landscape {Pat8} {Pat7} ifelse setpattern} bind def +} def +% +% +%End of PostScript Level 2 code +% +/PatternBgnd { + TransparentPatterns {} {gsave 1 setgray fill grestore} ifelse +} def +% +% Substitute for Level 2 pattern fill codes with +% grayscale if Level 2 support is not selected. +% +/Level1PatternFill { +/Pattern1 {0.250 Density} bind def +/Pattern2 {0.500 Density} bind def +/Pattern3 {0.750 Density} bind def +/Pattern4 {0.125 Density} bind def +/Pattern5 {0.375 Density} bind def +/Pattern6 {0.625 Density} bind def +/Pattern7 {0.875 Density} bind def +} def +% +% Now test for support of Level 2 code +% +Level1 {Level1PatternFill} {Level2PatternFill} ifelse +% +/Symbol-Oblique /Symbol findfont [1 0 .167 1 0 0] makefont +dup length dict begin {1 index /FID eq {pop pop} {def} ifelse} forall +currentdict end definefont pop +/MFshow { + { dup 5 get 3 ge + { 5 get 3 eq {gsave} {grestore} ifelse } + {dup dup 0 get findfont exch 1 get scalefont setfont + [ currentpoint ] exch dup 2 get 0 exch R dup 5 get 2 ne {dup dup 6 + get exch 4 get {Gshow} {stringwidth pop 0 R} ifelse }if dup 5 get 0 eq + {dup 3 get {2 get neg 0 exch R pop} {pop aload pop M} ifelse} {dup 5 + get 1 eq {dup 2 get exch dup 3 get exch 6 get stringwidth pop -2 div + dup 0 R} {dup 6 get stringwidth pop -2 div 0 R 6 get + show 2 index {aload pop M neg 3 -1 roll neg R pop pop} {pop pop pop + pop aload pop M} ifelse }ifelse }ifelse } + ifelse } + forall} def +/Gswidth {dup type /stringtype eq {stringwidth} {pop (n) stringwidth} ifelse} def +/MFwidth {0 exch { dup 5 get 3 ge { 5 get 3 eq { 0 } { pop } ifelse } + {dup 3 get{dup dup 0 get findfont exch 1 get scalefont setfont + 6 get Gswidth pop add} {pop} ifelse} ifelse} forall} def +/MLshow { currentpoint stroke M + 0 exch R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/MRshow { currentpoint stroke M + exch dup MFwidth neg 3 -1 roll R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/MCshow { currentpoint stroke M + exch dup MFwidth -2 div 3 -1 roll R + Blacktext {gsave 0 setgray MFshow grestore} {MFshow} ifelse } bind def +/XYsave { [( ) 1 2 true false 3 ()] } bind def +/XYrestore { [( ) 1 2 true false 4 ()] } bind def +end +%%EndProlog +gnudict begin +gsave +doclip +50 50 translate +0.050 0.050 scale +0 setgray +newpath +(Times-BoldItalic) findfont 140 scalefont setfont +1.000 UL +LTb +1.000 UL +LTa +686 448 M +6261 0 V +stroke +LTb +686 448 M +63 0 V +6198 0 R +-63 0 V +stroke +602 448 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0)] +] -46.7 MRshow +1.000 UL +LTb +1.000 UL +LTa +686 1282 M +6261 0 V +stroke +LTb +686 1282 M +63 0 V +6198 0 R +-63 0 V +stroke +602 1282 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.2)] +] -46.7 MRshow +1.000 UL +LTb +1.000 UL +LTa +686 2116 M +6261 0 V +stroke +LTb +686 2116 M +63 0 V +6198 0 R +-63 0 V +stroke +602 2116 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.4)] +] -46.7 MRshow +1.000 UL +LTb +1.000 UL +LTa +686 2951 M +6261 0 V +stroke +LTb +686 2951 M +63 0 V +6198 0 R +-63 0 V +stroke +602 2951 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.6)] +] -46.7 MRshow +1.000 UL +LTb +1.000 UL +LTa +686 3785 M +6261 0 V +stroke +LTb +686 3785 M +63 0 V +6198 0 R +-63 0 V +stroke +602 3785 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0.8)] +] -46.7 MRshow +1.000 UL +LTb +1.000 UL +LTa +686 4619 M +6261 0 V +stroke +LTb +686 4619 M +63 0 V +6198 0 R +-63 0 V +stroke +602 4619 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 1)] +] -46.7 MRshow +1.000 UL +LTb +1.000 UL +LTa +686 448 M +0 4171 V +stroke +LTb +686 448 M +0 63 V +0 4108 R +0 -63 V +stroke +686 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 0)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +2251 448 M +0 4171 V +stroke +LTb +2251 448 M +0 63 V +0 4108 R +0 -63 V +stroke +2251 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 50)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +3816 448 M +0 4171 V +stroke +LTb +3816 448 M +0 63 V +0 4108 R +0 -63 V +stroke +3816 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 100)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +5382 448 M +0 3968 V +0 140 R +0 63 V +stroke +LTb +5382 448 M +0 63 V +0 4108 R +0 -63 V +stroke +5382 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 150)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTa +6947 448 M +0 4171 V +stroke +LTb +6947 448 M +0 63 V +0 4108 R +0 -63 V +stroke +6947 308 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 ( 200)] +] -46.7 MCshow +1.000 UL +LTb +1.000 UL +LTb +686 4619 N +686 448 L +6261 0 V +0 4171 V +-6261 0 V +Z stroke +LCb setrgbcolor +112 2533 M +currentpoint gsave translate -270 rotate 0 0 moveto +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (Packet Success Rate \(PSR\))] +] -46.7 MCshow +grestore +LTb +LCb setrgbcolor +3816 98 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (distance \(m\))] +] -46.7 MCshow +LTb +3816 4829 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (Packet \(MSDU\) size = 20 bytes; tx power = 0 dBm; channel = 11)] +] -46.7 MCshow +1.000 UP +1.000 UL +LTb +% Begin plot #1 +5.000 UL +LT0 +LCb setrgbcolor +6296 4486 M +[ [(Times-BoldItalic) 140.0 0.0 true true 0 (802.15.4-psr-vs-distance)] +] -46.7 MRshow +LT0 +6380 4486 M +399 0 V +717 4619 M +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 -4 V +31 -4 V +31 8 V +31 0 V +32 -13 V +31 -4 V +31 -16 V +32 -30 V +31 -41 V +31 4 V +32 -88 V +31 -62 V +31 -100 V +32 -113 V +31 -83 V +31 -176 V +31 -141 V +32 -263 V +31 -367 V +31 -175 V +32 -284 V +31 -359 V +31 -308 V +32 -217 V +31 -234 V +31 -296 V +31 -192 V +32 -96 V +31 -162 V +31 -163 V +stroke 3910 640 M +32 -34 V +31 -41 V +31 -42 V +32 -46 V +31 -12 V +31 -13 V +32 17 V +31 -13 V +31 -8 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +31 0 V +32 0 V +31 0 V +31 0 V +32 0 V +% End plot #1 +stroke +1.000 UL +LTb +686 4619 N +686 448 L +6261 0 V +0 4171 V +-6261 0 V +Z stroke +1.000 UP +1.000 UL +LTb +stroke +grestore +end +showpage +%%Trailer +%%DocumentFonts: Times-BoldItalic diff -Naur ns-3.19/src/lr-wpan/doc/lr-wpan-arch.dia ns-3.20/src/lr-wpan/doc/lr-wpan-arch.dia --- ns-3.19/src/lr-wpan/doc/lr-wpan-arch.dia 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/doc/lr-wpan-arch.dia 2014-06-17 10:33:13.894995954 -0700 @@ -0,0 +1,6 @@ +]Ms۶Wh ڝ4m g^9]t$ZfK.oHYDI({c ^ǟ-m490(ٻgQgb?o<_prrwwU +Oqp ;y`+ <&7y8HEx:ӿYz̆E4lpħW5<)9牾|J |%d=&M .;.\\YQ9I8 5n8ik{ZU3ī@v;Ϣ7V^Y~}p;6ZE8:(;we[ZC[0CçM4 WϘvf'ύnLdm!>LӃ3ytјi^/<'6d8f=7ݓ&Z#<{Q0y>`1.F^cEg|MfqY=/ bIjыXa4R[`6S`܉aD3lsöDŸU/؇Aӻ +D9xV}͢0{$Y9] fmUg L0!SZ1*T͐[+촩 WjV8Ou&yyp,^O{5*?{߆y4 _Ï`*svsQP1  VdV_=F^R>8Z^^Y􏶦 ~Xv|a"1 du31V8lLPśYẐlWCBZ*ڡ*!(c(n$%xr+ Y$ooaRb]pғma)Fzz~Z6H4+^~%GBr:t8G<=_(88珵[JnŖV[D;>>?Ǻ*SyR:")ᒔx[R&!?(K.BDռеIr&3{*`h>]DU/2Ȳ(me&6VOPMA;6j >n ]Yf72ּdKniw:FG1;d5 QzGydY!${֤͒$J[.IѤRڠ2 % ZCR!)ɶ.KWqxȨEM\D\xEdGrǑ d= #UXҫ4>`hjϩ6'q&4"L/bcZ# z-ׂz-(3#z`l:Vm_8 K1H(xqh%[U`i_e+Z[o`0=S}ZJ0rG'균~X'j"blNjlR @,O:XM] I>}ZO'pH<ݸSV`?C`IWW`=+CTE[/z\%&}p>ecD_tpʄt[0,F+Y!kϱ2oT k<#uǪO9^cQDRHd IF5X>%ܭ,edDz܄+RT @0k5;*}'* Re d !kYCFs kﬡj5 +Df - +6:H3d~O`XY +;XwצSJ򕢾!Jg>#ʴLǧNuNd !0+D%@NP bďTHO?cO'?I[/`4JŠ0HPe+e+3ΌY„ yY$VX46@Pf=||=` IJ"Y􊠔"}pI3C97Z/Q]KŸчUPYȃ8:сl:.vlqRU[^y&(q>S4 MJ> Pcγ=*A6y-Tj]:! q\O96DыO_.>\|Uq+ֺ".Fa{#j q G{*>>iʅ{G^j}d75O^җ_@GUY"Riu8F&rŲA0;qŠh@+zaTˆP4:+#(AM?`|[nƃ-jL$ڋ$Yl$Y"ɳ3hi*cf#3yh$n%U;% aeR TgGߕ>y,h c* \ No newline at end of file diff -Naur ns-3.19/src/lr-wpan/doc/lr-wpan-data-example.dia ns-3.20/src/lr-wpan/doc/lr-wpan-data-example.dia --- ns-3.19/src/lr-wpan/doc/lr-wpan-data-example.dia 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/doc/lr-wpan-data-example.dia 2014-06-17 10:33:13.894995954 -0700 @@ -0,0 +1,34 @@ +YoH) +jtGsWE/`c^Γ@UQRmaQvkO,"ueg+[%TrV!ApTNjt~2?.|6br^7o~U^/*TNЪxyYoAoF'u~4jzvUy>+/|rj/E5o8_oӼsν/>5_reQ?lXM!r됎?7iZك~x\m)Rb:ֱϦ "M)Cm⊬+WWگtu\TuOmɳŢ,yPbw8/=t[=|Z׋G7kbU~::;ܢFWijGlZ^ۋѪvdO)/E=f+,pQ45'.Rwq?!\gEﳘ_͚gDV4=/s{)! 0 jwf̢#GT"#"RkC |TP K,%%Kc3K:a,- X_,Y[@ƄZlR +h4j7@`Q,g%$N5Y m]!5jRWj3>P}!$-JA-'HMq{r%$g?+?u +o)&%jZҲz#߶HmN64j +d65iG=MnD6lf`kDmB 7K +& C#|Qp*`\k&3cԫBy1jrX:[*'!-mdt[ +~񚂽+ GJ"QW%)f F\~wSvOt-Dq;xyRZ9ͫj۾)yӲ_<<źٸ䣓gUȽ]gXx 3+5HH1a 0 qi&~MDqAk>uM +D\as: #!XJ{ێbzL uc֏ 5PF|ndʬac& DH +Aͧϯ??!>n0ʧ8һ‚".8Q;9 fY#G![p(E$5 J3Ca +"p)E.NƈYZDDSHb-‡6؞6_7EmB3*N9=S6{:H)m$SP>wpɃ@H":oI"7FA|6ШG)63A-442Eڭ8"'V~Hqu5NFCZRQb"Q[42Էء IE谳޽x1?VO:V@SyRdiDj5%)h0,DfF$JD;tk Q2P/j1@`Q,yKPQ5-;pBH{geVS íCđ>"7ܞ;A5[1R *I)v ;'ߋbX(Lc ԂGutpsKo-L + }5z?.|RT#+U>-ꀽUqUv,,%+||ɭV Qc]XzJŖ'2f9Ec텸P.H΄[uf~Gobn{\fGd̥lc@#)2_FYOFأ~I¨cKo +qϽ~` +Xn@I +cn2D. GPDPeVY* Hd%QНNXr&\dT#}r"VaVaYiaZF8_&zq2R}D#J:5U2OҺ2~*bY>C۫`rȱj!vLq!صGwⷖq +3^TW8HEw[ ">̙Bͤkpc +lu (E.Ysځk쓧 sdD|[:烓rV&ZEZMx xRfLEUHa8LH`_mjXܒ 2 q3+l9#]qG2QQƪΫ:VW)mp:Jnu(ZtFP |`7MuIv,cQ$$|$Z'IFSV +JY97uyK38ZM"zWrP{i4KCeHf@I$FRDy~^>@_.g;,nR +m/]}YvBɖ[lyY( +llϞu ɣ7"~°& 2@ptStt{ E b6^a9ȬW#έqF$4($P/pe;l9H":K4v,$`mEr֊E 3`l#=(tu + Ho}OG]6-'H/_Oj>/sXE>BuuUxV~ZGh||2;o/ +&c èbʀN +SH{*ldny9]^.?Al9Վp2CqMduu/wf@`v׷-IdLN1 `!L&AƁ$S[ﲭ]>#-~]KqvހKP ]2ջfq$dvo:X9b?hO>H L;]}DQ.I)C1gVar2rM[mIE)C^vEN###G?Sn:FH/QO)¨DNktu#Bn=[ C~fD!Z,ĶJ\)镨Q)h&7~( =x~iP0@"ctTL{( +Q\9@\mCN9qzXYNǰ1־vp eZp"[AQR$Q5ZQD"ԍZPAEq*3@'u1U`B+;1t gNoj8cSU/Fj8- +x|61 ,?p]^wFь3E`ߧrsnW{tRW?uvbFW@jWWy@ӑ/C5B̗X?L; =Tbq^k +*^x%fXZF +2XٸebIgRk?-~n'EnyBDH ,lx"ͫHF6 +" U$̜@2"F)Ҩwkj+b ۘѳ, 蛒(|.zw>.|_@ \ No newline at end of file diff -Naur ns-3.19/src/lr-wpan/doc/lr-wpan-primitives.dia ns-3.20/src/lr-wpan/doc/lr-wpan-primitives.dia --- ns-3.19/src/lr-wpan/doc/lr-wpan-primitives.dia 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/doc/lr-wpan-primitives.dia 2014-06-17 10:33:13.894995954 -0700 @@ -0,0 +1,5 @@ +]o6+f\"&6`؀b:-*KD;~HIib[JbJN!$u#P~v{kQ@, d~kΏ8{FgjO$;;Yonn@ɕI3G+*3{ TFkUeLMWF{ZsfYJBfifZǕG|/\O3>7K],<&f3i~?rk/^U٬⽿6 +Qe'.F;8@q9\nre/+43̾4McRd+}N>S Ǻ~>+@yK, +O-/7Qh/o;#(k}ߜ)~Pzk|DB3DWQ'lۦue6~jw;0奝v!*??WD뻳cN3SuQI{}Է0(<ۣ?͂po闘}4 L3cv'#%'}Ǧ`ng:gs0x$ &N]"7Y*}/7-vY~WfaPނkͯkpOI>h;|f# GfywS'E5Tai.M!Od[y Ftf_?$R#$k4䀦EEkJ'%aO3Kv_P[S9QI\,)dP0PP%!&ŚR=kK) ] ҆BM1(EaTeEBo]1:J݆K +<Ҫڅ)$IXH9nϖu8TY4-]_:w%VxIiR$h"06 @4r4ruZIHiR}##9&}beH Hv#d1v=B(v&{=5*524 [a87T]h21)IQ2r ~pl>;XkJ+>F%v96.*Ad FE/KB4vp畹}|) `S #F[.!( h %jL\|zz§BhPLr䞊Ϋ(R$:/5eiȇ"w[@{n륇]ZX¥ T y /FKáMt m fN5F>0aeyWfpBnIt'H (jE_Ey-_ +B,NG \ No newline at end of file diff -Naur ns-3.19/src/lr-wpan/doc/lr-wpan.rst ns-3.20/src/lr-wpan/doc/lr-wpan.rst --- ns-3.19/src/lr-wpan/doc/lr-wpan.rst 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/doc/lr-wpan.rst 2014-06-17 10:33:13.895995946 -0700 @@ -0,0 +1,258 @@ +PageBreak + +Low-Rate Wireless Personal Area Network (LR-WPAN) +------------------------------------------------- + +This chapter describes the implementation of ns-3 models for the +low-rate, wireless personal area network (LR-WPAN) as specified by +IEEE standard 802.15.4 (2006). + +Model Description +***************** + +The source code for the lr-wpan module lives in the directory ``src/lr-wpan``. + +Design +====== + +The model design closely follows the standard from an architectural standpoint. + +.. _fig-lr-wpan-arch: + +.. figure:: figures/lr-wpan-arch.* + + Architecture and scope of lr-wpan models + +The grey areas in the figure (adapted from Fig 3. of IEEE Std. 802.15.4-2006) +show the scope of the model. + +The Spectrum NetDevice from Nicola Baldo is the basis for the implementation. + +The implementation also plans to borrow from the ns-2 models developed by +Zheng and Lee in the future. + +APIs +#### + +The APIs closely follow the standard, adapted for ns-3 naming conventions +and idioms. The APIs are organized around the concept of service primitives +as shown in the following figure adapted from Figure 14 of +IEEE Std. 802.15.4-2006. + +.. _fig-lr-wpan-primitives: + +.. figure:: figures/lr-wpan-primitives.* + + Service primitives + +The APIs are organized around four conceptual services and service access +points (SAP): + +* MAC data service (MCPS) +* MAC management service (MLME) +* PHY data service (PD) +* PHY management service (PLME) + +In general, primitives are standardized as follows (e.g. Sec 7.1.1.1.1 +of IEEE 802.15.4-2006)::: + + MCPS-DATA.request ( + SrcAddrMode, + DstAddrMode, + DstPANId, + DstAddr, + msduLength, + msdu, + msduHandle, + TxOptions, + SecurityLevel, + KeyIdMode, + KeySource, + KeyIndex + ) + +This maps to ns-3 classes and methods such as::: + + struct McpsDataRequestParameters + { + uint8_t m_srcAddrMode; + uint8_t m_dstAddrMode; + ... + }; + + void + LrWpanMac::McpsDataRequest (McpsDataRequestParameters params) + { + ... + } + +MAC +### + +The MAC at present implements the unslotted CSMA/CA variant, without beaconing. +Currently there is no support for coordinators and the relavant APIs. + +The implemented MAC is similar to Contiki's NullMAC, i.e., a MAC without sleep +features. The radio is assumed to be always active (receiving or transmitting), +of completely shut down. Frame reception is not disabled while performing the +CCA. + +The main API supported is the data transfer API +(McpsDataRequest/Indication/Confirm). CSMA/CA according to Stc 802.15.4-2006, +section 7.5.1.4 is supported. Frame reception and rejection according to +Std 802.15.4-2006, section 7.5.6.2 is supported, including acknowledgements. +Only short addressing completely implemented. Various trace sources are +supported, and trace sources can be hooked to sinks. + +PHY +### + +The physical layer components consist of a Phy model, an error rate model, +and a loss model. The error rate model presently models the error rate +for IEEE 802.15.4 2.4 GHz AWGN channel for OQPSK; the model description can +be found in IEEE Std 802.15.4-2006, section E.4.1.7. The Phy model is +based on SpectrumPhy and it follows specification described in section 6 +of IEEE Std 802.15.4-2006. It models PHY service specifications, PPDU +formats, PHY constants and PIB attributes. It currently only supports +the transmit power spectral density mask specified in 2.4 GHz per section +6.5.3.1. The noise power density assumes uniformly distributed thermal +noise across the frequency bands. The loss model can fully utilize all +existing simple (non-spectrum phy) loss models. The Phy model uses +the existing single spectrum channel model. +The physical layer is modeled on packet level, that is, no preamble/SFD +detection is done. Packet reception will be started with the first bit of the +preamble (which is not modeled), if the SNR is more than -5 dB, see IEEE +Std 802.15.4-2006, appendix E, Figure E.2. Reception of the packet will finish +after the packet was completely transmitted. Other packets arriving during +reception will add up to the interference/noise. + +Currently the receiver sensitivity is set to a fixed value of -106.58 dBm. This +corresponds to a packet error rate of 1% for 20 byte reference packets for this +signal power, according to IEEE Std 802.15.4-2006, section 6.1.7. In the future +we will provide support for changing the sensitivity to different values. + +.. _fig-802-15-4-per-sens: + +.. figure:: figures/802-15-4-per-sens.* + + Packet error rate vs. signal power + + +NetDevice +######### + +Although it is expected that other technology profiles (such as +6LoWPAN and ZigBee) will write their own NetDevice classes, a basic +LrWpanNetDevice is provided, which encapsulates the common operations +of creating a generic LrWpan device and hooking things together. + +Scope and Limitations +===================== + +Future versions of this document will contain a PICS proforma similar to +Appendix D of IEEE 802.15.4-2006. The current emphasis is on the +unslotted mode of 802.15.4 operation for use in Zigbee, and the scope +is limited to enabling a single mode (CSMA/CA) with basic data transfer +capabilities. Association with PAN coordinators is not yet supported, nor the +use of extended addressing. Interference is modeled as AWGN but this is +currently not thoroughly tested. + +The NetDevice Tx queue is not limited, i.e., packets are never dropped +due to queue becoming full. They may be dropped due to excessive transmission +retries or channel access failure. + +References +========== + +* Wireless Medium Access Control (MAC) and Physical Layer (PHY) Specifications for Low-Rate Wireless Personal Area Networks (WPANs), IEEE Computer Society, IEEE Std 802.15.4-2006, 8 September 2006. +* J. Zheng and Myung J. Lee, "A comprehensive performance study of IEEE 802.15.4," Sensor Network Operations, IEEE Press, Wiley Interscience, Chapter 4, pp. 218-237, 2006. + +Usage +***** + +Enabling lr-wpan +================ + +Add ``lr-wpan`` to the list of modules built with ns-3. + +Helper +====== + +The helper is patterned after other device helpers. In particular, +tracing (ascii and pcap) is enabled similarly, and enabling of all +lr-wpan log components is performed similarly. Use of the helper +is exemplified in ``examples/lr-wpan-data.cc``. For ascii tracing, +the transmit and receive traces are hooked at the Mac layer. + +The default propagation loss model added to the channel, when this helper +is used, is the LogDistancePropagationLossModel with default parameters. + +Examples +======== + +The following examples have been written, which can be found in ``src/lr-wpan/examples/``: + +* ``lr-wpan-data.cc``: A simple example showing end-to-end data transfer. +* ``lr-wpan-error-distance-plot.cc``: An example to plot variations of the packet success ratio as a function of distance. +* ``lr-wpan-error-model-plot.cc``: An example to test the phy. +* ``lr-wpan-packet-print.cc``: An example to print out the MAC header fields. +* ``lr-wpan-phy-test.cc``: An example to test the phy. + +In particular, the module enables a very simplified end-to-end data +transfer scenario, implemented in ``lr-wpan-data.cc``. The figure +shows a sequence of events that are triggered when the MAC receives +a DataRequest from the higher layer. It invokes a Clear Channel +Assessment (CCA) from the PHY, and if successful, sends the frame +down to the PHY where it is transmitted over the channel and results +in a DataIndication on the peer node. + +.. _fig-lr-wpan-data: + +.. figure:: figures/lr-wpan-data-example.* + + Data example for simple LR-WPAN data transfer end-to-end + +The example ``lr-wpan-error-distance-plot.cc`` plots the packet success +ratio (PSR) as a function of distance, using the default LogDistance +propagation loss model and the 802.15.4 error model. The channel (default 11), +packet size (default 20 bytes) and transmit power (default 0 dBm) can be +varied by command line arguments. The program outputs a file named +``802.15.4-psr-distance.plt``. Loading this file into gnuplot yields +a file ``802.15.4-psr-distance.eps``, which can be converted to pdf or +other formats. The default output is shown below. + +.. _fig-802-15-4-psr-distance: + +.. figure:: figures/802-15-4-psr-distance.* + + Default output of the program ``lr-wpan-error-distance-plot.cc`` + +Tests +===== + +The following tests have been written, which can be found in ``src/lr-wpan/tests/``: + +* ``lr-wpan-ack-test.cc``: Check that acknowledgments are being used and issued in the correct order. +* ``lr-wpan-collision-test.cc``: Test correct reception of packets with interference and collisions. +* ``lr-wpan-error-model-test.cc``: Check that the error model gives predictable values. +* ``lr-wpan-packet-test.cc``: Test the 802.15.4 MAC header/trailer classes +* ``lr-wpan-pd-plme-sap-test.cc``: Test the PLME and PD SAP per IEEE 802.15.4 +* ``lr-wpan-spectrum-value-helper-test.cc``: Test that the conversion between power (expressed as a scalar quantity) and spectral power, and back again, falls within a 25% tolerance across the range of possible channels and input powers. + +Validation +********** + +The model has not been validated against real hardware. The error model +has been validated against the data in IEEE Std 802.15.4-2006, +section E.4.1.7 (Figure E.2). The MAC behavior (CSMA backoff) has been +validated by hand against expected behavior. The below plot is an example +of the error model validation and can be reproduced by running +``lr-wpan-error-model-plot.cc``: + +.. _fig-802-15-4-ber: + +.. figure:: figures/802-15-4-ber.* + + Default output of the program ``lr-wpan-error-model-plot.cc`` + + diff -Naur ns-3.19/src/lr-wpan/examples/lr-wpan-data.cc ns-3.20/src/lr-wpan/examples/lr-wpan-data.cc --- ns-3.19/src/lr-wpan/examples/lr-wpan-data.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/examples/lr-wpan-data.cc 2014-06-17 10:33:13.895995946 -0700 @@ -0,0 +1,163 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: Tom Henderson + */ + +/* + * Try to send data end-to-end through a LrWpanMac <-> LrWpanPhy <-> + * SpectrumChannel <-> LrWpanPhy <-> LrWpanMac chain + * + * Trace Phy state changes, and Mac DataIndication and DataConfirm events + * to stdout + */ +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +using namespace ns3; + +static void DataIndication (McpsDataIndicationParams params, Ptr p) +{ + NS_LOG_UNCOND ("Received packet of size " << p->GetSize ()); +} + +static void DataConfirm (McpsDataConfirmParams params) +{ + NS_LOG_UNCOND ("LrWpanMcpsDataConfirmStatus = " << params.m_status); +} + +static void StateChangeNotification (std::string context, Time now, LrWpanPhyEnumeration oldState, LrWpanPhyEnumeration newState) +{ + NS_LOG_UNCOND (context << " state change at " << now.GetSeconds () + << " from " << LrWpanHelper::LrWpanPhyEnumerationPrinter (oldState) + << " to " << LrWpanHelper::LrWpanPhyEnumerationPrinter (newState)); +} + +int main (int argc, char *argv[]) +{ + bool verbose = false; + + CommandLine cmd; + + cmd.AddValue ("verbose", "turn on all log components", verbose); + + cmd.Parse (argc, argv); + + LrWpanHelper lrWpanHelper; + if (verbose) + { + lrWpanHelper.EnableLogComponents (); + } + + // Enable calculation of FCS in the trailers. Only necessary when interacting with real devices or wireshark. + // GlobalValue::Bind ("ChecksumEnabled", BooleanValue (true)); + + // Create 2 nodes, and a NetDevice for each one + Ptr n0 = CreateObject (); + Ptr n1 = CreateObject (); + + Ptr dev0 = CreateObject (); + Ptr dev1 = CreateObject (); + + dev0->SetAddress (Mac16Address ("00:01")); + dev1->SetAddress (Mac16Address ("00:02")); + + // Each device must be attached to the same channel + Ptr channel = CreateObject (); + Ptr propModel = CreateObject (); + Ptr delayModel = CreateObject (); + channel->AddPropagationLossModel (propModel); + channel->SetPropagationDelayModel (delayModel); + + dev0->SetChannel (channel); + dev1->SetChannel (channel); + + // To complete configuration, a LrWpanNetDevice must be added to a node + n0->AddDevice (dev0); + n1->AddDevice (dev1); + + // Trace state changes in the phy + dev0->GetPhy ()->TraceConnect ("TrxState", std::string ("phy0"), MakeCallback (&StateChangeNotification)); + dev1->GetPhy ()->TraceConnect ("TrxState", std::string ("phy1"), MakeCallback (&StateChangeNotification)); + + Ptr sender0Mobility = CreateObject (); + sender0Mobility->SetPosition (Vector (0,0,0)); + dev0->GetPhy ()->SetMobility (sender0Mobility); + Ptr sender1Mobility = CreateObject (); + // Configure position 10 m distance + sender1Mobility->SetPosition (Vector (0,10,0)); + dev1->GetPhy ()->SetMobility (sender1Mobility); + + McpsDataConfirmCallback cb0; + cb0 = MakeCallback (&DataConfirm); + dev0->GetMac ()->SetMcpsDataConfirmCallback (cb0); + + McpsDataIndicationCallback cb1; + cb1 = MakeCallback (&DataIndication); + dev0->GetMac ()->SetMcpsDataIndicationCallback (cb1); + + McpsDataConfirmCallback cb2; + cb2 = MakeCallback (&DataConfirm); + dev1->GetMac ()->SetMcpsDataConfirmCallback (cb2); + + McpsDataIndicationCallback cb3; + cb3 = MakeCallback (&DataIndication); + dev1->GetMac ()->SetMcpsDataIndicationCallback (cb3); + + // Tracing + lrWpanHelper.EnablePcapAll (std::string ("lr-wpan-data"), true); + AsciiTraceHelper ascii; + Ptr stream = ascii.CreateFileStream ("lr-wpan-data.tr"); + lrWpanHelper.EnableAsciiAll (stream); + + // The below should trigger two callbacks when end-to-end data is working + // 1) DataConfirm callback is called + // 2) DataIndication callback is called with value of 50 + Ptr p0 = Create (50); // 50 bytes of dummy data + McpsDataRequestParams params; + params.m_srcAddrMode = SHORT_ADDR; + params.m_dstAddrMode = SHORT_ADDR; + params.m_dstPanId = 0; + params.m_dstAddr = Mac16Address ("00:02"); + params.m_msduHandle = 0; + params.m_txOptions = TX_OPTION_ACK; +// dev0->GetMac ()->McpsDataRequest (params, p0); + Simulator::ScheduleWithContext (1, Seconds (0.0), + &LrWpanMac::McpsDataRequest, + dev0->GetMac (), params, p0); + + // Send a packet back at time 2 seconds + Ptr p2 = Create (60); // 60 bytes of dummy data + params.m_dstAddr = Mac16Address ("00:01"); + Simulator::ScheduleWithContext (2, Seconds (2.0), + &LrWpanMac::McpsDataRequest, + dev1->GetMac (), params, p2); + + Simulator::Run (); + + Simulator::Destroy (); + return 0; +} diff -Naur ns-3.19/src/lr-wpan/examples/lr-wpan-error-distance-plot.cc ns-3.20/src/lr-wpan/examples/lr-wpan-error-distance-plot.cc --- ns-3.19/src/lr-wpan/examples/lr-wpan-error-distance-plot.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/examples/lr-wpan-error-distance-plot.cc 2014-06-17 10:33:13.895995946 -0700 @@ -0,0 +1,162 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: Tom Henderson + */ + +// This program produces a gnuplot file that plots the packet success rate +// as a function of distance for the 802.15.4 models, assuming a default +// LogDistance propagation loss model, the 2.4 GHz OQPSK error model, a +// default transmit power of 0 dBm, and a default packet size of 20 bytes of +// 802.15.4 payload. +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +using namespace ns3; +using namespace std; + +static uint32_t g_received = 0; + +NS_LOG_COMPONENT_DEFINE ("LrWpanErrorDistancePlot"); + +static void +LrWpanErrorDistanceCallback (McpsDataIndicationParams params, Ptr p) +{ + g_received++; +} + +int main (int argc, char *argv[]) +{ + std::ostringstream os; + std::ofstream berfile ("802.15.4-psr-distance.plt"); + + int minDistance = 1; + int maxDistance = 200; // meters + int increment = 1; + int maxPackets = 1000; + int packetSize = 20; + double txPower = 0; + uint32_t channelNumber = 11; + + CommandLine cmd; + + cmd.AddValue ("txPower", "transmit power (dBm)", txPower); + cmd.AddValue ("packetSize", "packet (MSDU) size (bytes)", packetSize); + cmd.AddValue ("channelNumber", "channel number", channelNumber); + + cmd.Parse (argc, argv); + + os << "Packet (MSDU) size = " << packetSize << " bytes; tx power = " << txPower << " dBm; channel = " << channelNumber; + + Gnuplot psrplot = Gnuplot ("802.15.4-psr-distance.eps"); + Gnuplot2dDataset psrdataset ("802.15.4-psr-vs-distance"); + + Ptr n0 = CreateObject (); + Ptr n1 = CreateObject (); + Ptr dev0 = CreateObject (); + Ptr dev1 = CreateObject (); + dev0->SetAddress (Mac16Address ("00:01")); + dev1->SetAddress (Mac16Address ("00:02")); + Ptr channel = CreateObject (); + Ptr model = CreateObject (); + channel->AddPropagationLossModel (model); + dev0->SetChannel (channel); + dev1->SetChannel (channel); + n0->AddDevice (dev0); + n1->AddDevice (dev1); + Ptr mob0 = CreateObject (); + dev0->GetPhy ()->SetMobility (mob0); + Ptr mob1 = CreateObject (); + dev1->GetPhy ()->SetMobility (mob1); + + LrWpanSpectrumValueHelper svh; + Ptr psd = svh.CreateTxPowerSpectralDensity (txPower, channelNumber); + dev0->GetPhy ()->SetTxPowerSpectralDensity (psd); + + McpsDataIndicationCallback cb0; + cb0 = MakeCallback (&LrWpanErrorDistanceCallback); + dev1->GetMac ()->SetMcpsDataIndicationCallback (cb0); + + McpsDataRequestParams params; + params.m_srcAddrMode = SHORT_ADDR; + params.m_dstAddrMode = SHORT_ADDR; + params.m_dstPanId = 0; + params.m_dstAddr = Mac16Address ("00:02"); + params.m_msduHandle = 0; + params.m_txOptions = 0; + + Ptr p; + mob0->SetPosition (Vector (0,0,0)); + mob1->SetPosition (Vector (minDistance,0,0)); + for (int j = minDistance; j < maxDistance; ) + { + for (int i = 0; i < maxPackets; i++) + { + p = Create (packetSize); + Simulator::Schedule (Seconds (i), + &LrWpanMac::McpsDataRequest, + dev0->GetMac (), params, p); + } + Simulator::Run (); + NS_LOG_DEBUG ("Received " << g_received << " packets for distance " << j); + psrdataset.Add (j, g_received / 1000.0); + g_received = 0; + j += increment; + mob1->SetPosition (Vector (j,0,0)); + } + + psrplot.AddDataset (psrdataset); + + psrplot.SetTitle (os.str ()); + psrplot.SetTerminal ("postscript eps color enh \"Times-BoldItalic\""); + psrplot.SetLegend ("distance (m)", "Packet Success Rate (PSR)"); + psrplot.SetExtra ("set xrange [0:200]\n\ +set yrange [0:1]\n\ +set grid\n\ +set style line 1 linewidth 5\n\ +set style increment user"); + psrplot.GenerateOutput (berfile); + berfile.close (); + + Simulator::Destroy (); + return 0; +} + diff -Naur ns-3.19/src/lr-wpan/examples/lr-wpan-error-model-plot.cc ns-3.20/src/lr-wpan/examples/lr-wpan-error-model-plot.cc --- ns-3.19/src/lr-wpan/examples/lr-wpan-error-model-plot.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/examples/lr-wpan-error-model-plot.cc 2014-06-17 10:33:13.896995938 -0700 @@ -0,0 +1,84 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: Gary Pei + */ +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +using namespace ns3; +using namespace std; + +NS_LOG_COMPONENT_DEFINE ("LrWpanErrorModelPlot"); + +// +// Plot 802.15.4 BER curve (compare against Figure E.2 of IEEE-802.15.4-2006) +// +int main (int argc, char *argv[]) +{ + std::ofstream berfile ("802.15.4-ber.plt"); + Ptr lrWpanError = CreateObject (); + + double increment = 0.1; + double minSnr = -10; //dB + double maxSnr = 5; + + Gnuplot berplot = Gnuplot ("802.15.4-ber.eps"); + Gnuplot2dDataset berdataset ("802.15.4"); + + for (double snr = minSnr; snr <= maxSnr; snr += increment) + { + double ber = 1.0 - lrWpanError->GetChunkSuccessRate (pow (10.0,snr / 10.0), 1); + NS_LOG_DEBUG (snr << "(dB) " << ber << " (BER)"); + berdataset.Add (snr, ber); + } + + berplot.AddDataset (berdataset); + + berplot.SetTerminal ("postscript eps color enh \"Times-BoldItalic\""); + berplot.SetLegend ("SNR (dB)", "Bit Error Rate (BER)"); + berplot.SetExtra ("set xrange [-10:15]\n\ +set yrange [1e-9:1]\n\ +set log y\n\ +set grid\n\ +set style line 1 linewidth 5\n\ +set style line 2 linewidth 5\n\ +set style line 3 linewidth 5\n\ +set style line 4 linewidth 5\n\ +set style line 5 linewidth 5\n\ +set style line 6 linewidth 5\n\ +set style line 7 linewidth 5\n\ +set style line 8 linewidth 5\n\ +set style increment user"); + berplot.GenerateOutput (berfile); + berfile.close (); + + return 0; +} + diff -Naur ns-3.19/src/lr-wpan/examples/lr-wpan-packet-print.cc ns-3.20/src/lr-wpan/examples/lr-wpan-packet-print.cc --- ns-3.19/src/lr-wpan/examples/lr-wpan-packet-print.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/examples/lr-wpan-packet-print.cc 2014-06-17 10:33:13.896995938 -0700 @@ -0,0 +1,52 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: Tom Henderson + */ +#include +#include + +#include + +using namespace ns3; + +int main (int argc, char *argv[]) +{ + Packet::EnablePrinting (); + Packet::EnableChecking (); + LrWpanMacHeader macHdr (LrWpanMacHeader::LRWPAN_MAC_BEACON, 0); //sequence number set to 0 + macHdr.SetSrcAddrMode (2); // short addr + macHdr.SetDstAddrMode (0); // no addr + // ... other setters + + uint16_t srcPanId = 100; + Mac16Address srcWpanAddr ("00:11"); + + macHdr.SetSrcAddrFields (srcPanId,srcWpanAddr ); + + LrWpanMacTrailer macTrailer; + + Ptr p = Create (20); // 20 bytes of dummy data + + p->AddHeader (macHdr); + p->AddTrailer (macTrailer); + + p->Print (std::cout); + std::cout << std::endl; + return 0; + +} diff -Naur ns-3.19/src/lr-wpan/examples/lr-wpan-phy-test.cc ns-3.20/src/lr-wpan/examples/lr-wpan-phy-test.cc --- ns-3.19/src/lr-wpan/examples/lr-wpan-phy-test.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/examples/lr-wpan-phy-test.cc 2014-06-17 10:33:13.896995938 -0700 @@ -0,0 +1,94 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: Gary Pei + */ +#include +#include +#include +#include +#include +#include +#include +#include + +using namespace ns3; + +void GetSetTRXStateConfirm (LrWpanPhyEnumeration status) +{ + NS_LOG_UNCOND ("At: " << Simulator::Now () + << " Received Set TRX Confirm: " << status); +} + +void +ReceivePdDataIndication (uint32_t psduLength, + Ptr p, + uint8_t lqi) +{ + NS_LOG_UNCOND ("At: " << Simulator::Now () + << " Received frame size: " << psduLength << " LQI: " << + lqi); +} + +void SendOnePacket (Ptr sender, Ptr receiver) +{ + uint32_t n = 10; + Ptr p = Create (n); + sender->PdDataRequest (p->GetSize (), p); +} + + +int main (int argc, char *argv[]) +{ + LogComponentEnableAll (LOG_PREFIX_FUNC); + LogComponentEnable ("LrWpanPhy", LOG_LEVEL_ALL); + LogComponentEnable ("SingleModelSpectrumChannel", LOG_LEVEL_ALL); + + Ptr sender = CreateObject (); + Ptr receiver = CreateObject (); + + Ptr channel = CreateObject (); + sender->SetChannel (channel); + receiver->SetChannel (channel); + channel->AddRx (sender); + channel->AddRx (receiver); + + // CONFIGURE MOBILITY + Ptr senderMobility = CreateObject (); + sender->SetMobility (senderMobility); + Ptr receiverMobility = CreateObject (); + receiver->SetMobility (senderMobility); + + + sender->SetPlmeSetTRXStateConfirmCallback (MakeCallback (&GetSetTRXStateConfirm)); + receiver->SetPlmeSetTRXStateConfirmCallback (MakeCallback (&GetSetTRXStateConfirm)); + + sender->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_TX_ON); + receiver->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_RX_ON); + + receiver->SetPdDataIndicationCallback (MakeCallback (&ReceivePdDataIndication)); + + Simulator::Schedule (Seconds (1.0), &SendOnePacket, sender, receiver); + + Simulator::Stop (Seconds (10.0)); + + Simulator::Run (); + + Simulator::Destroy (); + + return 0; +} diff -Naur ns-3.19/src/lr-wpan/examples/wscript ns-3.20/src/lr-wpan/examples/wscript --- ns-3.19/src/lr-wpan/examples/wscript 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/examples/wscript 2014-06-17 10:33:13.897995931 -0700 @@ -0,0 +1,17 @@ +## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*- + +def build(bld): + obj = bld.create_ns3_program('lr-wpan-packet-print', ['lr-wpan']) + obj.source = 'lr-wpan-packet-print.cc' + + obj = bld.create_ns3_program('lr-wpan-phy-test', ['lr-wpan']) + obj.source = 'lr-wpan-phy-test.cc' + + obj = bld.create_ns3_program('lr-wpan-data', ['lr-wpan']) + obj.source = 'lr-wpan-data.cc' + + obj = bld.create_ns3_program('lr-wpan-error-model-plot', ['lr-wpan', 'stats']) + obj.source = 'lr-wpan-error-model-plot.cc' + + obj = bld.create_ns3_program('lr-wpan-error-distance-plot', ['lr-wpan', 'stats']) + obj.source = 'lr-wpan-error-distance-plot.cc' diff -Naur ns-3.19/src/lr-wpan/helper/lr-wpan-helper.cc ns-3.20/src/lr-wpan/helper/lr-wpan-helper.cc --- ns-3.19/src/lr-wpan/helper/lr-wpan-helper.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/helper/lr-wpan-helper.cc 2014-06-17 10:33:13.897995931 -0700 @@ -0,0 +1,357 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * Gary Pei + * Tom Henderson + */ +#include "lr-wpan-helper.h" +#include +#include +#include +#include +#include +#include +#include + +NS_LOG_COMPONENT_DEFINE ("LrWpanHelper"); + +namespace ns3 { + +static void +AsciiLrWpanMacTransmitSinkWithContext ( + Ptr stream, + std::string context, + Ptr p) +{ + *stream->GetStream () << "t " << Simulator::Now ().GetSeconds () << " " << context << " " << *p << std::endl; +} + +static void +AsciiLrWpanMacTransmitSinkWithoutContext ( + Ptr stream, + Ptr p) +{ + *stream->GetStream () << "t " << Simulator::Now ().GetSeconds () << " " << *p << std::endl; +} + +LrWpanHelper::LrWpanHelper (void) +{ + m_channel = CreateObject (); + Ptr model = CreateObject (); + m_channel->AddPropagationLossModel (model); +} + +LrWpanHelper::~LrWpanHelper (void) +{ + m_channel->Dispose (); + m_channel = 0; +} + +void +LrWpanHelper::EnableLogComponents (void) +{ + LogComponentEnableAll (LOG_PREFIX_TIME); + LogComponentEnableAll (LOG_PREFIX_FUNC); + LogComponentEnable ("LrWpanCsmaCa", LOG_LEVEL_ALL); + LogComponentEnable ("LrWpanErrorModel", LOG_LEVEL_ALL); + LogComponentEnable ("LrWpanInterferenceHelper", LOG_LEVEL_ALL); + LogComponentEnable ("LrWpanMac", LOG_LEVEL_ALL); + LogComponentEnable ("LrWpanNetDevice", LOG_LEVEL_ALL); + LogComponentEnable ("LrWpanPhy", LOG_LEVEL_ALL); + LogComponentEnable ("LrWpanSpectrumSignalParameters", LOG_LEVEL_ALL); + LogComponentEnable ("LrWpanSpectrumValueHelper", LOG_LEVEL_ALL); +} + +std::string +LrWpanHelper::LrWpanPhyEnumerationPrinter (LrWpanPhyEnumeration e) +{ + switch (e) + { + case IEEE_802_15_4_PHY_BUSY: + return std::string ("BUSY"); + case IEEE_802_15_4_PHY_BUSY_RX: + return std::string ("BUSY_RX"); + case IEEE_802_15_4_PHY_BUSY_TX: + return std::string ("BUSY_TX"); + case IEEE_802_15_4_PHY_FORCE_TRX_OFF: + return std::string ("FORCE_TRX_OFF"); + case IEEE_802_15_4_PHY_IDLE: + return std::string ("IDLE"); + case IEEE_802_15_4_PHY_INVALID_PARAMETER: + return std::string ("INVALID_PARAMETER"); + case IEEE_802_15_4_PHY_RX_ON: + return std::string ("RX_ON"); + case IEEE_802_15_4_PHY_SUCCESS: + return std::string ("SUCCESS"); + case IEEE_802_15_4_PHY_TRX_OFF: + return std::string ("TRX_OFF"); + case IEEE_802_15_4_PHY_TX_ON: + return std::string ("TX_ON"); + case IEEE_802_15_4_PHY_UNSUPPORTED_ATTRIBUTE: + return std::string ("UNSUPPORTED_ATTRIBUTE"); + case IEEE_802_15_4_PHY_READ_ONLY: + return std::string ("READ_ONLY"); + case IEEE_802_15_4_PHY_UNSPECIFIED: + return std::string ("UNSPECIFIED"); + default: + return std::string ("INVALID"); + } +} + +std::string +LrWpanHelper::LrWpanMacStatePrinter (LrWpanMacState e) +{ + switch (e) + { + case MAC_IDLE: + return std::string ("MAC_IDLE"); + case CHANNEL_ACCESS_FAILURE: + return std::string ("CHANNEL_ACCESS_FAILURE"); + case CHANNEL_IDLE: + return std::string ("CHANNEL_IDLE"); + case SET_PHY_TX_ON: + return std::string ("SET_PHY_TX_ON"); + default: + return std::string ("INVALID"); + } +} + +void +LrWpanHelper::AddMobility (Ptr phy, Ptr m) +{ + phy->SetMobility (m); +} + +NetDeviceContainer +LrWpanHelper::Install (NodeContainer c) +{ + NetDeviceContainer devices; + for (NodeContainer::Iterator i = c.Begin (); i != c.End (); i++) + { + Ptr node = *i; + + Ptr netDevice = CreateObject (); + netDevice->SetChannel (m_channel); + node->AddDevice (netDevice); + netDevice->SetNode (node); + // \todo add the capability to change short address, extended + // address and panId. Right now they are hardcoded in LrWpanMac::LrWpanMac () + devices.Add (netDevice); + } + return devices; +} + +int64_t +LrWpanHelper::AssignStreams (NetDeviceContainer c, int64_t stream) +{ + int64_t currentStream = stream; + Ptr netDevice; + for (NetDeviceContainer::Iterator i = c.Begin (); i != c.End (); ++i) + { + netDevice = (*i); + Ptr lrwpan = DynamicCast (netDevice); + if (lrwpan) + { + currentStream += lrwpan->AssignStreams (currentStream); + } + } + return (currentStream - stream); +} + +void +LrWpanHelper::AssociateToPan (NetDeviceContainer c, uint16_t panId) +{ + NetDeviceContainer devices; + uint16_t id = 1; + uint8_t idBuf[2]; + + for (NetDeviceContainer::Iterator i = c.Begin (); i != c.End (); i++) + { + Ptr device = DynamicCast (*i); + if (device) + { + idBuf[0] = (id >> 8) & 0xff; + idBuf[1] = (id >> 0) & 0xff; + Mac16Address address; + address.CopyFrom (idBuf); + + device->GetMac ()->SetPanId (panId); + device->GetMac ()->SetShortAddress (address); + id++; + } + } + return; +} + +static void +PcapSniffLrWpan (Ptr file, Ptr packet) +{ + file->Write (Simulator::Now (), packet); +} + +void +LrWpanHelper::EnablePcapInternal (std::string prefix, Ptr nd, bool promiscuous, bool explicitFilename) +{ + NS_LOG_FUNCTION (this << prefix << nd << promiscuous << 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. + // + + // In the future, if we create different NetDevice types, we will + // have to switch on each type below and insert into the right + // NetDevice type + // + Ptr device = nd->GetObject (); + if (device == 0) + { + NS_LOG_INFO ("LrWpanHelper::EnablePcapInternal(): Device " << device << " not of type ns3::LrWpanNetDevice"); + return; + } + + PcapHelper pcapHelper; + + std::string filename; + if (explicitFilename) + { + filename = prefix; + } + else + { + filename = pcapHelper.GetFilenameFromDevice (prefix, device); + } + + Ptr file = pcapHelper.CreateFile (filename, std::ios::out, + PcapHelper::DLT_IEEE802_15_4); + + if (promiscuous == true) + { + device->GetMac ()->TraceConnectWithoutContext ("PromiscSniffer", MakeBoundCallback (&PcapSniffLrWpan, file)); + + } + else + { + device->GetMac ()->TraceConnectWithoutContext ("Sniffer", MakeBoundCallback (&PcapSniffLrWpan, file)); + } +} + +void +LrWpanHelper::EnableAsciiInternal ( + Ptr stream, + std::string prefix, + Ptr nd, + bool explicitFilename) +{ + uint32_t nodeid = nd->GetNode ()->GetId (); + uint32_t deviceid = nd->GetIfIndex (); + std::ostringstream oss; + + Ptr device = nd->GetObject (); + if (device == 0) + { + NS_LOG_INFO ("LrWpanHelper::EnableAsciiInternal(): Device " << device << " not of type ns3::LrWpanNetDevice"); + 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 theStream = asciiTraceHelper.CreateFileStream (filename); + + // Ascii traces typically have "+", '-", "d", "r", and sometimes "t" + // The Mac and Phy objects have the trace sources for these + // + + asciiTraceHelper.HookDefaultReceiveSinkWithoutContext (device, "MacRx", theStream); + + device->GetMac ()->TraceConnectWithoutContext ("MacTx", MakeBoundCallback (&AsciiLrWpanMacTransmitSinkWithoutContext, theStream)); + + asciiTraceHelper.HookDefaultEnqueueSinkWithoutContext (device, "MacTxEnqueue", theStream); + asciiTraceHelper.HookDefaultDequeueSinkWithoutContext (device, "MacTxDequeue", theStream); + asciiTraceHelper.HookDefaultDropSinkWithoutContext (device, "MacTxDrop", theStream); + + return; + } + + // + // If we are provided an OutputStreamWrapper, we are expected to use it, and + // to provide 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. + // + + + oss.str (""); + oss << "/NodeList/" << nodeid << "/DeviceList/" << deviceid << "/$ns3::LrWpanNetDevice/Mac/MacRx"; + device->GetMac ()->TraceConnect ("MacRx", oss.str (), MakeBoundCallback (&AsciiTraceHelper::DefaultReceiveSinkWithContext, stream)); + + oss.str (""); + oss << "/NodeList/" << nodeid << "/DeviceList/" << deviceid << "/$ns3::LrWpanNetDevice/Mac/MacTx"; + device->GetMac ()->TraceConnect ("MacTx", oss.str (), MakeBoundCallback (&AsciiLrWpanMacTransmitSinkWithContext, stream)); + + oss.str (""); + oss << "/NodeList/" << nodeid << "/DeviceList/" << deviceid << "/$ns3::LrWpanNetDevice/Mac/MacTxEnqueue"; + device->GetMac ()->TraceConnect ("MacTxEnqueue", oss.str (), MakeBoundCallback (&AsciiTraceHelper::DefaultEnqueueSinkWithContext, stream)); + + oss.str (""); + oss << "/NodeList/" << nodeid << "/DeviceList/" << deviceid << "/$ns3::LrWpanNetDevice/Mac/MacTxDequeue"; + device->GetMac ()->TraceConnect ("MacTxDequeue", oss.str (), MakeBoundCallback (&AsciiTraceHelper::DefaultDequeueSinkWithContext, stream)); + + oss.str (""); + oss << "/NodeList/" << nodeid << "/DeviceList/" << deviceid << "/$ns3::LrWpanNetDevice/Mac/MacTxDrop"; + device->GetMac ()->TraceConnect ("MacTxDrop", oss.str (), MakeBoundCallback (&AsciiTraceHelper::DefaultDropSinkWithContext, stream)); + +} + +} // namespace ns3 + diff -Naur ns-3.19/src/lr-wpan/helper/lr-wpan-helper.h ns-3.20/src/lr-wpan/helper/lr-wpan-helper.h --- ns-3.19/src/lr-wpan/helper/lr-wpan-helper.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/helper/lr-wpan-helper.h 2014-06-17 10:33:13.898995923 -0700 @@ -0,0 +1,139 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * Gary Pei + * Tom Henderson + */ +#ifndef LR_WPAN_HELPER_H +#define LR_WPAN_HELPER_H + +#include +#include +#include +#include + +namespace ns3 { + +class SingleModelSpectrumChannel; +class MobilityModel; + +/** + * \ingroup lr-wpan + * + * \brief helps to manage and create IEEE 802.15.4 NetDevice objects + * + * This class can help to create IEEE 802.15.4 NetDevice objects + * and to configure their attributes during creation. It also contains + * additional helper functions used by client code. + */ + +class LrWpanHelper : public PcapHelperForDevice, + public AsciiTraceHelperForDevice +{ +public: + /** + * \brief Create a LrWpan helper in an empty state. + */ + LrWpanHelper (void); + virtual ~LrWpanHelper (void); + + /** + * \brief Add mobility model to a physical device + * \param phy the physical device + * \param m the mobility model + */ + void AddMobility (Ptr phy, Ptr m); + + /** + * \param c a set of nodes + */ + NetDeviceContainer Install (NodeContainer c); + + /** + * \brief Associate the nodes to the same PAN + * + * \param c a set of nodes + * \param panId the PAN Id + */ + void AssociateToPan (NetDeviceContainer c, uint16_t panId); + + /** + * Helper to enable all LrWpan log components with one statement + */ + void EnableLogComponents (void); + + static std::string LrWpanPhyEnumerationPrinter (LrWpanPhyEnumeration); + static std::string LrWpanMacStatePrinter (LrWpanMacState e); + + /** + * Assign a fixed random variable stream number to the random variables + * used by this model. Return the number of streams that have been + * assigned. The Install() method should have previously been + * called by the user. + * + * \param c NetDeviceContainer of the set of net devices for which the + * CsmaNetDevice should be modified to use a fixed stream + * \param stream first stream index to use + * \return the number of stream indices assigned by this helper + */ + int64_t AssignStreams (NetDeviceContainer c, int64_t stream); + +private: + // Disable implicit constructors + LrWpanHelper (LrWpanHelper const &); + LrWpanHelper& operator= (LrWpanHelper const &); + /** + * \internal + * + * \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 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 stream, + std::string prefix, + Ptr nd, + bool explicitFilename); + +private: + Ptr m_channel; + +}; + +} + +#endif /* LR_WPAN_HELPER_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-csmaca.cc ns-3.20/src/lr-wpan/model/lr-wpan-csmaca.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-csmaca.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-csmaca.cc 2014-06-17 10:33:13.898995923 -0700 @@ -0,0 +1,387 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * kwong yin + * Sascha Alexander Jopen + */ + +#include "lr-wpan-csmaca.h" +#include +#include +#include +#include + +NS_LOG_COMPONENT_DEFINE ("LrWpanCsmaCa"); + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanCsmaCa); + +TypeId +LrWpanCsmaCa::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanCsmaCa") + .SetParent () + .AddConstructor () + ; + return tid; +} + +LrWpanCsmaCa::LrWpanCsmaCa () +{ + // TODO-- make these into ns-3 attributes + + m_isSlotted = false; + m_NB = 0; + m_CW = 2; + m_BLE = false; + m_macMinBE = 3; + m_macMaxBE = 5; + m_macMaxCSMABackoffs = 4; + m_aUnitBackoffPeriod = 20; //20 symbols + m_random = CreateObject (); + m_BE = m_macMinBE; + m_ccaRequestRunning = false; +} + +LrWpanCsmaCa::~LrWpanCsmaCa () +{ + m_mac = 0; +} + +void +LrWpanCsmaCa::DoDispose () +{ + m_lrWpanMacStateCallback = MakeNullCallback< void, LrWpanMacState> (); + Cancel (); + m_mac = 0; +} + +void +LrWpanCsmaCa::SetMac (Ptr mac) +{ + m_mac = mac; +} + +Ptr +LrWpanCsmaCa::GetMac (void) const +{ + return m_mac; +} + +void +LrWpanCsmaCa::SetSlottedCsmaCa (void) +{ + NS_LOG_FUNCTION (this); + m_isSlotted = true; +} + +void +LrWpanCsmaCa::SetUnSlottedCsmaCa (void) +{ + NS_LOG_FUNCTION (this); + m_isSlotted = false; +} + +bool +LrWpanCsmaCa::IsSlottedCsmaCa (void) const +{ + NS_LOG_FUNCTION (this); + return (m_isSlotted); +} + +bool +LrWpanCsmaCa::IsUnSlottedCsmaCa (void) const +{ + NS_LOG_FUNCTION (this); + return (!m_isSlotted); +} + +void +LrWpanCsmaCa::SetMacMinBE (uint8_t macMinBE) +{ + NS_LOG_FUNCTION (this << macMinBE); + m_macMinBE = macMinBE; +} + +uint8_t +LrWpanCsmaCa::GetMacMinBE (void) const +{ + NS_LOG_FUNCTION (this); + return m_macMinBE; +} + +void +LrWpanCsmaCa::SetMacMaxBE (uint8_t macMaxBE) +{ + NS_LOG_FUNCTION (this << macMaxBE); + m_macMinBE = macMaxBE; +} + +uint8_t +LrWpanCsmaCa::GetMacMaxBE (void) const +{ + NS_LOG_FUNCTION (this); + return m_macMaxBE; +} + +void +LrWpanCsmaCa::SetMacMaxCSMABackoffs (uint8_t macMaxCSMABackoffs) +{ + NS_LOG_FUNCTION (this << macMaxCSMABackoffs); + m_macMaxCSMABackoffs = macMaxCSMABackoffs; +} + +uint8_t +LrWpanCsmaCa::GetMacMaxCSMABackoffs (void) const +{ + NS_LOG_FUNCTION (this); + return m_macMaxCSMABackoffs; +} + +void +LrWpanCsmaCa::SetUnitBackoffPeriod (uint64_t unitBackoffPeriod) +{ + NS_LOG_FUNCTION (this << unitBackoffPeriod); + m_aUnitBackoffPeriod = unitBackoffPeriod; +} + +uint64_t +LrWpanCsmaCa::GetUnitBackoffPeriod (void) const +{ + NS_LOG_FUNCTION (this); + return m_aUnitBackoffPeriod; +} + +Time +LrWpanCsmaCa::GetTimeToNextSlot (void) const +{ + NS_LOG_FUNCTION (this); + + // TODO: Calculate the offset to the next slot. + + return Seconds (0); + +} +void +LrWpanCsmaCa::Start () + +{ + NS_LOG_FUNCTION (this); + m_NB = 0; + if (IsSlottedCsmaCa ()) + { + m_CW = 2; + if (m_BLE) + { + m_BE = std::min (static_cast (2), m_macMinBE); + } + else + { + m_BE = m_macMinBE; + } + //TODO: for slotted, locate backoff period boundary. i.e. delay to the next slot boundary + Time backoffBoundary = GetTimeToNextSlot (); + m_randomBackoffEvent = Simulator::Schedule (backoffBoundary, &LrWpanCsmaCa::RandomBackoffDelay, this); + } + else + { + m_BE = m_macMinBE; + m_randomBackoffEvent = Simulator::ScheduleNow (&LrWpanCsmaCa::RandomBackoffDelay, this); + } + /* + * TODO: If using Backoff.cc (will need to modify Backoff::GetBackoffTime) + * Backoff.m_minSlots = 0; + * Backoff.m_ceiling = m_BE; + * Backoff.ResetBackoffTime(); //m_NB is same as m_numBackoffRetries in Backoff.h + * Backoff.m_maxRetries = macMaxCSMABackoffs; + * Backoff.m_slotTime = m_backoffPeriod; + */ +} + +void +LrWpanCsmaCa::Cancel () +{ + m_randomBackoffEvent.Cancel (); + m_requestCcaEvent.Cancel (); + m_canProceedEvent.Cancel (); +} + +/* + * Delay for backoff period in the range 0 to 2^BE -1 units + * TODO: If using Backoff.cc (Backoff::GetBackoffTime) will need to be slightly modified + */ +void +LrWpanCsmaCa::RandomBackoffDelay () +{ + NS_LOG_FUNCTION (this); + + uint64_t upperBound = (uint64_t) pow (2, m_BE) - 1; + uint64_t backoffPeriod; + Time randomBackoff; + uint64_t symbolRate; + bool isData = false; + + + symbolRate = (uint64_t) m_mac->GetPhy ()->GetDataOrSymbolRate (isData); //symbols per second + backoffPeriod = (uint64_t)m_random->GetValue (0, upperBound); //num backoff periods + randomBackoff = MicroSeconds (backoffPeriod * GetUnitBackoffPeriod () * 1000 * 1000 / symbolRate); + + if (IsUnSlottedCsmaCa ()) + { + NS_LOG_LOGIC ("Unslotted: requesting CCA after backoff of " << randomBackoff.GetMicroSeconds () << " us"); + m_requestCcaEvent = Simulator::Schedule (randomBackoff, &LrWpanCsmaCa::RequestCCA, this); + } + else + { + NS_LOG_LOGIC ("Slotted: proceeding after backoff of " << randomBackoff.GetMicroSeconds () << " us"); + m_canProceedEvent = Simulator::Schedule (randomBackoff, &LrWpanCsmaCa::CanProceed, this); + } +} + +// TODO : Determine if transmission can be completed before end of CAP for the slotted csmaca +// If not delay to the next CAP +void +LrWpanCsmaCa::CanProceed () +{ + NS_LOG_FUNCTION (this); + + bool canProceed = true; + + if (m_BLE) + { + } + else + { + } + + if (canProceed) + { + // TODO: For slotted, Perform CCA on backoff period boundary i.e. delay to next slot boundary + Time backoffBoundary = GetTimeToNextSlot (); + m_requestCcaEvent = Simulator::Schedule (backoffBoundary, &LrWpanCsmaCa::RequestCCA, this); + } + else + { + Time nextCap = Seconds (0); + m_randomBackoffEvent = Simulator::Schedule (nextCap, &LrWpanCsmaCa::RandomBackoffDelay, this); + } +} + +void +LrWpanCsmaCa::RequestCCA () +{ + NS_LOG_FUNCTION (this); + m_ccaRequestRunning = true; + m_mac->GetPhy ()->PlmeCcaRequest (); +} + +/* + * This function is called when the phy calls back after completing a PlmeCcaRequest + */ +void +LrWpanCsmaCa::PlmeCcaConfirm (LrWpanPhyEnumeration status) +{ + NS_LOG_FUNCTION (this << status); + + // Only react on this event, if we are actually waiting for a CCA. + // If the CSMA algorithm was canceled, we could still receive this event from + // the PHY. In this case we ignore the event. + if (m_ccaRequestRunning) + { + m_ccaRequestRunning = false; + if (status == IEEE_802_15_4_PHY_IDLE) + { + if (IsSlottedCsmaCa ()) + { + m_CW--; + if (m_CW == 0) + { + // inform MAC channel is idle + if (!m_lrWpanMacStateCallback.IsNull ()) + { + NS_LOG_LOGIC ("Notifying MAC of idle channel"); + m_lrWpanMacStateCallback (CHANNEL_IDLE); + } + } + else + { + NS_LOG_LOGIC ("Perform CCA again, m_CW = " << m_CW); + m_requestCcaEvent = Simulator::ScheduleNow (&LrWpanCsmaCa::RequestCCA, this); // Perform CCA again + } + } + else + { + // inform MAC, channel is idle + if (!m_lrWpanMacStateCallback.IsNull ()) + { + NS_LOG_LOGIC ("Notifying MAC of idle channel"); + m_lrWpanMacStateCallback (CHANNEL_IDLE); + } + } + } + else + { + if (IsSlottedCsmaCa ()) + { + m_CW = 2; + } + m_BE = std::min (static_cast (m_BE + 1), static_cast (m_macMaxBE)); + m_NB++; + if (m_NB > m_macMaxCSMABackoffs) + { + // no channel found so cannot send pkt + NS_LOG_DEBUG ("Channel access failure"); + if (!m_lrWpanMacStateCallback.IsNull ()) + { + NS_LOG_LOGIC ("Notifying MAC of Channel access failure"); + m_lrWpanMacStateCallback (CHANNEL_ACCESS_FAILURE); + } + return; + } + else + { + NS_LOG_DEBUG ("Perform another backoff; m_NB = " << static_cast (m_NB)); + m_randomBackoffEvent = Simulator::ScheduleNow (&LrWpanCsmaCa::RandomBackoffDelay, this); //Perform another backoff (step 2) + } + } + } +} + +void +LrWpanCsmaCa::SetLrWpanMacStateCallback (LrWpanMacStateCallback c) +{ + NS_LOG_FUNCTION (this); + m_lrWpanMacStateCallback = c; +} + +int64_t +LrWpanCsmaCa::AssignStreams (int64_t stream) +{ + NS_LOG_FUNCTION (this); + m_random->SetStream (stream); + return 1; +} + +uint8_t +LrWpanCsmaCa::GetNB (void) +{ + return m_NB; +} + +} //namespace ns3 diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-csmaca.h ns-3.20/src/lr-wpan/model/lr-wpan-csmaca.h --- ns-3.19/src/lr-wpan/model/lr-wpan-csmaca.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-csmaca.h 2014-06-17 10:33:13.899995915 -0700 @@ -0,0 +1,335 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * kwong yin + * Sascha Alexander Jopen + */ + +#ifndef LR_WPAN_CSMACA_H +#define LR_WPAN_CSMACA_H + +#include +#include +#include + +namespace ns3 { + +class UniformRandomVariable; + +/** + * This method informs the MAC whether the channel is idle or busy. + */ +typedef Callback LrWpanMacStateCallback; + +/** + * \ingroup lr-wpan + * + * This class is a helper for the LrWpanMac to manage the Csma/CA + * state machine according to IEEE 802.15.4-2006, section 7.5.1.4. + */ +class LrWpanCsmaCa : public Object +{ + +public: + /** + * Get the type ID. + * + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + /** + * Default constructor. + */ + LrWpanCsmaCa (void); + virtual ~LrWpanCsmaCa (void); + + /** + * Set the MAC to which this CSMA/CA implementation is attached to. + * + * \param mac the used MAC + */ + void SetMac (Ptr mac); + + /** + * Get the MAC to which this CSMA/CA implementation is attached to. + * + * \return the used MAC + */ + Ptr GetMac (void) const; + + /** + * Configure for the use of the slotted CSMA/CA version. + */ + void SetSlottedCsmaCa (void); + + /** + * Configure for the use of the unslotted CSMA/CA version. + */ + void SetUnSlottedCsmaCa (void); + + /** + * Check if the slotted CSMA/CA version is being used. + * + * \return true, if slotted CSMA/CA is used, false otherwise. + */ + bool IsSlottedCsmaCa (void) const; + + /** + * Check if the unslotted CSMA/CA version is being used. + * + * \return true, if unslotted CSMA/CA is used, false otherwise. + */ + bool IsUnSlottedCsmaCa (void) const; + + /** + * Set the minimum backoff exponent value. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + * + * \param macMinBE the minimum backoff exponent value + */ + void SetMacMinBE (uint8_t macMinBE); + + /** + * Get the minimum backoff exponent value. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + * + * \return the minimum backoff exponent value + */ + uint8_t GetMacMinBE (void) const; + + /** + * Set the maximum backoff exponent value. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + * + * \param macMaxBE the maximum backoff exponent value + */ + void SetMacMaxBE (uint8_t macMaxBE); + + /** + * Get the maximum backoff exponent value. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + * + * \return the maximum backoff exponent value + */ + uint8_t GetMacMaxBE (void) const; + + /** + * Set the maximum number of backoffs. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + * + * \param macMaxCSMABackoffs the maximum number of backoffs + */ + void SetMacMaxCSMABackoffs (uint8_t macMaxCSMABackoffs); + + /** + * Get the maximum number of backoffs. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + * + * \return the maximum number of backoffs + */ + uint8_t GetMacMaxCSMABackoffs (void) const; + + /** + * Set the number of symbols forming the basic time period used by the + * CSMA-CA algorithm. + * See IEEE 802.15.4-2006, section 7.4.1, Table 85. + * + * \param unitBackoffPeriod the period length in symbols + */ + void SetUnitBackoffPeriod (uint64_t unitBackoffPeriod); + + /** + * Get the number of symbols forming the basic time period used by the + * CSMA-CA algorithm. + * See IEEE 802.15.4-2006, section 7.4.1, Table 85. + * + * \return the period length in symbols + */ + uint64_t GetUnitBackoffPeriod (void) const; + + /** + * Get the amount of time from now to the beginning of the next slot. + * + * \return time offset to the next slot + */ + Time GetTimeToNextSlot (void) const; + + /** + * Start CSMA-CA algorithm (step 1), initialize NB, BE for both slotted and unslotted + * CSMA-CA. For the slotted intialize CW plus also start on the backoff boundary + */ + void Start (void); + + /** + * Cancel CSMA-CA algorithm. + */ + void Cancel (void); + + /** + * In step 2 of the CSMA-CA, perform a random backoff in the range of 0 to 2^BE -1 + */ + void RandomBackoffDelay (void); + + /** + * In the slotted CSMA-CA, after random backoff, determine if the remaining + * CSMA-CA operation can proceed, i.e. can the entire transactions can be + * transmitted before the end of the CAP. This step is performed between step + * 2 and 3. This step is NOT performed for the unslotted CSMA-CA. If it can + * proceed function RequestCCA() is called. + */ + void CanProceed (void); + + /** + * Request the Phy to perform CCA (Step 3) + */ + void RequestCCA (void); + + /** + * IEEE 802.15.4-2006 section 6.2.2.2 + * PLME-CCA.confirm status + * @param status TRX_OFF, BUSY or IDLE + * + * When Phy has completed CCA, it calls back here which in turn execute the final steps + * of the CSMA-CA algorithm. + * It checks to see if the Channel is idle, if so check the Contention window before + * permitting transmission (step 5). If channel is busy, either backoff and perform CCA again or + * treat as channel access failure (step 4). + */ + void PlmeCcaConfirm (LrWpanPhyEnumeration status); + + /** + * Set the callback function to the MAC. Used at the end of a Channel Assessment, as part of the + * interconnections between the CSMA-CA and the MAC. The callback + * lets MAC know a channel is either idle or busy. + * + * \param macState the mac state callback + */ + void SetLrWpanMacStateCallback (LrWpanMacStateCallback macState); + + /** + * Assign a fixed random variable stream number to the random variables + * used by this model. Return the number of streams that have been assigned. + * + * \param stream first stream index to use + * \return the number of stream indices assigned by this model + */ + int64_t AssignStreams (int64_t stream); + + /** + * Get the number of CSMA retries + * + * \returns the number of CSMA retries + */ + uint8_t GetNB (void); + +private: + // Disable implicit copy constructors + LrWpanCsmaCa (LrWpanCsmaCa const &); + LrWpanCsmaCa& operator= (LrWpanCsmaCa const &); + + virtual void DoDispose (void); + + /** + * The callback to inform the configured MAC of the CSMA/CA result. + */ + LrWpanMacStateCallback m_lrWpanMacStateCallback; + + /** + * Beacon-enabled slotted or nonbeacon-enabled unslotted CSMA-CA. + */ + bool m_isSlotted; + + /** + * The MAC instance for which this CSMAÄ/CA implemenation is configured. + */ + Ptr m_mac; + + /** + * Number of backoffs for the current transmission. + */ + uint8_t m_NB; + + /** + * Contention window length (used in slotted ver only). + */ + uint8_t m_CW; + + /** + * Backoff exponent. + */ + uint8_t m_BE; + + /** + * Battery Life Extension. + */ + bool m_BLE; + + /** + * Minimum backoff exponent. 0 - macMaxBE, default 3 + */ + uint8_t m_macMinBE; // + + /** + * Maximum backoff exponent. 3 - 8, default 5 + */ + uint8_t m_macMaxBE; + + /** + * Maximum number of backoffs. 0 - 5, default 4 + */ + uint8_t m_macMaxCSMABackoffs; + + /** + * Number of symbols per CSMA/CA time unit, default 20 symbols. + */ + uint64_t m_aUnitBackoffPeriod; + + /** + * Uniform random variable stream. + */ + Ptr m_random; + + /** + * Scheduler event for the start of the next random backoff/slot. + */ + EventId m_randomBackoffEvent; + + /** + * Scheduler event when to start the CCA after a random backoff. + */ + EventId m_requestCcaEvent; + + /** + * Scheduler event for checking if we can complete the transmission before the + * end of the CAP. + */ + EventId m_canProceedEvent; + + /** + * Flag indicating that the PHY is currently running a CCA. Used to prevent + * reporting the channel status to the MAC while canceling the CSMA algorithm. + */ + bool m_ccaRequestRunning; +}; + +} + +// namespace ns-3 + +#endif /* LR_WPAN_CSMACA_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-error-model.cc ns-3.20/src/lr-wpan/model/lr-wpan-error-model.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-error-model.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-error-model.cc 2014-06-17 10:33:13.899995915 -0700 @@ -0,0 +1,79 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: Gary Pei + */ +#include "lr-wpan-error-model.h" +#include + +#include + +NS_LOG_COMPONENT_DEFINE ("LrWpanErrorModel"); + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanErrorModel); + +TypeId +LrWpanErrorModel::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanErrorModel") + .SetParent () + .AddConstructor () + ; + return tid; +} + +LrWpanErrorModel::LrWpanErrorModel (void) +{ + m_binomialCoefficients[0] = 1; + m_binomialCoefficients[1] = -16; + m_binomialCoefficients[2] = 120; + m_binomialCoefficients[3] = -560; + m_binomialCoefficients[4] = 1820; + m_binomialCoefficients[5] = -4368; + m_binomialCoefficients[6] = 8008; + m_binomialCoefficients[7] = -11440; + m_binomialCoefficients[8] = 12870; + m_binomialCoefficients[9] = -11440; + m_binomialCoefficients[10] = 8008; + m_binomialCoefficients[11] = -4368; + m_binomialCoefficients[12] = 1820; + m_binomialCoefficients[13] = -560; + m_binomialCoefficients[14] = 120; + m_binomialCoefficients[15] = -16; + m_binomialCoefficients[16] = 1; +} + +double +LrWpanErrorModel::GetChunkSuccessRate (double snr, uint32_t nbits) const +{ + double ber = 0.0; + + for (uint32_t k = 2; k <= 16; k++) + { + ber += m_binomialCoefficients[k] * exp (20.0 * snr * (1.0 / k - 1.0)); + } + + ber = ber * 8.0 / 15.0 / 16.0; + + ber = std::min (ber, 1.0); + double retval = pow (1.0 - ber, nbits); + return retval; +} + +} // namespace ns3 diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-error-model.h ns-3.20/src/lr-wpan/model/lr-wpan-error-model.h --- ns-3.19/src/lr-wpan/model/lr-wpan-error-model.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-error-model.h 2014-06-17 10:33:13.899995915 -0700 @@ -0,0 +1,66 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: Gary Pei + */ +#ifndef LR_WPAN_ERROR_MODEL_H +#define LR_WPAN_ERROR_MODEL_H + +#include + +namespace ns3 { + +/** + * \ingroup lr-wpan + * + * Model the error rate for IEEE 802.15.4 2.4 GHz AWGN channel for OQPSK + * the model description can be found in IEEE Std 802.15.4-2006, section + * E.4.1.7 + */ +class LrWpanErrorModel : public Object +{ +public: + /** + * Get the type ID. + * + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + LrWpanErrorModel (void); + + /** + * Return chunk success rate for given SNR. + * + * \return success rate (i.e. 1 - chunk error rate) + * \param snr SNR expressed as a power ratio (i.e. not in dB) + * \param nbits number of bits in the chunk + */ + double GetChunkSuccessRate (double snr, uint32_t nbits) const; + +private: + /** + * Array of precalculated binomial coefficients. + */ + double m_binomialCoefficients[17]; + +}; + + +} // namespace ns3 + +#endif /* LR_WPAN_ERROR_MODEL_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-interference-helper.cc ns-3.20/src/lr-wpan/model/lr-wpan-interference-helper.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-interference-helper.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-interference-helper.cc 2014-06-17 10:33:13.900995908 -0700 @@ -0,0 +1,109 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2013 Fraunhofer FKIE + * + * 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: + * Sascha Alexander Jopen + */ +#include "lr-wpan-interference-helper.h" +#include +#include +#include + +NS_LOG_COMPONENT_DEFINE ("LrWpanInterferenceHelper"); + +namespace ns3 { + +LrWpanInterferenceHelper::LrWpanInterferenceHelper (Ptr spectrumModel) + : m_spectrumModel (spectrumModel), + m_dirty (false) +{ + m_signal = Create (m_spectrumModel); +} + +LrWpanInterferenceHelper::~LrWpanInterferenceHelper (void) +{ + m_spectrumModel = 0; + m_signal = 0; + m_signals.clear (); +} + +bool +LrWpanInterferenceHelper::AddSignal (Ptr signal) +{ + NS_LOG_FUNCTION (this << signal); + + bool result = false; + + if (signal->GetSpectrumModel () == m_spectrumModel) + { + result = m_signals.insert (signal).second; + if (result && !m_dirty) + { + *m_signal += *signal; + } + } + return result; +} + +bool +LrWpanInterferenceHelper::RemoveSignal (Ptr signal) +{ + NS_LOG_FUNCTION (this << signal); + + bool result = false; + + if (signal->GetSpectrumModel () == m_spectrumModel) + { + result = (m_signals.erase (signal) == 1); + if (result) + { + m_dirty = true; + } + } + return result; +} + +void +LrWpanInterferenceHelper::ClearSignals (void) +{ + NS_LOG_FUNCTION (this); + + m_signals.clear (); + m_dirty = true; +} + +Ptr +LrWpanInterferenceHelper::GetSignalPsd (void) const +{ + NS_LOG_FUNCTION (this); + + if (m_dirty) + { + // Sum up the current interference PSD. + std::set >::const_iterator it; + m_signal = Create (m_spectrumModel); + for (it = m_signals.begin (); it != m_signals.end (); ++it) + { + *m_signal += *(*it); + } + m_dirty = false; + } + + return m_signal->Copy (); +} + +} diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-interference-helper.h ns-3.20/src/lr-wpan/model/lr-wpan-interference-helper.h --- ns-3.19/src/lr-wpan/model/lr-wpan-interference-helper.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-interference-helper.h 2014-06-17 10:33:13.900995908 -0700 @@ -0,0 +1,116 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2013 Fraunhofer FKIE + * + * 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: + * Sascha Alexander Jopen + */ +#ifndef LR_WPAN_INTERFERENCE_HELPER_H +#define LR_WPAN_INTERFERENCE_HELPER_H + +#include +#include +#include + +namespace ns3 { + +class SpectrumValue; +class SpectrumModel; + +/** + * \ingroup lr-wpan + * + * \brief This class provides helper functions for LrWpan interference handling. + */ +class LrWpanInterferenceHelper : public SimpleRefCount +{ +public: + /** + * Create a new interference helper for the given SpectrumModel. + * + * \param spectrumModel the SpectrumModel to be used + */ + LrWpanInterferenceHelper (Ptr spectrumModel); + + ~LrWpanInterferenceHelper (void); + + /** + * Add the given signal to the set of accumulated signals. Never add the same + * signal more than once. The SpectrumModels of the signal and the one used + * for instantiation of the helper have to be the same. + * + * \param signal the signal to be added + * \return false, if the signal was not added because the SpectrumModel of the + * signal does not match the one of the helper, true otherwise. + */ + bool AddSignal (Ptr signal); + + /** + * Remove the given signal to the set of accumulated signals. + * + * \param signal the signal to be removed + * \return false, if the signal was not removed (because it was not added + * before), true otherwise. + */ + bool RemoveSignal (Ptr signal); + + /** + * Remove all currently accumulated signals. + */ + void ClearSignals (void); + + /** + * Get the sum of all accumulated signals. + * + * \return the sum of the signals + */ + Ptr GetSignalPsd (void) const; + + /** + * Get the SpectrumModel used by the helper. + * + * \return the helpers SpectrumModel + */ + Ptr GetSpectrumModel (void) const; +private: + // Disable implicit copy constructors + LrWpanInterferenceHelper (LrWpanInterferenceHelper const &); + LrWpanInterferenceHelper& operator= (LrWpanInterferenceHelper const &); + /** + * The helpers SpectrumModel. + */ + Ptr m_spectrumModel; + + /** + * The set of accumulated signals. + */ + std::set > m_signals; + + /** + * The precomputed sum of all accumulated signals. + */ + mutable Ptr m_signal; + + /** + * Mark m_signal as dirty, whenever a signal is added or removed. m_signal has + * to be recomputed before next use. + */ + mutable bool m_dirty; +}; + +} + +#endif /* LR_WPAN_INTERFERENCE_HELPER_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-lqi-tag.cc ns-3.20/src/lr-wpan/model/lr-wpan-lqi-tag.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-lqi-tag.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-lqi-tag.cc 2014-06-17 10:33:13.900995908 -0700 @@ -0,0 +1,94 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2013 Fraunhofer FKIE + * + * 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: + * Sascha Alexander Jopen + */ +#include "lr-wpan-lqi-tag.h" +#include + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanLqiTag); + +TypeId +LrWpanLqiTag::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanLqiTag") + .SetParent () + .AddConstructor () + .AddAttribute ("Lqi", "The lqi of the last packet received", + IntegerValue (0), + MakeIntegerAccessor (&LrWpanLqiTag::Get), + MakeIntegerChecker ()) + ; + return tid; +} + +TypeId +LrWpanLqiTag::GetInstanceTypeId (void) const +{ + return GetTypeId (); +} + +LrWpanLqiTag::LrWpanLqiTag (void) + : m_lqi (0) +{ +} + +LrWpanLqiTag::LrWpanLqiTag (uint8_t lqi) + : m_lqi (lqi) +{ +} + +uint32_t +LrWpanLqiTag::GetSerializedSize (void) const +{ + return sizeof (uint8_t); +} + +void +LrWpanLqiTag::Serialize (TagBuffer i) const +{ + i.WriteU8 (m_lqi); +} + +void +LrWpanLqiTag::Deserialize (TagBuffer i) +{ + m_lqi = i.ReadU8 (); +} + +void +LrWpanLqiTag::Print (std::ostream &os) const +{ + os << "Lqi = " << m_lqi; +} + +void +LrWpanLqiTag::Set (uint8_t lqi) +{ + m_lqi = lqi; +} + +uint8_t +LrWpanLqiTag::Get (void) const +{ + return m_lqi; +} + +} diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-lqi-tag.h ns-3.20/src/lr-wpan/model/lr-wpan-lqi-tag.h --- ns-3.19/src/lr-wpan/model/lr-wpan-lqi-tag.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-lqi-tag.h 2014-06-17 10:33:13.901995900 -0700 @@ -0,0 +1,77 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2013 Fraunhofer FKIE + * + * 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: + * Sascha Alexander Jopen + */ +#ifndef LR_WPAN_LQI_TAG_H +#define LR_WPAN_LQI_TAG_H + +#include + +namespace ns3 { + +class LrWpanLqiTag : public Tag +{ +public: + /** + * Get the type ID. + * + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + virtual TypeId GetInstanceTypeId (void) const; + + /** + * Create a LrWpanLqiTag with the default LQI 0. + */ + LrWpanLqiTag (void); + + /** + * Create a LrWpanLqiTag with the given LQI value. + */ + LrWpanLqiTag (uint8_t lqi); + + 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 LQI to the given value. + * + * \param lqi the value of the LQI to set + */ + void Set (uint8_t lqi); + + /** + * Get the LQI value. + * + * \return the LQI value + */ + uint8_t Get (void) const; +private: + /** + * The current LQI value of the tag. + */ + uint8_t m_lqi; +}; + + +} +#endif /* LR_WPAN_LQI_TAG_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-mac.cc ns-3.20/src/lr-wpan/model/lr-wpan-mac.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-mac.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-mac.cc 2014-06-17 10:33:13.903995884 -0700 @@ -0,0 +1,1015 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * Gary Pei + * kwong yin + * Tom Henderson + * Sascha Alexander Jopen + * Erwan Livolant + */ +#include "lr-wpan-mac.h" +#include "lr-wpan-csmaca.h" +#include "lr-wpan-mac-header.h" +#include "lr-wpan-mac-trailer.h" +#include +#include +#include +#include +#include +#include +#include + +NS_LOG_COMPONENT_DEFINE ("LrWpanMac"); + +#undef NS_LOG_APPEND_CONTEXT +#define NS_LOG_APPEND_CONTEXT \ + std::clog << "[address " << m_shortAddress << "] "; + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanMac); + +const uint32_t LrWpanMac::aMinMPDUOverhead = 9; // Table 85 + +TypeId +LrWpanMac::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanMac") + .SetParent () + .AddConstructor () + .AddAttribute ("PanId", "16-bit identifier of the associated PAN", + UintegerValue (), + MakeUintegerAccessor (&LrWpanMac::m_macPanId), + MakeUintegerChecker ()) + .AddTraceSource ("MacTxEnqueue", + "Trace source indicating a packet has was enqueued in the transaction queue", + MakeTraceSourceAccessor (&LrWpanMac::m_macTxEnqueueTrace)) + .AddTraceSource ("MacTxDequeue", + "Trace source indicating a packet has was dequeued from the transaction queue", + MakeTraceSourceAccessor (&LrWpanMac::m_macTxDequeueTrace)) + .AddTraceSource ("MacTx", + "Trace source indicating a packet has arrived for transmission by this device", + MakeTraceSourceAccessor (&LrWpanMac::m_macTxTrace)) + .AddTraceSource ("MacTxOk", + "Trace source indicating a packet has been successfully sent", + MakeTraceSourceAccessor (&LrWpanMac::m_macTxOkTrace)) + .AddTraceSource ("MacTxDrop", + "Trace source indicating a packet has been dropped during transmission", + MakeTraceSourceAccessor (&LrWpanMac::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 (&LrWpanMac::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 (&LrWpanMac::m_macRxTrace)) + .AddTraceSource ("MacRxDrop", + "Trace source indicating a packet was received, but dropped before being forwarded up the stack", + MakeTraceSourceAccessor (&LrWpanMac::m_macRxDropTrace)) + .AddTraceSource ("Sniffer", + "Trace source simulating a non-promiscuous packet sniffer attached to the device", + MakeTraceSourceAccessor (&LrWpanMac::m_snifferTrace)) + .AddTraceSource ("PromiscSniffer", + "Trace source simulating a promiscuous packet sniffer attached to the device", + MakeTraceSourceAccessor (&LrWpanMac::m_promiscSnifferTrace)) + .AddTraceSource ("MacState", + "The state of LrWpan Mac", + MakeTraceSourceAccessor (&LrWpanMac::m_macStateLogger)) + .AddTraceSource ("MacSentPkt", + "Trace source reporting some information about the sent packet", + MakeTraceSourceAccessor (&LrWpanMac::m_sentPktTrace)) + ; + return tid; +} + +LrWpanMac::LrWpanMac () +{ + + // First set the state to a known value, call ChangeMacState to fire trace source. + m_lrWpanMacState = MAC_IDLE; + ChangeMacState (MAC_IDLE); + + m_macRxOnWhenIdle = true; + m_macPanId = 0; + m_associationStatus = ASSOCIATED; + m_selfExt = Mac64Address::Allocate (); + m_macPromiscuousMode = false; + m_macMaxFrameRetries = 3; + m_retransmission = 0; + m_numCsmacaRetry = 0; + m_txPkt = 0; + + Ptr uniformVar = CreateObject (); + uniformVar->SetAttribute ("Min", DoubleValue (0.0)); + uniformVar->SetAttribute ("Max", DoubleValue (255.0)); + m_macDsn = SequenceNumber8 (uniformVar->GetValue ()); + m_shortAddress = Mac16Address ("00:00"); +} + +LrWpanMac::~LrWpanMac () +{ +} + +void +LrWpanMac::DoInitialize () +{ + if (m_macRxOnWhenIdle) + { + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_RX_ON); + } + else + { + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_TRX_OFF); + } + + Object::DoInitialize (); +} + +void +LrWpanMac::DoDispose () +{ + if (m_csmaCa != 0) + { + m_csmaCa->Dispose (); + m_csmaCa = 0; + } + m_txPkt = 0; + for (uint32_t i = 0; i < m_txQueue.size (); i++) + { + m_txQueue[i]->txQPkt = 0; + delete m_txQueue[i]; + } + m_txQueue.clear (); + m_phy = 0; + m_mcpsDataIndicationCallback = MakeNullCallback< void, McpsDataIndicationParams, Ptr > (); + m_mcpsDataConfirmCallback = MakeNullCallback< void, McpsDataConfirmParams > (); + + Object::DoDispose (); +} + +bool +LrWpanMac::GetRxOnWhenIdle () +{ + return m_macRxOnWhenIdle; +} + +void +LrWpanMac::SetRxOnWhenIdle (bool rxOnWhenIdle) +{ + NS_LOG_FUNCTION (this << rxOnWhenIdle); + m_macRxOnWhenIdle = rxOnWhenIdle; + + if (m_lrWpanMacState == MAC_IDLE) + { + if (m_macRxOnWhenIdle) + { + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_RX_ON); + } + else + { + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_TRX_OFF); + } + } +} + +void +LrWpanMac::SetShortAddress (Mac16Address address) +{ + //NS_LOG_FUNCTION (this << address); + m_shortAddress = address; +} + +void +LrWpanMac::SetExtendedAddress (Mac64Address address) +{ + //NS_LOG_FUNCTION (this << address); + m_selfExt = address; +} + + +Mac16Address +LrWpanMac::GetShortAddress () const +{ + NS_LOG_FUNCTION (this); + return m_shortAddress; +} + +Mac64Address +LrWpanMac::GetExtendedAddress () const +{ + NS_LOG_FUNCTION (this); + return m_selfExt; +} +void +LrWpanMac::McpsDataRequest (McpsDataRequestParams params, Ptr p) +{ + NS_LOG_FUNCTION (this << p); + + McpsDataConfirmParams confirmParams; + confirmParams.m_msduHandle = params.m_msduHandle; + + // TODO: We need a drop trace for the case that the packet is too large or the request parameters are maleformed. + // The current tx drop trace is not suitable, because packets dropped using this trace carry the mac header + // and footer, while packets being dropped here do not have them. + + LrWpanMacHeader macHdr (LrWpanMacHeader::LRWPAN_MAC_DATA, m_macDsn.GetValue ()); + m_macDsn++; + + if (p->GetSize () > LrWpanPhy::aMaxPhyPacketSize - aMinMPDUOverhead) + { + // Note, this is just testing maximum theoretical frame size per the spec + // The frame could still be too large once headers are put on + // in which case the phy will reject it instead + NS_LOG_ERROR (this << " packet too big: " << p->GetSize ()); + confirmParams.m_status = IEEE_802_15_4_FRAME_TOO_LONG; + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + return; + } + + if ((params.m_srcAddrMode == NO_PANID_ADDR) + && (params.m_dstAddrMode == NO_PANID_ADDR)) + { + NS_LOG_ERROR (this << " Can not send packet with no Address field" ); + confirmParams.m_status = IEEE_802_15_4_INVALID_ADDRESS; + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + return; + } + switch (params.m_srcAddrMode) + { + case NO_PANID_ADDR: + macHdr.SetSrcAddrMode (params.m_srcAddrMode); + macHdr.SetNoPanIdComp (); + break; + case ADDR_MODE_RESERVED: + macHdr.SetSrcAddrMode (params.m_srcAddrMode); + break; + case SHORT_ADDR: + macHdr.SetSrcAddrMode (params.m_srcAddrMode); + macHdr.SetSrcAddrFields (GetPanId (), GetShortAddress ()); + break; + case EXT_ADDR: + macHdr.SetSrcAddrMode (params.m_srcAddrMode); + macHdr.SetSrcAddrFields (GetPanId (), GetExtendedAddress ()); + break; + default: + NS_LOG_ERROR (this << " Can not send packet with incorrect Source Address mode = " << params.m_srcAddrMode); + confirmParams.m_status = IEEE_802_15_4_INVALID_ADDRESS; + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + return; + } + + macHdr.SetDstAddrMode (params.m_dstAddrMode); + // TODO: Add field for EXT_ADDR destination address (and use it here). + macHdr.SetDstAddrFields (params.m_dstPanId, params.m_dstAddr); + macHdr.SetSecDisable (); + //extract the last 3 bits in TxOptions and map to macHdr + int b0 = params.m_txOptions & TX_OPTION_ACK; + int b1 = params.m_txOptions & TX_OPTION_GTS; + int b2 = params.m_txOptions & TX_OPTION_INDIRECT; + if (b0 == TX_OPTION_ACK) + { + // Set AckReq bit only if the destination is not the broadcast address. + if (!(macHdr.GetDstAddrMode () == SHORT_ADDR && macHdr.GetShortDstAddr () == "ff:ff")) + { + macHdr.SetAckReq (); + } + } + else if (b0 == 0) + { + macHdr.SetNoAckReq (); + } + else + { + confirmParams.m_status = IEEE_802_15_4_INVALID_PARAMETER; + NS_LOG_ERROR (this << "Incorrect TxOptions bit 0 not 0/1"); + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + return; + } + + //if is Slotted CSMA means its beacon enabled + if (m_csmaCa->IsSlottedCsmaCa ()) + { + if (b1 == TX_OPTION_GTS) + { + //TODO:GTS Transmission + } + else if (b1 == 0) + { + //TODO:CAP Transmission + } + else + { + NS_LOG_ERROR (this << "Incorrect TxOptions bit 1 not 0/1"); + confirmParams.m_status = IEEE_802_15_4_INVALID_PARAMETER; + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + return; + } + } + else + { + if (b1 != 0) + { + NS_LOG_ERROR (this << "for non-beacon-enables PAN, bit 1 should always be set to 0"); + confirmParams.m_status = IEEE_802_15_4_INVALID_PARAMETER; + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + return; + } + } + + if (b2 == TX_OPTION_INDIRECT) + { + //TODO :indirect tx + } + else if (b2 == 0) + { + //TODO :direct tx + } + else + { + NS_LOG_ERROR (this << "Incorrect TxOptions bit 2 not 0/1"); + confirmParams.m_status = IEEE_802_15_4_INVALID_PARAMETER; + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + return; + } + + p->AddHeader (macHdr); + + LrWpanMacTrailer macTrailer; + // Calculate FCS if the global attribute ChecksumEnable is set. + if (Node::ChecksumEnabled ()) + { + macTrailer.EnableFcs (true); + macTrailer.SetFcs (p); + } + p->AddTrailer (macTrailer); + + m_macTxEnqueueTrace (p); + + TxQueueElement *txQElement = new TxQueueElement; + txQElement->txQMsduHandle = params.m_msduHandle; + txQElement->txQPkt = p; + m_txQueue.push_back (txQElement); + + CheckQueue (); +} + +void +LrWpanMac::CheckQueue () +{ + NS_LOG_FUNCTION (this); + + // Pull a packet from the queue and start sending, if we are not already sending. + if (m_lrWpanMacState == MAC_IDLE && !m_txQueue.empty () && m_txPkt == 0 && !m_setMacState.IsRunning ()) + { + TxQueueElement *txQElement = m_txQueue.front (); + m_txPkt = txQElement->txQPkt; + m_setMacState = Simulator::ScheduleNow (&LrWpanMac::SetLrWpanMacState, this, MAC_CSMA); + } +} + +void +LrWpanMac::SetCsmaCa (Ptr csmaCa) +{ + m_csmaCa = csmaCa; +} + +void +LrWpanMac::SetPhy (Ptr phy) +{ + m_phy = phy; +} + +Ptr +LrWpanMac::GetPhy (void) +{ + return m_phy; +} + +void +LrWpanMac::SetMcpsDataIndicationCallback (McpsDataIndicationCallback c) +{ + m_mcpsDataIndicationCallback = c; +} + +void +LrWpanMac::SetMcpsDataConfirmCallback (McpsDataConfirmCallback c) +{ + m_mcpsDataConfirmCallback = c; +} + +void +LrWpanMac::PdDataIndication (uint32_t psduLength, Ptr p, uint8_t lqi) +{ + NS_ASSERT (m_lrWpanMacState == MAC_IDLE || m_lrWpanMacState == MAC_ACK_PENDING || m_lrWpanMacState == MAC_CSMA); + + NS_LOG_FUNCTION (this << psduLength << p << lqi); + + bool acceptFrame; + + // from sec 7.5.6.2 Reception and rejection, Std802.15.4-2006 + // level 1 filtering, test FCS field and reject if frame fails + // level 2 filtering if promiscuous mode pass frame to higher layer otherwise perform level 3 filtering + // level 3 filtering accept frame + // if Frame type and version is not reserved, and + // if there is a dstPanId then dstPanId=m_macPanId or broadcastPanI, and + // if there is a shortDstAddr then shortDstAddr =shortMacAddr or broadcastAddr, and + // if beacon frame then srcPanId = m_macPanId + // if only srcAddr field in Data or Command frame,accept frame if srcPanId=m_macPanId + + Ptr originalPkt = p->Copy (); // because we will strip headers + + m_promiscSnifferTrace (originalPkt); + + m_macPromiscRxTrace (originalPkt); + // XXX no rejection tracing (to macRxDropTrace) being performed below + + LrWpanMacTrailer receivedMacTrailer; + p->RemoveTrailer (receivedMacTrailer); + if (Node::ChecksumEnabled ()) + { + receivedMacTrailer.EnableFcs (true); + } + + // level 1 filtering + if (!receivedMacTrailer.CheckFcs (p)) + { + m_macRxDropTrace (originalPkt); + } + else + { + LrWpanMacHeader receivedMacHdr; + p->RemoveHeader (receivedMacHdr); + + McpsDataIndicationParams params; + params.m_dsn = receivedMacHdr.GetSeqNum (); + params.m_mpduLinkQuality = lqi; + params.m_srcPanId = receivedMacHdr.GetSrcPanId (); + params.m_srcAddrMode = receivedMacHdr.GetSrcAddrMode (); + // TODO: Add field for EXT_ADDR source address. + if (params.m_srcAddrMode == SHORT_ADDR) + { + params.m_srcAddr = receivedMacHdr.GetShortSrcAddr (); + } + params.m_dstPanId = receivedMacHdr.GetDstPanId (); + params.m_dstAddrMode = receivedMacHdr.GetDstAddrMode (); + // TODO: Add field for EXT_ADDR destination address. + if (params.m_dstAddrMode == SHORT_ADDR) + { + params.m_dstAddr = receivedMacHdr.GetShortDstAddr (); + } + + NS_LOG_DEBUG ("Packet from " << params.m_srcAddr << " to " << params.m_dstAddr); + + if (m_macPromiscuousMode) + { + //level 2 filtering + if (!m_mcpsDataIndicationCallback.IsNull ()) + { + NS_LOG_DEBUG ("promiscuous mode, forwarding up"); + m_mcpsDataIndicationCallback (params, p); + } + else + { + NS_LOG_ERROR (this << " Data Indication Callback not initialised"); + } + } + else + { + //level 3 frame filtering + acceptFrame = (receivedMacHdr.GetType () != LrWpanMacHeader::LRWPAN_MAC_RESERVED); + + if (acceptFrame) + { + acceptFrame = (receivedMacHdr.GetFrameVer () <= 1); + } + + if (acceptFrame + && (receivedMacHdr.GetDstAddrMode () > 1)) + { + acceptFrame = receivedMacHdr.GetDstPanId () == m_macPanId + || receivedMacHdr.GetDstPanId () == 0xffff; + } + + if (acceptFrame + && (receivedMacHdr.GetDstAddrMode () == 2)) + { + acceptFrame = receivedMacHdr.GetShortDstAddr () == m_shortAddress + || receivedMacHdr.GetShortDstAddr () == Mac16Address ("ff:ff"); // check for broadcast addrs + } + + if (acceptFrame + && (receivedMacHdr.GetDstAddrMode () == 3)) + { + acceptFrame = (receivedMacHdr.GetExtDstAddr () == m_selfExt); + } + + if (acceptFrame + && (receivedMacHdr.GetType () == LrWpanMacHeader::LRWPAN_MAC_BEACON)) + { + if (m_macPanId == 0xffff) + { + // TODO: Accept only if the frame version field is valid + acceptFrame = true; + } + else + { + acceptFrame = receivedMacHdr.GetSrcPanId () == m_macPanId; + } + } + + if (acceptFrame + && ((receivedMacHdr.GetType () == LrWpanMacHeader::LRWPAN_MAC_DATA) + || (receivedMacHdr.GetType () == LrWpanMacHeader::LRWPAN_MAC_COMMAND)) + && (receivedMacHdr.GetSrcAddrMode () > 1)) + { + acceptFrame = receivedMacHdr.GetSrcPanId () == m_macPanId; // \todo need to check if PAN coord + } + + if (acceptFrame) + { + m_macRxTrace (originalPkt); + // \todo: What should we do if we receive a frame while waiting for an ACK? + // Especially if this frame has the ACK request bit set, should we reply with an ACK, possibly missing the pending ACK? + + // If the received frame is a frame with the ACK request bit set, we immediately send back an ACK. + // If we are currently waiting for a pending ACK, we assume the ACK was lost and trigger a retransmission after sending the ACK. + if ((receivedMacHdr.IsData () || receivedMacHdr.IsCommand ()) && receivedMacHdr.IsAckReq () + && !(receivedMacHdr.GetDstAddrMode () == SHORT_ADDR && receivedMacHdr.GetShortDstAddr () == "ff:ff")) + { + // If this is a data or mac command frame, which is not a broadcast, + // with ack req set, generate and send an ack frame. + // If there is a CSMA medium access in progress we cancel the medium access + // for sending the ACK frame. A new transmission attempt will be started + // after the ACK was send. + if (m_lrWpanMacState == MAC_ACK_PENDING) + { + m_ackWaitTimeout.Cancel (); + PrepareRetransmission (); + } + else if (m_lrWpanMacState == MAC_CSMA) + { + // \todo: If we receive a packet while doing CSMA/CA, should we drop the packet because of channel busy, + // or should we restart CSMA/CA for the packet after sending the ACK? + // Currently we simply restart CSMA/CA after sending the ACK. + m_csmaCa->Cancel (); + } + // Cancel any pending MAC state change, ACKs have higher priority. + m_setMacState.Cancel (); + ChangeMacState (MAC_IDLE); + m_setMacState = Simulator::ScheduleNow (&LrWpanMac::SendAck, this, receivedMacHdr.GetSeqNum ()); + } + + if (receivedMacHdr.IsData () && !m_mcpsDataIndicationCallback.IsNull ()) + { + // If it is a data frame, push it up the stack. + NS_LOG_DEBUG ("PdDataIndication(): Packet is for me; forwarding up"); + m_mcpsDataIndicationCallback (params, p); + } + else if (receivedMacHdr.IsAcknowledgment () && m_txPkt && m_lrWpanMacState == MAC_ACK_PENDING) + { + LrWpanMacHeader macHdr; + m_txPkt->PeekHeader (macHdr); + if (receivedMacHdr.GetSeqNum () == macHdr.GetSeqNum ()) + { + m_macTxOkTrace (m_txPkt); + // If it is an ACK with the expected sequence number, finish the transmission + // and notify the upper layer. + m_ackWaitTimeout.Cancel (); + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + TxQueueElement *txQElement = m_txQueue.front (); + McpsDataConfirmParams confirmParams; + confirmParams.m_msduHandle = txQElement->txQMsduHandle; + confirmParams.m_status = IEEE_802_15_4_SUCCESS; + m_mcpsDataConfirmCallback (confirmParams); + } + RemoveFirstTxQElement (); + m_setMacState.Cancel (); + m_setMacState = Simulator::ScheduleNow (&LrWpanMac::SetLrWpanMacState, this, MAC_IDLE); + } + else + { + // If it is an ACK with an unexpected sequence number, mark the current transmission as failed and start a retransmit. (cf 7.5.6.4.3) + m_ackWaitTimeout.Cancel (); + if (!PrepareRetransmission ()) + { + m_setMacState.Cancel (); + m_setMacState = Simulator::ScheduleNow (&LrWpanMac::SetLrWpanMacState, this, MAC_IDLE); + } + else + { + m_setMacState.Cancel (); + m_setMacState = Simulator::ScheduleNow (&LrWpanMac::SetLrWpanMacState, this, MAC_CSMA); + } + } + } + } + else + { + m_macRxDropTrace (originalPkt); + } + } + } +} + +void +LrWpanMac::SendAck (uint8_t seqno) +{ + NS_LOG_FUNCTION (this << static_cast (seqno)); + + NS_ASSERT (m_lrWpanMacState == MAC_IDLE); + + // Generate a corresponding ACK Frame. + LrWpanMacHeader macHdr (LrWpanMacHeader::LRWPAN_MAC_ACKNOWLEDGMENT, seqno); + LrWpanMacTrailer macTrailer; + Ptr ackPacket = Create (0); + ackPacket->AddHeader (macHdr); + // Calculate FCS if the global attribute ChecksumEnable is set. + if (Node::ChecksumEnabled ()) + { + macTrailer.EnableFcs (true); + macTrailer.SetFcs (ackPacket); + } + ackPacket->AddTrailer (macTrailer); + + // Enqueue the ACK packet for further processing + // when the transmitter is activated. + m_txPkt = ackPacket; + + // Switch transceiver to TX mode. Proceed sending the Ack on confirm. + ChangeMacState (MAC_SENDING); + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_TX_ON); +} + +void +LrWpanMac::RemoveFirstTxQElement () +{ + TxQueueElement *txQElement = m_txQueue.front (); + Ptr p = txQElement->txQPkt; + m_numCsmacaRetry += m_csmaCa->GetNB () + 1; + + Ptr pkt = p->Copy (); + LrWpanMacHeader hdr; + pkt->RemoveHeader (hdr); + if (hdr.GetShortDstAddr () != Mac16Address ("ff:ff")) + { + m_sentPktTrace (p, m_retransmission + 1, m_numCsmacaRetry); + } + + txQElement->txQPkt = 0; + delete txQElement; + m_txQueue.pop_front (); + m_txPkt = 0; + m_retransmission = 0; + m_numCsmacaRetry = 0; + m_macTxDequeueTrace (p); +} + +void +LrWpanMac::AckWaitTimeout (void) +{ + NS_LOG_FUNCTION (this); + + // TODO: If we are a PAN coordinator and this was an indirect transmission, + // we will not initiate a retransmission. Instead we wait for the data + // being extracted after a new data request command. + if (!PrepareRetransmission ()) + { + SetLrWpanMacState (MAC_IDLE); + } + else + { + SetLrWpanMacState (MAC_CSMA); + } +} + +bool +LrWpanMac::PrepareRetransmission (void) +{ + NS_LOG_FUNCTION (this); + + if (m_retransmission >= m_macMaxFrameRetries) + { + // Maximum number of retransmissions has been reached. + // remove the copy of the packet that was just sent + TxQueueElement *txQElement = m_txQueue.front (); + m_macTxDropTrace (txQElement->txQPkt); + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + McpsDataConfirmParams confirmParams; + confirmParams.m_msduHandle = txQElement->txQMsduHandle; + confirmParams.m_status = IEEE_802_15_4_NO_ACK; + m_mcpsDataConfirmCallback (confirmParams); + } + RemoveFirstTxQElement (); + return false; + } + else + { + m_retransmission++; + m_numCsmacaRetry += m_csmaCa->GetNB () + 1; + // Start next CCA process for this packet. + return true; + } +} + +void +LrWpanMac::PdDataConfirm (LrWpanPhyEnumeration status) +{ + NS_ASSERT (m_lrWpanMacState == MAC_SENDING); + + NS_LOG_FUNCTION (this << status << m_txQueue.size ()); + + LrWpanMacHeader macHdr; + m_txPkt->PeekHeader (macHdr); + if (status == IEEE_802_15_4_PHY_SUCCESS) + { + if (!macHdr.IsAcknowledgment ()) + { + // We have just send a regular data packet, check if we have to wait + // for an ACK. + if (macHdr.IsAckReq ()) + { + // wait for the ack or the next retransmission timeout + // start retransmission timer + Time waitTime = MicroSeconds (GetMacAckWaitDuration () * 1000 * 1000 / m_phy->GetDataOrSymbolRate (false)); + NS_ASSERT (m_ackWaitTimeout.IsExpired ()); + m_ackWaitTimeout = Simulator::Schedule (waitTime, &LrWpanMac::AckWaitTimeout, this); + m_setMacState.Cancel (); + m_setMacState = Simulator::ScheduleNow (&LrWpanMac::SetLrWpanMacState, this, MAC_ACK_PENDING); + return; + } + else + { + m_macTxOkTrace (m_txPkt); + // remove the copy of the packet that was just sent + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + McpsDataConfirmParams confirmParams; + NS_ASSERT_MSG (m_txQueue.size () > 0, "TxQsize = 0"); + TxQueueElement *txQElement = m_txQueue.front (); + confirmParams.m_msduHandle = txQElement->txQMsduHandle; + confirmParams.m_status = IEEE_802_15_4_SUCCESS; + m_mcpsDataConfirmCallback (confirmParams); + } + RemoveFirstTxQElement (); + } + } + else + { + // We have send an ACK. Clear the packet buffer. + m_txPkt = 0; + } + } + else if (status == IEEE_802_15_4_PHY_UNSPECIFIED) + { + + if (!macHdr.IsAcknowledgment ()) + { + NS_ASSERT_MSG (m_txQueue.size () > 0, "TxQsize = 0"); + TxQueueElement *txQElement = m_txQueue.front (); + m_macTxDropTrace (txQElement->txQPkt); + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + McpsDataConfirmParams confirmParams; + confirmParams.m_msduHandle = txQElement->txQMsduHandle; + confirmParams.m_status = IEEE_802_15_4_FRAME_TOO_LONG; + m_mcpsDataConfirmCallback (confirmParams); + } + RemoveFirstTxQElement (); + } + else + { + NS_LOG_ERROR ("Unable to send ACK"); + } + } + else + { + // Something went really wrong. The PHY is not in the correct state for + // data transmission. + NS_FATAL_ERROR ("Transmission attempt failed with PHY status " << status); + } + + m_setMacState.Cancel (); + m_setMacState = Simulator::ScheduleNow (&LrWpanMac::SetLrWpanMacState, this, MAC_IDLE); +} + +void +LrWpanMac::PlmeCcaConfirm (LrWpanPhyEnumeration status) +{ + NS_LOG_FUNCTION (this << status); + // Direct this call through the csmaCa object + m_csmaCa->PlmeCcaConfirm (status); +} + +void +LrWpanMac::PlmeEdConfirm (LrWpanPhyEnumeration status, uint8_t energyLevel) +{ + NS_LOG_FUNCTION (this << status << energyLevel); + +} + +void +LrWpanMac::PlmeGetAttributeConfirm (LrWpanPhyEnumeration status, + LrWpanPibAttributeIdentifier id, + LrWpanPhyPibAttributes* attribute) +{ + NS_LOG_FUNCTION (this << status << id << attribute); +} + +void +LrWpanMac::PlmeSetTRXStateConfirm (LrWpanPhyEnumeration status) +{ + NS_LOG_FUNCTION (this << status); + + if (m_lrWpanMacState == MAC_SENDING && (status == IEEE_802_15_4_PHY_TX_ON || status == IEEE_802_15_4_PHY_SUCCESS)) + { + NS_ASSERT (m_txPkt); + + // Start sending if we are in state SENDING and the PHY transmitter was enabled. + m_promiscSnifferTrace (m_txPkt); + m_snifferTrace (m_txPkt); + m_macTxTrace (m_txPkt); + m_phy->PdDataRequest (m_txPkt->GetSize (), m_txPkt); + } + else if (m_lrWpanMacState == MAC_CSMA && (status == IEEE_802_15_4_PHY_RX_ON || status == IEEE_802_15_4_PHY_SUCCESS)) + { + // Start the CSMA algorithm as soon as the receiver is enabled. + m_csmaCa->Start (); + } + else if (m_lrWpanMacState == MAC_IDLE) + { + NS_ASSERT (status == IEEE_802_15_4_PHY_RX_ON || status == IEEE_802_15_4_PHY_SUCCESS || status == IEEE_802_15_4_PHY_TRX_OFF); + // Do nothing special when going idle. + } + else if (m_lrWpanMacState == MAC_ACK_PENDING) + { + NS_ASSERT (status == IEEE_802_15_4_PHY_RX_ON || status == IEEE_802_15_4_PHY_SUCCESS); + } + else + { + // TODO: What to do when we receive an error? + // If we want to transmit a packet, but switching the transceiver on results + // in an error, we have to recover somehow (and start sending again). + NS_FATAL_ERROR ("Error changing transceiver state"); + } +} + +void +LrWpanMac::PlmeSetAttributeConfirm (LrWpanPhyEnumeration status, + LrWpanPibAttributeIdentifier id) +{ + NS_LOG_FUNCTION (this << status << id); +} + +void +LrWpanMac::SetLrWpanMacState (LrWpanMacState macState) +{ + NS_LOG_FUNCTION (this << "mac state = " << macState); + + McpsDataConfirmParams confirmParams; + + if (macState == MAC_IDLE) + { + ChangeMacState (MAC_IDLE); + + if (m_macRxOnWhenIdle) + { + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_RX_ON); + } + else + { + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_TRX_OFF); + } + + CheckQueue (); + } + else if (macState == MAC_ACK_PENDING) + { + ChangeMacState (MAC_ACK_PENDING); + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_RX_ON); + } + else if (macState == MAC_CSMA) + { + NS_ASSERT (m_lrWpanMacState == MAC_IDLE || m_lrWpanMacState == MAC_ACK_PENDING); + + ChangeMacState (MAC_CSMA); + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_RX_ON); + } + else if (m_lrWpanMacState == MAC_CSMA && macState == CHANNEL_IDLE) + { + // Channel is idle, set transmitter to TX_ON + ChangeMacState (MAC_SENDING); + m_phy->PlmeSetTRXStateRequest (IEEE_802_15_4_PHY_TX_ON); + } + else if (m_lrWpanMacState == MAC_CSMA && macState == CHANNEL_ACCESS_FAILURE) + { + NS_ASSERT (m_txPkt); + + // cannot find a clear channel, drop the current packet. + NS_LOG_DEBUG ( this << " cannot find clear channel"); + confirmParams.m_msduHandle = m_txQueue.front ()->txQMsduHandle; + confirmParams.m_status = IEEE_802_15_4_CHANNEL_ACCESS_FAILURE; + m_macTxDropTrace (m_txPkt); + if (!m_mcpsDataConfirmCallback.IsNull ()) + { + m_mcpsDataConfirmCallback (confirmParams); + } + // remove the copy of the packet that was just sent + RemoveFirstTxQElement (); + + ChangeMacState (MAC_IDLE); + } +} + +LrWpanAssociationStatus +LrWpanMac::GetAssociationStatus (void) const +{ + return m_associationStatus; +} + +void +LrWpanMac::SetAssociationStatus (LrWpanAssociationStatus status) +{ + m_associationStatus = status; +} + +uint16_t +LrWpanMac::GetPanId (void) const +{ + return m_macPanId; +} + +void +LrWpanMac::SetPanId (uint16_t panId) +{ + m_macPanId = panId; +} + +void +LrWpanMac::ChangeMacState (LrWpanMacState newState) +{ + NS_LOG_LOGIC (this << " change lrwpan mac state from " + << m_lrWpanMacState << " to " + << newState); + m_macStateLogger (m_lrWpanMacState, newState); + m_lrWpanMacState = newState; +} + +uint64_t +LrWpanMac::GetMacAckWaitDuration (void) const +{ + return m_csmaCa->GetUnitBackoffPeriod () + m_phy->aTurnaroundTime + m_phy->GetPhySHRDuration () + + ceil (6 * m_phy->GetPhySymbolsPerOctet ()); +} + +uint8_t +LrWpanMac::GetMacMaxFrameRetries (void) const +{ + return m_macMaxFrameRetries; +} + +void +LrWpanMac::SetMacMaxFrameRetries (uint8_t retries) +{ + m_macMaxFrameRetries = retries; +} + +} // namespace ns3 diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-mac.h ns-3.20/src/lr-wpan/model/lr-wpan-mac.h --- ns-3.19/src/lr-wpan/model/lr-wpan-mac.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-mac.h 2014-06-17 10:33:13.904995877 -0700 @@ -0,0 +1,743 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * Gary Pei + * kwong yin + * Tom Henderson + * Sascha Alexander Jopen + */ +#ifndef LR_WPAN_MAC_H +#define LR_WPAN_MAC_H + +#include +#include +#include +#include +#include +#include +#include +#include + + +namespace ns3 { + +class Packet; +class LrWpanCsmaCa; + +/** + * \defgroup lr-wpan LR-WPAN models + * + * This section documents the API of the IEEE 802.15.4-related models. For a generic functional description, please refer to the ns-3 manual. + */ +typedef enum +{ + TX_OPTION_NONE = 0, + TX_OPTION_ACK = 1, + TX_OPTION_GTS = 2, + TX_OPTION_INDIRECT = 4 +} LrWpanTxOption; + +typedef enum +{ + MAC_IDLE, + MAC_CSMA, + MAC_SENDING, + MAC_ACK_PENDING, + CHANNEL_ACCESS_FAILURE, + CHANNEL_IDLE, + SET_PHY_TX_ON +} LrWpanMacState; + +/** + * table 80 of 802.15.4 + */ +typedef enum +{ + NO_PANID_ADDR = 0, + ADDR_MODE_RESERVED = 1, + SHORT_ADDR = 2, + EXT_ADDR = 3 +} LrWpanAddressMode; + +/** + * table 83 of 802.15.4 + */ +typedef enum +{ + ASSOCIATED = 0, + PAN_AT_CAPACITY = 1, + PAN_ACCESS_DENIED = 2, + ASSOCIATED_WITHOUT_ADDRESS = 0xfe, + DISASSOCIATED = 0xff +} LrWpanAssociationStatus; + +/* + * Table 42 of 802.15.4-2006 + */ +typedef enum +{ + IEEE_802_15_4_SUCCESS = 0, + IEEE_802_15_4_TRANSACTION_OVERFLOW = 1, + IEEE_802_15_4_TRANSACTION_EXPIRED = 2, + IEEE_802_15_4_CHANNEL_ACCESS_FAILURE = 3, + IEEE_802_15_4_INVALID_ADDRESS = 4, + IEEE_802_15_4_INVALID_GTS = 5, + IEEE_802_15_4_NO_ACK = 6, + IEEE_802_15_4_COUNTER_ERROR = 7, + IEEE_802_15_4_FRAME_TOO_LONG = 8, + IEEE_802_15_4_UNAVAILABLE_KEY = 9, + IEEE_802_15_4_UNSUPPORTED_SECURITY = 10, + IEEE_802_15_4_INVALID_PARAMETER = 11 +} LrWpanMcpsDataConfirmStatus; + +struct McpsDataRequestParams +{ + McpsDataRequestParams () + : m_srcAddrMode (SHORT_ADDR), + m_dstAddrMode (SHORT_ADDR), + m_dstPanId (0), + m_dstAddr (), + m_msduHandle (0), + m_txOptions (0) + { + } + LrWpanAddressMode m_srcAddrMode; + LrWpanAddressMode m_dstAddrMode; + uint16_t m_dstPanId; + Mac16Address m_dstAddr; + uint8_t m_msduHandle; + uint8_t m_txOptions; // bitmap +}; + +struct McpsDataConfirmParams +{ + uint8_t m_msduHandle; + LrWpanMcpsDataConfirmStatus m_status; +}; + +struct McpsDataIndicationParams +{ + uint8_t m_srcAddrMode; + uint16_t m_srcPanId; + Mac16Address m_srcAddr; + uint8_t m_dstAddrMode; + uint16_t m_dstPanId; + Mac16Address m_dstAddr; + uint8_t m_mpduLinkQuality; + uint8_t m_dsn; +}; + +// This callback is called after a McpsDataRequest has been called from +// the higher layer. It returns a status of the outcome of the +// transmission request +typedef Callback McpsDataConfirmCallback; + +// This callback is called after a Mcps has successfully received a +// frame and wants to deliver it to the higher layer. +// +// XXX for now, we do not deliver all of the parameters in section +// 7.1.1.3.1 but just send up the packet. +typedef Callback > McpsDataIndicationCallback; + + +/** + * \ingroup lr-wpan + * + * Class that implements the LR-WPAN Mac state machine + */ +class LrWpanMac : public Object +{ +public: + /** + * Get the type ID. + * + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + /** + * The minimum number of octets added by the MAC sublayer to the PSDU. + * See IEEE 802.15.4-2006, section 7.4.1, Table 85 + */ + static const uint32_t aMinMPDUOverhead; + + /** + * Default constructor. + */ + LrWpanMac (void); + virtual ~LrWpanMac (void); + + /** + * Check if the receiver will be enabled when the MAC is idle. + * + * \return true, if the receiver is enabled during idle periods, false otherwise + */ + bool GetRxOnWhenIdle (void); + + /** + * Set if the receiver should be enabled when the MAC is idle. + * + * \param rxOnWhenIdle set to true to enable the receiver during idle periods + */ + void SetRxOnWhenIdle (bool rxOnWhenIdle); + + // XXX these setters will become obsolete if we use the attribute system + /** + * Set the short address of this MAC. + * + * \param address the new address + */ + void SetShortAddress (Mac16Address address); + + /** + * Get the short address of this MAC. + * + * \return the short address + */ + Mac16Address GetShortAddress (void) const; + + /** + * Set the extended address of this MAC. + * + * \param address the new address + */ + void SetExtendedAddress (Mac64Address address); + + /** + * Get the extended address of this MAC. + * + * \return the extended address + */ + Mac64Address GetExtendedAddress (void) const; + + /** + * Set the PAN id used by this MAC. + * + * \param panId the new PAN id. + */ + void SetPanId (uint16_t panId); + + /** + * Get the PAN id used by this MAC. + * + * \return the PAN id. + */ + uint16_t GetPanId (void) const; + + /** + * IEEE 802.15.4-2006, section 7.1.1.1 + * MCPS-DATA.request + * Request to transfer a MSDU. + * + * \param params the request parameters + * \param p the packet to be transmitted + */ + void McpsDataRequest (McpsDataRequestParams params, Ptr p); + + /** + * Set the CSMA/CA implementation to be used by the MAC. + * + * \param csmaCa the CSMA/CA implementation + */ + void SetCsmaCa (Ptr csmaCa); + + /** + * Set the underlying PHY for the MAC. + * + * \param phy the PHY + */ + void SetPhy (Ptr phy); + + /** + * Get the underlying PHY of the MAC. + * + * \return the PHY + */ + Ptr GetPhy (void); + + /** + * Set the callback for the indication of an incoming data packet. + * The callback implements MCPS-DATA.indication SAP of IEEE 802.15.4-2006, + * section 7.1.1.3. + * + * \param c the callback + */ + void SetMcpsDataIndicationCallback (McpsDataIndicationCallback c); + + /** + * Set the callback for the confirmation of a data transmission request. + * The callback implements MCPS-DATA.confirm SAP of IEEE 802.15.4-2006, + * section 7.1.1.2. + * + * \param c the callback + */ + void SetMcpsDataConfirmCallback (McpsDataConfirmCallback c); + + // interfaces between MAC and PHY + /** + * IEEE 802.15.4-2006 section 6.2.1.3 + * PD-DATA.indication + * Indicates the transfer of an MPDU from PHY to MAC (receiving) + * @param psduLength number of bytes in the PSDU + * @param p the packet to be transmitted + * @param lqi Link quality (LQI) value measured during reception of the PPDU + */ + void PdDataIndication (uint32_t psduLength, Ptr p, uint8_t lqi); + + /** + * IEEE 802.15.4-2006 section 6.2.1.2 + * Confirm the end of transmission of an MPDU to MAC + * @param status to report to MAC + * PHY PD-DATA.confirm status + */ + void PdDataConfirm (LrWpanPhyEnumeration status); + + /** + * IEEE 802.15.4-2006 section 6.2.2.2 + * PLME-CCA.confirm status + * @param status TRX_OFF, BUSY or IDLE + */ + void PlmeCcaConfirm (LrWpanPhyEnumeration status); + + /** + * IEEE 802.15.4-2006 section 6.2.2.4 + * PLME-ED.confirm status and energy level + * @param status SUCCESS, TRX_OFF or TX_ON + * @param energyLevel 0x00-0xff ED level for the channel + */ + void PlmeEdConfirm (LrWpanPhyEnumeration status, uint8_t energyLevel); + + /** + * IEEE 802.15.4-2006 section 6.2.2.6 + * PLME-GET.confirm + * Get attributes per definition from Table 23 in section 6.4.2 + * @param status SUCCESS or UNSUPPORTED_ATTRIBUTE + * @param id the attributed identifier + * @param attribute the attribute value + */ + void PlmeGetAttributeConfirm (LrWpanPhyEnumeration status, + LrWpanPibAttributeIdentifier id, + LrWpanPhyPibAttributes* attribute); + + /** + * IEEE 802.15.4-2006 section 6.2.2.8 + * PLME-SET-TRX-STATE.confirm + * Set PHY state + * @param status in RX_ON,TRX_OFF,FORCE_TRX_OFF,TX_ON + */ + void PlmeSetTRXStateConfirm (LrWpanPhyEnumeration status); + + /** + * IEEE 802.15.4-2006 section 6.2.2.10 + * PLME-SET.confirm + * Set attributes per definition from Table 23 in section 6.4.2 + * @param status SUCCESS, UNSUPPORTED_ATTRIBUTE, INVALID_PARAMETER, or READ_ONLY + * @param id the attributed identifier + */ + void PlmeSetAttributeConfirm (LrWpanPhyEnumeration status, + LrWpanPibAttributeIdentifier id); + + /** + * CSMA-CA algorithm calls back the MAC after executing channel assessment. + * + * \param macState indicate BUSY oder IDLE channel condition + */ + void SetLrWpanMacState (LrWpanMacState macState); + + /** + * Get the current association status. + * + * \return current association status + */ + LrWpanAssociationStatus GetAssociationStatus (void) const; + + /** + * Set the current association status. + * + * \param status new association status + */ + void SetAssociationStatus (LrWpanAssociationStatus status); + + //MAC sublayer constants + /** + * Length of a superframe slot in symbols. Defaults to 60 symbols in each + * superframe slot. + * See IEEE 802.15.4-2006, section 7.4.1, Table 85. + */ + uint64_t m_aBaseSlotDuration; + + /** + * Number of a superframe slots per superframe. Defaults to 16. + * See IEEE 802.15.4-2006, section 7.4.1, Table 85. + */ + uint64_t m_aNumSuperframeSlots; + + /** + * Length of a superframe in symbols. Defaults to + * aBaseSlotDuration * aNumSuperframeSlots in symbols. + * See IEEE 802.15.4-2006, section 7.4.1, Table 85. + */ + uint64_t m_aBaseSuperframeDuration; + + //MAC PIB attributes + /** + * The time that the device transmitted its last beacon frame, in symbol + * periods. Only 24 bits used. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + uint64_t m_macBeaconTxTime; + + /** + * Symbol boundary is same as m_macBeaconTxTime. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + uint64_t m_macSyncSymbolOffset; + + /** + * Specification of how often the coordinator transmits its beacon. + * 0 - 15 with 15 means no beacons are being sent. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + uint64_t m_macBeaconOrder; + + /** + * The length of the active portion of the outgoing superframe, including the + * beacon frame. + * 0 - 15 with 15 means the superframe will not be active after the beacon. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + uint64_t m_macSuperframeOrder; + + /** + * Indicates if MAC sublayer is in receive all mode. True mean accept all + * frames from PHY. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + bool m_macPromiscuousMode; + + /** + * 16 bits id of PAN on which this device is operating. 0xffff means not + * asscoiated. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + uint16_t m_macPanId; + + /** + * Sequence number added to transmitted data or MAC command frame, 00-ff. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + SequenceNumber8 m_macDsn; + + /** + * The maximum number of retries allowed after a transmission failure. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + uint8_t m_macMaxFrameRetries; + + /** + * Indication of whether the MAC sublayer is to enable its receiver during + * idle periods. + * See IEEE 802.15.4-2006, section 7.4.2, Table 86. + */ + bool m_macRxOnWhenIdle; + + /** + * Get the macAckWaitDuration attribute value. + * + * \return the maximum number symbols to wait for an acknowledgment frame + */ + uint64_t GetMacAckWaitDuration (void) const; + + /** + * Get the macMaxFrameRetries attribute value. + * + * \return the maximum number of retries + */ + uint8_t GetMacMaxFrameRetries (void) const; + + /** + * Set the macMaxFrameRetries attribute value. + * + * \param retries the maximum number of retries + */ + void SetMacMaxFrameRetries (uint8_t retries); + +protected: + // Inherited from Object. + virtual void DoInitialize (void); + virtual void DoDispose (void); + +private: + /** + * Helper structure for managing transmission queue elements. + */ + struct TxQueueElement + { + uint8_t txQMsduHandle; + Ptr txQPkt; + }; + + /** + * Send an acknowledgment packet for the given sequence number. + * + * \param seqno the sequence number for the ACK + */ + void SendAck (uint8_t seqno); + + /** + * Remove the tip of the transmission queue, including clean up related to the + * last packet transmission. + */ + void RemoveFirstTxQElement (); + + /** + * Change the current MAC state to the given new state. + * + * \param newState the new state + */ + void ChangeMacState (LrWpanMacState newState); + + /** + * Handle an ACK timeout with a packet retransmission, if there are + * retransmission left, or a packet drop. + */ + void AckWaitTimeout (void); + + /** + * Check for remaining retransmissions for the packet currently being sent. + * Drop the packet, if there are no retransmissions left. + * + * \return true, if the packet should be retransmitted, false otherwise. + */ + bool PrepareRetransmission (void); + + /** + * Check the transmission queue. If there are packets in the transmission + * queue and the MAC is idle, pick the first one and initiate a packet + * transmission. + */ + void CheckQueue (void); + + /** + * The trace source fired when packets are considered as successfully sent + * or the transmission has been given up. + * Only non-broadcast packets are traced. + * + * The data should represent: + * packet, number of retries, total number of csma backoffs + * + * \see class CallBackTraceSource + */ + TracedCallback, uint8_t, uint8_t > m_sentPktTrace; + + /** + * The trace source fired when packets come into the "top" of the device + * at the L3/L2 transition, when being queued for transmission. + * + * \see class CallBackTraceSource + */ + TracedCallback > m_macTxEnqueueTrace; + + /** + * The trace source fired when packets are dequeued from the + * L3/l2 transmission queue. + * + * \see class CallBackTraceSource + */ + TracedCallback > m_macTxDequeueTrace; + + /** + * The trace source fired when packets are being sent down to L1. + * + * \see class CallBackTraceSource + */ + TracedCallback > m_macTxTrace; + + /** + * The trace source fired when packets where successfully transmitted, that is + * an acknowledgment was received, if requested, or the packet was + * successfully sent by L1, if no ACK was requested. + * + * \see class CallBackTraceSource + */ + TracedCallback > m_macTxOkTrace; + + /** + * The trace source fired when packets are dropped due to missing ACKs or + * because of transmission failures in L1. + * + * \see class CallBackTraceSource + */ + TracedCallback > 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 > 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 > m_macRxTrace; + + /** + * The trace source fired for packets successfully received by the device + * but dropped before being forwarded up to higher layers (at the L2/L3 + * transition). + * + * \see class CallBackTraceSource + */ + TracedCallback > m_macRxDropTrace; + + /** + * 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 > 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 > m_promiscSnifferTrace; + + /* + * A trace source that fires when the LrWpanMac changes states. + * Parameters are the old mac state and the new mac state. + */ + TracedCallback m_macStateLogger; + + /** + * The PHY associated with this MAC. + */ + Ptr m_phy; + + /** + * The CSMA/CA implementation used by this MAC. + */ + Ptr m_csmaCa; + + /** + * This callback is used to notify incoming packets to the upper layers. + * See IEEE 802.15.4-2006, section 7.1.1.3. + */ + McpsDataIndicationCallback m_mcpsDataIndicationCallback; + + /** + * This callback is used to report data transmission request status to the + * upper layers. + * See IEEE 802.15.4-2006, section 7.1.1.2. + */ + McpsDataConfirmCallback m_mcpsDataConfirmCallback; + + /** + * The current state of the MAC layer. + */ + LrWpanMacState m_lrWpanMacState; + + /** + * The current association status of the MAC layer. + */ + LrWpanAssociationStatus m_associationStatus; + + /** + * The packet which is currently being sent by the MAC layer. + */ + Ptr m_txPkt; // XXX need packet buffer instead of single packet + + /** + * The short address used by this MAC. Currently we do not have complete + * extended address support in the MAC, nor do we have the association + * primitives, so this address has to be configured manually. + */ + Mac16Address m_shortAddress; + + /** + * The extended address used by this MAC. Extended addresses are currently not + * really supported. + */ + Mac64Address m_selfExt; + + /** + * The transmit queue used by the MAC. + */ + std::deque m_txQueue; + + /** + * The number of already used retransmission for the currently transmitted + * packet. + */ + uint8_t m_retransmission; + + /** + * The number of CSMA/CA retries used for sending the current packet. + */ + uint8_t m_numCsmacaRetry; + + /** + * Scheduler event for the ACK timeout of the currently transmitted data + * packet. + */ + EventId m_ackWaitTimeout; + + /** + * Scheduler event for a deferred MAC state change. + */ + EventId m_setMacState; +}; + + +} // namespace ns3 + +#endif /* LR_WPAN_MAC_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-mac-header.cc ns-3.20/src/lr-wpan/model/lr-wpan-mac-header.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-mac-header.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-mac-header.cc 2014-06-17 10:33:13.901995900 -0700 @@ -0,0 +1,831 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: kwong yin + */ +#include "lr-wpan-mac-header.h" +#include + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanMacHeader); + +// TODO: Test Compressed PAN Id, Security Enabled, different size Key + +LrWpanMacHeader::LrWpanMacHeader () +{ + SetType (LRWPAN_MAC_DATA); // Assume Data frame + SetSecDisable (); // Assume there is No Aux Sec but + SetNoFrmPend (); // No Frame Pending + SetNoAckReq (); // No Ack Frame will be expected from recepient + SetNoPanIdComp (); // No PAN Id Compression since no addresses + SetFrmCtrlRes (0); // Initialize the 3 reserved bits to 0 + SetDstAddrMode (NOADDR); // Assume there will be no src and dst address + SetSrcAddrMode (NOADDR); + SetFrameVer (1); //Indicates an IEEE 802.15.4 frame +} + + +LrWpanMacHeader::LrWpanMacHeader (enum LrWpanMacType wpanMacType, + uint8_t seqNum) +{ + SetType (wpanMacType); + SetSeqNum (seqNum); + SetSecDisable (); // Assume there is No Aux Sec but + SetNoFrmPend (); // No Frame Pending + SetNoAckReq (); // No Ack Frame will be expected from recepient + SetNoPanIdComp (); // No PAN Id Compression since no addresses + SetFrmCtrlRes (0); // Initialize the 3 reserved bits to 0 + SetDstAddrMode (NOADDR); // Assume there will be no src and dst address + SetSrcAddrMode (NOADDR); + SetFrameVer (1); //Indicates an IEEE 802.15.4 frame +} + + +LrWpanMacHeader::~LrWpanMacHeader () +{ +} + + +enum LrWpanMacHeader::LrWpanMacType +LrWpanMacHeader::GetType (void) const +{ + switch (m_fctrlFrmType) + { + case 0: + return LRWPAN_MAC_BEACON; + break; + case 1: + return LRWPAN_MAC_DATA; + break; + case 2: + return LRWPAN_MAC_ACKNOWLEDGMENT; + break; + case 3: + return LRWPAN_MAC_COMMAND; + break; + default: + return LRWPAN_MAC_RESERVED; + } +} + + + +uint16_t +LrWpanMacHeader::GetFrameControl (void) const +{ + uint16_t val = 0; + + val = m_fctrlFrmType & (0x07); // Bit 0-2 + val |= (m_fctrlSecU << 3) & (0x01 << 3); // Bit 3 + val |= (m_fctrlFrmPending << 4) & (0x01 << 4); // Bit 4 + val |= (m_fctrlAckReq << 5) & (0x01 << 5); // Bit 5 + val |= (m_fctrlPanIdComp << 6) & (0x01 << 6); // Bit 6 + val |= (m_fctrlReserved << 7) & (0x07 << 7); // Bit 7-9 + val |= (m_fctrlDstAddrMode << 10) & (0x03 << 10); // Bit 10-11 + val |= (m_fctrlFrmVer << 12) & (0x03 << 12); // Bit 12-13 + val |= (m_fctrlSrcAddrMode << 14) & (0x03 << 14); // Bit 14-15 + return val; + +} + +bool +LrWpanMacHeader::IsSecEnable (void) const +{ + return (m_fctrlSecU == 1); +} + +bool +LrWpanMacHeader::IsSecDisable (void) const +{ + return (m_fctrlSecU == 0); +} + +bool +LrWpanMacHeader::IsFrmPend (void) const +{ + return (m_fctrlFrmPending == 1); +} + +bool +LrWpanMacHeader::IsNoFrmPend (void) const +{ + return (m_fctrlFrmPending == 0); +} + +bool +LrWpanMacHeader::IsAckReq (void) const +{ + return (m_fctrlAckReq == 1); +} + +bool +LrWpanMacHeader::IsNoAckReq (void) const +{ + return (m_fctrlAckReq == 0); +} + +bool +LrWpanMacHeader::IsPanIdComp (void) const +{ + return (m_fctrlPanIdComp == 1); +} + +bool +LrWpanMacHeader::IsNoPanIdComp (void) const +{ + return (m_fctrlPanIdComp == 0); +} + +uint8_t +LrWpanMacHeader::GetFrmCtrlRes (void) const +{ + return (m_fctrlReserved); +} + +uint8_t +LrWpanMacHeader::GetDstAddrMode (void) const +{ + return m_fctrlDstAddrMode; +} + +uint8_t +LrWpanMacHeader::GetFrameVer (void) const +{ + return m_fctrlFrmVer; +} + +uint8_t +LrWpanMacHeader::GetSrcAddrMode (void) const +{ + return m_fctrlSrcAddrMode; +} + + +uint8_t +LrWpanMacHeader::GetSeqNum (void) const +{ + return(m_SeqNum); +} + + +uint16_t +LrWpanMacHeader::GetDstPanId (void) const +{ + return(m_addrDstPanId); +} + + +Mac16Address +LrWpanMacHeader::GetShortDstAddr (void) const +{ + return(m_addrShortDstAddr); +} +Mac64Address +LrWpanMacHeader::GetExtDstAddr (void) const +{ + return(m_addrExtDstAddr); +} + +uint16_t +LrWpanMacHeader::GetSrcPanId (void) const +{ + return(m_addrSrcPanId); +} + + + +Mac16Address +LrWpanMacHeader::GetShortSrcAddr (void) const +{ + return(m_addrShortSrcAddr); +} +Mac64Address +LrWpanMacHeader::GetExtSrcAddr (void) const +{ + return(m_addrExtSrcAddr); +} + + +uint8_t +LrWpanMacHeader::GetSecControl (void) const +{ + uint8_t val = 0; + + val = m_secctrlSecLevel & (0x7); // Bit 0-2 + val |= (m_secctrlKeyIdMode << 3) & (0x3 << 3); // Bit 3-4 + val |= (m_secctrlReserved << 5) & (0x7 << 5); // Bit 5-7 + + return(val); +} + +uint32_t +LrWpanMacHeader::GetFrmCounter (void) const +{ + return(m_auxFrmCntr); +} + +uint8_t +LrWpanMacHeader::GetSecLevel (void) const +{ + return (m_secctrlSecLevel); +} + +uint8_t +LrWpanMacHeader::GetKeyIdMode (void) const +{ + return(m_secctrlKeyIdMode); +} + +uint8_t +LrWpanMacHeader::GetsecctrlReserved (void) const +{ + return (m_secctrlReserved); +} + +uint32_t +LrWpanMacHeader::GetKeyIdSrc32 (void) const +{ + return(m_auxKeyIdKeySrc32); +} + +uint64_t +LrWpanMacHeader::GetKeyIdSrc64 (void) const +{ + + return(m_auxKeyIdKeySrc64); +} + +uint8_t +LrWpanMacHeader::GetKeyIdIndex (void) const +{ + return(m_auxKeyIdKeyIndex); +} + + +bool +LrWpanMacHeader::IsBeacon (void) const +{ + return(m_fctrlFrmType == LRWPAN_MAC_BEACON); +} + + + +bool +LrWpanMacHeader::IsData (void) const +{ + return(m_fctrlFrmType == LRWPAN_MAC_DATA); +} + + + +bool +LrWpanMacHeader::IsAcknowledgment (void) const +{ + return(m_fctrlFrmType == LRWPAN_MAC_ACKNOWLEDGMENT); +} + + + +bool +LrWpanMacHeader::IsCommand (void) const +{ + return(m_fctrlFrmType == LRWPAN_MAC_COMMAND); +} + + + +void +LrWpanMacHeader::SetType (enum LrWpanMacType wpanMacType) +{ + m_fctrlFrmType = wpanMacType; +} + + +void +LrWpanMacHeader::SetFrameControl (uint16_t frameControl) +{ + m_fctrlFrmType = (frameControl) & (0x07); // Bit 0-2 + m_fctrlSecU = (frameControl >> 3) & (0x01); // Bit 3 + m_fctrlFrmPending = (frameControl >> 4) & (0x01); // Bit 4 + m_fctrlAckReq = (frameControl >> 5) & (0x01); // Bit 5 + m_fctrlPanIdComp = (frameControl >> 6) & (0x01); // Bit 6 + m_fctrlReserved = (frameControl >> 7) & (0x07); // Bit 7-9 + m_fctrlDstAddrMode = (frameControl >> 10) & (0x03); // Bit 10-11 + m_fctrlFrmVer = (frameControl >> 12) & (0x03); // Bit 12-13 + m_fctrlSrcAddrMode = (frameControl >> 14) & (0x03); // Bit 14-15 +} + + +void +LrWpanMacHeader::SetSecEnable (void) +{ + m_fctrlSecU = 1; +} + + +void +LrWpanMacHeader::SetSecDisable (void) +{ + m_fctrlSecU = 0; +} + + +void +LrWpanMacHeader::SetFrmPend (void) +{ + m_fctrlFrmPending = 1; +} + + +void +LrWpanMacHeader::SetNoFrmPend (void) +{ + m_fctrlFrmPending = 0; +} + + +void +LrWpanMacHeader::SetAckReq (void) +{ + m_fctrlAckReq = 1; +} + + +void +LrWpanMacHeader::SetNoAckReq (void) +{ + m_fctrlAckReq = 0; +} + + +void +LrWpanMacHeader::SetPanIdComp (void) +{ + m_fctrlPanIdComp = 1; +} + + +void LrWpanMacHeader::SetNoPanIdComp (void) +{ + m_fctrlPanIdComp = 0; +} + +void +LrWpanMacHeader::SetFrmCtrlRes (uint8_t res) +{ + m_fctrlReserved = res; +} + +void +LrWpanMacHeader::SetDstAddrMode (uint8_t addrMode) +{ + m_fctrlDstAddrMode = addrMode; +} + + +void +LrWpanMacHeader::SetFrameVer (uint8_t ver) +{ + m_fctrlFrmVer = ver; +} + + +void +LrWpanMacHeader::SetSrcAddrMode (uint8_t addrMode) +{ + m_fctrlSrcAddrMode = addrMode; +} + + +void +LrWpanMacHeader::SetSeqNum (uint8_t seqNum) +{ + m_SeqNum = seqNum; +} + +void +LrWpanMacHeader::SetSrcAddrFields (uint16_t panId, + Mac16Address addr) +{ + m_addrSrcPanId = panId; + m_addrShortSrcAddr = addr; +} + +void +LrWpanMacHeader::SetSrcAddrFields (uint16_t panId, + Mac64Address addr) +{ + m_addrSrcPanId = panId; + m_addrExtSrcAddr = addr; +} + +void +LrWpanMacHeader::SetDstAddrFields (uint16_t panId, + Mac16Address addr) +{ + m_addrDstPanId = panId; + m_addrShortDstAddr = addr; +} +void +LrWpanMacHeader::SetDstAddrFields (uint16_t panId, + Mac64Address addr) +{ + m_addrDstPanId = panId; + m_addrExtDstAddr = addr; +} +void +LrWpanMacHeader::SetSecControl (uint8_t secControl) +{ + m_secctrlSecLevel = (secControl) & (0x07); // Bit 0-2 + m_secctrlKeyIdMode = (secControl >> 3) & (0x03); // Bit 3-4 + m_secctrlReserved = (secControl >> 5) & (0x07); // Bit 5-7 +} + +void +LrWpanMacHeader::SetFrmCounter (uint32_t frmCntr) +{ + m_auxFrmCntr = frmCntr; +} + +void +LrWpanMacHeader::SetSecLevel (uint8_t secLevel) +{ + m_secctrlSecLevel = secLevel; +} + +void +LrWpanMacHeader::SetKeyIdMode (uint8_t keyIdMode) +{ + m_secctrlKeyIdMode = keyIdMode; +} + +void +LrWpanMacHeader::SetsecctrlReserved (uint8_t res) +{ + m_secctrlReserved = res; +} + +void +LrWpanMacHeader::SetKeyId (uint8_t keyIndex) +{ + m_auxKeyIdKeyIndex = keyIndex; +} + + +void +LrWpanMacHeader::SetKeyId (uint32_t keySrc, + uint8_t keyIndex) +{ + m_auxKeyIdKeyIndex = keyIndex; + m_auxKeyIdKeySrc32 = keySrc; +} + + +void +LrWpanMacHeader::SetKeyId (uint64_t keySrc, + uint8_t keyIndex) +{ + m_auxKeyIdKeyIndex = keyIndex; + m_auxKeyIdKeySrc64 = keySrc; +} + + +std::string +LrWpanMacHeader::GetName (void) const +{ + return "LrWpan MAC Header"; +} + +TypeId +LrWpanMacHeader::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanMacHeader") + .SetParent
() + .AddConstructor (); + return tid; +} + + +TypeId +LrWpanMacHeader::GetInstanceTypeId (void) const +{ + return GetTypeId (); +} + +void +LrWpanMacHeader::PrintFrameControl (std::ostream &os) const +{ + os << " Frame Type = " << (uint32_t) m_fctrlFrmType << ", Sec Enable = " << (uint32_t) m_fctrlSecU + << ", Frame Pending = " << (uint32_t) m_fctrlFrmPending << ", Ack Request = " << (uint32_t) m_fctrlAckReq + << ", PAN ID Compress = " << (uint32_t) m_fctrlPanIdComp << ", Frame Vers = " << (uint32_t) m_fctrlFrmVer + << ", Dst Addrs Mode = " << (uint32_t) m_fctrlDstAddrMode << ", Src Addr Mode = " << (uint32_t) m_fctrlSrcAddrMode; +} + +void +LrWpanMacHeader::Print (std::ostream &os) const +{ + PrintFrameControl (os); + os << ", Sequence Num = " << static_cast (m_SeqNum); + + switch (m_fctrlDstAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + os << ", Dst Addr Pan ID = " << static_cast (m_addrDstPanId) + << ", m_addrShortDstAddr = " << m_addrShortDstAddr; + break; + case EXTADDR: + os << ", Dst Addr Pan ID = " << static_cast (m_addrDstPanId) + << ", m_addrExtDstAddr = " << m_addrExtDstAddr; + break; + } + + switch (m_fctrlSrcAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + os << ", Src Addr Pan ID = " << static_cast (m_addrSrcPanId) + << ", m_addrShortSrcAddr = " << m_addrShortSrcAddr; + break; + case EXTADDR: + os << ", Src Addr Pan ID = " << static_cast (m_addrSrcPanId) + << ", m_addrExtSrcAddr = " << m_addrExtDstAddr; + break; + } + + if (IsSecEnable ()) + { + os << " Security Level = " << static_cast (m_secctrlSecLevel) + << ", Key Id Mode = " << static_cast (m_secctrlKeyIdMode) + << ", Frame Counter = " << static_cast (m_auxFrmCntr); + + switch (m_secctrlKeyIdMode) + { + case IMPLICIT: + break; + case NOKEYSOURCE: + os << ", Key Id - Key Index = " << static_cast (m_auxKeyIdKeyIndex); + break; + case SHORTKEYSOURCE: + os << ", Key Id - Key Source 32 =" << static_cast (m_auxKeyIdKeySrc32) + << ", Key Id - Key Index = " << static_cast (m_auxKeyIdKeyIndex); + break; + case LONGKEYSOURCE: + os << ", Key Id - Key Source 64 =" << static_cast (m_auxKeyIdKeySrc64) + << ", Key Id - Key Index = " << static_cast (m_auxKeyIdKeyIndex); + break; + } + } +} + +uint32_t +LrWpanMacHeader::GetSerializedSize (void) const +{ + /* + * Each mac header will have + * Frame Control : 2 octet + * Sequence Number : 1 Octet + * Dst PAN Id : 0/2 Octet + * Dst Address : 0/2/8 octet + * Src PAN Id : 0/2 octet + * Src Address : 0/2/8 octet + * Aux Sec Header : 0/5/6/10/14 octet + */ + + uint32_t size = 3; + + switch (m_fctrlDstAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + size += 4; + break; + case EXTADDR: + size += 10; + break; + } + + switch (m_fctrlSrcAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + // check if PAN Id compression is enabled + if (IsNoPanIdComp ()) + { + size += 4; + } + else + { + size += 2; + } + break; + case EXTADDR: + // check if PAN Id compression is enabled + if (IsNoPanIdComp ()) + { + size += 10; + } + else + { + size += 8; + } + break; + } + + + // check if security is enabled + if (IsSecEnable ()) + { + size += 5; + switch (m_secctrlKeyIdMode) + { + case IMPLICIT: + break; + case NOKEYSOURCE: + size += 1; + break; + case SHORTKEYSOURCE: + size += 5; + break; + case LONGKEYSOURCE: + size += 9; + break; + } + } + return (size); +} + + +void +LrWpanMacHeader::Serialize (Buffer::Iterator start) const +{ + Buffer::Iterator i = start; + uint16_t frameControl = GetFrameControl (); + + i.WriteHtolsbU16 (frameControl); + i.WriteU8 (GetSeqNum ()); + + switch (m_fctrlDstAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + i.WriteHtolsbU16 (GetDstPanId ()); + WriteTo (i, m_addrShortDstAddr); + break; + case EXTADDR: + i.WriteHtolsbU16 (GetDstPanId ()); + WriteTo (i, m_addrExtDstAddr); + break; + } + + switch (m_fctrlSrcAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + if (IsNoPanIdComp ()) + { + i.WriteHtolsbU16 (GetSrcPanId ()); + } + WriteTo (i, m_addrShortSrcAddr); + break; + case EXTADDR: + if (IsNoPanIdComp ()) + { + i.WriteHtolsbU16 (GetSrcPanId ()); + } + WriteTo (i, m_addrExtSrcAddr); + break; + } + + if (IsSecEnable ()) + { + i.WriteU8 (GetSecControl ()); + i.WriteHtolsbU32 (GetFrmCounter ()); + + switch (m_secctrlKeyIdMode) + { + case IMPLICIT: + break; + case NOKEYSOURCE: + i.WriteU8 (GetKeyIdIndex ()); + break; + case SHORTKEYSOURCE: + i.WriteHtolsbU32 (GetKeyIdSrc32 ()); + i.WriteU8 (GetKeyIdIndex ()); + break; + case LONGKEYSOURCE: + i.WriteHtolsbU64 (GetKeyIdSrc64 ()); + i.WriteU8 (GetKeyIdIndex ()); + break; + } + } +} + + +uint32_t +LrWpanMacHeader::Deserialize (Buffer::Iterator start) +{ + + Buffer::Iterator i = start; + uint16_t frameControl = i.ReadLsbtohU16 (); + SetFrameControl (frameControl); + + SetSeqNum (i.ReadU8 ()); + switch (m_fctrlDstAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + m_addrDstPanId = i.ReadLsbtohU16 (); + ReadFrom (i, m_addrShortDstAddr); + break; + case EXTADDR: + m_addrDstPanId = i.ReadLsbtohU16 (); + ReadFrom (i, m_addrExtDstAddr); + break; + } + + switch (m_fctrlSrcAddrMode) + { + case NOADDR: + break; + case SHORTADDR: + if (IsNoPanIdComp ()) + { + m_addrSrcPanId = i.ReadLsbtohU16 (); + } + else + { + if (m_fctrlDstAddrMode > 0) + { + m_addrSrcPanId = m_addrDstPanId; + } + } + ReadFrom (i, m_addrShortSrcAddr); + break; + case EXTADDR: + if (IsNoPanIdComp ()) + { + m_addrSrcPanId = i.ReadLsbtohU16 (); + } + else + { + if (m_fctrlDstAddrMode > 0) + { + m_addrSrcPanId = m_addrDstPanId; + } + } + ReadFrom (i, m_addrExtSrcAddr); + break; + } + + if (IsSecEnable ()) + { + SetSecControl (i.ReadU8 ()); + SetFrmCounter (i.ReadLsbtohU32 ()); + + switch (m_secctrlKeyIdMode) + { + case IMPLICIT: + break; + case NOKEYSOURCE: + SetKeyId (i.ReadU8 ()); + break; + case SHORTKEYSOURCE: + SetKeyId (i.ReadLsbtohU32 (),i.ReadU8 ()); + break; + case LONGKEYSOURCE: + SetKeyId (i.ReadLsbtohU64 (),i.ReadU8 ()); + break; + } + } + return i.GetDistanceFrom (start); +} + +// ---------------------------------------------------------------------------------------------------------- + + +} //namespace ns3 + + diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-mac-header.h ns-3.20/src/lr-wpan/model/lr-wpan-mac-header.h --- ns-3.19/src/lr-wpan/model/lr-wpan-mac-header.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-mac-header.h 2014-06-17 10:33:13.901995900 -0700 @@ -0,0 +1,238 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: kwong yin + */ + +/** + * the following classes implements the 802.15.4 Mac Header + * There are 4 types of 802.15.4 Mac Headers Frames, and they have these fields + * + * Headers Frames : Fields + * ------------------------------------------------------------------------------------------- + * Beacon : Frame Control, Sequence Number, Address Fields+, Auxiliary Security Header++. + * Data : Frame Control, Sequence Number, Address Fields++, Auxiliary Security Header++. + * Acknowledgment : Frame Control, Sequence Number. + * Command : Frame Control, Sequence Number, Address Fields++, Auxiliary Security Header++. + * + * + - The Address fields in Beacon frame is made up of the Source PAN Id and address only and size + * is 4 or 8 octets whereas the other frames may contain the Destination PAN Id and address as + * well. (see specs). + * ++ - These fields are optional and of variable size + */ + +#ifndef LR_WPAN_MAC_HEADER_H +#define LR_WPAN_MAC_HEADER_H + +#include +#include +#include + + +namespace ns3 { + + +/* + * \ingroup lr-wpan + * Represent the Mac Header with the Frame Control and Sequence Number fields + */ +class LrWpanMacHeader : public Header +{ + +public: + enum LrWpanMacType + { + LRWPAN_MAC_BEACON = 0, + LRWPAN_MAC_DATA = 1, + LRWPAN_MAC_ACKNOWLEDGMENT = 2, + LRWPAN_MAC_COMMAND = 3, + LRWPAN_MAC_RESERVED + }; + + enum AddrModeType + { + NOADDR = 0, + RESADDR = 1, + SHORTADDR = 2, + EXTADDR = 3 + }; + + enum KeyIdModeType + { + IMPLICIT = 0, + NOKEYSOURCE = 1, + SHORTKEYSOURCE = 2, + LONGKEYSOURCE = 3 + }; + + LrWpanMacHeader (void); + + LrWpanMacHeader (enum LrWpanMacType wpanMacType, // Data, ACK, Control MAC Header must have + uint8_t seqNum); // frame control and sequence number. + // Beacon MAC Header must have frame control, + // sequence number, source PAN Id, source address. + + ~LrWpanMacHeader (void); + + + enum LrWpanMacType GetType (void) const; + uint16_t GetFrameControl (void) const; + bool IsSecEnable (void) const; + bool IsSecDisable (void) const; + bool IsFrmPend (void) const; + bool IsNoFrmPend (void) const; + bool IsAckReq (void) const; + bool IsNoAckReq (void) const; + bool IsPanIdComp (void) const; + bool IsNoPanIdComp (void) const; + uint8_t GetFrmCtrlRes (void) const; + uint8_t GetDstAddrMode (void) const; + uint8_t GetFrameVer (void) const; + uint8_t GetSrcAddrMode (void) const; + + uint8_t GetSeqNum (void) const; + + uint16_t GetDstPanId (void) const; + Mac16Address GetShortDstAddr (void) const; + Mac64Address GetExtDstAddr (void) const; + uint16_t GetSrcPanId (void) const; + Mac16Address GetShortSrcAddr (void) const; + Mac64Address GetExtSrcAddr (void) const; + + uint8_t GetSecControl (void) const; + uint32_t GetFrmCounter (void) const; + + uint8_t GetSecLevel (void) const; + uint8_t GetKeyIdMode (void) const; + uint8_t GetsecctrlReserved (void) const; + + uint32_t GetKeyIdSrc32 (void) const; + uint64_t GetKeyIdSrc64 (void) const; + uint8_t GetKeyIdIndex (void) const; + + + bool IsBeacon (void) const; + bool IsData (void) const; + bool IsAcknowledgment (void) const; + bool IsCommand (void) const; + + + void SetType (enum LrWpanMacType wpanMacType); + void SetFrameControl (uint16_t frameControl); + void SetSecEnable (void); + void SetSecDisable (void); + void SetFrmPend (void); + void SetNoFrmPend (void); + void SetAckReq (void); + void SetNoAckReq (void); + void SetPanIdComp (void); + void SetNoPanIdComp (void); + void SetFrmCtrlRes (uint8_t res); + void SetDstAddrMode (uint8_t addrMode); + void SetFrameVer (uint8_t ver); + void SetSrcAddrMode (uint8_t addrMode); + + void SetSeqNum (uint8_t seqNum); + + /* The Source/Destination Addressing fields are only set if SrcAddrMode/DstAddrMode are set */ + void SetSrcAddrFields (uint16_t panId, + Mac16Address addr); + void SetSrcAddrFields (uint16_t panId, + Mac64Address addr); + void SetDstAddrFields (uint16_t panId, + Mac16Address addr); + void SetDstAddrFields (uint16_t panId, + Mac64Address addr); + + /* Auxiliary Security Header is only set if Sec Enable (SecU) field is set to 1 */ + void SetSecControl (uint8_t secLevel); + void SetFrmCounter (uint32_t frmCntr); + + void SetSecLevel (uint8_t secLevel); + void SetKeyIdMode (uint8_t keyIdMode); + void SetsecctrlReserved (uint8_t res); + + /* Variable length will be dependent on Key Id Mode*/ + void SetKeyId (uint8_t keyIndex); + void SetKeyId (uint32_t keySrc, + uint8_t keyIndex); + void SetKeyId (uint64_t keySrc, + uint8_t keyIndex); + + + std::string GetName (void) const; + static TypeId GetTypeId (void); + virtual TypeId GetInstanceTypeId (void) const; + void PrintFrameControl (std::ostream &os) const; + void Print (std::ostream &os) const; + uint32_t GetSerializedSize (void) const; + void Serialize (Buffer::Iterator start) const; + uint32_t Deserialize (Buffer::Iterator start); + + +private: + /* Frame Control 2 Octets */ + /* Frame Control fields */ + uint8_t m_fctrlFrmType; // Bit 0-2 = 0 - Beacon, 1 - Data, 2 - Ack, 3 - Command + uint8_t m_fctrlSecU; // Bit 3 = 0 - no AuxSecHdr , 1 - security enabled AuxSecHdr present + uint8_t m_fctrlFrmPending; // Bit 4 + uint8_t m_fctrlAckReq; // Bit 5 + uint8_t m_fctrlPanIdComp; // Bit 6 = 0 - no compression, 1 - using only DstPanId for both Src and DstPanId + uint8_t m_fctrlReserved; // Bit 7-9 + uint8_t m_fctrlDstAddrMode; // Bit 10-11 = 0 - No DstAddr, 2 - ShtDstAddr, 3 - ExtDstAddr + uint8_t m_fctrlFrmVer; // Bit 12-13 + uint8_t m_fctrlSrcAddrMode; // Bit 14-15 = 0 - No DstAddr, 2 - ShtDstAddr, 3 - ExtDstAddr + + /* Sequence Number */ + uint8_t m_SeqNum; // 1 Octet + + /* Addressing fields */ + uint16_t m_addrDstPanId; // 0 or 2 Octet + Mac16Address m_addrShortDstAddr; // 0 or 8 Octet + Mac64Address m_addrExtDstAddr; // 0 or 8 Octet + uint16_t m_addrSrcPanId; // 0 or 2 Octet + Mac16Address m_addrShortSrcAddr; // 0 or 8 Octet + Mac64Address m_addrExtSrcAddr; // 0 or 8 Octet + + /* Auxiliary Security Header // 0, 5, 6, 10 or 14 Octets */ + // uint8_t m_auxSecCtrl; // 1 Octet see below + uint32_t m_auxFrmCntr; // 4 Octet + + /* Security Control fields */ + uint8_t m_secctrlSecLevel; // Bit 0-2 + uint8_t m_secctrlKeyIdMode; // Bit 3-4 will indicate size of Key Id + // = 0 - Key is determined implicitly + // from originator and receipient + // = 1 - 1 Octet Key Index + // = 2 - 1 octet Key Index and 4 oct Key src + // = 3 - 1 octet Key Index and 8 oct Key src + + uint8_t m_secctrlReserved; // Bit 5-7 + + union + { + uint32_t m_auxKeyIdKeySrc32; // 4 octets + uint64_t m_auxKeyIdKeySrc64; // 8 octets + }; + + uint8_t m_auxKeyIdKeyIndex; // 1 octet + +}; //LrWpanMacHeader + +}; // namespace ns-3 + +#endif /* LR_WPAN_MAC_HEADER_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-mac-trailer.cc ns-3.20/src/lr-wpan/model/lr-wpan-mac-trailer.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-mac-trailer.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-mac-trailer.cc 2014-06-17 10:33:13.902995892 -0700 @@ -0,0 +1,160 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * kwong yin + * Sascha Alexander Jopen + * Erwan Livolant + */ +#include "lr-wpan-mac-trailer.h" +#include + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanMacTrailer); + +const uint16_t LrWpanMacTrailer::LR_WPAN_MAC_FCS_LENGTH = 2; + +LrWpanMacTrailer::LrWpanMacTrailer (void) + : m_fcs (0), + m_calcFcs (false) +{ +} + +TypeId +LrWpanMacTrailer::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanMacTrailer") + .SetParent () + .AddConstructor () + ; + return tid; +} + +TypeId +LrWpanMacTrailer::GetInstanceTypeId (void) const +{ + return GetTypeId (); +} + +void +LrWpanMacTrailer::Print (std::ostream &os) const +{ + os << " FCS = " << m_fcs; +} + +uint32_t +LrWpanMacTrailer::GetSerializedSize (void) const +{ + return LR_WPAN_MAC_FCS_LENGTH; +} + +void +LrWpanMacTrailer::Serialize (Buffer::Iterator start) const +{ + start.Prev (LR_WPAN_MAC_FCS_LENGTH); + start.WriteU16 (m_fcs); +} + +uint32_t +LrWpanMacTrailer::Deserialize (Buffer::Iterator start) +{ + start.Prev (LR_WPAN_MAC_FCS_LENGTH); + m_fcs = start.ReadU16 (); + + return LR_WPAN_MAC_FCS_LENGTH; +} + +uint16_t +LrWpanMacTrailer::GetFcs (void) const +{ + return m_fcs; +} + +void +LrWpanMacTrailer::SetFcs (Ptr p) +{ + if (m_calcFcs) + { + uint16_t size = p->GetSize (); + uint8_t *serial_packet = new uint8_t[size]; + + p->CopyData (serial_packet, size); + + m_fcs = GenerateCrc16 (serial_packet, size); + delete[] serial_packet; + } +} + +/* Be sure to have removed the trailer and only the trailer + * from the packet before to use CheckFcs */ +bool +LrWpanMacTrailer::CheckFcs (Ptr p) +{ + if (!m_calcFcs) + { + return true; + } + else + { + uint16_t checkFcs; + uint16_t size = p->GetSize (); + uint8_t *serial_packet = new uint8_t[size]; + + p->CopyData (serial_packet, size); + + checkFcs = GenerateCrc16 (serial_packet, size); + delete[] serial_packet; + return (checkFcs == GetFcs ()); + } +} + +void +LrWpanMacTrailer::EnableFcs (bool enable) +{ + m_calcFcs = enable; + if (!enable) + { + m_fcs = 0; + } +} + +bool +LrWpanMacTrailer::IsFcsEnabled (void) +{ + return m_calcFcs; +} + +uint16_t +LrWpanMacTrailer::GenerateCrc16 (uint8_t *data, int length) +{ + int i; + uint16_t accumulator = 0; + + for (i = 0; i < length; ++i) + { + accumulator ^= *data; + accumulator = (accumulator >> 8) | (accumulator << 8); + accumulator ^= (accumulator & 0xff00) << 4; + accumulator ^= (accumulator >> 8) >> 4; + accumulator ^= (accumulator & 0xff00) >> 5; + ++data; + } + return accumulator; +} + +} //namespace ns3 diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-mac-trailer.h ns-3.20/src/lr-wpan/model/lr-wpan-mac-trailer.h --- ns-3.19/src/lr-wpan/model/lr-wpan-mac-trailer.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-mac-trailer.h 2014-06-17 10:33:13.902995892 -0700 @@ -0,0 +1,131 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * kwong yin + * Sascha Alexander Jopen + * Erwan Livolant + */ + +#ifndef LR_WPAN_MAC_TRAILER_H +#define LR_WPAN_MAC_TRAILER_H + +#include + +namespace ns3 { + +class Packet; + +/** + * \ingroup lr-wpan + * + * Represent the Mac Trailer with the Frame Check Sequence field. + */ +class LrWpanMacTrailer : public Trailer +{ +public: + /** + * The length in octets of the IEEE 802.15.4 MAC FCS field + */ + static const uint16_t LR_WPAN_MAC_FCS_LENGTH; + + /** + * Get the type ID. + * + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + /** + * Default constructor for a MAC trailer with disabled FCS calculation. + */ + LrWpanMacTrailer (void); + + // Inherited from the Trailer class. + virtual TypeId GetInstanceTypeId (void) const; + virtual void Print (std::ostream &os) const; + virtual uint32_t GetSerializedSize (void) const; + virtual void Serialize (Buffer::Iterator start) const; + virtual uint32_t Deserialize (Buffer::Iterator start); + + /** + * Get this trailers FCS value. If FCS calculation is disabled for this + * trailer, the returned value is always 0. + * + * \return the FCS value. + */ + uint16_t GetFcs (void) const; + + /** + * Calculate and set the FCS value based on the given packet. + * + * \param p the packet for which the FCS should be calculated + */ + void SetFcs (Ptr p); + + /** + * Check the FCS of a given packet against the FCS value stored in the + * trailer. The packet itself should contain no trailer. If FCS calculation is + * disabled for this trailer, CheckFcs() will always return true. + * + * \param the packet to be checked + * \return false, if the FCS values do not match, true otherwise + */ + bool CheckFcs (Ptr p); + + /** + * Enable or disable FCS calculation for this trailer. + * + * \param enable flag, indicating if FCS calculation should be enabled or not + */ + void EnableFcs (bool enable); + + /** + * Query if FCS calculation is enabled for this trailer. + * + * \return true, if FCS calculation is enabled, false otherwise. + */ + bool IsFcsEnabled (void); + +private: + /** + * Calculate the 16-bit FCS value. + * CRC16-CCITT with a generator polynomial = ^16 + ^12 + ^5 + 1, LSB first and + * initial value = 0x0000. + * + * \param data the checksum will be calculated over this data + * \param length the length of the data + * \return the checksum + */ + uint16_t GenerateCrc16 (uint8_t *data, int length); + + /** + * The FCS value stored in this trailer. + */ + uint16_t m_fcs; + + /** + * Only if m_calcFcs is true, FCS values will be calculated and used in the + * trailer + */ + bool m_calcFcs; + +}; + +} // namespace ns3 + +#endif /* LR_WPAN_MAC_TRAILER_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-net-device.cc ns-3.20/src/lr-wpan/model/lr-wpan-net-device.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-net-device.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-net-device.cc 2014-06-17 10:33:13.904995877 -0700 @@ -0,0 +1,471 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * Tom Henderson + * Tommaso Pecorella + * Margherita Filippetti + */ +#include "lr-wpan-net-device.h" +#include "lr-wpan-phy.h" +#include "lr-wpan-csmaca.h" +#include "lr-wpan-error-model.h" +#include +#include +#include +#include +#include +#include +#include +#include + + +NS_LOG_COMPONENT_DEFINE ("LrWpanNetDevice"); + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanNetDevice); + +TypeId +LrWpanNetDevice::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanNetDevice") + .SetParent () + .AddConstructor () + .AddAttribute ("Channel", "The channel attached to this device", + PointerValue (), + MakePointerAccessor (&LrWpanNetDevice::DoGetChannel), + MakePointerChecker ()) + .AddAttribute ("Phy", "The PHY layer attached to this device.", + PointerValue (), + MakePointerAccessor (&LrWpanNetDevice::GetPhy, + &LrWpanNetDevice::SetPhy), + MakePointerChecker ()) + .AddAttribute ("Mac", "The MAC layer attached to this device.", + PointerValue (), + MakePointerAccessor (&LrWpanNetDevice::GetMac, + &LrWpanNetDevice::SetMac), + MakePointerChecker ()) + .AddAttribute ("UseAcks", "Request acknowledgments for data frames.", + BooleanValue (true), + MakeBooleanAccessor (&LrWpanNetDevice::m_useAcks), + MakeBooleanChecker ()) + ; + return tid; +} + +LrWpanNetDevice::LrWpanNetDevice () + : m_configComplete (false) +{ + NS_LOG_FUNCTION (this); + m_mac = CreateObject (); + m_phy = CreateObject (); + m_csmaca = CreateObject (); + CompleteConfig (); +} + +LrWpanNetDevice::~LrWpanNetDevice () +{ + NS_LOG_FUNCTION (this); +} + + +void +LrWpanNetDevice::DoDispose (void) +{ + NS_LOG_FUNCTION (this); + m_mac->Dispose (); + m_phy->Dispose (); + m_csmaca->Dispose (); + m_phy = 0; + m_mac = 0; + m_csmaca = 0; + m_node = 0; + // chain up. + NetDevice::DoDispose (); + +} + +void +LrWpanNetDevice::DoInitialize (void) +{ + NS_LOG_FUNCTION (this); + m_phy->Initialize (); + m_mac->Initialize (); + NetDevice::DoInitialize (); +} + + +void +LrWpanNetDevice::CompleteConfig (void) +{ + NS_LOG_FUNCTION (this); + if (m_mac == 0 + || m_phy == 0 + || m_csmaca == 0 + || m_node == 0 + || m_configComplete) + { + return; + } + m_mac->SetPhy (m_phy); + m_mac->SetCsmaCa (m_csmaca); + m_mac->SetMcpsDataIndicationCallback (MakeCallback (&LrWpanNetDevice::McpsDataIndication, this)); + m_csmaca->SetMac (m_mac); + + m_phy->SetMobility (m_node->GetObject ()); + Ptr model = CreateObject (); + m_phy->SetErrorModel (model); + m_phy->SetDevice (this); + + m_phy->SetPdDataIndicationCallback (MakeCallback (&LrWpanMac::PdDataIndication, m_mac)); + m_phy->SetPdDataConfirmCallback (MakeCallback (&LrWpanMac::PdDataConfirm, m_mac)); + m_phy->SetPlmeEdConfirmCallback (MakeCallback (&LrWpanMac::PlmeEdConfirm, m_mac)); + m_phy->SetPlmeGetAttributeConfirmCallback (MakeCallback (&LrWpanMac::PlmeGetAttributeConfirm, m_mac)); + m_phy->SetPlmeSetTRXStateConfirmCallback (MakeCallback (&LrWpanMac::PlmeSetTRXStateConfirm, m_mac)); + m_phy->SetPlmeSetAttributeConfirmCallback (MakeCallback (&LrWpanMac::PlmeSetAttributeConfirm, m_mac)); + + m_csmaca->SetLrWpanMacStateCallback (MakeCallback (&LrWpanMac::SetLrWpanMacState, m_mac)); + m_phy->SetPlmeCcaConfirmCallback (MakeCallback (&LrWpanCsmaCa::PlmeCcaConfirm, m_csmaca)); + m_configComplete = true; +} + +void +LrWpanNetDevice::SetMac (Ptr mac) +{ + NS_LOG_FUNCTION (this); + m_mac = mac; + CompleteConfig (); +} + +void +LrWpanNetDevice::SetPhy (Ptr phy) +{ + NS_LOG_FUNCTION (this); + m_phy = phy; + CompleteConfig (); +} + +void +LrWpanNetDevice::SetCsmaCa (Ptr csmaca) +{ + NS_LOG_FUNCTION (this); + m_csmaca = csmaca; + CompleteConfig (); +} + +void +LrWpanNetDevice::SetChannel (Ptr channel) +{ + NS_LOG_FUNCTION (this << channel); + m_phy->SetChannel (channel); + channel->AddRx (m_phy); + CompleteConfig (); +} + +Ptr +LrWpanNetDevice::GetMac (void) const +{ + // NS_LOG_FUNCTION (this); + return m_mac; +} + +Ptr +LrWpanNetDevice::GetPhy (void) const +{ + NS_LOG_FUNCTION (this); + return m_phy; +} + +Ptr +LrWpanNetDevice::GetCsmaCa (void) const +{ + NS_LOG_FUNCTION (this); + return m_csmaca; +} +void +LrWpanNetDevice::SetIfIndex (const uint32_t index) +{ + NS_LOG_FUNCTION (this << index); + m_ifIndex = index; +} + +uint32_t +LrWpanNetDevice::GetIfIndex (void) const +{ + NS_LOG_FUNCTION (this); + return m_ifIndex; +} + +Ptr +LrWpanNetDevice::GetChannel (void) const +{ + NS_LOG_FUNCTION (this); + return m_phy->GetChannel (); +} + +void +LrWpanNetDevice::LinkUp (void) +{ + NS_LOG_FUNCTION (this); + m_linkUp = true; + m_linkChanges (); +} + +void +LrWpanNetDevice::LinkDown (void) +{ + NS_LOG_FUNCTION (this); + m_linkUp = false; + m_linkChanges (); +} + +Ptr +LrWpanNetDevice::DoGetChannel (void) const +{ + NS_LOG_FUNCTION (this); + return m_phy->GetChannel (); +} + +void +LrWpanNetDevice::SetAddress (Address address) +{ + NS_LOG_FUNCTION (this); + m_mac->SetShortAddress (Mac16Address::ConvertFrom (address)); +} + +Address +LrWpanNetDevice::GetAddress (void) const +{ + NS_LOG_FUNCTION (this); + return m_mac->GetShortAddress (); +} + +bool +LrWpanNetDevice::SetMtu (const uint16_t mtu) +{ + NS_ABORT_MSG ("Unsupported"); + return false; +} + +uint16_t +LrWpanNetDevice::GetMtu (void) const +{ + NS_LOG_FUNCTION (this); + // Maximum payload size is: max psdu - frame control - seqno - addressing - security - fcs + // = 127 - 2 - 1 - (2+2+2+2) - 0 - 2 + // = 114 + // assuming no security and addressing with only 16 bit addresses without pan id compression. + return 114; +} + +bool +LrWpanNetDevice::IsLinkUp (void) const +{ + NS_LOG_FUNCTION (this); + return m_phy != 0 && m_linkUp; +} + +void +LrWpanNetDevice::AddLinkChangeCallback (Callback callback) +{ + NS_LOG_FUNCTION (this); + m_linkChanges.ConnectWithoutContext (callback); +} + +bool +LrWpanNetDevice::IsBroadcast (void) const +{ + NS_LOG_FUNCTION (this); + return true; +} + +Address +LrWpanNetDevice::GetBroadcast (void) const +{ + NS_LOG_FUNCTION (this); + return Mac16Address ("ff:ff"); +} + +bool +LrWpanNetDevice::IsMulticast (void) const +{ + NS_LOG_FUNCTION (this); + return true; +} + +Address +LrWpanNetDevice::GetMulticast (Ipv4Address multicastGroup) const +{ + NS_ABORT_MSG ("Unsupported"); + return Address (); +} + +Address +LrWpanNetDevice::GetMulticast (Ipv6Address addr) const +{ + NS_LOG_FUNCTION (this); + /* Implementation based on RFC 4944 Section 9. + * An IPv6 packet with a multicast destination address (DST), + * consisting of the sixteen octets DST[1] through DST[16], is + * transmitted to the following 802.15.4 16-bit multicast address: + * 0 1 + * 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 + * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ + * |1 0 0|DST[15]* | DST[16] | + * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ + * Here, DST[15]* refers to the last 5 bits in octet DST[15], that is, + * bits 3-7 within DST[15]. The initial 3-bit pattern of "100" follows + * the 16-bit address format for multicast addresses (Section 12). */ + + // \todo re-add this once Lr-Wpan will be able to accept these multicast addresses + // uint8_t buf[16]; + // uint8_t buf2[2]; + // + // addr.GetBytes(buf); + // + // buf2[0] = 0x80 | (buf[14] & 0x1F); + // buf2[1] = buf[15]; + // + // Mac16Address newaddr = Mac16Address(); + // newaddr.CopyFrom(buf2); + // return newaddr; + + return Mac16Address ("ff:ff"); +} + +bool +LrWpanNetDevice::IsBridge (void) const +{ + NS_LOG_FUNCTION (this); + return false; +} + +bool +LrWpanNetDevice::IsPointToPoint (void) const +{ + NS_LOG_FUNCTION (this); + return false; +} + +bool +LrWpanNetDevice::Send (Ptr packet, const Address& dest, uint16_t protocolNumber) +{ + // This method basically assumes an 802.3-compliant device, but a raw + // 802.15.4 device does not have an ethertype, and requires specific + // McpsDataRequest parameters. + // For further study: how to support these methods somehow, such as + // inventing a fake ethertype and packet tag for McpsDataRequest + NS_LOG_FUNCTION (this << packet << dest << protocolNumber); + + if (packet->GetSize () > GetMtu ()) + { + NS_LOG_ERROR ("Fragmentation is needed for this packet, drop the packet "); + return false; + } + + McpsDataRequestParams m_mcpsDataRequestParams; + m_mcpsDataRequestParams.m_dstAddr = Mac16Address::ConvertFrom (dest); + m_mcpsDataRequestParams.m_dstAddrMode = SHORT_ADDR; + m_mcpsDataRequestParams.m_dstPanId = m_mac->GetPanId (); + m_mcpsDataRequestParams.m_srcAddrMode = SHORT_ADDR; + // Using ACK requests for broadcast destinations is ok here. They are disabled + // by the MAC. + if (m_useAcks) + { + m_mcpsDataRequestParams.m_txOptions = TX_OPTION_ACK; + } + m_mcpsDataRequestParams.m_msduHandle = 0; + m_mac->McpsDataRequest (m_mcpsDataRequestParams, packet); + return true; +} + +bool +LrWpanNetDevice::SendFrom (Ptr packet, const Address& source, const Address& dest, uint16_t protocolNumber) +{ + NS_ABORT_MSG ("Unsupported"); + // TODO: To support SendFrom, the MACs McpsDataRequest has to use the provided source address, instead of to local one. + return false; +} + +Ptr +LrWpanNetDevice::GetNode (void) const +{ + NS_LOG_FUNCTION (this); + return m_node; +} + +void +LrWpanNetDevice::SetNode (Ptr node) +{ + NS_LOG_FUNCTION (this); + m_node = node; + CompleteConfig (); +} + +bool +LrWpanNetDevice::NeedsArp (void) const +{ + NS_LOG_FUNCTION (this); + return true; +} + +void +LrWpanNetDevice::SetReceiveCallback (ReceiveCallback cb) +{ + NS_LOG_FUNCTION (this); + m_receiveCallback = cb; +} + +void +LrWpanNetDevice::SetPromiscReceiveCallback (PromiscReceiveCallback cb) +{ + // This method basically assumes an 802.3-compliant device, but a raw + // 802.15.4 device does not have an ethertype, and requires specific + // McpsDataIndication parameters. + // For further study: how to support these methods somehow, such as + // inventing a fake ethertype and packet tag for McpsDataRequest + NS_LOG_WARN ("Unsupported; use LrWpan MAC APIs instead"); +} + +void +LrWpanNetDevice::McpsDataIndication (McpsDataIndicationParams params, Ptr pkt) +{ + NS_LOG_FUNCTION (this); + // TODO: Use the PromiscReceiveCallback if the MAC is in promiscuous mode. + m_receiveCallback (this, pkt, 0, params.m_srcAddr); +} + +bool +LrWpanNetDevice::SupportsSendFrom (void) const +{ + NS_LOG_FUNCTION_NOARGS (); + return false; +} + +int64_t +LrWpanNetDevice::AssignStreams (int64_t stream) +{ + NS_LOG_FUNCTION (stream); + int64_t streamIndex = stream; + streamIndex += m_csmaca->AssignStreams (stream); + streamIndex += m_phy->AssignStreams (stream); + NS_LOG_DEBUG ("Number of assigned RV streams: " << (streamIndex - stream)); + return (streamIndex - stream); +} + +} // namespace ns3 diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-net-device.h ns-3.20/src/lr-wpan/model/lr-wpan-net-device.h --- ns-3.19/src/lr-wpan/model/lr-wpan-net-device.h 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-net-device.h 2014-06-17 10:33:13.905995869 -0700 @@ -0,0 +1,246 @@ +/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * Tom Henderson + * Tommaso Pecorella + * Margherita Filippetti + */ +#ifndef LR_WPAN_NET_DEVICE_H +#define LR_WPAN_NET_DEVICE_H + +#include +#include +#include + +namespace ns3 { + +class LrWpanPhy; +class LrWpanCsmaCa; +class SpectrumChannel; +class Node; + +/** + * \ingroup lr-wpan + * + * \brief Network layer to device interface. + * + * The ns3::NetDevice includes IP-specific API such as GetMulticast(), Send() + * and SendTo() methods, which do not map well the the 802.15.4 MAC MCPS + * DataRequest primitive. So, the basic design is to provide, as + * much as makes sense, the class ns3::NetDevice API, but rely on the user + * accessing the LrWpanMac pointer to make 802.15.4-specific API calls. + * As such, this is really just an encapsulating class. + */ +class LrWpanNetDevice : public NetDevice +{ +public: + /** + * Get the type ID. + * + * \return the object TypeId + */ + static TypeId GetTypeId (void); + + LrWpanNetDevice (void); + virtual ~LrWpanNetDevice (void); + + /** + * Set the MAC to be used by this NetDevice. + * + * \param mac the MAC to be used + */ + void SetMac (Ptr mac); + + /** + * Set the PHY to be used by the MAC and this NetDevice. + * + * \param phy the PHY to be used + */ + void SetPhy (Ptr phy); + + /** + * Set the CSMA/CA implementation to be used by the MAC and this NetDevice. + * + * \param csmaca the CSMA/CA implementation to be used + */ + void SetCsmaCa (Ptr csmaca); + + /** + * Set the channel to which the NetDevice, and therefore the PHY, should be + * attached to. + * + * \param channel the channel to be used + */ + void SetChannel (Ptr channel); + + /** + * Get the MAC used by this NetDevice. + * + * \return the MAC object + */ + Ptr GetMac (void) const; + + /** + * Get the PHY used by this NetDevice. + * + * \return the PHY object + */ + Ptr GetPhy (void) const; + + /** + * Get the CSMA/CA implementation used by this NetDevice. + * + * \return the CSMA/CA implementation object + */ + Ptr GetCsmaCa (void) const; + + // From class NetDevice + virtual void SetIfIndex (const uint32_t index); + virtual uint32_t GetIfIndex (void) const; + virtual Ptr GetChannel (void) const; + /** + * This method indirects to LrWpanMac::SetShortAddress () + */ + virtual void SetAddress (Address address); + /** + * This method indirects to LrWpanMac::SetShortAddress () + */ + 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 callback); + virtual bool IsBroadcast (void) const; + virtual Address GetBroadcast (void) const; + virtual bool IsMulticast (void) const; + virtual Address GetMulticast (Ipv4Address multicastGroup) const; + virtual Address GetMulticast (Ipv6Address addr) const; + virtual bool IsBridge (void) const; + virtual bool IsPointToPoint (void) const; + virtual bool Send (Ptr packet, const Address& dest, uint16_t protocolNumber); + virtual bool SendFrom (Ptr packet, const Address& source, const Address& dest, uint16_t protocolNumber); + virtual Ptr GetNode (void) const; + virtual void SetNode (Ptr node); + virtual bool NeedsArp (void) const; + + virtual void SetReceiveCallback (ReceiveCallback cb); + virtual void SetPromiscReceiveCallback (PromiscReceiveCallback cb); + virtual bool SupportsSendFrom (void) const; + + /** + * The callback used by the MAC to hand over incoming packets to the + * NetDevice. This callback will in turn use the ReceiveCallback set by + * SetReceiveCallback() to notify upper layers. + * + * \param params 802.15.4 specific parameters, including source and destination addresses + * \param pkt the packet do be delivered + */ + void McpsDataIndication (McpsDataIndicationParams params, Ptr pkt); + + /** + * Assign a fixed random variable stream number to the random variables + * used by this model. Return the number of streams that have been assigned. + * + * \param stream first stream index to use + * \return the number of stream indices assigned by this model + */ + int64_t AssignStreams (int64_t stream); + +private: + // Inherited from NetDevice/Object + virtual void DoDispose (void); + virtual void DoInitialize (void); + + /** + * Mark NetDevice link as up. + */ + void LinkUp (void); + + /** + * Mark NetDevice link as down. + */ + void LinkDown (void); + + /** + * Attribute accessor method for the "Channel" attribute. + * + * \return the channel to which this NetDevice is attached + */ + Ptr DoGetChannel (void) const; + + /** + * Configure PHY, MAC and CSMA/CA. + */ + void CompleteConfig (void); + + /** + * The MAC for this NetDevice. + */ + Ptr m_mac; + + /** + * The PHY for this NetDevice. + */ + Ptr m_phy; + + /** + * The CSMA/CA implementation for this NetDevice. + */ + Ptr m_csmaca; + + /** + * The node associated with this NetDevice. + */ + Ptr m_node; + + /** + * True if MAC, PHY and CSMA/CA where successfully configured and the + * NetDevice is ready for being used. + */ + bool m_configComplete; + + /** + * Configure the NetDevice to request MAC layer acknowledgements when sending + * packets using the Send() API. + */ + bool m_useAcks; + + /** + * Is the link/device currently up and running? + */ + bool m_linkUp; + + /** + * The interface index of this NetDevice. + */ + uint32_t m_ifIndex; + + /** + * Trace source for link up/down changes. + */ + TracedCallback<> m_linkChanges; + + /** + * Upper layer callback used for notification of new data packet arrivals. + */ + ReceiveCallback m_receiveCallback; +}; + +} // namespace ns3 + +#endif /* LR_WPAN_NET_DEVICE_H */ diff -Naur ns-3.19/src/lr-wpan/model/lr-wpan-phy.cc ns-3.20/src/lr-wpan/model/lr-wpan-phy.cc --- ns-3.19/src/lr-wpan/model/lr-wpan-phy.cc 1969-12-31 16:00:00.000000000 -0800 +++ ns-3.20/src/lr-wpan/model/lr-wpan-phy.cc 2014-06-17 10:33:13.906995861 -0700 @@ -0,0 +1,1376 @@ +/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ +/* + * Copyright (c) 2011 The Boeing Company + * + * 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: + * Gary Pei + * Sascha Alexander Jopen + */ +#include "lr-wpan-phy.h" +#include "lr-wpan-lqi-tag.h" +#include "lr-wpan-spectrum-signal-parameters.h" +#include "lr-wpan-spectrum-value-helper.h" +#include "lr-wpan-error-model.h" +#include "lr-wpan-net-device.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +NS_LOG_COMPONENT_DEFINE ("LrWpanPhy"); + +namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (LrWpanPhy); + +// Table 22 in section 6.4.1 of ieee802.15.4 +const uint32_t LrWpanPhy::aMaxPhyPacketSize = 127; // max PSDU in octets +const uint32_t LrWpanPhy::aTurnaroundTime = 12; // RX-to-TX or TX-to-RX in symbol periods + +// IEEE802.15.4-2006 Table 2 in section 6.1.2 (kb/s and ksymbol/s) +// The index follows LrWpanPhyOption +const LrWpanPhyDataAndSymbolRates +LrWpanPhy::dataSymbolRates[7] = { { 20.0, 20.0}, + { 40.0, 40.0}, + { 250.0, 12.5}, + { 250.0, 50.0}, + { 100.0, 25.0}, + { 250.0, 62.5}, + { 250.0, 62.5}}; +// IEEE802.15.4-2006 Table 19 and Table 20 in section 6.3. +// The PHR is 1 octet and it follows phySymbolsPerOctet in Table 23 +// The index follows LrWpanPhyOption +const LrWpanPhyPpduHeaderSymbolNumber +LrWpanPhy::ppduHeaderSymbolNumbers[7] = { { 32.0, 8.0, 8.0}, + { 32.0, 8.0, 8.0}, + { 2.0, 1.0, 0.4}, + { 6.0, 1.0, 1.6}, + { 8.0, 2.0, 2.0}, + { 8.0, 2.0, 2.0}, + { 8.0, 2.0, 2.0}}; + +TypeId +LrWpanPhy::GetTypeId (void) +{ + static TypeId tid = TypeId ("ns3::LrWpanPhy") + .SetParent () + .AddConstructor () + .AddTraceSource ("TrxState", + "The state of the transceiver", + MakeTraceSourceAccessor (&LrWpanPhy::m_trxStateLogger)) + .AddTraceSource ("PhyTxBegin", + "Trace source indicating a packet has begun transmitting over the channel medium", + MakeTraceSourceAccessor (&LrWpanPhy::m_phyTxBeginTrace)) + .AddTraceSource ("PhyTxEnd", + "Trace source indicating a packet has been completely transmitted over the channel.", + MakeTraceSourceAccessor (&LrWpanPhy::m_phyTxEndTrace)) + .AddTraceSource ("PhyTxDrop", + "Trace source indicating a packet has been dropped by the device during transmission", + MakeTraceSourceAccessor (&LrWpanPhy::m_phyTxDropTrace)) + .AddTraceSource ("PhyRxBegin", + "Trace source indicating a packet has begun being received from the channel medium by the device", + MakeTraceSourceAccessor (&LrWpanPhy::m_phyRxBeginTrace)) + .AddTraceSource ("PhyRxEnd", + "Trace source indicating a packet has been completely received from the channel medium by the device", + MakeTraceSourceAccessor (&LrWpanPhy::m_phyRxEndTrace)) + .AddTraceSource ("PhyRxDrop", + "Trace source indicating a packet has been dropped by the device during reception", + MakeTraceSourceAccessor (&LrWpanPhy::m_phyRxDropTrace)) + ; + return tid; +} + +LrWpanPhy::LrWpanPhy (void) + : m_edRequest (), + m_setTRXState () +{ + m_trxState = IEEE_802_15_4_PHY_TRX_OFF; + m_trxStatePending = IEEE_802_15_4_PHY_IDLE; + + // default PHY PIB attributes + m_phyPIBAttributes.phyCurrentChannel = 11; + m_phyPIBAttributes.phyTransmitPower = 0; + m_phyPIBAttributes.phyCurrentPage = 0; + for (uint32_t i = 0; i < 32; i++) + { + m_phyPIBAttributes.phyChannelsSupported[i] = 0x07ffffff; + } + m_phyPIBAttributes.phyCCAMode = 1; + + SetMyPhyOption (); + + m_edPower.averagePower = 0.0; + --- transfer too big, truncated ---