This is really a JNDI question. JNDI relies on several different ways to
identify the "Initial Context", all of which boil down to the same thing:
JNDI expects the class name of the "Initial Context" to be the value to a
property (whose value is equal to the String constant
Context.INITIAL_CONTEXT_FACTORY). This property can be specified in one of
several ways:
1) On the command-line, using "-D",
2) In a Hashtable containing name-value pairs, passed into the
InitialContext object, or
3) Directly setting the property in the System properties
(System.getProperties.set(...); ).

Check out the JNDI mailing list or the *excellent* Javasoft JNDI book/online
tutorial) for more details on JNDI.

Ted Neward
{.NET||Java} Instructor, DevelopMentor  (http://www.develop.com)
http://www.javageeks.com/~tneward/index.html

> -----Original Message-----
> From: A mailing list for Enterprise JavaBeans development
> [mailto:[EMAIL PROTECTED]]On Behalf Of ZHU Jia
> Sent: Monday, April 02, 2001 12:03 AM
> To: [EMAIL PROTECTED]
> Subject: [EJB-INT] Different syntax of locating EJB Home Interface?
>
>
> Hi,
>
> I just wondered why in the books/docs there are different ways of
> locating the
> EJB Home Interface. Some times they create a Property/Hashtable (any
> difference?), using some quite funny looking values like
> "Context.INITIAL_CONTEXT_FACTORY", sometimes just using
> System.properties, and
> sometimes even omit it at all.
> What really is the difference? Since none of the books I've
> really bothers to
> explain why they chose a certain approach, I'm a bit confused here:-(
> Many thanks for any hints!
>
> regard
> ZHU Jia
>
> ==================================================================
> =========
> To unsubscribe, send email to [EMAIL PROTECTED] and include
> in the body
> of the message "signoff EJB-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to