org.docx4j.openpackaging

Object structure

The basic structure is that the Java Package object contains a collection of all its parts (excluding relationship parts).

The Package, and each Part, also stores its own relationship part (if a Part has one).

So for a Part to access a target part specified in its relationship part, it has to fetch that part from the Java Package object.

Loading and saving

The classes in org.docx4j.openpackaging walk the relationship part tree, loading or saving each target part.