Package org.milyn.javabean.context

Examples of org.milyn.javabean.context.BeanContext


        long start = System.currentTimeMillis();
        JavaResult javaResult = null;
        NoddyObserver nobserver = new NoddyObserver();
        for(int i = 0; i < TestConstants.NUM_ITERATIONS; i++) {
          ExecutionContext execContext = smooks.createExecutionContext();
          BeanContext beanCtx = execContext.getBeanContext();
         
          for(int ii = 0; ii < 15; ii++) {
            beanCtx.addObserver(nobserver);
          }
         
            javaResult = new JavaResult();
            smooks.filterSource(execContext, new StreamSource(TestConstants.getMessageReader()), javaResult);
        }
View Full Code Here


        try {
            ExecutionContext nestedExecutionContext = (ExecutionContext) executionContext.getAttribute(NestedExecutionVisitor.class);

            try {
                if(nestedExecutionContext != null) {
                    BeanContext parentBeanContext = executionContext.getBeanContext();
                    BeanContext nestedBeanContext = nestedExecutionContext.getBeanContext();

                    for(BeanId beanId : mapBeanIds) {
                        Object bean = nestedBeanContext.getBean(beanId.getName());

                        // Add the bean from the nested context onto the parent context and then remove
                        // it again.  This is enough to fire the wiring and end events...
                        parentBeanContext.notifyObservers(new BeanContextLifecycleEvent(executionContext, null, BeanLifecycle.START_FRAGMENT, beanId, bean));
                        parentBeanContext.addBean(beanId, bean);
View Full Code Here

TOP

Related Classes of org.milyn.javabean.context.BeanContext

Copyright © 2018 www.massapicom. 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.