3.1.4.1.2 IManagedObject::GetObjectIdentity (Opnum 4)

The IManagedObject::GetObjectIdentity method is used by a CLR instance to determine whether a COM object entering the system is really a managed object that originated in this CLR instance and within the current process division.

 HRESULT GetObjectIdentity(
   [out] BSTR* pBSTRGUID,
   [out] int* AppDomainID,
   [out] CCW_PTR pCCW
 );

pBSTRGUID: The pBSTRGUID parameter is a GUID ([MS-DTYP] section 2.3.4.3). The pBSTRGUID parameter MUST indicate the CLR instance in which this object was created.

AppDomainID: Optional parameter that contains implementation-specific, opaque, process-unique identifiers. If present, the AppDomainID parameter MUST denote the process subdivision in which this object resides.

pCCW: Optional field. Implementation-specific, opaque value that helps identify the managed object. If present, this field MUST map back to the implementation's internal representation of a managed object.

Return Values: The method MUST return a positive value or 0 to indicate successful completion or a negative value to indicate failure.

Return value/code

Description

0x00000000

ERROR_SUCCESS

Success

Exceptions Thrown: No exceptions are thrown from this method beyond those thrown by the underlying RPC protocol.