Hi,

well, I think the container should have the possibility to extend the
class with it's own dynamiccally created code and overload the
ejbCreate methods with it's own stuff (e.g. performance reasons)
(security, logging, etc.).

Declaring the methods of the bean-container-interface 'final' would
result in many denied opportunities for container developers.

But maybe this approach would help you:

public void ejbCreate() throws RemoteException {
  myOwnCreate();
}

public final void myOwnCreate() throws RemoteException {
  // this create stuff is secured from overloading
}

I don't know if you can still change your framework to more
private create-methods which could be safe from being changed by
overloaded methods.

The 'real' ejbCreate-method would only call the private create method
and you would still be in happiness with the ejb-spec :)

Stephan.

JDC> Thanks Stephan,

JDC> ... unfortunately pressing reply  to a sourceforge mail has not the list as 
JDC> the default recipient ... Juha already clarified this point.

JDC> although I still cannot see the REASON for this requirement.

JDC> Best,
JDC> CGJ 

JDC> -----Ursprüngliche Nachricht-----
JDC> Von: Stephan Gruschke [mailto:[EMAIL PROTECTED]]
JDC> Gesendet: Montag, 26. März 2001 12:56
JDC> An: [EMAIL PROTECTED]
JDC> Betreff: Re: [JBoss-dev]
JDC> org.jboss.verifier.strategy.AbstractVerifier.hasEJBCreateMethod(C lass
JDC> c, boolean isSession)


JDC> Hi,

JDC> EJB2.0 (EJB1.1 as well) Specification states in 6.10.3 (ejbCreate<METHOD>
JDC> methods):

JDC> 'The method must not be declared as final or static.'

JDC> Therefore :)

JDC> Stephan.

JDC>> Hi,

JDC>> Is there any particular reason, why above method only looks for
JDC> non-final
JDC>> create methods? 

JDC>> In our framework, we have a base class for session beans which
JDC> implements
JDC>> all the necessary creation logic and we like to prevent our developers
JDC>> to get around that code.

JDC>> Browsing through the spec, I could not find a in Chapter 6 that
JDC> requires
JDC>> create methods to be non-final.

JDC>> Best,
JDC>> CGJ

JDC>> _______________________________________________
JDC>> Jboss-development mailing list
JDC>> [EMAIL PROTECTED]
JDC>> http://lists.sourceforge.net/lists/listinfo/jboss-development



_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to