posted 16 years ago
Example:
@Stateless
@Local({One.class})
class OneBean implements One{
public void doSmth(){...}
}
@Stateless
@Local({Two.class})
class TwoBean implements Two{
@EJB
private One oneBeanInstance;
public void doSmth2(){...}
}
You have to refer to OneBean class through business interface.
Container will inject implementation of that interface after bean creation and before every invocation of business method.