rpc_object_set_type- registers the type of an object with the RPC run-time system
#include <dce/rpc.h>
void rpc_object_set_type(
uuid_t *obj_uuid,
uuid_t *type_uuid,
unsigned32 *status);
Input
- obj_uuid
- Specifies an object UUID to associate with the type UUID in the type_uuid argument. This may not be the nil UUID.
- type_uuid
- Specifies the type UUID of the obj_uuid argument.
Specify the nil UUID to reset the object type to the default association of object UUID/nil type UUID.
Output
- status
- Returns the status code from this routine. The status code indicates whether the routine completed successfully, or if not, why not.
Possible status codes and their meanings include:
- rpc_s_ok
- Success.
- rpc_s_already_registered
Object already registered.
- rpc_s_invalid_object
Invalid object.
The rpc_object_set_type() routine assigns a type UUID to an object UUID.By default, the RPC run-time system assumes that the type of all objects is nil. A server program that contains one implementation of an interface (one manager entry point vector) does not need to call this routine, provided that the server registered the interface with the nil type UUID (see
tagmref_rpc_server_register_if for a description).A server program that contains multiple implementations of an interface (multiple manager entry point vectors; that is, multiple type UUIDs) calls this routine once for each non-default object UUID the server offers. Associating each object with a type UUID tells the RPC run-time system which manager entry point vector (interface implementation) to use when the server receives a remote procedure call for a non-nil object UUID.
The RPC run-time system allows an application to set the type for an unlimited number of objects.
To remove the association between an object UUID and its type UUID (established by calling this routine), a server calls this routine again and specifies the nil UUID for the type_uuid argument. This resets the association between an object UUID and type UUID to the default.
A server cannot register a nil object UUID. The RPC run-time system automatically registers the nil object UUID with a nil type UUID. Attempting to set the type of a nil object UUID will result in the routine's returning the status code rpc_s_invalid_object.
Servers that want to maintain their own object UUID to type UUID mapping can use the rpc_object_set_inq_fn() routine in place of, or in addition to, the rpc_object_set_type() routine.
None.
rpc_object_set_inq_fn()
Please note that the html version of this specification may contain formatting aberrations. The definitive version is available as an electronic publication on CD-ROM from The Open Group.
Contents | Next section | Index |