Book a Demo

Author Topic: XMI import problem -- Invalid unicode  (Read 6017 times)

volcano_son

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
XMI import problem -- Invalid unicode
« 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.



Molto Mike

  • EA User
  • **
  • Posts: 66
  • Karma: +0/-0
    • View Profile
Re: XMI import problem -- Invalid unicode
« Reply #1 on: April 10, 2005, 11:36:36 pm »
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

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: XMI import problem -- Invalid unicode
« Reply #2 on: April 11, 2005, 03:39:39 pm »
I'm not an XMI expert, but I don't think running unix2dos should be necessary.

Simon

volcano_son

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: XMI import problem -- Invalid unicode
« Reply #3 on: April 12, 2005, 06:35:22 am »
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....

Tormentor

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: XMI import problem -- Invalid unicode
« Reply #4 on: April 14, 2005, 06:50:19 am »
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

thomaskilian

  • Guest
Re: XMI import problem -- Invalid unicode
« Reply #5 on: April 14, 2005, 08:12:15 am »
No chance. Likely Sparx support will have a look at this one...

VK

  • EA Administrator
  • EA User
  • *****
  • Posts: 50
  • Karma: +0/-0
    • View Profile
Re: XMI import problem -- Invalid unicode
« Reply #6 on: April 14, 2005, 06:11:05 pm »
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.

ljkish

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: XMI import problem -- Invalid unicode
« Reply #7 on: September 21, 2006, 02:01:10 am »
I am having a similar problem. Anyone get this resolved in regards to HL7's XMI file? Why the inline DTD must be removed?

thomaskilian

  • Guest
Re: XMI import problem -- Invalid unicode
« Reply #8 on: September 21, 2006, 02:12:47 pm »
If even the Sparxians don't know the answer, you won't get it elsewhere.