This service provides the DOM and mapping to real InDesign elements and/or derived data from those elements (eg artwork). You'd normally implement one of these services only if you want to expand the preflight object model from what is supported natively. Having said that, this is still somewhat common because you may want to inspect and/or invalidate objects in the model in a way that isn't useful for a rule you want to implement.
In order to extend the model you need to:
- Indicate which object classes your service supports (GetMappedClasses)
- Indicate which objects your object is related to in the hierarchy (GetHierarchyClasses et al) (the preflight hierarchy, which may or may not match the natural document hierarchy)
- Expand (ie create child nodes for) your object classes when handed a parent you say your nodes are children of.
The preflight object model as a whole (ie IPreflightObjectModel) takes care of pulling together the composite response of all service providers and builds master trees of all of the relationships. All of the native objects are implemented using this same public interface.
- See Also
- IPreflightObjectModel
Given a class you say you provide hierarchy information for, indicate what classes are its children. Since multiple services may provide hierarchy for the same class, this isn't an exhaustive list; it's only the list you intend to expand.
Also, you only need to declare one side of the parent-child relationship. Eg if 'B' is a child of 'A' then A can declare B a child, or B can declare A a parent; but either one is sufficient. No harm is done by declaring them both.
- Note
- You should only list children that are one generation deep from the class; we want children and not all descendents (the object model compiles that list automatically).
- Parameters
| parentClass | IN The class ID of interest. |
- Returns
- The vector of child class IDs.
Given a class you say you provide hierarchy information for, indicate what classes are its parents. Since multiple services may provide hierarchy for the same class, this isn't an exhaustive list; it's only the list you intend to expand.
Also, you only need to declare one side of the parent-child relationship. Eg if 'B' is a child of 'A' then A can declare B a child, or B can declare A a parent; but either one is sufficient. No harm is done by declaring them both.
- Note
- You should only list parents that are one generation deep from the class; we want parents and not all ancestors (the object model compiles that list automatically).
- Parameters
| parentClass | IN The class ID of interest. |
- Returns
- The vector of child class IDs.