Advertisement
TwisterMike

file_util.h

Feb 16th, 2020
177
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. /*Group 2 Program 1
  2. Paul Maclean- mac7537@calu.edu
  3. Mike Gorse- gor9632@calu.edu
  4. Robert Breckenridge- bre6896@calu.edu
  5. Chase Smith- smi8808@calu.edu
  6.  
  7. CSC 460
  8. Language Translations
  9. */
  10.  
  11. #ifndef FILE_UTIL_H
  12. #define FILE_UTIL_H
  13.  
  14. #define FILENAME_MAXSZ 100
  15.  
  16.  
  17. #include <stdio.h>
  18. #include <string.h>
  19.  
  20.  
  21. //***Enums***//
  22.  
  23. typedef enum { lfalse, ltrue } logical;
  24. typedef enum { cont, quit } file_outcome;
  25.  
  26.  
  27. //***Character Arrays***//
  28.  
  29. static char INPFILE_EXTENSION[] = ".in";
  30. static char OUTFILE_EXTENSION[] = ".out";
  31. static char LISFILE_EXTENSION[] = ".lis";
  32.  
  33.  
  34. //***Files***//
  35. FILE* InpFile, * OutFile, * LisFile, * BckFile, * TmpFile;
  36.  
  37. //***Exported Functions***//
  38. file_outcome openFiles(int, char* []);
  39. void copyToFile(FILE*, FILE*);
  40. void closeFiles(void);
  41.  
  42. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement