Method Invocations in RosterApp

To show how the various components interact, this section describes the sequence of method invocations that occur for particular functions. The source code for the components is in the j2eetutorial/examples/src/ejb/cmproster directory.

Creating a Player

1. RosterClient

The RosterClient invokes the createPlayer business method of the RosterEJB session bean. In the following line of code, the type of the myRoster object is Roster, the remote interface of RosterEJB. The argument of the createPlayer method is a PlayerDetails object, which encapsulates information about a particular player.

myRoster.createPlayer(new PlayerDetails("P1", "Phil Jones", 
   "goalkeeper", 100.00)); 
2. RosterEJB

The createPlayer method ...

Get J2EE™ Tutorial, The now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.