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

Class _SerializedPart

src/docx/opc/pkgreader.py:130–164  ·  view source on GitHub ↗

Value object for an OPC package part. Provides access to the partname, content type, blob, and serialized relationships for the part.

Source from the content-addressed store, hash-verified

128
129
130class _SerializedPart:
131 """Value object for an OPC package part.
132
133 Provides access to the partname, content type, blob, and serialized relationships
134 for the part.
135 """
136
137 def __init__(self, partname, content_type, reltype, blob, srels):
138 super(_SerializedPart, self).__init__()
139 self._partname = partname
140 self._content_type = content_type
141 self._reltype = reltype
142 self._blob = blob
143 self._srels = srels
144
145 @property
146 def partname(self):
147 return self._partname
148
149 @property
150 def content_type(self):
151 return self._content_type
152
153 @property
154 def blob(self):
155 return self._blob
156
157 @property
158 def reltype(self):
159 """The referring relationship type of this part."""
160 return self._reltype
161
162 @property
163 def srels(self):
164 return self._srels
165
166
167class _SerializedRelationship:

Callers 2

Calls

no outgoing calls

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…