The merge process facilitates reuse of wizard components from local or network locations.
The merge process is the first step in loading TaskML into the Mechanical Wizard. The process involves selectively copying information from a merged TaskML document into a parent TaskML document. The parent document includes a Merge element linking to the merged file. The merge process generates a composite TaskML document in memory; neither the parent or merged TaskML files are modified.
The merge process consists of the following steps:
If the merged TaskML document contains Merge elements, this process is called recursively. That is, a TaskML document may merge a file that merges a file, and so on.
Script elements are copied to the parent only if the src attribute is unique.
object-group elements are copied to the parent only if the merged object-group has a unique name attribute.
status elements are copied to the parent only if the merged status has a unique id.
language collections (and contained string elements) are copied only if the language has a unique xml:lang attribute.
string elements are copied only if the merged string has a unique id.
task elements are copied only if the merged task has a unique id.
If both the parent and the merged TaskML documents contain a group with the same id:
Attributes defined for the merged group but omitted in the parent group are copied to the parent group.
All children of the merged group are appended to the parent group.
For diagnostic purposes the merge process automatically adds a merged-from attribute to elements added to the parent TaskML file. The merged-from attribute contains the url of the TaskML file from which the element was obtained.