MCPcopy Create free account
hub / github.com/python-openxml/python-docx / iter_sparts

Method iter_sparts

src/docx/opc/pkgreader.py:29–33  ·  view source on GitHub ↗

Generate a 4-tuple `(partname, content_type, reltype, blob)` for each of the serialized parts in the package.

(self)

Source from the content-addressed store, hash-verified

27 return PackageReader(content_types, pkg_srels, sparts)
28
29 def iter_sparts(self):
30 """Generate a 4-tuple `(partname, content_type, reltype, blob)` for each of the
31 serialized parts in the package."""
32 for s in self._sparts:
33 yield (s.partname, s.content_type, s.reltype, s.blob)
34
35 def iter_srels(self):
36 """Generate a 2-tuple `(source_uri, srel)` for each of the relationships in the

Calls

no outgoing calls