Version: (using KDE Devel) Installed from: Compiled sources I've tried to write extra information (xml tags of another namespace) in an Umbrello xmi file . The problem is that Umbrello simply remove them when updating the xmi file, so my extra information about traceability is lost Umbrello must preserve any extern information it finds in the xmi file.
Are you talking about <XMI.extensions> ? Please attach a sample file.
umbrello writes: <?xml version="1.0"?> <XMI xmlns:UML="http://...UML/1.3"> ... <UML Class name="new_class"/> ... </XMI> then I change it to: <?xml version="1.0"?> <XMI xmlns:UML="http://...UML/1.3" xmlns:rel="http://....."> ... <UML:Class name="new_class"> <rel:trace><rel:requirement href="1"/></rel:trace> </UML:Class> ... </XMI> umbrello destroy this manually (or 3rdparty program) added information.
Be aware that interspersing such extensions in the non <XMI.extensions> part violates the XMI standard and may entail loss of interoperability.
> <UML:Class name="new_class"> > <rel:trace><rel:requirement href="1"/></rel:trace> > </UML:Class> To be valid XMI, this should be <UML:Class name="new_class"> <XMI.extension xmi.extender="your_tool_name"> <rel:trace><rel:requirement href="1"/></rel:trace> </XMI.extension> </UML:Class> I don't know how umbrello deals with it, though. Also note it's called "XMI.extension" when inside an element, and "XMI.extensions" (note the extra "s") for the file-scope extension node.
I dont think so, XML specification allow mixture of languajes, through namespaces. so, a program which reads XMI should not be affected with element belonging to other namespaces.
> XML specification allow mixture of languages, through namespaces. XML yes but XMI no.
XMI is XML. XMI is an spec for information model transportation, that's why inside xmi.content can be storer elements from the namespace UML, and it can allocate other namespaces. xmi.extension should be used to extend the XMI spec, so, IMHO, elements that actually umbrello allocates inside xmi.extension, like those which characterizes a particular class, sould be written inside the <uml:class> element , example: <XMI.CONTENT> ... <uml:class ...> <umbrello:defaul_fill_color value="66"/> <!--(is an invented property)--> </uml:class> </XMI.CONTENT>
See comment #4 from Marcus Alanen - you need to embed your extension in the XMI.extension tag. I am not making this up - various XMI readers will fail or even crash if you don't.