summaryrefslogtreecommitdiff
path: root/include/zverse.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/zverse.h')
-rw-r--r--include/zverse.h28
1 files changed, 15 insertions, 13 deletions
diff --git a/include/zverse.h b/include/zverse.h
index ba29b8d..b5df882 100644
--- a/include/zverse.h
+++ b/include/zverse.h
@@ -1,5 +1,5 @@
/******************************************************************************
- * rawverse.h - code for class 'RawVerse'- a module that reads raw text
+ * rawverse.h - code for class 'zVerse'- a module that reads raw text
* files: ot and nt using indexs ??.bks ??.cps ??.vss
* and provides lookup and parsing functions based on
* class VerseKey
@@ -15,21 +15,22 @@
#include <defs.h>
+SWORD_NAMESPACE_START
+
class SWDLLEXPORT zVerse {
SWCompress *compressor;
protected:
- static int instance; // number of instantiated RawVerse objects or derivitives
+ static int instance; // number of instantiated zVerse objects or derivitives
FileDesc *idxfp[2];
FileDesc *textfp[2];
FileDesc *compfp[2];
char *path;
- void preptext (char *buf);
- void settext (char testmt, long idxoff, const char *buf, long len = 0);
- void linkentry (char testmt, long destidxoff, long srcidxoff);
- void flushCache ();
- //RawVerse();
+ void prepText(SWBuf &buf);
+ void doSetText(char testmt, long idxoff, const char *buf, long len = 0);
+ void doLinkEntry(char testmt, long destidxoff, long srcidxoff);
+ void flushCache();
char *cacheBuf;
char cacheTestament;
long cacheBufIdx;
@@ -45,12 +46,13 @@ public:
char nl;
- zVerse (const char *ipath, int fileMode = O_RDONLY, int blockType = CHAPTERBLOCKS, SWCompress * icomp = 0);
- virtual ~ zVerse ();
- void findoffset (char testmt, long idxoff, long *start, unsigned short *end);
- void swgettext (char testmt, long start, unsigned short size, char *buf);
- static char createModule (const char *path, int blockBound);
+ zVerse(const char *ipath, int fileMode = O_RDONLY, int blockType = CHAPTERBLOCKS, SWCompress * icomp = 0);
+ virtual ~zVerse();
+ void findOffset(char testmt, long idxoff, long *start, unsigned short *end);
+ void zReadText(char testmt, long start, unsigned short size, SWBuf &buf);
+ virtual void rawZFilter(SWBuf &buf, char direction = 0) {}
+ static char createModule(const char *path, int blockBound);
};
-
+SWORD_NAMESPACE_END
#endif