00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef NeesData_h
00027 #define NeesData_h
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039 #include <FE_Datastore.h>
00040
00041 #include <fstream>
00042 using std::fstream;
00043
00044 #include <bool.h>
00045
00046 class NEES_table
00047 {
00048 public:
00049 char *name;
00050 char **columns;
00051 int numColumns;
00052 NEES_table *next;
00053 bool hasOutExtension;
00054 };
00055
00056 class FEM_ObjectBroker;
00057
00058 class NEESData: public FE_Datastore
00059 {
00060 public:
00069 NEESData(const char *dataBase,
00070 Domain &theDomain,
00071 FEM_ObjectBroker &theBroker);
00072
00073 ~NEESData();
00074
00075
00076 int getDbTag(void);
00077
00078
00079 int sendMsg(int dbTag, int commitTag,
00080 const Message &,
00081 ChannelAddress *theAddress =0);
00082 int recvMsg(int dbTag, int commitTag,
00083 Message &,
00084 ChannelAddress *theAddress =0);
00085
00086 int sendMatrix(int dbTag, int commitTag,
00087 const Matrix &theMatrix,
00088 ChannelAddress *theAddress =0);
00089 int recvMatrix(int dbTag, int commitTag,
00090 Matrix &theMatrix,
00091 ChannelAddress *theAddress =0);
00092
00093 int sendVector(int dbTag, int commitTag,
00094 const Vector &theVector,
00095 ChannelAddress *theAddress =0);
00096 int recvVector(int dbTag, int commitTag,
00097 Vector &theVector,
00098 ChannelAddress *theAddress =0);
00099
00100 int sendID(int dbTag, int commitTag,
00101 const ID &theID,
00102 ChannelAddress *theAddress =0);
00103 int recvID(int dbTag, int commitTag,
00104 ID &theID,
00105 ChannelAddress *theAddress =0);
00106
00107 int createTable(const char *tableName, int numColumns, char *columns[]);
00108 int insertData(const char *tableName, char *columns[],
00109 int commitTag, const Vector &data);
00110
00111 int getData(const char *tableName, char *columns[], int commitTag, Vector &data);
00112
00113
00114 int commitState(int commitTag);
00115
00116 protected:
00117
00118 private:
00119 char *dataBase;
00120 NEES_table *tables;
00121 int numTables;
00122 };
00123
00124
00125
00126 #endif
00127