Appends or replaces a profile in an IOR. If the specified profile exists, the component is replaced. This can be suppressed by using the flag IIOP_NO_REPLACE. If a replacement is impossible because of an invalid profile index, the function appends the component to the list. This again can be suppressed with the flag IIOP_NO_APPEND.
IIOP.bdh
IiopObjectSetProfile( in hIiop : number, in nProfile : number, in nProfileTag : number, in sProfileData : string, in sProfileLen : number optional ): boolean;
true if successful
false otherwise
Parameter | Description |
---|---|
hIiop | Handle to a CORBA object. |
nProfile |
Index of the profile. Set this parameter to IIOP_FIRST or IIOP_LAST for the first or the last profile, respectively. In addition, you can supply either the IIOP_NO_REPLACE or the IIOP_NO_APPEND flag. The index of the first profile is zero (0). |
nProfileTag | Profile tag as described in the CORBA specification. |
sProfileData | Profile data containing the byte order flag as described in the CORBA specification. |
sProfileLen | Amount of profile data in bytes (optional). |
var hBank, hSSLBank, hCombined: number; dcltrans transaction TMain var sData : string; nType : number; begin // create an empty object IiopObjectCreate(hCombined, "", "", "", 0, "",0); // copy profile of bank object using SSL IiopObjectGetProfile(hSSLBank, IIOP_FIRST, nType, sData); IiopObjectSetProfile(hCombined, IIOP_NO_REPLACE, nType, sData); // copy profile of bank object IiopObjectGetProfile(hBank, IIOP_FIRST, nType, sData); IiopObjectSetProfile(hCombined, IIOP_NO_REPLACE, nType, sData); IiopSetString(hCombined, "James Smith"); IiopRequest(hCombined, "open"); end TMain;