Javatpoint Logo
Javatpoint Logo

Tika Parsing Document to Plain Text

Tika allows us to get extracted content in various formats like text, html or xhtml etc. The ContentHandler class is responsible for returning content. We can use BodyContentHandler also if want to get content of the document's body as plain text.

Lets see an example in which we are getting plain text output from the html file.

Tika Parsing to Plain Text Example


Following is the our html file.

// index. html

<title>Index Page</title>
<h2>Hello, Welcome to Javatpoint. </h2>

After extracting, it produces the output in plain text.

Hello, Welcome to Javatpoint.

Youtube For Videos Join Our Youtube Channel: Join Now


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Trending Technologies

B.Tech / MCA