aboutsummaryrefslogtreecommitdiffstats
path: root/include/rawverse.h
diff options
context:
space:
mode:
authordanglassey <danglassey>2002-08-14 09:57:17 +0000
committerdanglassey <danglassey>2002-08-14 09:57:17 +0000
commitdaa67ff1f728c07f2a116ee9a9f4505479ca6808 (patch)
treec224a537d30480002ae0560cc9104b543b4d1b5e /include/rawverse.h
parent6d6973e035aac5ec1676efccd5b8ada70c40b639 (diff)
downloadsword-sf-cvs-daa67ff1f728c07f2a116ee9a9f4505479ca6808.tar.gz
Initial import from crosswire CVS for syncingimport-1.1.1
Diffstat (limited to 'include/rawverse.h')
-rw-r--r--include/rawverse.h38
1 files changed, 38 insertions, 0 deletions
diff --git a/include/rawverse.h b/include/rawverse.h
new file mode 100644
index 0000000..3917fd7
--- /dev/null
+++ b/include/rawverse.h
@@ -0,0 +1,38 @@
+/******************************************************************************
+ * rawverse.h - code for class 'RawVerse'- 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
+ */
+
+#ifndef RAWVERSE_H
+#define RAWVERSE_H
+
+#include <filemgr.h>
+#include <fcntl.h>
+
+#include <defs.h>
+
+class SWDLLEXPORT RawVerse {
+ static int instance; // number of instantiated RawVerse objects or derivitives
+protected:
+ FileDesc *idxfp[2];
+ FileDesc *textfp[2];
+
+ char *path;
+ void preptext(char *buf);
+ void settext(char testmt, long idxoff, const char *buf, long len = -1);
+ void linkentry(char testmt, long destidxoff, long srcidxoff);
+
+public:
+ static const char *nl;
+ RawVerse(const char *ipath, int fileMode = -1);
+ virtual ~ RawVerse();
+ void findoffset(char testmt, long idxoff, long *start,
+ unsigned short *end);
+ void readtext(char testmt, long start, unsigned short size, char *buf);
+ static char createModule(const char *path);
+};
+
+
+#endif