Previous Table of Contents Next


3.15.1 Repository Identity Declaration


   The syntax of a repository identity declaration is as follows:

   (102) <type_id_dcl> ::= “typeid? <scoped_name> <string_literal>

   A repository identifier declaration includes the following elements:

   The <scoped_name> is resolved according to normal IDL name resolution rules, based on the scope in which the declaration occurs. It must denote a previously-declared name of one of the following IDL constructs:

   The value of the string literal is assigned as the repository identity of the specified type definition. This value will be returned as the RepositoryId by the interface repository definition object corresponding to the specified type definition. Language mappings constructs, such as Java helper classes, that return repository identifiers shall return the values declared for their corresponding definitions.

   At most one repository identity declaration may occur for any named type definition. An attempt to redefine the repository identity for a type definition is illegal, regardless of the value of the redefinition.

   If no explicit repository identity declaration exists for a type definition, the repository identifier for the type definition shall be an IDL format repository identifier, as defined in Section 10.7.1, “OMG IDL Format,? on page 10-65.