Package org.jboss.aop

Examples of org.jboss.aop.Advisor


      {
         // set the dependency policy
         this.dependencyPolicy = deployment.createDependencyPolicy(this);
      }
     
      Advisor advisor = getAdvisor();
      AdviceStack stack = advisor.getManager().getAdviceStack("InjectionCallbackStack");
      if(stack == null)
         throw new IllegalStateException("EJBTHREE-2020: No InjectionCallbackStack defined for domain " + domain + " of " + this);
      injectionCallbackStack = stack.createInterceptors(advisor, null);

      this.effigy = effigy(classloader, beanMetaData);
View Full Code Here


         // have fully integrated SwitchBoard and jboss-injection in place
         if(injectors == null)
         {
            this.injectors = new ArrayList<Injector>();
         }
         Advisor advisor = getAdvisor();
         InjectionInvocation invocation = new InjectionInvocation(beanContext, injectors, injectionCallbackStack, this.injectionManager);
         invocation.setAdvisor(advisor);
         invocation.setTargetObject(beanContext.getInstance());
         invocation.invokeNext();
      }
View Full Code Here

   {
      try
      {
         // Do lifecycle callbacks
         List<Class<?>> lifecycleInterceptorClasses = beanContainer.getInterceptorRegistry().getLifecycleInterceptorClasses();
         Advisor advisor = getAdvisor();
         Interceptor interceptors[] = LifecycleCallbacks.createLifecycleCallbackInterceptors(advisor, lifecycleInterceptorClasses, beanContext, callbackAnnotationClass);
        
         Constructor<?> constructor = beanClass.getConstructor();
         Object initargs[] = null;
         ConstructionInvocation invocation = new ConstructionInvocation(interceptors, constructor, initargs);
View Full Code Here

               synchronized (manager.getAdvisors())
               {
                  WeakReference<Advisor> ref = manager.getAdvisors().get(clazz);
                  if (ref != null)
                  {
                     Advisor advisor = ref.get();
                     manager.getAdvisors().remove(clazz);
                     if (advisor != null)
                     {
                        advisor.cleanup();
                     }
                  }
                  Class<?> advisedClass = clazz;
                  try
                  {
View Full Code Here

               synchronized (manager.getAdvisors())
               {
                  WeakReference<Advisor> ref = manager.getAdvisors().get(clazz);
                  if (ref != null)
                  {
                     Advisor advisor = ref.get();
                     manager.getAdvisors().remove(clazz);
                     if (advisor != null)
                     {
                        advisor.cleanup();
                     }
                  }
                  Class<?> advisedClass = clazz;
                  try
                  {
View Full Code Here

         // Get the method hash
         long methodHash = si.getMethodHash();
         log.debug("Received dynamic invocation for method with hash: " + methodHash);

         // Get the Method via MethodInfo from the Advisor
         Advisor advisor = this.getAdvisor();
         MethodInfo info = advisor.getMethodInfo(methodHash);
         Method unadvisedMethod = info.getMethod();
         SerializableMethod unadvisedMethodSerializable = new SerializableMethod(unadvisedMethod);
        
         try
         {
View Full Code Here

         // Get the method hash
         long methodHash = si.getMethodHash();
         log.debug("Received dynamic invocation for method with hash: " + methodHash);

         // Get the Method via MethodInfo from the Advisor
         Advisor advisor = this.getAdvisor();
         MethodInfo info = advisor.getMethodInfo(methodHash);
         Method unadvisedMethod = info.getMethod();
         SerializableMethod unadvisedMethodSerializable = new SerializableMethod(unadvisedMethod);
        
         // Get the invoked method from invocation metadata
         Object objInvokedMethod = si.getMetaData(SessionSpecRemotingMetadata.TAG_SESSION_INVOCATION,
View Full Code Here

      initialContextProperties = ctxProperties;

      if(deployment != null)
         this.dependencyPolicy = deployment.createDependencyPolicy(this);

      Advisor advisor = getAdvisor();
      AdviceStack stack = advisor.getManager().getAdviceStack("InjectionCallbackStack");
      if(stack == null)
         throw new IllegalStateException("EJBTHREE-2020: No InjectionCallbackStack defined for domain " + domain + " of " + this);
      injectionCallbackStack = stack.createInterceptors(advisor, null);
   }
View Full Code Here

   {
      try
      {
         if(injectors == null)
            return;
         Advisor advisor = getAdvisor();
         InjectionInvocation invocation = new InjectionInvocation(beanContext, injectors, injectionCallbackStack);
         invocation.setAdvisor(advisor);
         invocation.setTargetObject(beanContext.getInstance());
         invocation.invokeNext();
      }
View Full Code Here

   }

   public void initialize(EJBContainer container) throws Exception
   {
      this.container = (StatefulContainer) container;
      Advisor advisor = container.getAdvisor();
      cacheMap = new CacheMap();
      PersistenceManager pmConfig = (PersistenceManager) advisor.resolveAnnotation(PersistenceManager.class);
      EJBContainer ejbContainer = (EJBContainer)container;
      String pmConfigValue = pmConfig.value();
      PersistenceManagerFactoryRegistry pmFactoryRegistry = ejbContainer.getDeployment()
            .getPersistenceManagerFactoryRegistry();
      PersistenceManagerFactory pmFactory = pmFactoryRegistry.getPersistenceManagerFactory(pmConfigValue);
      this.pm = pmFactory.createPersistenceManager();
      pm.initialize(container);
      CacheConfig config = (CacheConfig) advisor.resolveAnnotation(CacheConfig.class);
      maxSize = config.maxSize();
      sessionTimeout = config.idleTimeoutSeconds();
      removalTimeout = config.removalTimeoutSeconds();
      log = Logger.getLogger(getClass().getName() + "." + container.getEjbName());
      log.debug("Initializing SimpleStatefulCache with maxSize: " +maxSize + " timeout: " +sessionTimeout +
View Full Code Here

TOP

Related Classes of org.jboss.aop.Advisor

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.