# Copyright (C) 2014 INRIA
#
# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
+# 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
class NS3BaseErrorRateModel(NS3Base):
_rtype = "abstract::ns3::ErrorRateModel"
+ @property
+ def node(self):
+ return self.phy.node
+
@property
def phy(self):
from nepi.resources.ns3.ns3wifiphy import NS3BaseWifiPhy
if not phys:
msg = "ErrorRateModel not connected to phy"
self.error(msg)
- raise RuntimeError, msg
+ raise RuntimeError(msg)
return phys[0]
def _connect_object(self):
phy = self.phy
if phy.uuid not in self.connected:
- self.simulator.invoke(phy.uuid, "SetErrorRateModel", self.uuid)
+ self.simulation.invoke(phy.uuid, "SetErrorRateModel", self.uuid)
self._connected.add(phy.uuid)