WebLogic Server 6.1 Code Examples, BEA Systems, Inc.

examples.ejb20.sequence.oracle
Class Client

java.lang.Object
  |
  +--examples.ejb20.sequence.oracle.Client

public class Client
extends java.lang.Object

This class illustrates how to set up a CMP EJBean to automatically generate the primary key upon insert.

Create accounts and deposit some money into them. The primary key will be retrieved and printed after each creation.

Author:
Copyright (c) 1998 by WebLogic, Inc. All Rights Reserved., Copyright (c) 1998-2001 by BEA Systems, Inc. All Rights Reserved.

Constructor Summary
Client(java.lang.String url)
           
 
Method Summary
static void main(java.lang.String[] args)
          Runs this example from the command line.
 void runExample()
          Deposit and print the primary key of the newly created Account.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Client

public Client(java.lang.String url)
       throws javax.naming.NamingException
Method Detail

main

public static void main(java.lang.String[] args)
Runs this example from the command line. Example:

java examples.ejb20.sequence.oracle.Client "t3://localhost:7001"

The parameter is optional. If none is passed in, it t3://localhost:7001 will be used.

Parameters:
url - URL such as "t3://localhost:7001" of Server

runExample

public void runExample()
Deposit and print the primary key of the newly created Account.

Documentation is available at
http://e-docs.bea.com/wls/docs61

Copyright © 2001 BEA Systems, Inc. All Rights Reserved.