Implementing an Interface
One-to-one mappings that reference interfaces that have multiple implementors are known as variable one-to-one mappings. See "Working with Java Object Relationship Mappings" and "About TopLink Descriptors" for more information.
Use this procedure to implement an interface.
To configure an interface descriptor:
- In the Structure window, select an interface.
- On the Implementors tab, select the descriptors that implement this interface and share at least one common query key.
The Common Query Keys list displays all the query keys for the interface's implementors.
To specify a class descriptor as a single implementor of an interface:
- In the Structure window, select the descriptor that will be the sole implementor of an interface.
- If the Interface Alias advanced descriptor property is not visible for this descriptor, choose Advanced Properties | Interface Alias from the pop-up menu to create the Interface Alias page.
- Select the interface that will serve as an alias for this descriptor on the Interface Alias page. It is not necessary for this interface to have a descriptor in the project, and in fact, if an associated descriptor exists, it will be removed. Every instance of the interface will now be treated as an instance of this class as well.
Related Topics
About TopLink Descriptors
Working with Interfaces
Working with Descriptors
Working with Descriptor Properties
Working with Advanced Properties
Understanding Interface Descriptors
Copyright © 1997, 2004, Oracle.
All rights reserved.