+#
+# This class is automatically generated by mig. DO NOT EDIT THIS FILE.
+# This class implements a Python interface to the 'UdpReport'
+# message type.
+#
+
+import tinyos.message.Message
+
+# The default size of this message type in bytes.
+DEFAULT_MESSAGE_SIZE = 32
+
+# The Active Message type associated with this message.
+AM_TYPE = -1
+
+class UdpReport(tinyos.message.Message.Message):
+ # Create a new UdpReport of size 32.
+ def __init__(self, data="", addr=None, gid=None, base_offset=0, data_length=32):
+ tinyos.message.Message.Message.__init__(self, data, addr, gid, base_offset, data_length)
+ self.amTypeSet(AM_TYPE)
+
+ # Get AM_TYPE
+ def get_amType(cls):
+ return AM_TYPE
+
+ get_amType = classmethod(get_amType)
+
+ #
+ # Return a String representation of this message. Includes the
+ # message type name and the non-indexed field values.
+ #
+ def __str__(self):
+ s = "Message <UdpReport> \n"
+ try:
+ s += " [udp.total=0x%x]\n" % (self.get_udp_total())
+ except:
+ pass
+ try:
+ s += " [udp.failed=0x%x]\n" % (self.get_udp_failed())
+ except:
+ pass
+ try:
+ s += " [udp.seqno=0x%x]\n" % (self.get_udp_seqno())
+ except:
+ pass
+ try:
+ s += " [udp.sender=0x%x]\n" % (self.get_udp_sender())
+ except:
+ pass
+ try:
+ s += " [icmp.rx=0x%x]\n" % (self.get_icmp_rx())
+ except:
+ pass
+ try:
+ s += " [route.parent.flags=0x%x]\n" % (self.get_route_parent_flags())
+ except:
+ pass
+ try:
+ s += " [route.parent.hops=0x%x]\n" % (self.get_route_parent_hops())
+ except:
+ pass
+ try:
+ s += " [route.parent.neighbor=0x%x]\n" % (self.get_route_parent_neighbor())
+ except:
+ pass
+ try:
+ s += " [route.parent.costEstimate=0x%x]\n" % (self.get_route_parent_costEstimate())
+ except:
+ pass
+ try:
+ s += " [route.parent.linkEstimate=0x%x]\n" % (self.get_route_parent_linkEstimate())
+ except:
+ pass
+ try:
+ s += " [route.parent.rssiEstimate=0x%x]\n" % (self.get_route_parent_rssiEstimate())
+ except:
+ pass
+ try:
+ s += " [route.parent.stats.success=";
+ for i in range(0, 2):
+ s += "0x%x " % (self.getElement_route_parent_stats_success(i) & 0xff)
+ s += "]\n";
+ except:
+ pass
+ try:
+ s += " [route.parent.stats.total=";
+ for i in range(0, 2):
+ s += "0x%x " % (self.getElement_route_parent_stats_total(i) & 0xff)
+ s += "]\n";
+ except:
+ pass
+ try:
+ s += " [route.parent.stats.receptions=";
+ for i in range(0, 2):
+ s += "0x%x " % (self.getElement_route_parent_stats_receptions(i) & 0xff)
+ s += "]\n";
+ except:
+ pass
+ return s
+
+ # Message-type-specific access methods appear below.
+
+ #
+ # Accessor methods for field: udp.total
+ # Field type: int
+ # Offset (bits): 0
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'udp.total' is signed (False).
+ #
+ def isSigned_udp_total(self):
+ return False
+
+ #
+ # Return whether the field 'udp.total' is an array (False).
+ #
+ def isArray_udp_total(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'udp.total'
+ #
+ def offset_udp_total(self):
+ return (0 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'udp.total'
+ #
+ def offsetBits_udp_total(self):
+ return 0
+
+ #
+ # Return the value (as a int) of the field 'udp.total'
+ #
+ def get_udp_total(self):
+ return self.getUIntElement(self.offsetBits_udp_total(), 16, 1)
+
+ #
+ # Set the value of the field 'udp.total'
+ #
+ def set_udp_total(self, value):
+ self.setUIntElement(self.offsetBits_udp_total(), 16, value, 1)
+
+ #
+ # Return the size, in bytes, of the field 'udp.total'
+ #
+ def size_udp_total(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'udp.total'
+ #
+ def sizeBits_udp_total(self):
+ return 16
+
+ #
+ # Accessor methods for field: udp.failed
+ # Field type: int
+ # Offset (bits): 16
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'udp.failed' is signed (False).
+ #
+ def isSigned_udp_failed(self):
+ return False
+
+ #
+ # Return whether the field 'udp.failed' is an array (False).
+ #
+ def isArray_udp_failed(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'udp.failed'
+ #
+ def offset_udp_failed(self):
+ return (16 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'udp.failed'
+ #
+ def offsetBits_udp_failed(self):
+ return 16
+
+ #
+ # Return the value (as a int) of the field 'udp.failed'
+ #
+ def get_udp_failed(self):
+ return self.getUIntElement(self.offsetBits_udp_failed(), 16, 1)
+
+ #
+ # Set the value of the field 'udp.failed'
+ #
+ def set_udp_failed(self, value):
+ self.setUIntElement(self.offsetBits_udp_failed(), 16, value, 1)
+
+ #
+ # Return the size, in bytes, of the field 'udp.failed'
+ #
+ def size_udp_failed(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'udp.failed'
+ #
+ def sizeBits_udp_failed(self):
+ return 16
+
+ #
+ # Accessor methods for field: udp.seqno
+ # Field type: int
+ # Offset (bits): 32
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'udp.seqno' is signed (False).
+ #
+ def isSigned_udp_seqno(self):
+ return False
+
+ #
+ # Return whether the field 'udp.seqno' is an array (False).
+ #
+ def isArray_udp_seqno(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'udp.seqno'
+ #
+ def offset_udp_seqno(self):
+ return (32 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'udp.seqno'
+ #
+ def offsetBits_udp_seqno(self):
+ return 32
+
+ #
+ # Return the value (as a int) of the field 'udp.seqno'
+ #
+ def get_udp_seqno(self):
+ return self.getUIntElement(self.offsetBits_udp_seqno(), 16, 1)
+
+ #
+ # Set the value of the field 'udp.seqno'
+ #
+ def set_udp_seqno(self, value):
+ self.setUIntElement(self.offsetBits_udp_seqno(), 16, value, 1)
+
+ #
+ # Return the size, in bytes, of the field 'udp.seqno'
+ #
+ def size_udp_seqno(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'udp.seqno'
+ #
+ def sizeBits_udp_seqno(self):
+ return 16
+
+ #
+ # Accessor methods for field: udp.sender
+ # Field type: int
+ # Offset (bits): 48
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'udp.sender' is signed (False).
+ #
+ def isSigned_udp_sender(self):
+ return False
+
+ #
+ # Return whether the field 'udp.sender' is an array (False).
+ #
+ def isArray_udp_sender(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'udp.sender'
+ #
+ def offset_udp_sender(self):
+ return (48 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'udp.sender'
+ #
+ def offsetBits_udp_sender(self):
+ return 48
+
+ #
+ # Return the value (as a int) of the field 'udp.sender'
+ #
+ def get_udp_sender(self):
+ return self.getUIntElement(self.offsetBits_udp_sender(), 16, 1)
+
+ #
+ # Set the value of the field 'udp.sender'
+ #
+ def set_udp_sender(self, value):
+ self.setUIntElement(self.offsetBits_udp_sender(), 16, value, 1)
+
+ #
+ # Return the size, in bytes, of the field 'udp.sender'
+ #
+ def size_udp_sender(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'udp.sender'
+ #
+ def sizeBits_udp_sender(self):
+ return 16
+
+ #
+ # Accessor methods for field: icmp.rx
+ # Field type: int
+ # Offset (bits): 64
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'icmp.rx' is signed (False).
+ #
+ def isSigned_icmp_rx(self):
+ return False
+
+ #
+ # Return whether the field 'icmp.rx' is an array (False).
+ #
+ def isArray_icmp_rx(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'icmp.rx'
+ #
+ def offset_icmp_rx(self):
+ return (64 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'icmp.rx'
+ #
+ def offsetBits_icmp_rx(self):
+ return 64
+
+ #
+ # Return the value (as a int) of the field 'icmp.rx'
+ #
+ def get_icmp_rx(self):
+ return self.getUIntElement(self.offsetBits_icmp_rx(), 16, 1)
+
+ #
+ # Set the value of the field 'icmp.rx'
+ #
+ def set_icmp_rx(self, value):
+ self.setUIntElement(self.offsetBits_icmp_rx(), 16, value, 1)
+
+ #
+ # Return the size, in bytes, of the field 'icmp.rx'
+ #
+ def size_icmp_rx(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'icmp.rx'
+ #
+ def sizeBits_icmp_rx(self):
+ return 16
+
+ #
+ # Accessor methods for field: route.parent.flags
+ # Field type: short
+ # Offset (bits): 80
+ # Size (bits): 8
+ #
+
+ #
+ # Return whether the field 'route.parent.flags' is signed (False).
+ #
+ def isSigned_route_parent_flags(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.flags' is an array (False).
+ #
+ def isArray_route_parent_flags(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.flags'
+ #
+ def offset_route_parent_flags(self):
+ return (80 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.flags'
+ #
+ def offsetBits_route_parent_flags(self):
+ return 80
+
+ #
+ # Return the value (as a short) of the field 'route.parent.flags'
+ #
+ def get_route_parent_flags(self):
+ return self.getUIntElement(self.offsetBits_route_parent_flags(), 8, 0)
+
+ #
+ # Set the value of the field 'route.parent.flags'
+ #
+ def set_route_parent_flags(self, value):
+ self.setUIntElement(self.offsetBits_route_parent_flags(), 8, value, 0)
+
+ #
+ # Return the size, in bytes, of the field 'route.parent.flags'
+ #
+ def size_route_parent_flags(self):
+ return (8 / 8)
+
+ #
+ # Return the size, in bits, of the field 'route.parent.flags'
+ #
+ def sizeBits_route_parent_flags(self):
+ return 8
+
+ #
+ # Accessor methods for field: route.parent.hops
+ # Field type: short
+ # Offset (bits): 88
+ # Size (bits): 8
+ #
+
+ #
+ # Return whether the field 'route.parent.hops' is signed (False).
+ #
+ def isSigned_route_parent_hops(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.hops' is an array (False).
+ #
+ def isArray_route_parent_hops(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.hops'
+ #
+ def offset_route_parent_hops(self):
+ return (88 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.hops'
+ #
+ def offsetBits_route_parent_hops(self):
+ return 88
+
+ #
+ # Return the value (as a short) of the field 'route.parent.hops'
+ #
+ def get_route_parent_hops(self):
+ return self.getUIntElement(self.offsetBits_route_parent_hops(), 8, 0)
+
+ #
+ # Set the value of the field 'route.parent.hops'
+ #
+ def set_route_parent_hops(self, value):
+ self.setUIntElement(self.offsetBits_route_parent_hops(), 8, value, 0)
+
+ #
+ # Return the size, in bytes, of the field 'route.parent.hops'
+ #
+ def size_route_parent_hops(self):
+ return (8 / 8)
+
+ #
+ # Return the size, in bits, of the field 'route.parent.hops'
+ #
+ def sizeBits_route_parent_hops(self):
+ return 8
+
+ #
+ # Accessor methods for field: route.parent.neighbor
+ # Field type: int
+ # Offset (bits): 96
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'route.parent.neighbor' is signed (False).
+ #
+ def isSigned_route_parent_neighbor(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.neighbor' is an array (False).
+ #
+ def isArray_route_parent_neighbor(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.neighbor'
+ #
+ def offset_route_parent_neighbor(self):
+ return (96 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.neighbor'
+ #
+ def offsetBits_route_parent_neighbor(self):
+ return 96
+
+ #
+ # Return the value (as a int) of the field 'route.parent.neighbor'
+ #
+ def get_route_parent_neighbor(self):
+ return self.getUIntElement(self.offsetBits_route_parent_neighbor(), 16, 0)
+
+ #
+ # Set the value of the field 'route.parent.neighbor'
+ #
+ def set_route_parent_neighbor(self, value):
+ self.setUIntElement(self.offsetBits_route_parent_neighbor(), 16, value, 0)
+
+ #
+ # Return the size, in bytes, of the field 'route.parent.neighbor'
+ #
+ def size_route_parent_neighbor(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'route.parent.neighbor'
+ #
+ def sizeBits_route_parent_neighbor(self):
+ return 16
+
+ #
+ # Accessor methods for field: route.parent.costEstimate
+ # Field type: int
+ # Offset (bits): 112
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'route.parent.costEstimate' is signed (False).
+ #
+ def isSigned_route_parent_costEstimate(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.costEstimate' is an array (False).
+ #
+ def isArray_route_parent_costEstimate(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.costEstimate'
+ #
+ def offset_route_parent_costEstimate(self):
+ return (112 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.costEstimate'
+ #
+ def offsetBits_route_parent_costEstimate(self):
+ return 112
+
+ #
+ # Return the value (as a int) of the field 'route.parent.costEstimate'
+ #
+ def get_route_parent_costEstimate(self):
+ return self.getUIntElement(self.offsetBits_route_parent_costEstimate(), 16, 0)
+
+ #
+ # Set the value of the field 'route.parent.costEstimate'
+ #
+ def set_route_parent_costEstimate(self, value):
+ self.setUIntElement(self.offsetBits_route_parent_costEstimate(), 16, value, 0)
+
+ #
+ # Return the size, in bytes, of the field 'route.parent.costEstimate'
+ #
+ def size_route_parent_costEstimate(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'route.parent.costEstimate'
+ #
+ def sizeBits_route_parent_costEstimate(self):
+ return 16
+
+ #
+ # Accessor methods for field: route.parent.linkEstimate
+ # Field type: int
+ # Offset (bits): 128
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'route.parent.linkEstimate' is signed (False).
+ #
+ def isSigned_route_parent_linkEstimate(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.linkEstimate' is an array (False).
+ #
+ def isArray_route_parent_linkEstimate(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.linkEstimate'
+ #
+ def offset_route_parent_linkEstimate(self):
+ return (128 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.linkEstimate'
+ #
+ def offsetBits_route_parent_linkEstimate(self):
+ return 128
+
+ #
+ # Return the value (as a int) of the field 'route.parent.linkEstimate'
+ #
+ def get_route_parent_linkEstimate(self):
+ return self.getUIntElement(self.offsetBits_route_parent_linkEstimate(), 16, 0)
+
+ #
+ # Set the value of the field 'route.parent.linkEstimate'
+ #
+ def set_route_parent_linkEstimate(self, value):
+ self.setUIntElement(self.offsetBits_route_parent_linkEstimate(), 16, value, 0)
+
+ #
+ # Return the size, in bytes, of the field 'route.parent.linkEstimate'
+ #
+ def size_route_parent_linkEstimate(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'route.parent.linkEstimate'
+ #
+ def sizeBits_route_parent_linkEstimate(self):
+ return 16
+
+ #
+ # Accessor methods for field: route.parent.rssiEstimate
+ # Field type: int
+ # Offset (bits): 144
+ # Size (bits): 16
+ #
+
+ #
+ # Return whether the field 'route.parent.rssiEstimate' is signed (False).
+ #
+ def isSigned_route_parent_rssiEstimate(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.rssiEstimate' is an array (False).
+ #
+ def isArray_route_parent_rssiEstimate(self):
+ return False
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.rssiEstimate'
+ #
+ def offset_route_parent_rssiEstimate(self):
+ return (144 / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.rssiEstimate'
+ #
+ def offsetBits_route_parent_rssiEstimate(self):
+ return 144
+
+ #
+ # Return the value (as a int) of the field 'route.parent.rssiEstimate'
+ #
+ def get_route_parent_rssiEstimate(self):
+ return self.getUIntElement(self.offsetBits_route_parent_rssiEstimate(), 16, 0)
+
+ #
+ # Set the value of the field 'route.parent.rssiEstimate'
+ #
+ def set_route_parent_rssiEstimate(self, value):
+ self.setUIntElement(self.offsetBits_route_parent_rssiEstimate(), 16, value, 0)
+
+ #
+ # Return the size, in bytes, of the field 'route.parent.rssiEstimate'
+ #
+ def size_route_parent_rssiEstimate(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of the field 'route.parent.rssiEstimate'
+ #
+ def sizeBits_route_parent_rssiEstimate(self):
+ return 16
+
+ #
+ # Accessor methods for field: route.parent.stats.success
+ # Field type: int[]
+ # Offset (bits): 0
+ # Size of each element (bits): 16
+ #
+
+ #
+ # Return whether the field 'route.parent.stats.success' is signed (False).
+ #
+ def isSigned_route_parent_stats_success(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.stats.success' is an array (True).
+ #
+ def isArray_route_parent_stats_success(self):
+ return True
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.stats.success'
+ #
+ def offset_route_parent_stats_success(self, index1):
+ offset = 0
+ if index1 < 0 or index1 >= 2:
+ raise IndexError
+ offset += 160 + index1 * 48
+ return (offset / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.stats.success'
+ #
+ def offsetBits_route_parent_stats_success(self, index1):
+ offset = 0
+ if index1 < 0 or index1 >= 2:
+ raise IndexError
+ offset += 160 + index1 * 48
+ return offset
+
+ #
+ # Return the entire array 'route.parent.stats.success' as a int[]
+ #
+ def get_route_parent_stats_success(self):
+ tmp = [None]*2
+ for index0 in range (0, self.numElements_route_parent_stats_success(0)):
+ tmp[index0] = self.getElement_route_parent_stats_success(index0)
+ return tmp
+
+ #
+ # Set the contents of the array 'route.parent.stats.success' from the given int[]
+ #
+ def set_route_parent_stats_success(self, value):
+ for index0 in range(0, len(value)):
+ self.setElement_route_parent_stats_success(index0, value[index0])
+
+ #
+ # Return an element (as a int) of the array 'route.parent.stats.success'
+ #
+ def getElement_route_parent_stats_success(self, index1):
+ return self.getUIntElement(self.offsetBits_route_parent_stats_success(index1), 16, 0)
+
+ #
+ # Set an element of the array 'route.parent.stats.success'
+ #
+ def setElement_route_parent_stats_success(self, index1, value):
+ self.setUIntElement(self.offsetBits_route_parent_stats_success(index1), 16, value, 0)
+
+ #
+ # Return the total size, in bytes, of the array 'route.parent.stats.success'
+ #
+ def totalSize_route_parent_stats_success(self):
+ return (96 / 8)
+
+ #
+ # Return the total size, in bits, of the array 'route.parent.stats.success'
+ #
+ def totalSizeBits_route_parent_stats_success(self):
+ return 96
+
+ #
+ # Return the size, in bytes, of each element of the array 'route.parent.stats.success'
+ #
+ def elementSize_route_parent_stats_success(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of each element of the array 'route.parent.stats.success'
+ #
+ def elementSizeBits_route_parent_stats_success(self):
+ return 16
+
+ #
+ # Return the number of dimensions in the array 'route.parent.stats.success'
+ #
+ def numDimensions_route_parent_stats_success(self):
+ return 1
+
+ #
+ # Return the number of elements in the array 'route.parent.stats.success'
+ #
+ def numElements_route_parent_stats_success():
+ return 2
+
+ #
+ # Return the number of elements in the array 'route.parent.stats.success'
+ # for the given dimension.
+ #
+ def numElements_route_parent_stats_success(self, dimension):
+ array_dims = [ 2, ]
+ if dimension < 0 or dimension >= 1:
+ raise IndexException
+ if array_dims[dimension] == 0:
+ raise IndexError
+ return array_dims[dimension]
+
+ #
+ # Accessor methods for field: route.parent.stats.total
+ # Field type: int[]
+ # Offset (bits): 16
+ # Size of each element (bits): 16
+ #
+
+ #
+ # Return whether the field 'route.parent.stats.total' is signed (False).
+ #
+ def isSigned_route_parent_stats_total(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.stats.total' is an array (True).
+ #
+ def isArray_route_parent_stats_total(self):
+ return True
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.stats.total'
+ #
+ def offset_route_parent_stats_total(self, index1):
+ offset = 16
+ if index1 < 0 or index1 >= 2:
+ raise IndexError
+ offset += 160 + index1 * 48
+ return (offset / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.stats.total'
+ #
+ def offsetBits_route_parent_stats_total(self, index1):
+ offset = 16
+ if index1 < 0 or index1 >= 2:
+ raise IndexError
+ offset += 160 + index1 * 48
+ return offset
+
+ #
+ # Return the entire array 'route.parent.stats.total' as a int[]
+ #
+ def get_route_parent_stats_total(self):
+ tmp = [None]*2
+ for index0 in range (0, self.numElements_route_parent_stats_total(0)):
+ tmp[index0] = self.getElement_route_parent_stats_total(index0)
+ return tmp
+
+ #
+ # Set the contents of the array 'route.parent.stats.total' from the given int[]
+ #
+ def set_route_parent_stats_total(self, value):
+ for index0 in range(0, len(value)):
+ self.setElement_route_parent_stats_total(index0, value[index0])
+
+ #
+ # Return an element (as a int) of the array 'route.parent.stats.total'
+ #
+ def getElement_route_parent_stats_total(self, index1):
+ return self.getUIntElement(self.offsetBits_route_parent_stats_total(index1), 16, 0)
+
+ #
+ # Set an element of the array 'route.parent.stats.total'
+ #
+ def setElement_route_parent_stats_total(self, index1, value):
+ self.setUIntElement(self.offsetBits_route_parent_stats_total(index1), 16, value, 0)
+
+ #
+ # Return the total size, in bytes, of the array 'route.parent.stats.total'
+ #
+ def totalSize_route_parent_stats_total(self):
+ return (96 / 8)
+
+ #
+ # Return the total size, in bits, of the array 'route.parent.stats.total'
+ #
+ def totalSizeBits_route_parent_stats_total(self):
+ return 96
+
+ #
+ # Return the size, in bytes, of each element of the array 'route.parent.stats.total'
+ #
+ def elementSize_route_parent_stats_total(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of each element of the array 'route.parent.stats.total'
+ #
+ def elementSizeBits_route_parent_stats_total(self):
+ return 16
+
+ #
+ # Return the number of dimensions in the array 'route.parent.stats.total'
+ #
+ def numDimensions_route_parent_stats_total(self):
+ return 1
+
+ #
+ # Return the number of elements in the array 'route.parent.stats.total'
+ #
+ def numElements_route_parent_stats_total():
+ return 2
+
+ #
+ # Return the number of elements in the array 'route.parent.stats.total'
+ # for the given dimension.
+ #
+ def numElements_route_parent_stats_total(self, dimension):
+ array_dims = [ 2, ]
+ if dimension < 0 or dimension >= 1:
+ raise IndexException
+ if array_dims[dimension] == 0:
+ raise IndexError
+ return array_dims[dimension]
+
+ #
+ # Accessor methods for field: route.parent.stats.receptions
+ # Field type: int[]
+ # Offset (bits): 32
+ # Size of each element (bits): 16
+ #
+
+ #
+ # Return whether the field 'route.parent.stats.receptions' is signed (False).
+ #
+ def isSigned_route_parent_stats_receptions(self):
+ return False
+
+ #
+ # Return whether the field 'route.parent.stats.receptions' is an array (True).
+ #
+ def isArray_route_parent_stats_receptions(self):
+ return True
+
+ #
+ # Return the offset (in bytes) of the field 'route.parent.stats.receptions'
+ #
+ def offset_route_parent_stats_receptions(self, index1):
+ offset = 32
+ if index1 < 0 or index1 >= 2:
+ raise IndexError
+ offset += 160 + index1 * 48
+ return (offset / 8)
+
+ #
+ # Return the offset (in bits) of the field 'route.parent.stats.receptions'
+ #
+ def offsetBits_route_parent_stats_receptions(self, index1):
+ offset = 32
+ if index1 < 0 or index1 >= 2:
+ raise IndexError
+ offset += 160 + index1 * 48
+ return offset
+
+ #
+ # Return the entire array 'route.parent.stats.receptions' as a int[]
+ #
+ def get_route_parent_stats_receptions(self):
+ tmp = [None]*2
+ for index0 in range (0, self.numElements_route_parent_stats_receptions(0)):
+ tmp[index0] = self.getElement_route_parent_stats_receptions(index0)
+ return tmp
+
+ #
+ # Set the contents of the array 'route.parent.stats.receptions' from the given int[]
+ #
+ def set_route_parent_stats_receptions(self, value):
+ for index0 in range(0, len(value)):
+ self.setElement_route_parent_stats_receptions(index0, value[index0])
+
+ #
+ # Return an element (as a int) of the array 'route.parent.stats.receptions'
+ #
+ def getElement_route_parent_stats_receptions(self, index1):
+ return self.getUIntElement(self.offsetBits_route_parent_stats_receptions(index1), 16, 0)
+
+ #
+ # Set an element of the array 'route.parent.stats.receptions'
+ #
+ def setElement_route_parent_stats_receptions(self, index1, value):
+ self.setUIntElement(self.offsetBits_route_parent_stats_receptions(index1), 16, value, 0)
+
+ #
+ # Return the total size, in bytes, of the array 'route.parent.stats.receptions'
+ #
+ def totalSize_route_parent_stats_receptions(self):
+ return (96 / 8)
+
+ #
+ # Return the total size, in bits, of the array 'route.parent.stats.receptions'
+ #
+ def totalSizeBits_route_parent_stats_receptions(self):
+ return 96
+
+ #
+ # Return the size, in bytes, of each element of the array 'route.parent.stats.receptions'
+ #
+ def elementSize_route_parent_stats_receptions(self):
+ return (16 / 8)
+
+ #
+ # Return the size, in bits, of each element of the array 'route.parent.stats.receptions'
+ #
+ def elementSizeBits_route_parent_stats_receptions(self):
+ return 16
+
+ #
+ # Return the number of dimensions in the array 'route.parent.stats.receptions'
+ #
+ def numDimensions_route_parent_stats_receptions(self):
+ return 1
+
+ #
+ # Return the number of elements in the array 'route.parent.stats.receptions'
+ #
+ def numElements_route_parent_stats_receptions():
+ return 2
+
+ #
+ # Return the number of elements in the array 'route.parent.stats.receptions'
+ # for the given dimension.
+ #
+ def numElements_route_parent_stats_receptions(self, dimension):
+ array_dims = [ 2, ]
+ if dimension < 0 or dimension >= 1:
+ raise IndexException
+ if array_dims[dimension] == 0:
+ raise IndexError
+ return array_dims[dimension]
+