VMS Help DCE_RPC, Application Routines, idl_es_encode_fixed_buffer *Conan The Librarian (sorry for the slow response - running on an old VAX) |
NAME idl_es_encode_fixed_buffer - Returns a fixed buffer encoding handle to the IDL encoding services SYNOPSIS void idl_es_encode_fixed_buffer( idl_byte *data_buffer, idl_ulong_int data_buffer_size, idl_ulong_int *encoded_buffer_size, idl_es_handle_t *es_handle, error_status_t *status ); PARAMETERS Input data_buffer The address of the application-supplied buffer. This address must be 8-byte aligned. data_buffer_size The size of the application-supplied buffer. The size must be a multiple of 8 bytes. Output encoded_buffer_size Returns the address to which the IDL encoding services write the size of the encoded buffer when they have completed encoding the data. es_handle Returns the address of an IDL encoding services handle for use by a client or server encoding operation. status Returns the status code from this routine. This status code indicates whether the routine completed successfully or, if not, why not. The possible status codes and their meanings are as follows: rpc_s_ok Success. rpc_s_bad_buffer Bad buffer operation. rpc_s_no_memory Insufficient memory available to complete operation. DESCRIPTION The IDL encoding services provide client and server RPC applications with a method for encoding data types in input parameters into a byte stream and decoding data types in output parameters from a byte stream without invoking the RPC runtime. Encoding and decoding operations are analogous to marshalling and unmarshalling, except that the data is stored locally, and is not transmitted over the network. Client and server applications can use the IDL encoding services to create persistent storage for their data. Encoding "flattens" complex data types into a byte stream for storage on disk, while decoding restores the flattened data to complex form. The idl_es_encode_fixed_buffer() routine belongs to a set of routines that return handles to the IDL encoding services for use by client and server encoding and decoding operations. The information in the handle controls the way in which the IDL encoding services manage memory when encoding or decoding data. The idl_es_encode_fixed_buffer() routine returns a fixed buffer encoding handle, which directs the IDL encoding services to encode data into a single buffer that the application has provided. The fixed buffer encoding style is useful for applications that need only one buffer for their encoding and decoding process. The buffer that the application allocates must be large enough to hold all of the encoded data, and must also allocate 56 bytes for each encoding operation that the application has defined (this space is used to hold per-operation header information.) RETURN VALUES None. RELATED INFORMATION Functions: idl_es_encode_dyn_buffer idl_es_encode_incremental
|