Examples of Initialization


Examples of org.jboss.seam.init.Initialization

   {
      startJbossEmbeddedIfNecessary();
      this.servletContext = createServletContext();
      ServletLifecycle.beginApplication(servletContext);
      FactoryFinder.setFactory(FactoryFinder.APPLICATION_FACTORY, MockApplicationFactory.class.getName());
      new Initialization(servletContext).create().init();
      ((Init) servletContext.getAttribute(Seam.getComponentName(Init.class))).setDebug(false);
   }
View Full Code Here

Examples of org.jboss.seam.init.Initialization

         }
      }
      ServletContext context = super.newServletContext(path);
      startJbossEmbeddedIfNecessary();
      ServletLifecycle.beginApplication(context);
      new Initialization(context).create().init();
      ((Init) context.getAttribute(Seam.getComponentName(Init.class))).setDebug(false);
      return context;
   }
View Full Code Here

Examples of org.jboss.seam.init.Initialization

   {
      startJbossEmbeddedIfNecessary();
      this.servletContext = createServletContext();
      ServletLifecycle.beginApplication(servletContext);
      FactoryFinder.setFactory(FactoryFinder.APPLICATION_FACTORY, MockApplicationFactory.class.getName());
      new Initialization(servletContext).create().init();
      ((Init) servletContext.getAttribute(Seam.getComponentName(Init.class))).setDebug(false);
   }
View Full Code Here

Examples of org.jboss.seam.init.Initialization

   {
      startJbossEmbeddedIfNecessary();
      this.servletContext = createServletContext();
      ServletLifecycle.beginApplication(servletContext);
      FactoryFinder.setFactory(FactoryFinder.APPLICATION_FACTORY, MockApplicationFactory.class.getName());
      new Initialization(servletContext).create().init();
      ((Init) servletContext.getAttribute(Seam.getComponentName(Init.class))).setDebug(false);
   }
View Full Code Here

Examples of org.jboss.seam.init.Initialization

         Init init = (Init) getServletContext().getAttribute(Seam.getComponentName(Init.class));
         if (init != null)
         {
            try
            {
               new Initialization(getServletContext()).redeploy((HttpServletRequest) request, init);
            }
            catch (InterruptedException e)
            {
               log.warn("Unable to redeploy, please try again");
            }
View Full Code Here

Examples of org.jboss.seam.init.Initialization

   public void contextInitialized(ServletContextEvent event)
   {
      log.info( "Welcome to Seam " + Seam.getVersion() );
      event.getServletContext().setAttribute( Seam.VERSION, Seam.getVersion() );
      ServletLifecycle.beginApplication( event.getServletContext() );
      new Initialization( event.getServletContext() ).create().init();
   }
View Full Code Here

Examples of org.jboss.seam.init.Initialization

      {
         for ( File file: init.getHotDeployPaths() )
         {
            if ( scan(request, init, file) )
            {
               new Initialization( getServletContext() ).redeploy( ( (HttpServletRequest) request ).getSession(true) );
               break;
            }
         }
      }
     
View Full Code Here

Examples of org.jboss.seam.init.Initialization

        } catch (Exception e) {
            e.printStackTrace();
        }
        // redeploy the components
        try {
            Initialization init = new Initialization(ServletLifecycle.getServletContext());

            Method redeploy = Initialization.class.getDeclaredMethod("installScannedComponentAndRoles", Class.class);
            redeploy.setAccessible(true);
            for (int i = 0; i < changed.size(); ++i) {
                redeploy.invoke(init, changed.get(i).getChangedClass());
View Full Code Here

Examples of org.jboss.seam.init.Initialization

   public void testConstraints() throws Exception
   {
      // Initialize Seam
      MockServletContext servletContext = new MockServletContext();
      ServletLifecycle.beginApplication(servletContext);
      new Initialization(servletContext).init();

      try
      {
         Lifecycle.beginCall();
View Full Code Here

Examples of org.jboss.seam.init.Initialization

   @Test
   public void testInitialization()
   {
      MockServletContext servletContext = new MockServletContext();
      ServletLifecycle.beginApplication(servletContext);
      new Initialization(servletContext).init();

      assert !servletContext.getAttributes().isEmpty();
      assert servletContext.getAttributes().containsKey( Seam.getComponentName(Manager.class) + ".component" );
      assert servletContext.getAttributes().containsKey( Seam.getComponentName(Foo.class) + ".component" );
      assert !Contexts.isApplicationContextActive();
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.