|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.crosswire.jsword.book.sword.AbstractBackend
org.crosswire.jsword.book.sword.AbstractKeyBackend
org.crosswire.jsword.book.sword.RawLDBackend
org.crosswire.jsword.book.sword.ZLDBackend
public class ZLDBackend
An extension of RawLDBackend to read Z format files.
for license details. The copyright to this program is
held by it's authors.
,
Serialized FormField Summary | |
---|---|
private boolean |
active
Flags whether there are open files or not |
private static int |
BLOCK_ENTRY_COUNT
|
private static int |
BLOCK_ENTRY_SIZE
|
private static byte[] |
EMPTY_BYTES
|
private static String |
EXTENSION_Z_DATA
|
private static String |
EXTENSION_Z_INDEX
|
private long |
lastBlockNum
The index of the block that is cached. |
private byte[] |
lastUncompressed
The cache for a read of a compressed block. |
private static Logger |
log
The log stream |
private static long |
serialVersionUID
Serialization ID |
private File |
zdtFile
The compressed text. |
private RandomAccessFile |
zdtRaf
The compressed text random access file. |
private static int |
ZDX_ENTRY_SIZE
|
private File |
zdxFile
The compressed index. |
private RandomAccessFile |
zdxRaf
The compressed index random access file. |
Constructor Summary | |
---|---|
ZLDBackend(SwordBookMetaData sbmd)
Simple ctor |
Method Summary | |
---|---|
void |
activate(Lock lock)
Called to indicate that the Book should initialize itself, and consume whatever system resources it needs to be able to respond to other queries. |
void |
deactivate(Lock lock)
Called to indicate that the Book should release whatever system resources it can to make way for other uses. |
protected String |
getRawText(DataEntry entry)
|
protected boolean |
isActive()
Determine whether we are active. |
private void |
readObject(ObjectInputStream is)
Serialization support. |
Methods inherited from class org.crosswire.jsword.book.sword.RawLDBackend |
---|
checkActive, get, getCardinality, getRawText, getRawText, indexOf |
Methods inherited from class org.crosswire.jsword.book.sword.AbstractKeyBackend |
---|
addAll, blur, canHaveChildren, clear, clone, compareTo, contains, equals, getChildCount, getName, getName, getOsisID, getOsisRef, getParent, getRootName, hashCode, isEmpty, iterator, removeAll, retainAll |
Methods inherited from class org.crosswire.jsword.book.sword.AbstractBackend |
---|
decipher, encipher, getBookMetaData, getExpandedDataPath, isSupported, isWritable, readIndex, setRawText |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final String EXTENSION_Z_INDEX
private static final String EXTENSION_Z_DATA
private static final int ZDX_ENTRY_SIZE
private static final int BLOCK_ENTRY_COUNT
private static final int BLOCK_ENTRY_SIZE
private static final byte[] EMPTY_BYTES
private transient boolean active
private transient File zdxFile
private transient RandomAccessFile zdxRaf
private transient File zdtFile
private transient RandomAccessFile zdtRaf
private transient long lastBlockNum
private transient byte[] lastUncompressed
private static final long serialVersionUID
private static final Logger log
Constructor Detail |
---|
public ZLDBackend(SwordBookMetaData sbmd)
Method Detail |
---|
protected String getRawText(DataEntry entry)
getRawText
in class RawLDBackend
public void activate(Lock lock)
Activatable
activate
in interface Activatable
activate
in class RawLDBackend
lock
- An attempt to ensure that only the Activator calls this methodpublic void deactivate(Lock lock)
Activatable
deactivate
in interface Activatable
deactivate
in class RawLDBackend
lock
- An attempt to ensure that only the Activator calls this methodprotected boolean isActive()
isActive
in class RawLDBackend
private void readObject(ObjectInputStream is) throws IOException, ClassNotFoundException
is
-
IOException
ClassNotFoundException
|
Copyright ยจ 2003-2007 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |