GlobalObjects
Lade ...
Suche ...
Keine Treffer
GloTableWriterInterface.h
gehe zur Dokumentation dieser Datei
1#ifndef INC_GLOTABLEWRITERINTERFACE_H
2#define INC_GLOTABLEWRITERINTERFACE_H
3//-----------------------------------------------------------------------------
36//-----------------------------------------------------------------------------
37#include "GloTableInterface.h"
38#include "GloTypes.h"
39#include <vector>
40//---------------------------------------------------------------------------
41/* Forwards */
42namespace eut
43{
44 class UnsignedMagicNumber;
45}
46//-----------------------------------------------------------------------------
47namespace glo
48{
49 //---------------------------------------------------------------------------
50 /* Forwards */
51 class TransactionIndexPool;
52 class Record;
53 class BaseRecordAttribute;
54 //---------------------------------------------------------------------------
70 {
71 private:
72 //============== Enums
73 //-----------------------------------------------------------------------
85 enum EnInUd
86 {
106 eUPDATE
107 };
108 //-----------------------------------------------------------------------
109
110 //============== Attribute
111 //-----------------------------------------------------------------------
131 std::vector<TransactionIndexPool *>* m_pTransactionIndexPoolVector;
132 //-----------------------------------------------------------------------
133
134 protected:
135 //============== Konstruktoren
136 //-----------------------------------------------------------------------
147 //-----------------------------------------------------------------------
148
149 public:
150 //============== De- und Konstruktoren
151 //-----------------------------------------------------------------------
169 RealIndexPool * pRealIndexPool);
170 //-----------------------------------------------------------------------
182 //-----------------------------------------------------------------------
183
184 private:
185 //============== Konstruktoren
186 //-----------------------------------------------------------------------
197 //-----------------------------------------------------------------------
198
199 public:
200 //============== Methoden
201 //-----------------------------------------------------------------------
216 virtual int openTable( const std::string & sTableName );
217 //-----------------------------------------------------------------------
243 int storeObjectData( Record * pRecord,
244 std::vector< TransactionIndexPool * > * pTransactionIndexPoolVector = 0 );
245 //-----------------------------------------------------------------------
270 int deleteObjectData( Record * pRecord,
271 std::vector< TransactionIndexPool * > * pTransactionIndexPoolVector = 0 );
272 //-----------------------------------------------------------------------
286 int getNewObjID( ObjID & rObjID );
287 //-----------------------------------------------------------------------
288
289 protected:
290 //============== Methoden
291 //-----------------------------------------------------------------------
292
311 ObjID ObjID );
312 //-----------------------------------------------------------------------
332 int updateInsert( Record * pInputUpdateRecord, EnInUd eInUd );
333 //-----------------------------------------------------------------------
351 int readLastObjCounter( unsigned long & rulObjCounter );
352 //-----------------------------------------------------------------------
374 int writeLastObjCounter( const unsigned long & rulObjCounter, bool bNew );
375 //-----------------------------------------------------------------------
397 void removeForbiddenCharacters (std::string & rsField) const;
398 //-----------------------------------------------------------------------
433 int writeInTable( const std::string & rsTableName,
434 const std::string & rsContents,
435 const std::streampos spFileIndexPosition );
436 //-----------------------------------------------------------------------
467 int appendOnTable( std::streampos & rspFileIndexPosition,
468 const std::string & rsTableName,
469 unsigned long ulClassID,
470 const std::string & rsDataRow );
471 //-----------------------------------------------------------------------
493 int updateExternFiles( BaseRecordAttribute * pRecordAttribute,
494 DATA_REFERENCE_INFO MethodInfo );
495 //-----------------------------------------------------------------------
518 int getFirstDeletedRecordItem( std::streampos & rspFileIndexPosition,
519 unsigned long ulClassID );
520 //-----------------------------------------------------------------------
536 int getFirstDeletedRecordItem( std::streampos & rspFileIndexPosition,
537 const std::string & rsFullTableName );
538 //-----------------------------------------------------------------------
556 int readLastUL( unsigned long & rulRetVal, const std::string & rsFileName );
557 //-----------------------------------------------------------------------
580 int writeLastUL( const unsigned long & rulVal,
581 const std::string & rsFileName,
582 bool bNew );
583 //-----------------------------------------------------------------------
603 const std::string & rsFileName );
604 //-----------------------------------------------------------------------
628 const std::string & rsFileName,
629 bool bNew );
630 //-----------------------------------------------------------------------
631
632 private:
633 //============== Operatoren
634 //-----------------------------------------------------------------------
644 TableInterface & operator= ( const TableInterface & );
645 //-----------------------------------------------------------------------
646 };
647 //---------------------------------------------------------------------------
648} // namespace glo
649#endif
Header für TableInterface und TableInterface::TableInterfaceTable
Für jede Bibliothek, hier 'GlobalObjects' gibt es eine Typen-Datei.
#define __glo_export_dll
Definition GloTypes.h:63
Ein UnsignedMagicNumber ist eine künstliche Zahl aus Ziffern und Buchstaben (so ähnlich wie Hex-Zahle...
Definition EuUnsignedMagicNumber.h:107
Basisklasse für die einzelnen Attribute eines Record.
Definition GloBaseRecordAttribute.h:109
Ein Objekt-ID besteht aus der Klassen-ID, einer Datenbank-ID und der eigentlichen eindeutigen ObjektZ...
Definition GloObjID.h:77
Der reale Index im Gegensatz zum TransactionIndexPool, welcher für jede Transaktion erstellt wird.
Definition GloIndexPool.h:5151
Objekte dieser Klasse transportieren die Daten von den Tabellen ins persistente Objekt und von diesen...
Definition GloRecord.h:101
Diese Klasse ist die Schnittstelle zu einem GlobalObjects-Schema. Sie beinhaltet alle Klasseninformat...
Definition GloSchemaInterface.h:84
Ein Objekt dieser Klasse bzw. der Unterklasse greift auf Tabellen zu und liest bzw....
Definition GloTableInterface.h:87
Ein Objekt dieser Klasse greift auf Tabellen zu und schreibt Datensätze (Record) und Binärdateien (eu...
Definition GloTableWriterInterface.h:70
std::vector< TransactionIndexPool * > * m_pTransactionIndexPoolVector
Definition GloTableWriterInterface.h:131
TableWriterInterface(const SchemaInterface &rScheme, RealIndexPool *pRealIndexPool)
int updateExternFiles(BaseRecordAttribute *pRecordAttribute, DATA_REFERENCE_INFO MethodInfo)
int readLastMagicNumber(eut::UnsignedMagicNumber &rRetVal, const std::string &rsFileName)
int writeLastUL(const unsigned long &rulVal, const std::string &rsFileName, bool bNew)
int updateInsert(Record *pInputUpdateRecord, EnInUd eInUd)
int writeLastMagicNumber(const eut::UnsignedMagicNumber &rVal, const std::string &rsFileName, bool bNew)
void removeForbiddenCharacters(std::string &rsField) const
TableWriterInterface(const TableWriterInterface &)
int updateObjectDataAttribute(BaseRecordAttribute *pRecordAttribute, ObjID ObjID)
int deleteObjectData(Record *pRecord, std::vector< TransactionIndexPool * > *pTransactionIndexPoolVector=0)
int writeLastObjCounter(const unsigned long &rulObjCounter, bool bNew)
int getNewObjID(ObjID &rObjID)
int writeInTable(const std::string &rsTableName, const std::string &rsContents, const std::streampos spFileIndexPosition)
int readLastObjCounter(unsigned long &rulObjCounter)
int storeObjectData(Record *pRecord, std::vector< TransactionIndexPool * > *pTransactionIndexPoolVector=0)
int appendOnTable(std::streampos &rspFileIndexPosition, const std::string &rsTableName, unsigned long ulClassID, const std::string &rsDataRow)
int getFirstDeletedRecordItem(std::streampos &rspFileIndexPosition, unsigned long ulClassID)
virtual int openTable(const std::string &sTableName)
int readLastUL(unsigned long &rulRetVal, const std::string &rsFileName)
EnInUd
Definition GloTableWriterInterface.h:86
@ eINSERT
Definition GloTableWriterInterface.h:96
int getFirstDeletedRecordItem(std::streampos &rspFileIndexPosition, const std::string &rsFullTableName)
Definition IniFile.h:47
Definition GloAbstractBaseLot.h:42
unsigned long DATA_REFERENCE_INFO
Definition GloRecordAttributeTypes.h:745