Examples of CurrentLiteral


Examples of org.apache.webbeans.annotation.CurrentLiteral

                Annotation[] annot = annots[i];

                if (annot.length == 0)
                {
                    annot = new Annotation[1];
                    annot[0] = new CurrentLiteral();
                }

                lists.add(getGenericInjectionPoint(owner, annot, type, member));

                i++;
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

            listAnnot.add(ann);
        }

        if (listAnnot.isEmpty())
        {
            listAnnot.add(new CurrentLiteral());
        }

        while (it.hasNext())
        {
            decorator = (WebBeansDecorator) it.next();
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

    {
        boolean isDefined = XMLDefinitionUtil.defineXMLBindingType(component, annotationSet, annotationElementList, createConfigurationFailedMessage());

        if (!isDefined)
        {
            component.addBindingType(new CurrentLiteral());
        }

    }
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

       

        // No-binding annotation
        if (component.getBindings().size() == 0)
        {
            component.addBindingType(new CurrentLiteral());
        }

    }
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

    public InjectionPointComponentImpl(InjectionPoint injectionPoint)
    {
        super(WebBeansType.INJECTIONPOINT,InjectionPoint.class);
        this.injectionPoint = injectionPoint;
       
        addBindingType(new CurrentLiteral());
        setImplScopeType(new DependentScopeLiteral());
        setType(new StandardLiteral());
        addApiType(InjectionPoint.class);
        addApiType(Object.class);
    }
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

        account.withdraw(new BigDecimal(3000));

        Set<Type> apiTyeps = new HashSet<Type>();
        apiTyeps.add(Account.class);

        List<Decorator<?>> decs = getManager().resolveDecorators(apiTyeps, new Annotation[] { new CurrentLiteral() });

        LargeTransactionDecorator dec = (LargeTransactionDecorator) getManager().getInstance(decs.get(0));
        Assert.assertEquals(new BigDecimal(1500), dec.getDepositeAmount());
        Assert.assertEquals(new BigDecimal(3000), dec.getWithDrawAmount());
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

             * .lang.String)
             */
            @Override
            public void sendRedirect(String location) throws IOException
            {
                Bean<?> bean = BeanManagerImpl.getManager().resolveByType(Conversation.class, new CurrentLiteral()).iterator().next();
                Conversation conversation = (Conversation)BeanManagerImpl.getManager().getInstance(bean);

                String path = location;

                if (conversation != null)
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

    {
        ExtensionLoader.getInstance().loadExtensionServices();
       
        MockServletContext servletContext = new MockServletContext();
        ContextFactory.initApplicationContext(servletContext);
        Bean<MyExtension> extension = (Bean<MyExtension>)getManager().resolveByType(MyExtension.class, new CurrentLiteral()).iterator().next();
       
        MyExtension ext = getManager().getInstance(extension);
        System.out.println(ext.toString());
       
        defineSimpleWebBean(BookShop.class);
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

    {
        ManagerComponentImpl managerComponent = new ManagerComponentImpl();

        managerComponent.setImplScopeType(new DependentScopeLiteral());
        managerComponent.setType(new StandardLiteral());
        managerComponent.addBindingType(new CurrentLiteral());
        managerComponent.addApiType(Manager.class);
        managerComponent.addApiType(Object.class);

        return managerComponent;
    }
View Full Code Here

Examples of org.apache.webbeans.annotation.CurrentLiteral

        conversationComp.addApiType(Conversation.class);
        conversationComp.addApiType(ConversationImpl.class);
        conversationComp.addApiType(Object.class);
        conversationComp.setImplScopeType(new RequestedScopeLiteral());
        conversationComp.setType(new StandardLiteral());
        conversationComp.addBindingType(new CurrentLiteral());

        return conversationComp;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.