Thanks for your reply, Nick.<br/>I suppose I'm calling Tika with parse+content 
handler, the following code is one example I found on the internet:<br/><br/>   
         File f=new File(fn);<br/>               Parser parser = new 
AutoDetectParser();<br/>            InputStream is = null;<br/>             try 
{<br/>                      Metadata metadata = new Metadata();<br/>            
            metadata.set(Metadata.RESOURCE_NAME_KEY, f.getName());<br/>         
            is = new FileInputStream(f);<br/>                       
ContentHandler handler = new BodyContentHandler();<br/>                 
ParseContext context = new ParseContext();<br/>                 
context.set(Parser.class, parser);<br/>                 parser.parse(is, 
handler, metadata, context);<br/>                      return new 
TikaBox(metadata,handler);<br/>                {
At 2014-10-14 17:56:20, "Nick Burch" <[email protected]> wrote:
>On Tue, 14 Oct 2014, imyuka wrote:
>> In these cases, how can I increase the limit or retrieve only the first 
>> 100000 characters of the document without throwing an exception?
>
>Depends largely on how you're calling Apache Tika?
>
>(The answer differs depending on if you're using the Tika CLI (app), Tika 
>Server, Tika facade class or parser+content handler)
>
>Nick

Reply via email to