Package org.jboss.aop

Examples of org.jboss.aop.DomainDefinition


      return bootstrap;
   }

   protected static Domain getDomain(String domainName)
   {
      DomainDefinition domainDef = AspectManager.instance().getContainer(domainName);
      if (domainDef == null)
         throw new IllegalArgumentException("No such domain '" + domainName + "'");
      return (Domain) domainDef.getManager();
   }
View Full Code Here


      AspectXmlLoader.deployXML(url);

      // Bootstrap the basic container
      String containerName = "InterceptorContainer";
     
      DomainDefinition domainDefinition = AspectManager.instance().getContainer(containerName);
      if(domainDefinition == null)
         throw new IllegalArgumentException("Domain definition for container '" + containerName + "' can not be found");
     
      final Domain domain = (Domain) domainDefinition.getManager();
     
      ClassLoader classLoader = new DomainClassLoader(Thread.currentThread().getContextClassLoader(), deploymentClassLoader, domain);
      Thread.currentThread().setContextClassLoader(classLoader);
     
      // The moment an instrumented class comes up it does AspectManager.instance(classLoader), which
View Full Code Here

   /*
    * TODO: this should not be here, it's an AspectManager helper function.
    */
   protected static final Domain getDomain(String domainName)
   {
      DomainDefinition domainDefinition = AspectManager.instance().getContainer(domainName);
      if(domainDefinition == null)
         throw new IllegalArgumentException("Domain definition '" + domainName + "' can not be found");
     
      final Domain domain = (Domain) domainDefinition.getManager();
      return domain;
   }
View Full Code Here

      if (this.parent != null)
      {
         parent = this.parent.getDomain();
      }
        
      definition = new DomainDefinition(name, parent, parentFirst, inheritDefinitions, inheritBindings);
      manager.addContainer(definition);
   }
View Full Code Here

   }
  
   protected AspectManager getDomain(String name)
   {
      AspectManager manager = getMainAspectManager();
      DomainDefinition def = manager.getContainer(name);
      assertNotNull(def);
      AspectManager domain = def.getManager();
      assertNotNull(domain);
      return domain;
   }
View Full Code Here

   }

   protected ServiceContainer getServiceContainer(int ejbIndex) throws Exception
   {
      String containerName = getAspectDomain(ejbIndex, defaultServiceDomain);
      DomainDefinition domain = AspectManager.instance().getContainer(containerName);

      if (domain == null)
         throw new RuntimeException("No container configured with name '"
                 + containerName + "''");

      return new ServiceContainer(deployment.getMbeanServer(), di.getClassLoader(), className,
              ejbNames.get(ejbIndex), (AspectManager) domain.getManager(), ctxProperties,
              di.getInterceptorInfoRepository(), deployment);

   }
View Full Code Here

   }

   protected ConsumerContainer getConsumerContainer(int ejbIndex) throws Exception
   {
      String containerName = getAspectDomain(ejbIndex, defaultConsumerDomain);
      DomainDefinition domain = AspectManager.instance().getContainer(containerName);

      if (domain == null)
         throw new RuntimeException("No container configured with name '"
                 + containerName + "''");

      return new ConsumerContainer(ejbNames.get(ejbIndex), (AspectManager) domain.getManager(),
              di.getClassLoader(), className, ctxProperties,
              di.getInterceptorInfoRepository(), deployment);

   }
View Full Code Here

   }

   protected StatefulContainer getStatefulContainer(int ejbIndex) throws Exception
   {
      String containerName = getAspectDomain(ejbIndex, defaultSFSBDomain);
      DomainDefinition domain = AspectManager.instance().getContainer(containerName);

      if (domain == null)
         throw new RuntimeException("No container configured with name '"
                 + containerName + "''");

      return new StatefulContainer(di.getClassLoader(), className,
              ejbNames.get(ejbIndex), (AspectManager) domain.getManager(), ctxProperties,
              di.getInterceptorInfoRepository(), deployment);

   }
View Full Code Here

   protected EJBContainer getStatelessContainer(int ejbIndex) throws Exception
   {
      String containerName = getAspectDomain(ejbIndex, defaultSLSBDomain);
     
      DomainDefinition domain = AspectManager.instance().getContainer(containerName);

      if (domain == null)
         throw new RuntimeException("No container configured with name '"
                 + containerName + "''");

      return new StatelessContainer(di.getClassLoader(), className,
              ejbNames.get(ejbIndex), (AspectManager) domain.getManager(),
              ctxProperties, di.getInterceptorInfoRepository(),
              deployment);
   }
View Full Code Here

   protected MDB getMDB(int ejbIndex, EnterpriseBean xml) throws Exception
   {
      String domainName = getMDBDomainName(ejbIndex);
     
      String containerName = getAspectDomain(ejbIndex, domainName);
      DomainDefinition domain = AspectManager.instance().getContainer(containerName);

      if (domain == null)
         throw new RuntimeException("No container configured with name '"
                 + containerName + "''");

      MDB container = new MDB(ejbNames.get(ejbIndex), (AspectManager) domain.getManager(), di.getClassLoader(), className,
              ctxProperties, di.getInterceptorInfoRepository(), deployment);

      return container;
   }
View Full Code Here

TOP

Related Classes of org.jboss.aop.DomainDefinition

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.