Note that the this documentation is for the old 5.0 release.
For the newest documentation, please see the current release documentation.

XML handling by Deploy

The deploy program needs to create an xml settings for each application. The creation of these files involves manipulating xml datastructures, creating new xml instances based on previous ones and saving the result to a file.These manipulations are carried out in the class (dk.netarkivet.deploy.XmlStructure) which uses the com.dom4j structure for handling the xml datastructure.

The dk.netarkivet.deploy.XmlStructure class has the ability to inherit and overwrite, which is used in the deploy configuration structure. The abilty to inherit is implemented as creating a new instance identical to a current instance, thus inheritance can only occur during creation of a new instance of this class.

The overwrite function merges the current XmlStructure with a new tree. This means that the for leafs which are present in both new tree and the current one, the value in the current leaf will be overwritten by the leaf on the new tree. Branches which only exist in the new tree will be appended to the current tree. The branches in both trees are then recursively overwritten

 

Â