Sparx Systems Forum
Enterprise Architect => General Board => Topic started by: volcano_son on April 08, 2005, 12:24:28 pm
-
I am evaluating EA for ability to import XMI of an existing Eiffel codebase. I'm using EStudio on Linux, which allows me to generate an XMI description of an existing Eiffel codebase. I then 'unix2dos' the output file, move it to a Windows machine, and try to import it into EA. The file looks fine on the Windows side; first few lines are:
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE XMI (View Source for full doctype...)>
- <XMI xmi.version="1.0" xmlns:UML="omg.org/UML1.3">
- <XMI.header>
- <XMI.documentation>.....
But the import fails with this error:
Code = 0xc00ce51f
Source = Line : 1 ; Char : 5
Error description = Invalid unicode character
It doesn't like the 'l'? That seems strange. I don't think we even use unicode. Thanks in advance for any info that could be of help here.
-
Have you tried reading the XMI file with another XML parser? I am not sure it is the "l" (lower letter "L") that is confusing the parser:
In UTF-8 characters (so-called codepoints) are encoded in byte sequences with a length between 1 and 6 bytes. All ASCII characters (<128) are encoded with the same single byte value in UTF-8 (UTF-8 is ASCII compatible). The byte sequences are *not* subject to byte order of the used platform.
Using a tool like dos2unix might do s/th bad. Is the tool Unicode enabled or does it simply assume ASCII files and just switched the codes for CR/LF?
Could you maybe export a file in ASCII or latin-1 instead?
Just some thoughts,
Mike
-
I'm not an XMI expert, but I don't think running unix2dos should be necessary.
Simon
-
Thank you for the suggestions. I did same thing w/o unix2dos conversion, but the result was still the same import error.
The EStudio tool does not provide any output options for generating the XMI file, but I believe the file to be ok for two reasons:
1. EA can read the file just fine if I click the "View XMI" button on the Import window.
2. I tried another CASE tool and imported the same XMI file into the model w/o any problem.
Thanks again....
-
I get the same error on XMI import when trying to import the HL7 spec.
Can anyone successfully import the following file?
http://www.hl7.org/library/data-model/RIM/C30204/rim0204i.zip
Thanks
-
No chance. Likely Sparx support will have a look at this one...
-
Hi Tormentor ,
i downloaded the xml file from the link and imported it in EA.
EA does throw out an error, but when i removed the inline DTD definition from the xml file ( from lines 2 - 15 ), EA imported the file without complaining ( i am not sure why ).
if you need the definition, try adding it to 'uml.dtd' instead of extending it in the xml file.
Cheers.
-
I am having a similar problem. Anyone get this resolved in regards to HL7's XMI file? Why the inline DTD must be removed?
-
If even the Sparxians don't know the answer, you won't get it elsewhere.