Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有两个豆子。一种有状态,一种无状态。现在我想从有状态 bean 中调用一个方法,该方法位于无状态 bean 中。我怎样才能做到这一点?无状态 bean 也有一个接口。
我假设您使用的是 EJB3.0。因此,放入您的有状态 bean:
@EJB private YourStatelessBeanInterface statelessBean;