MCPcopy Create free account
hub / github.com/NatLabRockies/windtools / read_int1

Method read_int1

windtools/io/binary.py:77–81  ·  view source on GitHub ↗
(self,N=1)

Source from the content-addressed store, hash-verified

75
76 # integer reads
77 def read_int1(self,N=1):
78 if N==1:
79 return self.unpack('b',self.f.read(1))[0] #short
80 else:
81 return self.unpack('{:d}b',self.f.read(N*1))[0:N] #short
82 def read_int2(self,N=1):
83 if N==1:
84 return self.unpack('h',self.f.read(2))[0] #short

Callers

nothing calls this directly

Calls 2

unpackMethod · 0.95
readMethod · 0.80

Tested by

no test coverage detected