See Annotations
for session facades and SDOs for reference information
about the @ws.sdo and @ws.sbf tag sets.
For this scenario, you
have
an EJB project that includes CMP entity beans that manage the persistence
of data for an auction application. For example, your CMP entity beans
handle
the registration of user accounts, the handling of accounts payable,
and the
management of bids and items for sale. The project includes an EJB
2.1 CMP
entity bean called Registration.
The Registration CMP entity
bean is
designed to persist all data related to a given user. For example,
the Registration
bean includes the following attributes:
- userid (primary key)
- email
- passwd
- name
- cardtype
- acctnum
- expiry
- shippingsame
- active
- rank
The
Registration CMP entity bean also has the following relationships
defined:
- [0..*] accountspayable : Accountspayable
- [0..*]
bid : Bid
- [0..*] item : Item
- [0..*] sale : Sale
- [0..*]
sale_1 : Sale
- [0..*] usertorole: Usertorole
- [0..1]
fk_shipaddress : Address (foreign key)
- [0..1] fk_billingaddress
: Address (foreign key)
You want to create a session
bean facade and SDOs for the Registration
CMP entity bean to manage users and their accounts payable. You can
use the
Create Session Bean Facade wizard to quickly create the facade and
SDOs.
Remember: Because the sample bean code is not
provided for this example,
the following steps simply demonstrate the process and the resulting
output.
You can experiment with the wizard and annotations using your own
CMP entity
beans.