Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ rpc_object_set_inq_fn(3) — OSF1 1.0

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

rpc_object_inq_type(3)

rpc_object_set_type(3)

rpc_object_set_inq_fn(3)  —  Subroutines

NAME

rpc_object_set_inq_fn - Registers an object inquiry function

Used by server applications. 

SYNOPSIS

#include <dce/rpc.h>
void rpc_object_set_inq_fn(

rpc_object_inq_fn_t ∗inquiry_fn ,
unsigned32 ∗status );

PARAMETERS

Input

inquiry_fnSpecifies a pointer to an object type inquiry function. When an application calls the rpc_object_inq_type routine and the RPC runtime finds that the specified object is not registered, the runtime automatically calls the rpc_object_inq_type routine to determine the object’s type.  Specify NULL to remove a previously set inquiry function.  The following C language definition for rpc_object_inq_fn_t illustrates the prototype for this function:

typedef void (∗rpc_object_inq_fn_t)
(
    uuid_t       ∗object_uuid,  /∗ in  ∗/
    uuid_t       ∗type_uuid,    /∗ out ∗/
    unsigned32   ∗status        /∗ out ∗/
);

The returned type_uuid and status values are returned as the output arguments from the rpc_object_inq_type routine.  If you specify NULL, the rpc_object_set_inq_fn routine unregisters (that is, removes) a previously registered object type inquiry function. 

Output

statusReturns the status code from this routine.  This status code indicates whether the routine completed successfully or, if not, why not.  The possible status code and its meaning is as follows:

rpc_s_okSuccess. 

DESCRIPTION

A server application calls the rpc_object_set_inq_fn routine to specify a function to determine an object’s type.  If an application privately maintains object/type registrations, the specified inquiry function returns the type UUID of an object from that registration. 

The RPC runtime automatically calls the inquiry function when the application calls routine rpc_object_inq_type and the object was not previously registered by the rpc_object_set_type routine.  The RPC runtime also automatically calls the inquiry function for every remote procedure call it receives if the object was not previously registered. 

Note: Use this routine with caution.  When the RPC runtime automatically calls this routine in response to a received remote procedure call, the inquiry function can be called from the context of runtime internal threads with runtime internal locks held.  The inquiry function should not block or at least not block for long (for example, the inquiry function should not perform a remote procedure call).  Also, the inquiry function must not unwind because of an exception.  In general, the inquiry function should not call back into the RPC runtime.  It is legal to call routine rpc_object_set_type or any of the uuid_∗ routines.  Failure to comply with these restrictions will result in undefined behavior. 

RETURN VALUES

None. 

RELATED INFORMATION

Functions: rpc_object_inq_type(3), rpc_object_set_type(3)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026