org.crosswire.jsword.book.filter.thml
Class THMLFilter
java.lang.Object
org.crosswire.jsword.book.filter.thml.THMLFilter
- All Implemented Interfaces:
- Cloneable, Filter
public class THMLFilter
- extends Object
- implements Filter
Filter to convert THML to OSIS format.
I used the THML ref page: http
://www.ccel.org/ThML/ThML1.04.htm to work out what the tags meant.
LATER(joe): check nesting on these THML elements
- Author:
- Joe Walker [joe at eireneh dot com]
- See Also:
for license details.
The copyright to this program is held by it's authors.
Method Summary |
private org.jdom2.Element |
cleanParse(Book book,
Key key,
String plain)
|
private org.jdom2.Element |
cleanTags(Book book,
Key key,
String plain)
|
private org.jdom2.Element |
cleanText(Book book,
Key key,
String plain)
|
THMLFilter |
clone()
This needs to be declared here so that it is visible as a method on a
derived Filter. |
private org.jdom2.Element |
parse(Book book,
Key key,
String plain,
String failMessage)
|
List<org.jdom2.Content> |
toOSIS(Book book,
Key key,
String plain)
Converter from plain (encoded) text to OSIS data |
errorMessage
private String errorMessage
error
private Exception error
finalInput
private String finalInput
log
private static final org.slf4j.Logger log
- The log stream
THMLFilter
public THMLFilter()
toOSIS
public List<org.jdom2.Content> toOSIS(Book book,
Key key,
String plain)
- Description copied from interface:
Filter
- Converter from plain (encoded) text to OSIS data
- Specified by:
toOSIS
in interface Filter
key
- The key for the textplain
- The encoded text
- Returns:
- a List of OSIS Elements
clone
public THMLFilter clone()
- Description copied from interface:
Filter
- This needs to be declared here so that it is visible as a method on a
derived Filter.
- Specified by:
clone
in interface Filter
- Overrides:
clone
in class Object
- Returns:
- A complete copy of ourselves
cleanParse
private org.jdom2.Element cleanParse(Book book,
Key key,
String plain)
cleanText
private org.jdom2.Element cleanText(Book book,
Key key,
String plain)
cleanTags
private org.jdom2.Element cleanTags(Book book,
Key key,
String plain)
parse
private org.jdom2.Element parse(Book book,
Key key,
String plain,
String failMessage)