00001
00002
00003
00004
00005
00006
00007
00008
00009 #ifndef __rdIO_h__
00010 #define __rdIO_h__
00011
00012
00013
00014 #include "rdTools.h"
00015
00016
00017
00018 const int rdIO_STRLEN = 2048;
00019 const int rdIO_STRING_INCREMENT = 2048;
00020
00021
00022
00023
00030 class RDTOOLS_API rdIO {
00031
00032
00033
00034
00035 public:
00037 static const int STRLEN;
00039 static const int STRING_INCREMENT;
00040
00041 private:
00042
00044 static bool _Scientific;
00046 static int _Pad;
00048 static int _Precision;
00050 static char _DoubleFormat[256];
00051
00052
00053
00054
00055
00056 public:
00057
00058 static void SetScientific(bool aTrueFalse);
00059 static bool GetScientific();
00060 static void SetDigitsPad(int aPad);
00061 static int GetDigitsPad();
00062 static void SetPrecision(int aPlaces);
00063 static int GetPrecision();
00064 static const char*
00065 GetDoubleOutputFormat();
00066 private:
00067 static void ConstructDoubleOutputFormat();
00068
00069 public:
00070
00071 static char* ReadToTokenLine(FILE *aFP,const char *aToken);
00072 static char* ReadLine(FILE *aFP);
00073 static int ComputeLineLength(FILE *aFP);
00074 static int ComputeNumberOfSteps(double aTI,double aTF,double aDT);
00075 static char* ReadCharacters(FILE *aFP,int aNChar);
00076 static FILE* OpenFile(const char *aFileName,const char *aMode);
00077
00078
00079 };
00080
00081
00082
00083 #endif // __rdIO_h__