|
|
Line 1: |
Line 1: |
− | <div style="float:right;border:1px solid #000000;padding:5px">__TOC__
| + | [[Configuring%20a%20Relational Mapping%20(ELUG)|Configuring a Relational Mapping]]. |
− | [[Special:Whatlinkshere/One-to-One Mapping (ELUG)|Related Topics]]</div>
| + | |
− | This section describes the various components that you must configure in order to use a relational one-to-one mapping.
| + | |
− | | + | |
− | For information on how to configure EclipseLink mappings options common to two or more mapping types, see [[Configuring%20a%20Mapping%20(ELUG)|Configuring a Mapping]].
| + | |
− | | + | |
− | For information on how to create EclipseLink mappings, see [[Creating%20a%20Mapping%20(ELUG)|Creating a Mapping]].
| + | |
− | | + | |
− | This table lists the configurable options for a relational one-to-one mapping.
| + | |
− | | + | |
− | | + | |
− | <span id="Table 36-1"></span>
| + | |
− | {| class="RuleFormalMax" dir="ltr" title="Configurable Options for Relational One-to-One Mapping" summary="This table lists the configurable options common to Relational One-to-One Mapping and indicates if the option can be configured with the Workbench, Java, or both." width="100%" border="1" frame="border" rules="all" cellpadding="3" frame="border" rules="all"
| + | |
− | |- align="left" valign="top"
| + | |
− | ! id="r1c1-t2" align="left" valign="bottom" | '''Option to Configure'''
| + | |
− | ! id="r1c2-t2" align="left" valign="bottom" | '''Workbench'''
| + | |
− | ! id="r1c3-t2" align="left" valign="bottom" | '''Java'''
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r2c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Relational%20Mapping%20(ELUG)#Configuring Reference Descriptor|Reference descriptor ]] | + | |
− | | headers="r2c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r2c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r3c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Mapping%20(ELUG)#Configuring Method or Direct Field Accessing at the Mapping Level|Method or direct field access]]
| + | |
− | | headers="r3c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r3c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r4c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Mapping%20(ELUG)#Configuring Read-Only Mappings|Read-only mapping ]]
| + | |
− | | headers="r4c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r4c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r5c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Mapping%20(ELUG)#Configuring Private or Independent Relationships|Private or Independent relationships]])
| + | |
− | | headers="r5c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r5c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r6c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Relational%20Mapping%20(ELUG)#Configuring Batch Reading|Batch reading ]]
| + | |
− | | headers="r6c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r6c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r7c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Relational%20Mapping%20(ELUG)#Configuring Joining at the Mapping Level|Joining ]]
| + | |
− | | headers="r7c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r7c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r8c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Mapping%20(ELUG)#Configuring Indirection (Lazy Loading)|Indirection (lazy loading)]])
| + | |
− | | headers="r8c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r8c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r9c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Mapping%20(ELUG)#Configuring Bidirectional Relationship|Bidirectional relationship ]]
| + | |
− | | headers="r9c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r9c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r10c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | [[Configuring%20a%20Mapping%20(ELUG)#Configuring Mapping Comments|Mapping comments ]]
| + | |
− | | headers="r10c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r10c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:unsupport.gif|Supported]]
| + | |
− | |- align="left" valign="top"
| + | |
− | | id="r11c1-t2" headers="r1c1-t2" align="left" |
| + | |
− | Table and field references (see [[Configuring%20a%20Relational%20Mapping%20(ELUG)|Configuring Joining at the Mapping Level]])
| + | |
− | | headers="r11c1-t2 r1c2-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | | headers="r11c1-t2 r1c3-t2" align="left" |
| + | |
− | [[Image:support.gif|Supported]]
| + | |
− | |}
| + | |
− | | + | |
− | | + | |
− | This example shows how to create a one-to-one mapping and add it to a descriptor using Java code.
| + | |
− | | + | |
− | <span id="Example 38-1"></span>
| + | |
− | ''''' One-to-One Mapping'''''
| + | |
− | | + | |
− | <pre>
| + | |
− | public void customize(ClassDescriptor descriptor) {
| + | |
− | OneToOneMapping mapping = new OneToOneMapping();
| + | |
− | | + | |
− | // configure mapping
| + | |
− | ...
| + | |
− | | + | |
− | // add mapping to descriptor
| + | |
− | descriptor.addMapping(mapping);
| + | |
− | }
| + | |
− | </pre>
| + | |
− | | + | |
− | For more information, see the following:
| + | |
− | | + | |
− | * [[Introduction%20to%20Relational%20Mappings%20(ELUG)|One-to-One Mapping]]
| + | |
− | * [[Configuring%20a%20Relational%20Mapping%20(ELUG)|Configuring a Relational Mapping]]
| + | |
− | * [[Creating%20and%20Configuring%20Mappings%20(ELUG)|Creating and Configuring Mappings]]
| + | |
− | | + | |
− | | + | |
− | For information on using JPA to configure one-to-one mappings, see [[Introduction%20to%20EclipseLink%20JPA%20(ELUG)|@OneToOne]].
| + | |
− | | + | |
− | | + | |
− | | + | |
− | ----
| + | |
− | ''[[EclipseLink User's Guide Copyright Statement|Copyright Statement]]''
| + | |
− | | + | |
− | | + | |
− | [[Category: EclipseLink User's Guide]]
| + | |
− | [[Category: Draft]]
| + | |
− | [[Category: Task]]
| + | |
− | [[Category: ORM]]
| + | |