GlobalObjects
Lade ...
Suche ...
Keine Treffer
GloBaseAllSet.h
gehe zur Dokumentation dieser Datei
1#ifndef INC_GLOBASEALLSET_H
2#define INC_GLOBASEALLSET_H
3//-----------------------------------------------------------------------------
36//-----------------------------------------------------------------------------
37#include <list>
38#include "GloTypes.h"
39#include "GloAbstractBaseLot.h"
40#include "GloPersistent.h"
41//-----------------------------------------------------------------------------
42namespace glo
43{
44 //---------------------------------------------------------------------------
45 /* Forwards */
46 class AllSetIndexInfo;
47 //---------------------------------------------------------------------------
48 /* 'Bezeichner': Klasse 'Typ' benötigt eine DLL-Schnittstelle, die von... */
49 #ifdef _MSC_VER
50 #pragma warning( disable : 4251 )
51 #endif
52 //---------------------------------------------------------------------------
80 {
81 //-----------------------------------------------------------------------
82 // >>>>>>>>>>>>>>>>>>> IndexNameClassIdTuple >>>>>>>>>>>>>>>>>>>>>>>>>>>>
83 //-----------------------------------------------------------------------
97 {
98 //---------------------------------------------------------------------
110 unsigned long m_ulIndexClassID;
111 //---------------------------------------------------------------------
124 std::string m_sIndexName;
125 //---------------------------------------------------------------------
136 //---------------------------------------------------------------------
153 IndexNameClassIdTuple( unsigned long ulIndexClassID, const std::string & rsIndexName );
154 //---------------------------------------------------------------------
168 IndexNameClassIdTuple( const IndexNameClassIdTuple & rIndexNameClassIdTuple );
169 //---------------------------------------------------------------------
181 IndexNameClassIdTuple & operator= ( const IndexNameClassIdTuple & rIndexNameClassIdTuple );
182 //-----------------------------------------------------------------------
193 bool operator== ( const IndexNameClassIdTuple & rIndexNameClassIdTuple ) const;
194 bool operator!= ( const IndexNameClassIdTuple & rIndexNameClassIdTuple ) const;
196 //-----------------------------------------------------------------------
197 };
198 //-----------------------------------------------------------------------
199 // <<<<<<<<<<<<<<<<<<< IndexNameClassIdTuple <<<<<<<<<<<<<<<<<<<<<<<<<<<<
200 //-----------------------------------------------------------------------
201
202 private:
203 //============== Friends
204 //-----------------------------------------------------------------------
205 friend class Base;
206 friend class PrivateBase;
207 //-----------------------------------------------------------------------
208
209 //============== Attribute
210 //-----------------------------------------------------------------------
221 //-----------------------------------------------------------------------
233 unsigned long m_ulClassID;
234 //-----------------------------------------------------------------------
253 //-----------------------------------------------------------------------
269 //-----------------------------------------------------------------------
283 std::vector<AllSetIndexInfo> m_AvailableIndices;
284 //-----------------------------------------------------------------------
301 //-----------------------------------------------------------------------
302
303 public:
304 //============== Konstruktoren
305 //-----------------------------------------------------------------------
316 //-----------------------------------------------------------------------
330 BaseAllSet( Base & rBase );
331 //-----------------------------------------------------------------------
351 BaseAllSet( Base & rBase, unsigned long ulClassID, bool bWithSubClasses = true );
352 //-----------------------------------------------------------------------
374 BaseAllSet( Base & rBase, unsigned long ulClassID, const std::string & rsFullIndexName );
375 //-----------------------------------------------------------------------
386 virtual ~BaseAllSet();
387 //-----------------------------------------------------------------------
388
389 private:
390 //============== Konstruktoren
391 //-----------------------------------------------------------------------
402 //-----------------------------------------------------------------------
403
404 private:
405 //============== Methoden
406 //-----------------------------------------------------------------------
429 int init( Base & rBase );
430 //-----------------------------------------------------------------------
453 const std::string & rsIndexName );
454 //-----------------------------------------------------------------------
478 BaseAllSet::IndexNameClassIdTuple getIndexNameClassIdTuple( const std::string & rsFullIndexName );
479 //-----------------------------------------------------------------------
480
481 public:
482 //============== Methoden
483 //-----------------------------------------------------------------------
499 virtual int getTypeAsString ( std::string & rsTypeName ) override;
500 //-----------------------------------------------------------------------
516 virtual std::size_t size() const override;
517 //-----------------------------------------------------------------------
545 virtual void setBase( Base * pBase ) override;
546 //-----------------------------------------------------------------------
569 virtual void setBase( Base & rBase );
570 //-----------------------------------------------------------------------
587 int open();
588 //-----------------------------------------------------------------------
602 int close();
603 //-----------------------------------------------------------------------
615 unsigned long getClassID() const;
616 //-----------------------------------------------------------------------
652 int getObjID( ObjID & rObjID, EnSeekMode eMode );
653 //-----------------------------------------------------------------------
681 int setFullIndexName( const std::string & rsFullIndexName );
682 //-----------------------------------------------------------------------
702 int setIndex( const BaseAllSet::IndexNameClassIdTuple & rIndexNameClassIdTuple );
703 //-----------------------------------------------------------------------
719 std::string getFullIndexName() const;
720 //-----------------------------------------------------------------------
735 std::string getIndexName() const;
736 //-----------------------------------------------------------------------
751 unsigned long getIndexClassID() const;
752 //-----------------------------------------------------------------------
770 //-----------------------------------------------------------------------
787 std::vector<AllSetIndexInfo> getAvailableIndices();
788 //-----------------------------------------------------------------------
802 bool isIndexAvailable( const BaseAllSet::IndexNameClassIdTuple & rIndexNameClassIdTuple );
803 //-----------------------------------------------------------------------
819 bool isIndexAvailable( unsigned long ulClassID, const std::string & rsIndexName );
820 //-----------------------------------------------------------------------
845 bool isIndexAvailable( const std::string & rsFullIndexName );
846 //-----------------------------------------------------------------------
867 int setIndexFilter( const std::string & rsIndexFilter );
868 //-----------------------------------------------------------------------
903 int setIndexFilter( const std::string & rsIndexFilter,
904 EnComparisionOp eComparisionOp );
905 //-----------------------------------------------------------------------
937 int setIndexFilter( const std::string & rsRangeStartIndexFilter,
938 const std::string & rsRangeEndIndexFilter );
939 //-----------------------------------------------------------------------
952 //-----------------------------------------------------------------------
982 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
983 const std::string & rsIndexSearchValue,
984 EnQueryType eQuerryType );
985 //-----------------------------------------------------------------------
1017 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1018 const std::string & rsIndexName,
1019 const std::string & rsIndexSearchValue,
1020 EnQueryType eQuerryType );
1021 //-----------------------------------------------------------------------
1058 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1059 const std::string & rsIndexName,
1060 unsigned long ulIndexClassID,
1061 const std::string & rsIndexSearchValue,
1062 EnQueryType eQuerryType );
1063 //-----------------------------------------------------------------------
1101 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1102 const std::string & rsIndexSearchValue,
1103 EnComparisionOp eComparisionOp );
1104 //-----------------------------------------------------------------------
1144 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1145 const std::string & rsIndexName,
1146 const std::string & rsIndexSearchValue,
1147 EnComparisionOp eComparisionOp );
1148 //-----------------------------------------------------------------------
1193 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1194 const std::string & rsIndexName,
1195 unsigned long ulIndexClassID,
1196 const std::string & rsIndexSearchValue,
1197 EnComparisionOp eComparisionOp );
1198 //-----------------------------------------------------------------------
1233 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1234 const std::string & rsRangeStartIndexSearchValue,
1235 const std::string & rsRangeEndIndexSearchValue );
1236 //-----------------------------------------------------------------------
1272 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1273 const std::string & rsIndexName,
1274 const std::string & rsRangeStartIndexSearchValue,
1275 const std::string & rsRangeEndIndexSearchValue );
1276 //-----------------------------------------------------------------------
1317 int getIndexedObjIds( std::list< ObjID > & rObjIDList,
1318 const std::string & rsIndexName,
1319 unsigned long ulIndexClassID,
1320 const std::string & rsRangeStartIndexSearchValue,
1321 const std::string & rsRangeEndIndexSearchValue );
1322 //-----------------------------------------------------------------------
1346 virtual bool inLot( const ObjID & rObjID ) const override;
1347 //-----------------------------------------------------------------------
1369 virtual bool inSet( const ObjID & rObjID ) const;
1370 //-----------------------------------------------------------------------
1386 virtual int setCurrentObject( const ObjID & rObjID ) override;
1387 //-----------------------------------------------------------------------
1401 virtual int setPosition( std::size_t nPosition ) override;
1402 //-----------------------------------------------------------------------
1403 //-----------------------------------------------------------------------
1404 // doxygen -> warning: unable to resolve reference to 'PAGE_GLO_WATCH_NOTIFY' for \ref command
1405 // is a reference to the GlobalObjects documentation.
1406 //-----------------------------------------------------------------------
1455 virtual int setWatch( TdWatchNotifyMode ulWatchMode,
1456 CallBack * pCallBack = 0 ) = 0;
1457 //-----------------------------------------------------------------------
1497 virtual int unsetWatch( TdWatchNotifyMode ulWatchMode,
1498 CallBack * pCallBack = 0 ) = 0;
1499 //-----------------------------------------------------------------------
1518 void setReadWithSubClasses( bool bWithSubClasses );
1519 //-----------------------------------------------------------------------
1534 //-----------------------------------------------------------------------
1535
1536 protected:
1537 //============== Methoden
1538 //-----------------------------------------------------------------------
1556 virtual void setClassID( unsigned long ulClassID );
1557 //-----------------------------------------------------------------------
1568 void setClassIDFromTemplate( unsigned long ulClassID );
1569 //-----------------------------------------------------------------------
1585 void setAllSetOpen( bool bOpen );
1586 //-----------------------------------------------------------------------
1601 //-----------------------------------------------------------------------
1602
1603 private:
1604 //============== Operatoren
1605 //-----------------------------------------------------------------------
1615 inline BaseAllSet & operator= ( const BaseAllSet & );
1616 //-----------------------------------------------------------------------
1617 };
1618 //---------------------------------------------------------------------------
1619 /* 'Bezeichner': Klasse 'Typ' benötigt eine DLL-Schnittstelle, die von... */
1620 #ifdef _MSC_VER
1621 #pragma warning( default : 4251 )
1622 #endif
1623 //---------------------------------------------------------------------------
1624} // namespace glo
1625#endif
Header für AbstractBaseLot
Header für Persistent
Für jede Bibliothek, hier 'GlobalObjects' gibt es eine Typen-Datei.
#define __glo_export_dll
Definition GloTypes.h:63
Die Basisklasse für Container mit persistenten Objekten.
Definition GloAbstractBaseLot.h:62
Ist die Basisklasse von Template-AllSets und dem generischen AllSet.
Definition GloBaseAllSet.h:80
unsigned long m_ulClassID
Definition GloBaseAllSet.h:233
int setAvailableIndices()
std::vector< AllSetIndexInfo > getAvailableIndices()
std::vector< AllSetIndexInfo > m_AvailableIndices
Definition GloBaseAllSet.h:283
BaseAllSet::IndexNameClassIdTuple getIndexNameClassIdTuple(unsigned long ulClassID, const std::string &rsIndexName)
bool m_AvailableIndicesRead
Definition GloBaseAllSet.h:300
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexName, unsigned long ulIndexClassID, const std::string &rsIndexSearchValue, EnQueryType eQuerryType)
std::string getFullIndexName() const
bool m_bWithSubClasses
Definition GloBaseAllSet.h:252
bool isIndexAvailable(const BaseAllSet::IndexNameClassIdTuple &rIndexNameClassIdTuple)
unsigned long getIndexClassID() const
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexName, unsigned long ulIndexClassID, const std::string &rsRangeStartIndexSearchValue, const std::string &rsRangeEndIndexSearchValue)
std::string getIndexName() const
int setIndexFilter(const std::string &rsRangeStartIndexFilter, const std::string &rsRangeEndIndexFilter)
BaseAllSet(Base &rBase)
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexName, const std::string &rsIndexSearchValue, EnComparisionOp eComparisionOp)
void setClassIDFromTemplate(unsigned long ulClassID)
bool isIndexAvailable(const std::string &rsFullIndexName)
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsRangeStartIndexSearchValue, const std::string &rsRangeEndIndexSearchValue)
void setReadWithSubClasses(bool bWithSubClasses)
virtual int setCurrentObject(const ObjID &rObjID) override
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexSearchValue, EnQueryType eQuerryType)
bool readWithSubClasses() const
virtual ~BaseAllSet()
BaseAllSet(const BaseAllSet &)
virtual int getTypeAsString(std::string &rsTypeName) override
virtual bool inLot(const ObjID &rObjID) const override
int getObjID(ObjID &rObjID, EnSeekMode eMode)
IndexNameClassIdTuple m_IndexNameWithClassID
Definition GloBaseAllSet.h:268
void setAllSetOpen(bool bOpen)
virtual void setClassID(unsigned long ulClassID)
int setIndexFilter(const std::string &rsIndexFilter, EnComparisionOp eComparisionOp)
std::size_t getAvailableIndicesSize()
virtual void setBase(Base *pBase) override
virtual int unsetWatch(TdWatchNotifyMode ulWatchMode, CallBack *pCallBack=0)=0
virtual bool inSet(const ObjID &rObjID) const
virtual void setBase(Base &rBase)
int setIndex(const BaseAllSet::IndexNameClassIdTuple &rIndexNameClassIdTuple)
BaseAllSet(Base &rBase, unsigned long ulClassID, bool bWithSubClasses=true)
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexName, unsigned long ulIndexClassID, const std::string &rsIndexSearchValue, EnComparisionOp eComparisionOp)
BaseAllSet(Base &rBase, unsigned long ulClassID, const std::string &rsFullIndexName)
int removeIndexFilter()
BaseAllSet::IndexNameClassIdTuple getIndexNameClassIdTuple(const std::string &rsFullIndexName)
bool m_bAllSetOpen
Definition GloBaseAllSet.h:220
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexName, const std::string &rsIndexSearchValue, EnQueryType eQuerryType)
bool isIndexAvailable(unsigned long ulClassID, const std::string &rsIndexName)
unsigned long getClassID() const
virtual std::size_t size() const override
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexSearchValue, EnComparisionOp eComparisionOp)
int init(Base &rBase)
int getIndexedObjIds(std::list< ObjID > &rObjIDList, const std::string &rsIndexName, const std::string &rsRangeStartIndexSearchValue, const std::string &rsRangeEndIndexSearchValue)
int setIndexFilter(const std::string &rsIndexFilter)
int setFullIndexName(const std::string &rsFullIndexName)
virtual int setPosition(std::size_t nPosition) override
virtual int setWatch(TdWatchNotifyMode ulWatchMode, CallBack *pCallBack=0)=0
Diese Klasse ist die Schnittstelle zu den persistenten Objekten. Hier können "Objekte" angemeldet,...
Definition GloBase.h:250
Oberklasse für die Klassen, welche mit einer Base 'verbunden' sind.
Definition GloCallBack.h:74
Ein Objekt-ID besteht aus der Klassen-ID, einer Datenbank-ID und der eigentlichen eindeutigen ObjektZ...
Definition GloObjID.h:77
In dieser Klasse werden Funktionen für Base gekapselt. Für den Fall, dass sich Änderungen in der Funk...
Definition GloPrivateBase.h:92
Definition GloAbstractBaseLot.h:42
EnComparisionOp
Definition GloTypes.h:1583
EnSeekMode
Definition GloTypes.h:166
EnQueryType
Definition GloTypes.h:1179
unsigned long TdWatchNotifyMode
Definition GloTypes.h:543
Tuple von IndexName und die Klassen-ID der indizierten Klasse.
Definition GloBaseAllSet.h:97
std::string m_sIndexName
Definition GloBaseAllSet.h:124
unsigned long m_ulIndexClassID
Definition GloBaseAllSet.h:110
IndexNameClassIdTuple(unsigned long ulIndexClassID, const std::string &rsIndexName)
IndexNameClassIdTuple(const IndexNameClassIdTuple &rIndexNameClassIdTuple)