|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.crosswire.jsword.book.basic.AbstractBook
org.crosswire.jsword.book.basic.AbstractPassageBook
org.crosswire.jsword.book.sword.SwordBook
public class SwordBook
SwordBook is a base class for all verse based Sword type books.
The GNU Lesser General Public License for details.| Field Summary | |
|---|---|
private Filter |
filter
The filter to use to convert to OSIS. |
private Key |
global
A cached representation of the global key list. |
private static org.slf4j.Logger |
log
The log stream |
| Constructor Summary | |
|---|---|
SwordBook(SwordBookMetaData sbmd,
Backend<?> backend)
Construct an SwordBook given the BookMetaData and the AbstractBackend. |
|
| Method Summary | |
|---|---|
void |
addOSIS(Key key,
org.jdom2.Element div,
List<org.jdom2.Content> osisContent)
Add the OSIS elements to the div element. |
void |
addOSIS(Key key,
List<org.jdom2.Content> contentList,
List<org.jdom2.Content> osisContent)
Add the OSIS elements to the content list. |
boolean |
contains(Key key)
Returns true if this book contains the specified element. |
protected Filter |
getFilter()
What filter should be used to filter data in the format produced by this Book?. |
Key |
getGlobalKeyList()
Get a complete list of index entries. |
protected List<org.jdom2.Content> |
getOsis(Key key,
RawTextToXmlProcessor processor)
|
String |
getRawText(Key key)
Returns the raw text that getData(Key key) builds into OSIS. |
Key |
getScope()
Get a complete list of entries. |
boolean |
isWritable()
A Book is writable if the file system allows the underlying files to be opened for writing and if the driver for the book allows writing. |
void |
setAliasKey(Key alias,
Key source)
Store an alias of one key to another. |
void |
setRawText(Key key,
String rawData)
Store the raw text for the given key. |
| Methods inherited from class org.crosswire.jsword.book.basic.AbstractPassageBook |
|---|
createEmptyKeyList, getBibleBooks, getKey, getOsisIterator, getValidKey, getVersification, setDocument |
| Methods inherited from class org.crosswire.jsword.book.basic.AbstractBook |
|---|
activate, addIndexStatusListener, compareTo, deactivate, equals, find, find, firePropertyChange, getAbbreviation, getBackend, getBook, getBookCategory, getBookMetaData, getDriver, getDriverName, getIndexStatus, getInitials, getLanguage, getName, getOsisID, getProperty, getPropertyKeys, getUnlockKey, hasFeature, hashCode, isEnciphered, isLeftToRight, isLocked, isQuestionable, isSupported, match, putProperty, putProperty, removeIndexStatusListener, setBookMetaData, setIndexStatus, toOSIS, toString, unlock |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private Filter filter
private Key global
private static final org.slf4j.Logger log
| Constructor Detail |
|---|
public SwordBook(SwordBookMetaData sbmd,
Backend<?> backend)
sbmd - the metadata that describes the bookbackend - the means by which the resource is accessed| Method Detail |
|---|
public final Key getGlobalKeyList()
Book
public Key getScope()
BookBook.getGlobalKeyList(), however for a Bible, it will
get the references that are actually in the book.
getScope in interface BookgetScope in class AbstractBookpublic boolean contains(Key key)
Book
key - element whose presence in this book is to be tested.
public String getRawText(Key key)
throws BookException
Book
key - The item to locate
BookException - If anything goes wrong with this method
protected List<org.jdom2.Content> getOsis(Key key,
RawTextToXmlProcessor processor)
throws BookException
getOsis in class AbstractBookBookException
public void addOSIS(Key key,
org.jdom2.Element div,
List<org.jdom2.Content> osisContent)
AbstractPassageBook
addOSIS in class AbstractPassageBookkey - The key being addeddiv - The div element to which the key's OSIS representation is
being addedosisContent - The OSIS representation of the key being added.
public void addOSIS(Key key,
List<org.jdom2.Content> contentList,
List<org.jdom2.Content> osisContent)
AbstractPassageBook
addOSIS in class AbstractPassageBookkey - The key being addedcontentList - The list to which the key's OSIS representation is being addedosisContent - The OSIS representation of the key being added.public boolean isWritable()
Book
isWritable in interface BookisWritable in class AbstractPassageBook
public void setRawText(Key key,
String rawData)
throws BookException
Book
key - The item to locaterawData - The text to store
BookException - If anything goes wrong with this method
public void setAliasKey(Key alias,
Key source)
throws BookException
BookIt should be an exception to set an alias when that alias already has raw text. Also, it should be an exception to set an alias to an alias. However, getRawText(Key) must be able to handle alias chains.
alias - the key that aliases anothersource - the key that holds the text
BookException - If anything goes wrong with this methodprotected Filter getFilter()
AbstractPassageBook
getFilter in class AbstractPassageBook
|
Copyright ยจ 2003-2015 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||