To answer my own question. According to http://www.panoptic.com/wiki/aolserver/TDOM, it is possible to make XPath queries independent from the prefix in the source document by adding a namespace declaration node to the root with a prefix of your own choosing.
This could mean, that after parsing the manifest you could call
$manifest setAttributeNS "" xmlns:imscp "http://www.imsglobal.org/xsd/imscp_v1p1"
This could mean, that after parsing the manifest you could call
$manifest setAttributeNS "" xmlns:imscp "http://www.imsglobal.org/xsd/imscp_v1p1"
Whereever in the code where you have constructs like
set organizations [$manifest child all imscp:organizations]
if { ![llength $organizations] } {
set organizations [$manifest child all organizations]
}
you could more simply write
set organizations [$manifest selectNodes imscp:organizations]
What do you think?
Regards,