Below is a simple example to illustrate how to use it.
BookDoxia doxia = (BookDoxia) lookup( BookDoxia.ROLE ); // load the book descriptor File book1 = new File( "book-1.xml" ); BookModel book = doxia.loadBook( book1 ); // files to include List files = FileUtils.getFiles( new File( "src/resources/book/" ), "**/*.apt, **/*.xml", "" ); // render books in different formats doxia.renderBook( book, "pdf", files, new File( "target/itext/" ) ); doxia.renderBook( book, "xhtml", files, new File( "target/xhtml/" ) ); doxia.renderBook( book, "xdoc", files, new File( "target/xdoc/" ) ); doxia.renderBook( book, "latex", files, new File( "target/latex/" ) ); doxia.renderBook( book, "doc-book", files, new File( "target/doc-book/" ) ); doxia.renderBook( book, "rtf", files, new File( "target/rtf/" ) );
See the Javadocs for more details.