Result set manipulation
authorSebastian Hammer <quinn@indexdata.com>
Thu, 3 Nov 1994 14:13:22 +0000 (14:13 +0000)
committerSebastian Hammer <quinn@indexdata.com>
Thu, 3 Nov 1994 14:13:22 +0000 (14:13 +0000)
include/rset.h [new file with mode: 0644]
rset/Makefile [new file with mode: 0644]

diff --git a/include/rset.h b/include/rset.h
new file mode 100644 (file)
index 0000000..789ae9d
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+ * Copyright (C) 1994, Index Data I/S 
+ * All rights reserved.
+ * Sebastian Hammer, Adam Dickmeiss
+ *
+ * $Log: rset.h,v $
+ * Revision 1.1  1994-11-03 14:13:22  quinn
+ * Result set manipulation
+ *
+ */
+
+#ifndef RSET_H
+#define RSET_H
+
+typedef struct rset_control
+{
+    char *buf;  /* state data stored by subsystem */
+    int (*f_open)(rset_control *ct, int wflag);
+    void (*f_close)(rset_control *ct *data);
+    void (*f_delete)(rset_control *ct);
+    void (*f_rewind)(rset_control *ct);
+    int (*f_count)(rset_control *ct);
+    int (*f_read)(...);
+    int (*f_write)(...);
+} rset_control;
+
+typedef struct rset
+{
+    rset_control *control;
+} rset *RSET;
+
+RSET rset_create();       /* parameters? */
+int rset_open(RSET rs, int wflag);
+void rset_close(RSET rs);
+void rset_delete(RSET rs);
+void rset_rewind(RSET rs);
+int rset_count(RSET rs);   /* more parameters? */
+int rset_read(RSET rs, void *buf);   /* change parameters */
+int rset_write(RSET rs, void *buf);  /* change parameters */
+
+#endif
diff --git a/rset/Makefile b/rset/Makefile
new file mode 100644 (file)
index 0000000..ede37d5
--- /dev/null
@@ -0,0 +1,46 @@
+# Copyright (C) 1994, Index Data I/S 
+# All rights reserved.
+# Sebastian Hammer, Adam Dickmeiss
+# $Id: Makefile,v 1.1 1994-11-03 14:13:29 quinn Exp $
+
+SHELL=/bin/sh
+INCLUDE=-I../include
+CFLAGS=-g -Wall -pedantic
+DEFS=$(INCLUDE)
+LIB=../lib/rset.a
+PROG=
+PO=
+CPP=cc -E
+
+all: $(PROG) $(LIB)
+
+$(PROG): $(PROG).o
+       $(CC) -o $(PROG) $(INCLUDE) $(CFLAGS) $(PROG).o $(LIB)
+
+
+$(LIB): $(PO)
+       ar aq $(LIB) $(PO)
+       ranlib $(LIB)
+
+.c.o:
+       $(CC) -c $(DEFS) $(CFLAGS) $<
+
+clean:
+       rm -f *.[oa] core mon.out gmon.out errlist
+
+depend: depend2
+
+depend1:
+       mv Makefile Makefile.tmp
+       sed '/^#Depend/q' <Makefile.tmp >Makefile
+       $(CPP) $(INCLUDE) -M *.c >>Makefile
+       -rm Makefile.tmp
+
+depend2:
+       $(CPP) $(INCLUDE) -M *.c >.depend       
+
+ifeq (.depend,$(wildcard .depend))
+include .depend
+endif
+
+#Depend --- DOT NOT DELETE THIS LINE