Doing it programmatically works:
@Name("shoppingCart")
| @Scope(ScopeType.SESSION)
| public class ShoppingCartManager
| {
| private ShoppingCart shoppingCart;
|
| @Create
| public void create() throws NamingException
| {
| InitialContext ic = new InitialContext();
| //shoppingCart = (ShoppingCart) ic.lookup(ShoppingCart.class.getName());
| shoppingCart = (ShoppingCart)
ic.lookup("wct-example/ShoppingCartBean/local");
| }
|
| @Unwrap
| public ShoppingCart getShoppingCart() {
| return shoppingCart;
| }
| }
But why not with the components.xml? Is this a bug?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4071303#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...