Overview | The lookup_name operation is used to locate an object by name within a particular object or within the objects contained by that object. |
Original interface | CORBA module: Container Interface |
Exceptions | CORBA::SystemException |
Intended Usage
The lookup_name operation is used to locate an object by name within a particular object or within the objects contained by that object. The parameters to the lookup_name operation specify the name for the search, the number of levels to search, the type of objects to be examined in the search, and whether containment by inheritance should be included.
Syntax
ContainedSeq lookup_name (in Identifier search_name, in long levels_to_search, in DefinitionKind limit_type, in boolean exclude_inherited);
Input parameters
An object can be contained within another object because it is defined within the containing object (for example, an interface is contained within a module). It may also be defined as contained because it is inherited by the containing object (for example, an operation may be contained by an interface because the interface inherits the operation from another interface).
When exclude_inherited is TRUE, inherited objects, if present, are not returned. If exclude_inherited is FALSE, all contained objects (whether contained due to inheritance or because they were defined within the object) are returned.
Return values
Example
// C++ // assume 'repository_ptr' is already initialized CORBA::Repository * repository_ptr; // search for a specific interface name CORBA::ContainedSeq * cont_seq; cont_seq = repository_ptr-> lookup_name ("Interface1", -1, CORBA::dk_Interface, 0);