Skip to main content
Jump to: navigation, search

Difference between revisions of "Creating an EIS Descriptor (ELUG)"

m
m
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
 +
[[Image:Elug draft icon.png]] '''For the latest EclipseLink documentation, please see http://www.eclipse.org/eclipselink/documentation/ '''
 +
 +
----
 
<div style="float:right;border:1px solid #000000;padding:5px">__TOC__
 
<div style="float:right;border:1px solid #000000;padding:5px">__TOC__
 
[[Special:Whatlinkshere/Creating an EIS Descriptor (ELUG)|Related Topics]]</div>
 
[[Special:Whatlinkshere/Creating an EIS Descriptor (ELUG)|Related Topics]]</div>
 
This section explains how to create descriptor options specific to an EIS descriptor.
 
This section explains how to create descriptor options specific to an EIS descriptor.
  
After you create a descriptor, you must configure its various options (see [[Configuring%20an%20IES%20Descriptor%20(ELUG)|Configuring an EIS Descriptor]]) and use it to define mappings.
+
After you create a descriptor, you must configure its various options (see [[Configuring%20an%20EIS%20Descriptor%20(ELUG)|Configuring an EIS Descriptor]]) and use it to define mappings.
  
 
For information on the various types of mapping that EclipseLink supports, see [[Introduction%20to%20Mappings%20(ELUG)|Introduction to Mappings]] and [[Creating%20a%20Mapping%20(ELUG)#CBBHHHJC|Creating a Mapping]].
 
For information on the various types of mapping that EclipseLink supports, see [[Introduction%20to%20Mappings%20(ELUG)|Introduction to Mappings]] and [[Creating%20a%20Mapping%20(ELUG)#CBBHHHJC|Creating a Mapping]].
Line 26: Line 29:
  
 
====EIS Root Descriptors====
 
====EIS Root Descriptors====
[[Image:eisdesin.gif|EIS root descriptor button]]  You can modify an EIS descriptor's behavior by configuring it as a root EIS descriptor (see [[Configuring%20an%20EIS%20Descriptor%20(ELUG)#Configuring an EIS Descriptor as a Root or Composite Type|Configuring an EIS Descriptor as a Root or Composite Type]]). When you designate an EIS descriptor as a root, you tell the EclipseLink runtime that the EIS descriptor's reference class is a parent class: no other class will reference it by way of a composite object mapping or composite collection mapping. Using an EIS root descriptor, you can configure all supported mappings. You can also configure an EIS root descriptor with EIS interactions (see [[Using%20Basic%20Query%20API%20(ELUG)#Using EIS Interactions|Using EIS Interactions]]). However, if you configure the EIS root descriptor with a composite object mapping or composite collection mapping, the reference descriptor you define must be an EIS composite descriptor; it cannot be another EIS root descriptor.
+
[[Image:eisdesin.gif|EIS root descriptor button]]  You can modify an EIS descriptor's behavior by configuring it as a root EIS descriptor (see [[Configuring%20an%20EIS%20Descriptor%20(ELUG)#Configuring an EIS Descriptor as a Root or Composite Type|Configuring an EIS Descriptor as a Root or Composite Type]]). When you designate an EIS descriptor as a root, you tell the EclipseLink runtime that the EIS descriptor's reference class is a parent class: no other class will reference it by way of a composite object mapping or composite collection mapping. Using an EIS root descriptor, you can configure all supported mappings. You can also configure an EIS root descriptor with [[Using%20Basic%20Query%20API%20(ELUG)#Using EIS Interactions|EIS Interactions]]. However, if you configure the EIS root descriptor with a composite object mapping or composite collection mapping, the reference descriptor you define must be an EIS composite descriptor; it cannot be another EIS root descriptor.
  
  
 
====EIS Composite Descriptors====
 
====EIS Composite Descriptors====
[[Image:eisdescompicon.gif|EIS composite descriptor button]] By default, when you add a class to an EIS project (see [[Configuring%20a%20Project%20(ELUG)#Configuring Project Classpath|Configuring Project Classpath]]), Workbench creates an EIS descriptor for the class, and designates the EIS descriptor as a composite. When you designate an EIS descriptor as a composite, you tell the EclipseLink runtime that the EIS descriptor's reference class may be referenced by a composite object mapping or composite collection mapping. Using an EIS composite descriptor, you can configure all supported mappings. However, you cannot configure an EIS composite descriptor with EIS interactions: for this, you need an EIS root descriptor (see [[#EIS Root Descriptors|EIS Root Descriptors]]).
+
[[Image:eisdescompicon.gif|EIS composite descriptor button]] By default, when you add a class to an EIS project (see [[Configuring%20a%20Project%20(ELUG)#Configuring Project Classpath|Configuring Project Classpath]]), Workbench creates an EIS descriptor for the class, and designates the EIS descriptor as a composite. When you designate an EIS descriptor as a composite, you tell the EclipseLink runtime that the EIS descriptor's reference class may be referenced by a composite object mapping or composite collection mapping. Using an EIS composite descriptor, you can configure all supported mappings. However, you cannot configure an EIS composite descriptor with EIS interactions: for this, you need an [[#EIS Root Descriptors|EIS Root Descriptor]].
  
  
Line 51: Line 54:
  
 
[[Category: EclipseLink User's Guide]]
 
[[Category: EclipseLink User's Guide]]
[[Category: Draft]]
+
[[Category: Release 1]]
 
[[Category: Concept]]
 
[[Category: Concept]]
 
[[Category: EIS]]
 
[[Category: EIS]]

Latest revision as of 11:11, 23 July 2012

Elug draft icon.png For the latest EclipseLink documentation, please see http://www.eclipse.org/eclipselink/documentation/


This section explains how to create descriptor options specific to an EIS descriptor.

After you create a descriptor, you must configure its various options (see Configuring an EIS Descriptor) and use it to define mappings.

For information on the various types of mapping that EclipseLink supports, see Introduction to Mappings and Creating a Mapping.

For information on the various types of descriptor that EclipseLink supports, see Descriptor Types.

For more information, see the following:


Creating an EIS Descriptor

You can create an EIS descriptor using the Workbench or Java code. We recommend that you use the Workbench to create and manage your EIS descriptors.


How to Create an EIS Descriptor Using Workbench

Using Workbench, you can create the following types of EIS descriptor in an EIS project:


EIS Root Descriptors

EIS root descriptor button You can modify an EIS descriptor's behavior by configuring it as a root EIS descriptor (see Configuring an EIS Descriptor as a Root or Composite Type). When you designate an EIS descriptor as a root, you tell the EclipseLink runtime that the EIS descriptor's reference class is a parent class: no other class will reference it by way of a composite object mapping or composite collection mapping. Using an EIS root descriptor, you can configure all supported mappings. You can also configure an EIS root descriptor with EIS Interactions. However, if you configure the EIS root descriptor with a composite object mapping or composite collection mapping, the reference descriptor you define must be an EIS composite descriptor; it cannot be another EIS root descriptor.


EIS Composite Descriptors

EIS composite descriptor button By default, when you add a class to an EIS project (see Configuring Project Classpath), Workbench creates an EIS descriptor for the class, and designates the EIS descriptor as a composite. When you designate an EIS descriptor as a composite, you tell the EclipseLink runtime that the EIS descriptor's reference class may be referenced by a composite object mapping or composite collection mapping. Using an EIS composite descriptor, you can configure all supported mappings. However, you cannot configure an EIS composite descriptor with EIS interactions: for this, you need an EIS Root Descriptor.


How to Create an EIS Descriptor Using Java

This example shows how to create a relational descriptor using Java code.


Creating an EIS Descriptor in Java

EISDescriptor descriptor = new EISDescriptor();
descriptor.setJavaClass(YourClass.class);

To designate an EIS descriptor as a composite, use ClassDescriptor method descriptorIsAggregate.



Copyright Statement

Back to the top