OdtToText2.java (Initial Version Committed)

May 21, 2007

The initial version of OdtToText2.java was committed to the CVS by Bernd Eilers. View the CVS log here

Features

  1. Extracts text, headings from a ODT file
  2. Uses the classes TextBody, BlockContent, Element, etc, in odf.text
  3. No manual SAX parsing

To Do’s

  1. Extend it to extract other information from a ODT file,like table information and etc.

    Test Run:

    • Input – ODT file containing simple text, a heading and List of elements
    • Output :

    DEBUG unhandled elem is org.openoffice.odf.text.UnknownElement node=office:forms
    DEBUG unhandled elem is org.openoffice.odf.text.UnknownElement node=text:sequence-decls
    He heard quiet steps behind him. That didn’t bode well. Who could be following him this late at night and in this deadbeat part of town? And at this particular moment, just after he pulled off the big time and was making off with the greenbacks. Was there another crook who’d had the same idea, and was now watching him and waiting for a chance to grab the fruit of his labor?

    *  aaa
    *  bbb
    *  ccc
    *  ddd
    *  eee
    *  ffff

    ==== Heading ====
    text below heading
    *  aaa
    *  bbb
    *  ccc
    *  ddd
    *  eee
    *  ffff