MCPcopy Create free account
hub / github.com/FDio/vpp / appendByteArray

Method appendByteArray

extras/packetforge/ProtocolHeader.py:295–308  ·  view source on GitHub ↗
(self, big, exp, size)

Source from the content-addressed store, hash-verified

293 return big
294
295 def appendByteArray(self, big, exp, size):
296 array = bytes(size >> 3)
297 if exp != None:
298 _, array = ExpressionConverter.ToByteArray(exp)
299 if not array:
300 print("Invalid byte array")
301 return False
302
303 for i in range(size >> 3):
304 big = big << 8
305 if i < len(array):
306 big = big | array[i]
307
308 return big
309
310 def append(self, big, phf):
311 bigVal = big["bigVal"]

Callers 1

appendMethod · 0.95

Calls 1

printFunction · 0.85

Tested by

no test coverage detected