You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@uima.apache.org by Neal Lewis <im...@gmail.com> on 2012/01/18 21:51:58 UTC
Adding Features as XML Elements instead of Attributes in CAS
Hello!
I see that in the UIMA reference it's possible to have Primitive Feature
Types as XML Elements instead of Attributes.
http://uima.apache.org/d/uimaj-2.4.0/references.html#ugr.ref.xmi.primitive_features
Does this become a part of the CAS XMI? And if so, how does one make the
switch from attributes to elements? Does it have to be a separate CAS
Consumer, or can make a change in the Type System Descriptor, or even the
Java Code for the Analysis Engine?
Thanks!
Neal
Re: Adding Features as XML Elements instead of Attributes in CAS
Posted by Neal Lewis <im...@gmail.com>.
Thanks! I understand now. I'll look into the deserializing library and just
write to file the way I would like to.
On Fri, Jan 20, 2012 at 8:09 AM, Adam Lally <al...@alum.rpi.edu> wrote:
> On Wed, Jan 18, 2012 at 3:51 PM, Neal Lewis <im...@gmail.com> wrote:
>
> > Hello!
> >
> > I see that in the UIMA reference it's possible to have Primitive Feature
> > Types as XML Elements instead of Attributes.
> >
> >
> >
> http://uima.apache.org/d/uimaj-2.4.0/references.html#ugr.ref.xmi.primitive_features
> >
> >
> > Does this become a part of the CAS XMI? And if so, how does one make the
> > switch from attributes to elements? Does it have to be a separate CAS
> > Consumer, or can make a change in the Type System Descriptor, or even the
> > Java Code for the Analysis Engine?
> >
> > Hi,
>
> UIMA's XMI Serializer always writes primitive features as attributes. The
> deserializer should be able to read either format. I think the meaning of
> that reference is to define that a valid XMI CAS could represent attributes
> in either way, but it was not meant to say that UIMA has the capability to
> produce it both ways.
>
> -Adam
>
Re: Adding Features as XML Elements instead of Attributes in CAS
Posted by Adam Lally <al...@alum.rpi.edu>.
On Wed, Jan 18, 2012 at 3:51 PM, Neal Lewis <im...@gmail.com> wrote:
> Hello!
>
> I see that in the UIMA reference it's possible to have Primitive Feature
> Types as XML Elements instead of Attributes.
>
>
> http://uima.apache.org/d/uimaj-2.4.0/references.html#ugr.ref.xmi.primitive_features
>
>
> Does this become a part of the CAS XMI? And if so, how does one make the
> switch from attributes to elements? Does it have to be a separate CAS
> Consumer, or can make a change in the Type System Descriptor, or even the
> Java Code for the Analysis Engine?
>
> Hi,
UIMA's XMI Serializer always writes primitive features as attributes. The
deserializer should be able to read either format. I think the meaning of
that reference is to define that a valid XMI CAS could represent attributes
in either way, but it was not meant to say that UIMA has the capability to
produce it both ways.
-Adam