|
BankAndCustomer
|
The base class of a reference attribute from persistent objects to other persistent objects in the database. More...
#include <GloReference.h>


Public Member Functions | |
| Reference () | |
| Reference (const ObjID &rObjID) | |
| Reference (const Reference &rT) | |
| virtual | ~Reference () |
| virtual Base * | getBase () const override |
| virtual int | getTypeAsString (std::string &rsTypeName) override |
| bool | isNULL () const |
| void | setNULL () |
| ObjID | getObjID () const |
| const ObjID * | getObjIDAsPointer () const |
| virtual int | set (const ObjID &rObjID) |
| virtual int | set (const BasePersistent *pObj) |
| virtual int | set (const BasePersistent &rObj) |
| int | getBasePersistent (BasePersistent *&prRetVal) |
| int | getBasePersistent (std::shared_ptr< BasePersistent > &rspRetVal) |
| virtual int | deleteInBase (EnDeepMode eDeepMode=DM_SHALLOW) |
| virtual int | lock (EnLockMode eLockMode=LK_DELETEvWRITE, EnDeepMode eDeepMode=DM_SHALLOW) const |
| virtual int | lock (const LockSpecification &rLockSpecification) const |
| virtual int | unlock (EnLockMode eLockMode=LK_DELETEvWRITE, EnDeepMode eDeepMode=DM_SHALLOW) const |
| virtual int | unlock (const LockSpecification &rLockSpecification) const |
| virtual int | isLocked (EnLockMode eLockMode=LK_DELETEvWRITE, EnDeepMode eDeepMode=DM_SHALLOW) const |
| virtual int | isLocked (const LockSpecification &rLockSpecification) const |
| virtual int | isPossible (bool bRead, bool bWrite, bool bDelete, EnDeepMode eDeepMode=DM_SHALLOW) const |
| virtual int | isPossible (const LockPossibleSpecification &rLockPossibleSpec, EnDeepMode eDeepMode=DM_SHALLOW) const |
| virtual int | setWatch (TdWatchNotifyMode ulWatchMode, EnDeepMode eDeepMode, CallBack *pCallBack=0) const |
| virtual int | setWatch (const WatchSpecification &rWatchSpec) const |
| virtual int | unsetWatch (TdWatchNotifyMode ulWatchMode, EnDeepMode eDeepMode, CallBack *pCallBack) const |
| virtual int | unsetWatch (const WatchSpecification &rWatchSpec) const |
| Reference & | operator= (const Reference &rT) |
| bool | operator== (const Reference &rT) const |
| Comparison operator. | |
| bool | operator!= (const Reference &rT) const |
| Comparison operator. | |
Public Member Functions inherited from glo::CallBack | |
| CallBack () | |
| virtual | ~CallBack () |
| virtual int | setBase (Base *pBase) |
| virtual void | notify (NotifyNote &rNote) |
| CallBack & | operator= (const CallBack &rT) |
| bool | operator== (const CallBack &rT) const |
| Comparison operator, all attributes are compared. | |
| bool | operator!= (const CallBack &rT) const |
| Comparison operator, all attributes are compared. | |
Private Attributes | |
| ObjID | m_RefObjID |
Friends | |
| class | ObjectMaker |
| class | OndemandLot |
| class | OndemandList |
| class | OndemandSet |
| class | TableReaderInterface |
| class | BaseAllSet |
| class | Base |
| class | OdRefRecordAttribute |
Additional Inherited Members | |
Public Attributes inherited from glo::CallBack | |
| std::string | m_strDebugInfo |
Protected Member Functions inherited from glo::CallBack | |
| CallBack (const CallBack &rT) | |
| void | init () |
| void | deinit () |
The base class of a reference attribute from persistent objects to other persistent objects in the database.
| glo::Reference::Reference | ( | ) |
Standard constructor.
| glo::Reference::Reference | ( | const ObjID & | rObjID | ) |
Constructor with parameter passing.
| [in] | rObjID | The object ID of the object to be referenced can be specified during creation. |
| glo::Reference::Reference | ( | const Reference & | rT | ) |
Copy constructor.
| [in] | rT | The data is copied from this object. |
|
virtual |
Destructor.
|
virtual |
Referenced object is deleted from the database.
| [in] | eDeepMode | The Deep Mode |
|
overridevirtual |
Reimplemented from glo::CallBack.
| int glo::Reference::getBasePersistent | ( | BasePersistent *& | prRetVal | ) |
Returns the referenced object from the database (or from memory if already loaded).
| [in,out] | prRetVal | The referenced object. |
| int glo::Reference::getBasePersistent | ( | std::shared_ptr< BasePersistent > & | rspRetVal | ) |
Returns the referenced object from the database (or from memory if already loaded).
| [in,out] | rspRetVal | The referenced object. |
| ObjID glo::Reference::getObjID | ( | ) | const |
Returns the object ID of the reference.
| const ObjID * glo::Reference::getObjIDAsPointer | ( | ) | const |
Returns the object ID of the reference as pointer.
|
overridevirtual |
Returns the type of the reference, i.e. the class name as string when connected to the database.
| [in,out] | rsTypeName | The type name. |
Reimplemented from glo::CallBack.
|
virtual |
Checks if referenced object is locked in the database with the passed parameters.
| [in] | rLockSpecification | The lock and lock depth mode. |
|
virtual |
Checks if referenced object is locked in the database with the passed parameters.
| [in] | eLockMode | The lock mode. |
| [in] | eDeepMode | The lock depth mode. |
| bool glo::Reference::isNULL | ( | ) | const |
Checks if the reference is formally valid.
|
virtual |
Checks the allowed actions for the referenced object in the database.
| [in] | bRead | If true, the read permission is checked. |
| [in] | bWrite | If true, the write permission is checked. |
| [in] | bDelete | If true, a check is made for delete permissions. |
| [in] | eDeepMode | The depth mode for which it is checked. |
|
virtual |
Checks the allowed actions for the referenced object in the database.
| [in] | rLockPossibleSpec | The possibility request. |
| [in] | eDeepMode | The depth mode for which it is checked. |
|
virtual |
The referenced object is locked in the database for other clients.
| [in] | rLockSpecification | The lock- and lock depth mode. |
|
virtual |
The referenced object is locked in the database for other clients.
| [in] | eLockMode | The lock mode. |
| [in] | eDeepMode | The lock depth mode. |
| bool glo::Reference::operator!= | ( | const Reference & | rT | ) | const |
Comparison operator.
| [in] | rT | The object to be compared with this one. |
Assignment operator.
| [in] | rT | The data is transferred from this object. |
| bool glo::Reference::operator== | ( | const Reference & | rT | ) | const |
Comparison operator.
| [in] | rT | The object to be compared with this one. |
|
virtual |
Adopts the object ID of the passed object as reference. Both objects, this and the object to be referenced must be logged on to the same database.
| [in] | rObj | The object ID of the object to be referenced. |
Reimplemented in glo::TOndemand< T >, glo::TOndemand< Bank >, and glo::TOndemand< Person >.
|
virtual |
Adopts the object ID of the passed object as reference. Both objects, this and the object to be referenced must be logged on to the same database.
| [in] | pObj | The object ID of the object to be referenced. |
Reimplemented in glo::TOndemand< T >, glo::TOndemand< Bank >, and glo::TOndemand< Person >.
|
virtual |
Adopts the object ID.
| [in] | rObjID | The object ID of the object to be referenced. |
Reimplemented in glo::TOndemand< T >, glo::TOndemand< Bank >, and glo::TOndemand< Person >.
| void glo::Reference::setNULL | ( | ) |
Sets the reference to formally invalid.
|
virtual |
The referenced object is monitored in the database.
| [in] | rWatchSpec | The monitoring specification. |
|
virtual |
The referenced object is monitored in the database.
| [in] | ulWatchMode | The watch mode. Allowed watch modes:
|
| [in] | eDeepMode | The watching depth mode. |
| [in] | pCallBack | The CallBack object that is notified via its method CallBack::notify(NotifyNote&). If no CallBack is passed, notify(NotifyNote&) is taken from this; in this case the method notify(NotifyNote&) should be overwritten in the respective derived class. |
|
virtual |
The referenced object is released in the database. A lock release must be called with the same parameters as the previous lock call.
| [in] | rLockSpecification | The original lock and lock depth mode. |
|
virtual |
The referenced object is released in the database. A lock release must be called with the same parameters as the previous lock call.
| [in] | eLockMode | The original lock mode. |
| [in] | eDeepMode | The original lock depth mode. |
|
virtual |
The monitoring of the referenced object in the database is terminated. A monitoring termination must be called with the same parameters as the previous monitoring.
| [in] | rWatchSpec | The original monitoring specification. |
|
virtual |
The monitoring of the referenced object in the database is terminated. A monitoring termination must be called with the same parameters as the previous monitoring.
| [in] | ulWatchMode | The original watch mode. Allowed watch modes:
|
| [in] | eDeepMode | The original monitoring depth mode. |
| [in] | pCallBack | The CallBack object that is notified via its method CallBack::notify(NotifyNote&). If no CallBack is passed, notify(NotifyNote&) is taken from this; in this case the method notify(NotifyNote&) should be overwritten in the respective derived class. |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
private |
The reference to a persistent object as object ID.