uima-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chavan, Girish" <chav...@upmc.edu>
Subject RE: Collection Reader
Date Thu, 25 Jun 2009 20:39:42 GMT
This is just initializing the CollectionReader using its descriptor file
specified as a URL. It has nothing to do with the actual documents that
you will be processing. 

you will need to populate the cas with your document within your
CollectionReader implementation, specifically in the getNext(Cas cas)
method, 

If your initial question was how to populate a CAS with a document
available as a URL, then you can read the document pointed to by the URL
by calling url.openStream and reading the data out.

-Girish

-----Original Message-----
From: Radwen ANIBA [mailto:aradwen@gmail.com] 
Sent: Thursday, June 25, 2009 4:32 PM
To: uima-user@incubator.apache.org
Subject: Re: Collection Reader

Thank  for your answer Chavan,
What does this means exactly, does it "download" the documents relative
to
the URL ? Let's suppose the URL points to a text file or image, does
this
code download these documents instead of having them in folder ?

Rad

2009/6/25 Chavan, Girish <chavang@upmc.edu>

> Here it is:
>
> XMLInputSource in = new XMLInputSource(collectionReaderDescURL);
> ResourceSpecifier specifier =
> UIMAFramework.getXMLParser().parseResourceSpecifier(in);
> CollectionReader collectionReader =
> UIMAFramework.produceCollectionReader(specifier);
>
> ~g
> -----Original Message-----
> From: Radwen ANIBA [mailto:aradwen@gmail.com]
> Sent: Thursday, June 25, 2009 4:24 PM
> To: uima-user@incubator.apache.org
> Subject: Re: Collection Reader
>
> yes ?
>
> 2009/6/25 Chavan, Girish <chavang@upmc.edu>
>
> > Do you mean the CollectionReader descriptor file being a URL?
> > ~g
> >
> > -----Original Message-----
> > From: Radwen ANIBA [mailto:aradwen@gmail.com]
> > Sent: Thursday, June 25, 2009 4:13 PM
> > To: uima-user
> > Subject: Collection Reader
> >
> > Hello everyone,
> >
> > A simple question :
> >
> > Could Collection reader be an URL ?
> >
> > If yes how to configure it ?
> >
> > Radwen
> >
>

Mime
View raw message