> used to make it work,if this way, why not use JNID_NAME in file of
> CalcUtil.java created by xdoclet?

Because you didn't tell it to.  You have to specify (in either the
build.xml file or in the actual class) that you want the Util class to be
generated using the JNDI_NAME to perform the look up.

Class method.  Add the following tag to your class definition:
..
@ejb.util generate="physical"
..

build.xml method.

<ejbdoclet .. >
..
<utilobject kind="physical"/>
..
</ejbdoclet>

Obviously if you have 400 beans, then you'll want to use the build.xml
file since it requires fewer changes.  However, I believe that the class
tags overrides the build.xml tags.

Regards,

Marc Chung
[EMAIL PROTECTED]

>
> public static com.CalcHome getHome() throws NamingException
>    {
>       InitialContext initialContext = new InitialContext();
>       try {
>          java.lang.Object objRef =
> initialContext.lookup(com.CalcHome.COMP_NAME);
>          com.CalcHome home =
> (com.CalcHome)PortableRemoteObject.narrow(objRef,
>                com.CalcHome.class);
>          return home;
>       } finally {
>          initialContext.close();
>       }
>    }
>
>
>
>
> _________________________________________________________________
> The new MSN 8 is here: Try it free* for 2 months
> http://join.msn.com/?page=dept/dialup
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Xdoclet-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/xdoclet-user
>
>



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to