MCPcopy Index your code
hub / github.com/python-openxml/python-docx / unmarshal

Method unmarshal

src/docx/opc/package.py:186–196  ·  view source on GitHub ↗

Construct graph of parts and realized relationships based on the contents of `pkg_reader`, delegating construction of each part to `part_factory`. Package relationships are added to `pkg`.

(pkg_reader, package, part_factory)

Source from the content-addressed store, hash-verified

184
185 @staticmethod
186 def unmarshal(pkg_reader, package, part_factory):
187 """Construct graph of parts and realized relationships based on the contents of
188 `pkg_reader`, delegating construction of each part to `part_factory`.
189
190 Package relationships are added to `pkg`.
191 """
192 parts = Unmarshaller._unmarshal_parts(pkg_reader, package, part_factory)
193 Unmarshaller._unmarshal_relationships(pkg_reader, package, parts)
194 for part in parts.values():
195 part.after_unmarshal()
196 package.after_unmarshal()
197
198 @staticmethod
199 def _unmarshal_parts(pkg_reader, package, part_factory):

Callers 2

openMethod · 0.80

Calls 3

_unmarshal_partsMethod · 0.80
after_unmarshalMethod · 0.45

Tested by 1