org.apache.maven.doxia.book
Class DefaultBookDoxia
java.lang.Object
org.codehaus.plexus.logging.AbstractLogEnabled
org.apache.maven.doxia.book.DefaultBookDoxia
- All Implemented Interfaces:
- BookDoxia, org.codehaus.plexus.logging.LogEnabled
public class DefaultBookDoxia
- extends org.codehaus.plexus.logging.AbstractLogEnabled
- implements BookDoxia
Default implementation of BookDoxia.
- Version:
- $Id: DefaultBookDoxia.java 740705 2009-02-04 11:57:33Z vsiveton $
- Author:
- Trygve Laugstøl
Fields inherited from interface org.apache.maven.doxia.book.BookDoxia |
ROLE |
Method Summary |
java.util.Set |
getAvailableBookRenderers()
Returns a Set of ids of the BookRenderers that are available in this BookDoxia. |
BookModel |
loadBook(java.io.File bookDescriptor)
Load a BookModel from a descriptor file. |
void |
renderBook(BookModel book,
java.lang.String bookRendererId,
java.util.List files,
java.io.File outputDirectory)
Creates a book from a BookModel using the Locale.getDefault() and UTF-8 as default encoding. |
void |
renderBook(BookModel book,
java.lang.String bookRendererId,
java.util.List files,
java.io.File outputDirectory,
java.util.Locale locale,
java.lang.String inputEncoding,
java.lang.String outputEncoding)
Creates a book from a BookModel. |
Methods inherited from class org.codehaus.plexus.logging.AbstractLogEnabled |
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultBookDoxia
public DefaultBookDoxia()
loadBook
public BookModel loadBook(java.io.File bookDescriptor)
throws BookDoxiaException
- Load a BookModel from a descriptor file.
- Specified by:
loadBook
in interface BookDoxia
- Parameters:
bookDescriptor
- the book descriptor file.
- Returns:
- BookModel
- Throws:
BookDoxiaException
- if the model cannot be loaded.
renderBook
public void renderBook(BookModel book,
java.lang.String bookRendererId,
java.util.List files,
java.io.File outputDirectory)
throws BookDoxiaException
- Creates a book from a BookModel using the
Locale.getDefault()
and UTF-8 as default encoding.
- Specified by:
renderBook
in interface BookDoxia
- Parameters:
book
- the BookModel.bookRendererId
- the id of the output format.files
- a list of source files.outputDirectory
- the output directory.
- Throws:
BookDoxiaException
- if the model cannot be loaded.- See Also:
BookDoxia.renderBook(BookModel, String, List, File, Locale, String, String)
,
Locale.getDefault()
renderBook
public void renderBook(BookModel book,
java.lang.String bookRendererId,
java.util.List files,
java.io.File outputDirectory,
java.util.Locale locale,
java.lang.String inputEncoding,
java.lang.String outputEncoding)
throws BookDoxiaException
- Creates a book from a BookModel.
- Specified by:
renderBook
in interface BookDoxia
- Parameters:
book
- the BookModel.bookRendererId
- the id of the output format.files
- a list of source files.outputDirectory
- the output directory.locale
- the wanted locale.inputEncoding
- the input encoding when processing files
.outputEncoding
- the output encoding when writing files in ouputDirectory
.
- Throws:
BookDoxiaException
- if the model cannot be loaded.
getAvailableBookRenderers
public java.util.Set getAvailableBookRenderers()
- Returns a Set of ids of the BookRenderers that are available in this BookDoxia.
- Returns:
- Set
Copyright © 2005-2012. All Rights Reserved.