|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openpermis.examples.ejb.client.HelloWorldCLClient
public final class HelloWorldCLClient
Java client that can be invoked from the command line.
The client uses the configured naming context and tries to access the hello world service from the EJB name passed on the command line. (The name at which the EJB is registered at the naming context usually corresponds to the EAR name when deploying to a EJB3 container.)
The rest of this client deals with a simple user interface.
For the sake of simplicity error handling is very simple
Field Summary | |
---|---|
private static String |
SERVICE
The service context location. |
private static String[] |
USER_CHOICES
The users used. |
Constructor Summary | |
---|---|
private |
HelloWorldCLClient()
Objects of this class cannot be instantiated. |
Method Summary | |
---|---|
static HelloWorldServiceRemote |
createService(String ejbName)
Creates the HelloWorldServiceRemote . |
static void |
main(String[] args)
Starts the hello world EJB client. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final String SERVICE
"/HelloWorldService/remote"
private static final String[] USER_CHOICES
Constructor Detail |
---|
private HelloWorldCLClient()
Method Detail |
---|
public static void main(String[] args)
Pass the name of the EJB as the first argument to the client.
args
- the application arguments containing the EJB name as the first argument.public static HelloWorldServiceRemote createService(String ejbName) throws NamingException
HelloWorldServiceRemote
.
ejbName
- the name of the ejb.
NamingException
- if name could not be resolved.
|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
PERMIS Role Based Access Control 0.4.0 (Build 15)
2009/05/20 08:15:52
Copyright (c) 2002-2007 Ergon Informatik AG