Actually implement the new procedure code and adapt all of its clients
[pspp-builds.git] / src / data / sys-file-reader.h
index 68e6e84ec54497f95a68818187c11f8a5de84fd1..337404757c42e5cdd00e9b64afe44c9203488e4b 100644 (file)
@@ -1,6 +1,5 @@
 /* PSPP - computes sample statistics.
    Copyright (C) 1997-9, 2000 Free Software Foundation, Inc.
-   Written by Ben Pfaff <blp@gnu.org>.
 
    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License as
@@ -23,6 +22,9 @@
 #include <stdbool.h>
 #include <stdio.h>
 
+#include <libpspp/float-format.h>
+#include <libpspp/integer-format.h>
+
 /* Reading system files. */
 
 /* System file info that doesn't fit in struct dictionary. */
@@ -30,8 +32,9 @@ struct sfm_read_info
   {
     char creation_date[10];    /* `dd mmm yy' plus a null. */
     char creation_time[9];     /* `hh:mm:ss' plus a null. */
-    int big_endian;            /* 1=big-endian, 0=little-endian. */
-    int compressed;            /* 0=no, 1=yes. */
+    enum integer_format integer_format;
+    enum float_format float_format;
+    bool compressed;           /* 0=no, 1=yes. */
     int case_cnt;               /* -1 if unknown. */
     char product[61];          /* Product name plus a null. */
   };
@@ -39,12 +42,9 @@ struct sfm_read_info
 struct dictionary;
 struct file_handle;
 struct ccase;
-struct sfm_reader *sfm_open_reader (struct file_handle *,
+struct casereader *sfm_open_reader (struct file_handle *,
                                     struct dictionary **,
                                     struct sfm_read_info *);
-int sfm_read_case (struct sfm_reader *, struct ccase *);
-bool sfm_read_error (const struct sfm_reader *);
-void sfm_close_reader (struct sfm_reader *);
 bool sfm_detect (FILE *);
 
 #endif /* sys-file-reader.h */