You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@any23.apache.org by Lewis John Mcgibbney <le...@gmail.com> on 2015/08/25 06:52:47 UTC

Re: Using String as an input

Hi Murik,

On Wed, Aug 5, 2015 at 4:44 AM, <us...@any23.apache.org> wrote:

>
> Is it possible to have *DocumentSource* input as a String instead of a
> File? I looked through the *org.apache.any23.source* package and tried
> using *StringDocumentSource* class, but it requires URI as a parameter.
> If I enter some uri (fake or real) it doesn't parse the String contents.
> Thanks everyone in advance.
>
>
Yes.
 You can check out the Javadoc which explains to you what the syntax needs
to look like
http://any23.apache.org/apidocs/index.html?org/apache/any23/source/StringDocumentSource.html
*StringDocumentSource
<http://any23.apache.org/apidocs/org/apache/any23/source/StringDocumentSource.html#StringDocumentSource%28java.lang.String,%20java.lang.String%29>*
(String
<http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true>
in,
String
<http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true>
 uri)
URI can be anything... an arbitrary placeholder for testing purposes.
Can you provide results?
Thanks
Lewis