#include <databaseObject.h>
Protected Member Functions | |
virtual void | onCreate () |
This method is invoked after an implicit object instance is created using DbPtr<T>(). |
DatabaseObject descendants are persistent classes that describe identity of their instances as a list of key attributes - KeyValues. Database objects do not necessarily need to have any identity defined as they may represent for example aggregate query results. DatabaseObject -s with the key attributes defined can be mapped into database tables. They even support vertical and horizontal database mapping. However, the subclasses have to share the same set of key attributes. This enables inheritance, but polymorphism is somewhat limited as IOPC 2 is not capable of recovering the effective type of an object from a set of key attribute values. IOPC 2 doesn't generate structures for classname resolution based on the key values, so when loading an object identified by its key values, the type of the loaded object must be specified. That is also the reason why filtered mapping is not supported for non-OID objects.
virtual void iopc::DatabaseObject::onCreate | ( | ) | [inline, protected, virtual] |
This method is invoked after an implicit object instance is created using DbPtr<T>().
This method sould not be overriden by users.
Reimplemented in iopc::OidObject.