|
Orion prioprietary EJB 1.1 OR mapping
This article describes how to Use Orion's proprietary OR-mapping for pre EJB 2.0 entity beans.
1 Step-by-step Guide
Go through the following steps to use Orions proprietary pre EJB 2.0 OR-mapping for entity beans:
1.1 Step 1: Create the fields
Create the field that is to hold the relational mapping, common types are Collection, Set List and Map:
Listing 1: Example field
1.2 Step 2: Add a type-descriptor (optional)
Add a type-descriptor (optional, will simplify deployment), to identify the contents of the type:
public static final Class items_type = java.lang.String.class;
|
Listing 2: Example type-descriptor
or if it is of type Map:
public static final Class items_keyType = java.lang.String.class; public static final Class items_valueType = java.lang.Integer.class;
|
Listing 3: Example type-descriptor
where "items" is the name of the field (public Set items; for instance).
1.3 Step 3: Redeploy
Redeploy, the OR-mapping should automatically be created.
Copyright ©
2005 IronFlare AB
|