You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@uima.apache.org by Greg Holmberg <ho...@comcast.net> on 2010/01/29 19:44:31 UTC

XMI XML XSD?

I know that the XMI schema is not defined by UIMA, but does anyone happen  
to know of an XML schema definition (.xsd) file for XMI?  It might make  
parsing XMI XML easier.

Thanks,

Greg Holmberg

Re: XMI XML XSD?

Posted by Adam Lally <al...@alum.rpi.edu>.
On Fri, Jan 29, 2010 at 5:25 PM, Greg Holmberg <ho...@comcast.net> wrote:
>> There is an XSD, but it's extremely open ended because the element and
>> attribute names that an XMI file uses are determined by the user's
>> model (i.e., the type system) and not by the XMI specification.
>>
>> Here's the link http://www.omg.org/spec/XMI/20071213/XMI.xsd
>
> Thanks, Adam.  I see what you mean by open-ended.
>
> Looking at the XMI produced by UIMA for my type system, I see that elements
> in the xmi namespace are a minority.  There are also elements in name spaces
> "cas", "tcas", and one derived from my type system.
>
> So to produce an XSD that described everything in the file, I would need to
> add definitions for all those.  The schema of the cas and tcas are fixed,
> however the schemas derived from the type systems deployed would have to be
> dynamically generated.  I suppose XmiCasSerializer should have all the
> information it needs to do that...
>

It is possible to produce such an XSD using EMF.  If you use the
utilities that come with UIMA to convert your type system to an Ecore
model, then you can load that into EMF and ask it to generate an XMI
XSD for you.  I did that once before, but my memory is a bit hazy.  It
was a bit of learning curve to figure out how to get EMF to do that, I
think.

 -Adam

Re: XMI XML XSD?

Posted by Greg Holmberg <ho...@comcast.net>.
> There is an XSD, but it's extremely open ended because the element and
> attribute names that an XMI file uses are determined by the user's
> model (i.e., the type system) and not by the XMI specification.
>
> Here's the link http://www.omg.org/spec/XMI/20071213/XMI.xsd

Thanks, Adam.  I see what you mean by open-ended.

Looking at the XMI produced by UIMA for my type system, I see that  
elements in the xmi namespace are a minority.  There are also elements in  
name spaces "cas", "tcas", and one derived from my type system.

So to produce an XSD that described everything in the file, I would need  
to add definitions for all those.  The schema of the cas and tcas are  
fixed, however the schemas derived from the type systems deployed would  
have to be dynamically generated.  I suppose XmiCasSerializer should have  
all the information it needs to do that...

Greg Holmberg

Re: XMI XML XSD?

Posted by Adam Lally <al...@alum.rpi.edu>.
There is an XSD, but it's extremely open ended because the element and
attribute names that an XMI file uses are determined by the user's
model (i.e., the type system) and not by the XMI specification.

Here's the link http://www.omg.org/spec/XMI/20071213/XMI.xsd

 -Adam


On Fri, Jan 29, 2010 at 1:44 PM, Greg Holmberg <ho...@comcast.net> wrote:
> I know that the XMI schema is not defined by UIMA, but does anyone happen to
> know of an XML schema definition (.xsd) file for XMI?  It might make parsing
> XMI XML easier.
>
> Thanks,
>
> Greg Holmberg
>