You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@uima.apache.org by hannes schantl <jo...@gmail.com> on 2014/05/05 11:25:56 UTC
creating new annotation
Hello,
I have following problem: I dont know how to add a new annotation to the
CAS when the type of the annotation is only available as a string, e.g.
com.test.AnnotationType1.
Does anyone know how to solve this issue?
Thanks a lot,
Greetings Hannes
Re: creating new annotation
Posted by hannes schantl <jo...@gmail.com>.
thank u, that solved it.
greetings
2014-05-05 11:41 GMT+02:00 Richard Eckart de Castilho <re...@apache.org>:
> Like this:
>
> Type type = cas.getTypeSystem().getType("com.test.AnnotationType1)";
> AnnotationFS annotation = cas.createAnnotation(type, begin, end);
>
> -- Richard
>
> On 05.05.2014, at 11:25, hannes schantl <jo...@gmail.com>
> wrote:
>
> > Hello,
> >
> > I have following problem: I dont know how to add a new annotation to the
> > CAS when the type of the annotation is only available as a string, e.g.
> > com.test.AnnotationType1.
> >
> > Does anyone know how to solve this issue?
> >
> > Thanks a lot,
> > Greetings Hannes
>
>
Re: creating new annotation
Posted by Richard Eckart de Castilho <re...@apache.org>.
Like this:
Type type = cas.getTypeSystem().getType("com.test.AnnotationType1)";
AnnotationFS annotation = cas.createAnnotation(type, begin, end);
-- Richard
On 05.05.2014, at 11:25, hannes schantl <jo...@gmail.com> wrote:
> Hello,
>
> I have following problem: I dont know how to add a new annotation to the
> CAS when the type of the annotation is only available as a string, e.g.
> com.test.AnnotationType1.
>
> Does anyone know how to solve this issue?
>
> Thanks a lot,
> Greetings Hannes