IiopOrbixServerBind Function

Action

Uses the Orbix daemon to retrieve a handle to a specified CORBA object. This function requests the getIIOPDetails operation provided by the Orbix daemon to get the IOR, and establishes an object handle used to reference to the object.

Include file

IIOP.bdh

Syntax

IiopOrbixServerBind( in hDaemon  : number,
                     in sHost    : string,
                     in sServer  : string,
                     in sMarker  : string,
                     in sIfrName : string ) : number;

Return value

  • Handle to the OrbixWeb object if successful

  • 0 if an error occurred

Parameter Description
hDaemon Handle to the Orbix daemon
sHost Orbix host
sServer Server name
sMarker Marker name of the object. If NULL, any OrbixWeb object will match
sIfrName Interface Repository name of the object. Pass only the object name to the function, neither the "IDL:" prefix, nor the "1.2" suffix

Example

dcltrans
  transaction TMain
  const
    ORBIX_HOST := "192.168.20.55"; // Orbix host
    ORBIX_PORT := 1571; // default Orbix port
  var
    hDaemon, hBank: number;
  begin
    // global settings
    IiopSetMaxGiopVersion("1.2");
    IiopSetByteOrder(IIOP_LITTLE_ENDIAN);
    IiopSetPrincipal("principal", Strlen("principal")+1);
    // OrbixWeb bootstrapping
    hDaemon := IiopOrbixDaemonBind(ORBIX_HOST, ORBIX_PORT);
    // get object reference handle to bank object
    hBank := IiopOrbixServerBind(hDaemon, ORBIX_HOST,
                                 "bank", "", "bank");

    // release objects
    IiopObjectRelease(hDaemon);
    IiopObjectRelease(hBank);
  end TMain;

Sample scripts

AnyDemo.bdf, AsyncBank.bdf, Bank.bdf, Callback.bdf, SimpleAsyncBank.bdf, TypeTest.bdf

You can find the sample script(s) here: <Public documents>\Silk Performer <version>\Samples\Corba