On Sep 10, 2013, at 9:55 AM, mauro2java2011 <mauro2java2...@gmail.com> wrote:

> this signify the object current. 
> But the first parameter "inject" it is the operation to make?????
> 
> exist other value for the first parameter into the method bind ???????

This is effectively a workaround.  Dependency Injection did not make it into 
the final version of EJBContainer API that went into the specification.

In order to make it work without introducing any OpenEJB-specific API classes 
that you'd have to use in your test code, we added the convention to call 
'bind(Sring, Object)' where the string must be "inject" and the object is an 
instance of the class that bootstrapped the EJBContainer (called 
.createEJBContainer() ).

As for what other options can be passed into the bind() method, it always must 
be "inject", but you can pass in:

 1. an instance of the class that called EJBContainer.createEJBContainer()
 2. any instance of a class annotated with @javax.annotation.ManagedBean


-David

Reply via email to