Searched refs:package_file (Results 1 – 5 of 5) sorted by relevance
105 def write_pkginfo(self, package_file): argument132 package_file.write(pkginfo)139 def write_component_info(self, component, package_file): argument148 package_file.seek(self.compinfo_offset)149 package_file.write(component.component_addr)152 package_file.seek(self.compinfo_offset)156 package_file.write(component_info)159 package_file.seek(self.compinfo_offset)160 package_file.write(component.version)163 package_file.seek(self.compinfo_offset)[all …]
92 def parse_package_file(self, package_file): argument94 package_file.seek(COMPINFO_LEN_OFFSET)95 compinfo_len_buffer = package_file.read(COMPINFO_LEN_SIZE)108 def parse_component(self, package_file): argument110 package_file.seek(self.addr_offset)111 component_addr = package_file.read(self.addr_size)114 package_file.seek(self.type_offset)115 component_type_buffer = package_file.read(COMPONENT_TYPE_SIZE)118 package_file.seek(self.size_offset)119 component_size_buffer = package_file.read(COMPONENT_SIZE_SIZE)[all …]
64 with open(package_path, 'rb') as package_file:66 hash_sha256.update(package_file.read(BLOCK_SIZE))69 hash_sha256.update(package_file.read(remain_len))
230 with open(package_path, 'rb') as package_file:232 hash_sha256.update(package_file.read(BLCOK_SIZE))235 hash_sha256.update(package_file.read(remain_len))
506 with open(update_package, 'rb') as package_file:508 buf = package_file.read(maxbuf)