DBaddMasterElement

Top  Previous  Next

Master element in object add.

A master Member connection produces a respect between an object as a master and several objects as a Member. This respect has a name. Every object can own only one respect as a master with this name. However, it can own at the same time a master and a Member respect under the same name. Also an object can have several master connections and several Member connections. The order of the Member objects in a connection is continual. To an object with a master connection the Member objects can be enumerated. Also the accompanying master can be found to a Member. If the master is extinguished, all Member which existed in this master are also extinguished. This also happens if only the element is extinguished which represents a master Member connection. A master object cannot be at the same time Member of this connection. A Member cannot be several times Member of the same master Member connection.

DBaddMasterElement opens a new master Member connection. This is empty at the time of the Erzeugens, i.e. no Member objects exist to this master. The connection is put on in the object object and receives the name name. If already such a connection exists in this object, an error message is generated.

Parametre

object (POBJECT) [IN]

The new master connection is put on in this object. The object may not be yet a master of a connection with this name.

set (PSET_ELEMENT) [IN]

The new connection receives this name.

Result

(PMASTER_ELEMENT) [OUT]

If the connection could be put on, this is the trading of the anew generated element. But one becomes zero-acts as a result delivered.

Declaration

#include "database.h"

 

PMASTER_ELEMENT DLLENTRY DBaddMasterElement (

POBJECT object,

PSET_ELEMENT set

);

 

Related function

DBaddMemberElement