def _register_attributes(cls): attr_advertisementjitter = Attribute( "AdvertisementJitter", "Uniform variable to provide jitter between min and max values of AdvInterval", type=Types.String, default="ns3::UniformRandomVariable", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_advertisementjitter) attr_starttime = Attribute("StartTime", "Time at which the application will start", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_starttime) attr_stoptime = Attribute("StopTime", "Time at which the application will stop", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_stoptime)
def _register_attributes(cls): attr_mtu = Attribute("Mtu", "The MAC-level Maximum Transmission Unit", type=Types.Integer, default="1500", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_mtu) attr_enablelearning = Attribute( "EnableLearning", "Enable the learning mode of the Learning Bridge", type=Types.Bool, default="True", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_enablelearning) attr_expirationtime = Attribute( "ExpirationTime", "Time it takes for learned MAC state entry to expire.", type=Types.String, default="+300000000000.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_expirationtime)
def _register_attributes(cls): attr_exponent = Attribute("Exponent", "The exponent of the Path Loss propagation model", type = Types.Double, default = "3", allowed = None, range = None, flags = Flags.Reserved | Flags.Construct) cls._register_attribute(attr_exponent) attr_referencedistance = Attribute("ReferenceDistance", "The distance at which the reference loss is calculated (m)", type = Types.Double, default = "1", allowed = None, range = None, flags = Flags.Reserved | Flags.Construct) cls._register_attribute(attr_referencedistance) attr_referenceloss = Attribute("ReferenceLoss", "The reference loss at reference distance (dB). (Default is Friis at 1m with 5.15 GHz)", type = Types.Double, default = "46.6777", allowed = None, range = None, flags = Flags.Reserved | Flags.Construct) cls._register_attribute(attr_referenceloss)
def _register_attributes(cls): cipher = Attribute("cipher", "Cipher to encript communication. " "One of PLAIN, AES, Blowfish, DES, DES3. ", default=None, allowed=["PLAIN", "AES", "Blowfish", "DES", "DES3"], type=Types.Enumerate, flags=Flags.Design) cipher_key = Attribute( "cipherKey", "Specify a symmetric encryption key with which to protect " "packets across the tunnel. python-crypto must be installed " "on the system.", flags=Flags.Design) txqueuelen = Attribute( "txQueueLen", "Specifies the interface's transmission queue length. " "Defaults to 1000. ", type=Types.Integer, flags=Flags.Design) bwlimit = Attribute( "bwLimit", "Specifies the interface's emulated bandwidth in bytes " "per second.", type=Types.Integer, flags=Flags.Design) cls._register_attribute(cipher) cls._register_attribute(cipher_key) cls._register_attribute(txqueuelen) cls._register_attribute(bwlimit)
def _register_attributes(cls): attr_dad = Attribute("DAD", "Always do DAD check.", type=Types.Bool, default="True", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_dad) attr_solicitationjitter = Attribute( "SolicitationJitter", "The jitter in ms a node is allowed to wait before sending any solicitation . Some jitter aims to prevent collisions. By default, the model will wait for a duration in ms defined by a uniform random-variable between 0 and SolicitationJitter", type=Types.String, default="ns3::UniformRandomVariable[Min=0.0|Max=10.0]", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_solicitationjitter) attr_protocolnumber = Attribute("ProtocolNumber", "The Ip protocol number.", type=Types.Integer, default="0", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_protocolnumber)
def _register_attributes(cls): """ Resource subclasses will invoke this method to register resource attributes. This method should be overriden in the RMs that define attributes. """ critical = Attribute("critical", "Defines whether the resource is critical. " "A failure on a critical resource will interrupt " "the experiment. ", type = Types.Bool, default = True, flags = Flags.Design) hard_release = Attribute("hardRelease", "Forces removal of all result files and directories associated " "to the RM upon resource release. After release the RM will " "be removed from the EC and the results will not longer be " "accessible", type = Types.Bool, default = False, flags = Flags.Design) cls._register_attribute(critical) cls._register_attribute(hard_release)
def _register_attributes(cls): uri = Attribute("uri", "URI prefix to match and route for this FIB entry", default = "ccnx:/", flags = Flags.Design) protocol = Attribute("protocol", "Transport protocol used in network connection to peer " "for this FIB entry. One of 'udp' or 'tcp'.", type = Types.Enumerate, default = "udp", allowed = ["udp", "tcp"], flags = Flags.Design) host = Attribute("host", "Peer hostname used in network connection for this FIB entry. ", flags = Flags.Design) port = Attribute("port", "Peer port address used in network connection to peer " "for this FIB entry.", flags = Flags.Design) ip = Attribute("ip", "Peer host public IP used in network connection for this FIB entry. ", flags = Flags.Design) cls._register_attribute(uri) cls._register_attribute(protocol) cls._register_attribute(host) cls._register_attribute(port) cls._register_attribute(ip)
def _register_attributes(cls): attr_frequency = Attribute("Frequency", "The propagation frequency in Hz", type=Types.Double, default="2.16e+09", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_frequency) attr_environment = Attribute( "Environment", "Environment Scenario", type=Types.Enumerate, default="Urban", allowed=["Urban", "SubUrban", "OpenAreas"], range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_environment) attr_citysize = Attribute("CitySize", "Dimension of the city", type=Types.Enumerate, default="Large", allowed=["Small", "Medium", "Large"], range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_citysize)
def _register_attributes(cls): attr_datarate = Attribute( "DataRate", "The transmission data rate to be provided to devices connected to the channel", type=Types.String, default="4294967295bps", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_datarate) attr_delay = Attribute("Delay", "Transmission delay through the channel", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_delay) attr_id = Attribute("Id", "The id (unique integer) of this Channel.", type=Types.Integer, default="0", allowed=None, range=None, flags=Flags.Reserved | Flags.NoWrite) cls._register_attribute(attr_id)
def _register_attributes(cls): attr_frequency = Attribute("Frequency", "The carrier frequency (in Hz) at which propagation occurs (default is 5.15 GHz).", type = Types.Double, default = "5.15e+09", allowed = None, range = None, flags = Flags.Reserved | Flags.Construct) cls._register_attribute(attr_frequency) attr_systemloss = Attribute("SystemLoss", "The system loss", type = Types.Double, default = "1", allowed = None, range = None, flags = Flags.Reserved | Flags.Construct) cls._register_attribute(attr_systemloss) attr_minloss = Attribute("MinLoss", "The minimum value (dB) of the total loss, used at short ranges. Note: ", type = Types.Double, default = "0", allowed = None, range = None, flags = Flags.Reserved | Flags.Construct) cls._register_attribute(attr_minloss)
def _register_attributes(cls): attr_rttestimatortype = Attribute("RttEstimatorType", "Type of RttEstimator objects.", type=Types.String, default="ns3::RttMeanDeviation", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_rttestimatortype) attr_sockettype = Attribute("SocketType", "Socket type of TCP objects.", type=Types.String, default="ns3::TcpNewReno", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_sockettype) attr_protocolnumber = Attribute("ProtocolNumber", "The Ip protocol number.", type=Types.Integer, default="0", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_protocolnumber)
def _register_attributes(cls): attr_port = Attribute("Port", "Port on which we listen for incoming packets.", type=Types.Integer, default="9", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_port) attr_starttime = Attribute("StartTime", "Time at which the application will start", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_starttime) attr_stoptime = Attribute("StopTime", "Time at which the application will stop", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_stoptime)
def _register_attributes(cls): interval = Attribute( "i", "Set ping interval in seconds (minimum 0.10 second) ", type=Types.Integer, flags=Flags.Design) count = Attribute("c", "Total number of pings", type=Types.Double, flags=Flags.Design) number = Attribute( "n", "Set the starting number, the number is incremented by 1 after each Interest ", type=Types.Integer, flags=Flags.Design) prefix = Attribute("prefix", "Prefix to serve content (e.g. ccnx:/name/prefix)", flags=Flags.Design) cls._register_attribute(interval) cls._register_attribute(count) cls._register_attribute(number) cls._register_attribute(prefix)
def _register_attributes(cls): network = Attribute("network", "Network address", flags=Flags.Design) prefix = Attribute("prefix", "IP prefix length", flags=Flags.Design) nexthop = Attribute("nexthop", "Nexthop IP", flags=Flags.Design) cls._register_attribute(network) cls._register_attribute(prefix) cls._register_attribute(nexthop)
def _register_attributes(cls): content_name = Attribute("contentName", "Content name for the content to peek", flags=Flags.Design) pipeline = Attribute("pipeline", "CCNCat pipeline", flags=Flags.Design) cls._register_attribute(content_name) cls._register_attribute(pipeline)
def _register_attributes(cls): attr_defaulttos = Attribute( "DefaultTos", "The TOS value set by default on all outgoing packets generated on this node.", type=Types.Integer, default="0", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_defaulttos) attr_defaultttl = Attribute( "DefaultTtl", "The TTL value set by default on all outgoing packets generated on this node.", type=Types.Integer, default="64", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_defaultttl) attr_fragmentexpirationtimeout = Attribute( "FragmentExpirationTimeout", "When this timeout expires, the fragments will be cleared from the buffer.", type=Types.String, default="+30000000000.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_fragmentexpirationtimeout) attr_ipforward = Attribute( "IpForward", "Globally enable or disable IP forwarding for all current and future Ipv4 devices.", type=Types.Bool, default="True", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_ipforward) attr_weakesmodel = Attribute( "WeakEsModel", "RFC1122 term for whether host accepts datagram with a dest. address on another interface", type=Types.Bool, default="True", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_weakesmodel)
def _register_attributes(cls): attr_los2nlosthr = Attribute( "Los2NlosThr", " Threshold from LoS to NLoS in ITU 1411 [m].", type=Types.Double, default="200", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_los2nlosthr) attr_shadowsigmaoutdoor = Attribute( "ShadowSigmaOutdoor", "Standard deviation of the normal distribution used for calculate the shadowing for outdoor nodes", type=Types.Double, default="7", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_shadowsigmaoutdoor) attr_shadowsigmaindoor = Attribute( "ShadowSigmaIndoor", "Standard deviation of the normal distribution used for calculate the shadowing for indoor nodes ", type=Types.Double, default="8", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_shadowsigmaindoor) attr_shadowsigmaextwalls = Attribute( "ShadowSigmaExtWalls", "Standard deviation of the normal distribution used for calculate the shadowing due to ext walls ", type=Types.Double, default="5", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_shadowsigmaextwalls) attr_internalwallloss = Attribute( "InternalWallLoss", "Additional loss for each internal wall [dB]", type=Types.Double, default="5", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_internalwallloss)
def _register_attributes(cls): action = Attribute("action", "Either add or del", allowed = ["add", "del"], flags = Flags.Design) network = Attribute("network", "IPv4 Network Address", flags = Flags.Design) cls._register_attribute(action) cls._register_attribute(network)
def _register_attributes(cls): attr_lambda = Attribute( "Lambda", "The wavelength (default is 2.3 GHz at 300 000 km/s).", type=Types.Double, default="0.130435", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_lambda) attr_frequency = Attribute("Frequency", "The Frequency (default is 2.3 GHz).", type=Types.Double, default="2.3e+09", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_frequency) attr_bsantennaheight = Attribute( "BSAntennaHeight", " BS Antenna Height (default is 50m).", type=Types.Double, default="50", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_bsantennaheight) attr_ssantennaheight = Attribute("SSAntennaHeight", " SS Antenna Height (default is 3m).", type=Types.Double, default="3", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_ssantennaheight) attr_mindistance = Attribute( "MinDistance", "The distance under which the propagation model refuses to give results (m) ", type=Types.Double, default="0.5", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_mindistance)
def _register_attributes(cls): attr_bounds = Attribute("Bounds", "The 2d bounding area", type=Types.String, default="-100|100|-100|100", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_bounds) attr_speed = Attribute( "Speed", "A random variable to control the speed (m/s).", type=Types.String, default="ns3::UniformRandomVariable[Min=1.0|Max=2.0]", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_speed) attr_pause = Attribute( "Pause", "A random variable to control the pause (s).", type=Types.String, default="ns3::ConstantRandomVariable[Constant=2.0]", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_pause) attr_position = Attribute( "Position", "The current position of the mobility model.", type=Types.String, default="0:0:0", allowed=None, range=None, flags=Flags.Reserved) cls._register_attribute(attr_position) attr_velocity = Attribute( "Velocity", "The current velocity of the mobility model.", type=Types.String, default="0:0:0", allowed=None, range=None, flags=Flags.Reserved | Flags.NoWrite) cls._register_attribute(attr_velocity)
def _register_attributes(cls): attr_address = Attribute("Address", "The MAC address of this device.", type=Types.String, default="ff:ff:ff:ff:ff:ff", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_address) attr_start = Attribute( "Start", "The simulation time at which to spin up the device thread.", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_start) attr_stop = Attribute( "Stop", "The simulation time at which to tear down the device thread.", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_stop) attr_encapsulationmode = Attribute( "EncapsulationMode", "The link-layer encapsulation type to use.", type=Types.Enumerate, default="Dix", allowed=["Dix", "Llc", "DixPi"], range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_encapsulationmode) attr_rxqueuesize = Attribute( "RxQueueSize", "Maximum size of the read queue. This value limits number of packets that have been read from the network into a memory buffer but have not yet been processed by the simulator.", type=Types.Integer, default="1000", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_rxqueuesize)
def _register_attributes(cls): attr_waypointsleft = Attribute("WaypointsLeft", "The number of waypoints remaining.", type=Types.Integer, default="0", allowed=None, range=None, flags=Flags.Reserved | Flags.NoWrite) cls._register_attribute(attr_waypointsleft) attr_lazynotify = Attribute( "LazyNotify", "Only call NotifyCourseChange when position is calculated.", type=Types.Bool, default="False", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_lazynotify) attr_initialpositioniswaypoint = Attribute( "InitialPositionIsWaypoint", "Calling SetPosition with no waypoints creates a waypoint.", type=Types.Bool, default="False", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_initialpositioniswaypoint) attr_position = Attribute( "Position", "The current position of the mobility model.", type=Types.String, default="0:0:0", allowed=None, range=None, flags=Flags.Reserved) cls._register_attribute(attr_position) attr_velocity = Attribute( "Velocity", "The current velocity of the mobility model.", type=Types.String, default="0:0:0", allowed=None, range=None, flags=Flags.Reserved | Flags.NoWrite) cls._register_attribute(attr_velocity)
def _register_attributes(cls): content_name = Attribute("contentName", "Content name for the content to peek", flags=Flags.Design) content = Attribute("content", "Content to poke (as a text string)", flags=Flags.Design) cls._register_attribute(content_name) cls._register_attribute(content)
def _register_attributes(cls): content_name = Attribute( "contentName", "Content name for the requested content object. ", flags=Flags.Design) content = Attribute("content", "Content to poke (as a text string). ", flags=Flags.Design) cls._register_attribute(content_name) cls._register_attribute(content)
def _register_attributes(cls): attr_remoteaddress = Attribute( "RemoteAddress", "The destination Address of the outbound packets", type=Types.String, default="00-00-00", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_remoteaddress) attr_remoteport = Attribute( "RemotePort", "The destination port of the outbound packets", type=Types.Integer, default="100", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_remoteport) attr_maxpacketsize = Attribute( "MaxPacketSize", "The maximum size of a packet (including the SeqTsHeader, 12 bytes).", type=Types.Integer, default="1024", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_maxpacketsize) attr_starttime = Attribute("StartTime", "Time at which the application will start", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_starttime) attr_stoptime = Attribute("StopTime", "Time at which the application will stop", type=Types.String, default="+0.0ns", allowed=None, range=None, flags=Flags.Reserved | Flags.Construct) cls._register_attribute(attr_stoptime)
def _register_attributes(cls): mac = Attribute("mac", "MAC address for device", flags=Flags.Design) ip = Attribute("ip", "IP address for device", flags=Flags.Design) prefix = Attribute("prefix", "Network prefix for device", flags=Flags.Design) cls._register_attribute(mac) cls._register_attribute(ip) cls._register_attribute(prefix)
def _register_attributes(cls): network = Attribute("network", "Destination network address", flags = Flags.Design) prefix = Attribute("prefix", "Network prefix for the network", flags = Flags.Design) nexthop = Attribute("nexthop", "Address of next hop in the route", flags = Flags.Design) cls._register_attribute(network) cls._register_attribute(prefix) cls._register_attribute(nexthop)
def _register_attributes(cls): ''' This method is used to register all the attribute of this RM. Check the file src/execution/attribute.py to see all the fields of this class ''' attribute1 = Attribute("nameOfAttribute1", "Description of the Attribute 1", flags = Flags.Design) attribute2 = Attribute("nameOfAttribute2", "Description of the Attribute 2", flags = Flags.Design) cls._register_attribute(attribute1) cls._register_attribute(attribute2)
def _register_attributes(cls): report_cycles = Attribute( "reportCycles", "sets mtr --report-cycles (-c) option. Determines the number of " "pings sent to determine both machines in the networks. Each " "cycle lasts one sencond.", flags=Flags.Design) no_dns = Attribute( "noDns", "sets mtr --no-dns (-n) option. Forces mtr to display IPs intead of " "trying to resolve to host names ", type=Types.Bool, default=True, flags=Flags.Design) address = Attribute( "address", "sets mtr --address (-a) option. Binds the socket to send outgoing " "packets to the interface of the specified address, so that any " "any packets are sent through this interface. ", flags=Flags.Design) interval = Attribute( "interval", "sets mtr --interval (-i) option. Specifies the number of seconds " "between ICMP ECHO requests. Default value is one second ", flags=Flags.Design) countinuous = Attribute("continuous", "Run mtr in a while loop", type=Types.Bool, default=False, flags=Flags.Design) print_timestamp = Attribute("printTimestamp", "Print timestamp before running mtr", type=Types.Bool, default=False, flags=Flags.Design) target = Attribute("target", "mtr target host (host that will be pinged)", flags=Flags.Design) early_start = Attribute("earlyStart", "Start ping as early as deployment. ", type=Types.Bool, default=False, flags=Flags.Design) cls._register_attribute(report_cycles) cls._register_attribute(no_dns) cls._register_attribute(address) cls._register_attribute(interval) cls._register_attribute(countinuous) cls._register_attribute(print_timestamp) cls._register_attribute(target) cls._register_attribute(early_start)
def _register_attributes(cls): content_name = Attribute( "contentName", "Content name for the requested content object. ", flags=Flags.Design) cls._register_attribute(content_name)