OSF DCE Application Development Guide--Core Components

OSF DCE Application Development Guide—Core Components
The cs_char attribute, which associates the local data type that the application code
uses to represent international characters in the local code set with the special
typedef defined in the .idl file. This is a required ACF attribute for an RPC
application that passes international character data. Chapter 18 provides complete
details on how to specify the cs_char ACF attribute and the programming restrictions
associated with its use.
The cs_stag, cs_drtag, and cs_rtag attributes, for each operation in the interface that
specifies sending tag, desired receiving tag, and/or receiving tag parameters. These
ACF attributes declare the tag parameters defined in the corresponding .idl file to be
special code set tag parameters. Operations defined in the .idl file that specify
international character in input parameters must use the cs_stag attribute. Operations
defined in the .idl file that specify international character in output parameters must
use the cs_drtag and cs_rtag attributes. Chapter 18 provides complete details on
how to specify the cs_stag, cs_drtag, and cs_rtag ACF attributes.
The cs_tag_rtn attribute, which specifies the name of a routine that the client and
server stubs will call to set an operation’s code set tag parameters to specific code set
values. The cs_tag_rtn attribute is an optional ACF attribute for internationalized
RPC applications; application developers can use it to provide code set tag
transparency for callers of their application’s operations. See Chapter 18 for
complete details on how to specify the cs_tag_rtn attribute. Section 15.3.3.3
provides more information on the role of the tag-setting routine.
Here is the companion .acf file for the cs_test interface defined in Section 15.3.1:
[
explicit_handle
]
interface cs_test
{
include "dce/codesets_stub";
typedef [cs_char(cs_byte)] net_byte;
[comm_status, cs_tag_rtn(rpc_cs_get_tags)] cs_fixed_trans (
[cs_stag] stag,
[cs_drtag] drtag,
[cs_rtag] p_rtag );
The ACF for cs_test uses the cs_char attribute to define net_byte as a data type that
represents international characters. Note that the local type specified in the cs_char
attribute definition is cs_byte. This local type is analogous to the byte type. The ACF
for cs_test also uses the cs_tag_rtn attribute to specify a tag-setting routine.
15.3.3 Writing the Stub Support Routines
When you use the cs_char attribute to define an international character data type, you
must provide stub support routines that check the buffer storage requirements for
character data to be converted and stub support routines that perform the conversions
15 10 Tandem Computers Incorporated 124245