PreviousNext

Interface Handle and Specification

An interface handle is a pointer-size opaque variable containing information the RPC runtime uses to access the interface specification data structure.

The DCE IDL compiler automatically creates an interface specification data structure from each IDL file and creates a global variable of type rpc_if_handle_t for the interface specification.

The DCE IDL compiler places an interface handle declaration in the generated interface-name.h file. The compiler generates this include file for each interface.

Routines requiring the interface handle as an argument show a data type of rpc_if_handle_t.

The form of each interface handle name is as follows:

· For the client:
if-name
_vmajor-version_minor-version_c_ifspec

· For the server:
if-name_vmajor-version_minor-version_s_ifspec

where

· The if-name variable is the interface identifier specified in the IDL file.

· The major-version variable is the interface's major-version number specified in the IDL file.

· The minor-version variable is the interface's minor-version number specified in the IDL file.

An example is notes_v1_2_c_ifspec

The maximum combined length of the interface identifier and interface version number is 19 characters.

Since the major-version and minor-version numbers must each be at least 1 character, the interface name can be no more than 17 characters. This limits the interface handle name to 31 or fewer characters.

No concurrency control is required for interface handles.

The following routines require an interface handle and show an argument data type of rpc_if_handle_t:

· rpc_ep_register( )

· rpc_ep_register_no_replace( )

· rpc_ep_resolve_binding( )

· rpc_ep_unregister( )

· rpc_if_inq_id( )

· rpc_ns_binding_export( )

· rpc_ns_binding_import_begin( )

· rpc_ns_binding_lookup_begin( )

· rpc_ns_binding_unexport( )

· rpc_server_inq_if( )

· rpc_server_register_if( )

· rpc_server_unregister_if( )

· rpc_server_use_all_protseqs_if( )

· rpc_server_use_protseq_if( )