Lines Matching defs:pax_headers
867 pax_headers = ('A dictionary containing key-value pairs of an '
897 self.pax_headers = {} # pax header information
1026 pax_headers = self.pax_headers.copy()
1034 if hname in pax_headers:
1042 pax_headers[hname] = info[name]
1046 pax_headers[hname] = info[name]
1067 if needs_pax and name not in pax_headers:
1068 pax_headers[name] = str(val)
1071 if pax_headers:
1072 buf = self._create_pax_generic_header(pax_headers, XHDTYPE, encoding)
1079 def create_pax_global_header(cls, pax_headers):
1082 return cls._create_pax_generic_header(pax_headers, XGLTYPE, "utf-8")
1170 def _create_pax_generic_header(cls, pax_headers, type, encoding):
1178 for keyword, value in pax_headers.items():
1190 for keyword, value in pax_headers.items():
1330 self._apply_pax_info(tarfile.pax_headers, tarfile.encoding, tarfile.errors)
1405 pax_headers = tarfile.pax_headers
1407 pax_headers = tarfile.pax_headers.copy()
1478 pax_headers[keyword] = value
1487 if "GNU.sparse.map" in pax_headers:
1489 self._proc_gnusparse_01(next, pax_headers)
1491 elif "GNU.sparse.size" in pax_headers:
1495 elif pax_headers.get("GNU.sparse.major") == "1" and pax_headers.get("GNU.sparse.minor") == "0":
1497 self._proc_gnusparse_10(next, pax_headers, tarfile)
1501 next._apply_pax_info(pax_headers, tarfile.encoding, tarfile.errors)
1504 if "size" in pax_headers:
1535 def _proc_gnusparse_01(self, next, pax_headers):
1538 sparse = [int(x) for x in pax_headers["GNU.sparse.map"].split(",")]
1541 def _proc_gnusparse_10(self, next, pax_headers, tarfile):
1557 def _apply_pax_info(self, pax_headers, encoding, errors):
1561 for keyword, value in pax_headers.items():
1578 self.pax_headers = pax_headers.copy()
1667 errors="surrogateescape", pax_headers=None, debug=None,
1713 if pax_headers is not None and self.format == PAX_FORMAT:
1714 self.pax_headers = pax_headers
1716 self.pax_headers = {}
1755 if self.pax_headers:
1756 buf = self.tarinfo.create_pax_global_header(self.pax_headers.copy())