SECTION 20.2
CORBA RMI
843
IIDL type identifiers ◊ Section 20.2.2 mentioned that type identifiers are generated by the IDL compiler for each type in an IDL interface. For example, the
IDL type for the interface Shape type (Figure 20.7) might be:
IDL:Whiteboard/Shape:1.0This example shows that an IDL type name has three parts – the IDL prefix, a type name and aversion number. Since interface identifiers are used as keys for accessing interface definitions in the interface repository, programmers must ensure that they provide a unique mapping to the interfaces themselves. A programmer may use the IDL prefix pragma to prefix an additional string to the type name in order to distinguish their own types from those of others.
IDL pragma directives
These allow additional, non-IDL properties to be specified for components in an IDL interface (see Henning and Vinoski [1999]). These properties include, for example, specifying that an interface
will be used only locally, or supplying the value of an interface repository ID. Each pragma is introduced by
#pragma and specifies its type, for example:
#pragma version Whiteboard 2.38>
Share with your friends: