Package org.jboss.aop

Examples of org.jboss.aop.ClassAdvisor$ResolveConstructorCallerMethodInfoAction


   }
  
   @SuppressWarnings("unchecked")
   public BeanContext<T> construct(Object initargs[], Class<?> parameterTypes[]) throws SecurityException, NoSuchMethodException
   {
      ClassAdvisor advisor = getAdvisor();
      Constructor<T> constructor = advisor.getClazz().getConstructor(parameterTypes);
      BeanContext<T> targetObject = construct(constructor, initargs);
     
      // If we're advising an indirect container make it aware of this
      if(targetObject.getInstance() instanceof IndirectContainer)
         ((IndirectContainer<T, C>) targetObject.getInstance()).setDirectContainer((C) this);
View Full Code Here


      {
         Map.Entry<String, Advisor> entry = it2.next();
         String classname = entry.getKey();
         indenter(pw, indent);
         pw.println("<class name=\"" + classname + "\">");
         ClassAdvisor advisor = (ClassAdvisor) entry.getValue();
         outputAdvisor(indent + 1, pw, advisor, root, classname);
         indenter(pw, indent);
         pw.println("</class>");
      }
   }
View Full Code Here

            {
               continue;
            }
            // Only need a temporary advisor for resolving metadata
            CtClass ctRef = null;
            ClassAdvisor advisor = null;
            if (ref.equals(clazz.getName()))
            {
               ctRef = clazz;
               advisor = clazzAdvisor;
            }
View Full Code Here

   }
  
   @SuppressWarnings("unchecked")
   public T construct(Object initargs[], Class<?> parameterTypes[]) throws SecurityException, NoSuchMethodException
   {
      ClassAdvisor advisor = getAdvisor();
      Constructor<T> constructor = advisor.getClazz().getConstructor(parameterTypes);
      T targetObject = construct(constructor, initargs);
     
      if(targetObject instanceof IndirectContainer)
         ((IndirectContainer<T, C>) targetObject).setDirectContainer((C) this);
     
View Full Code Here

        
         for (Iterator it = root.packages.entrySet().iterator() ; it.hasNext() ; )
         {
            Map.Entry entry = (Map.Entry) it.next();
            Package pkg = (Package) entry.getValue();
            ClassAdvisor advisor = findAdvisor(pkg, classname, name, 0);
            if (advisor != null)
            {
               return advisor;
            }
         }
View Full Code Here

        
         for (Iterator it = pkg.packages.entrySet().iterator() ; it.hasNext() ; )
         {
            Map.Entry entry = (Map.Entry) it.next();
            Package p = (Package) entry.getValue();
            ClassAdvisor advisor = findAdvisor(p, classname, name, depth + 1);
            if (advisor != null)
            {
               return advisor;
            }
         }

         for (Iterator it = pkg.advisors.entrySet().iterator(); it.hasNext() ; )
         {
            Map.Entry entry = (Map.Entry) it.next();
            ClassAdvisor advisor = (ClassAdvisor) entry.getValue();
            if (advisor.getClazz().getName().equals(classname))
            {
               return advisor;
            }
         }
        
View Full Code Here

      else if (joinpoint instanceof FieldJoinpoint)
      {
         FieldJoinpoint field = (FieldJoinpoint) joinpoint;
         if (Modifier.isStatic(field.getField().getModifiers()))
         {
            ClassAdvisor classAdvisor = (ClassAdvisor) advisor;
            return (Interceptor)classAdvisor.getFieldAspect(field, def);
         }

      }
      return new PerJoinpointInterceptor(def, advisor, joinpoint);
   }
View Full Code Here

            }
         }
         else if (joinpoint instanceof FieldJoinpoint)
         {
            FieldJoinpoint field = (FieldJoinpoint) joinpoint;
            ClassAdvisor classAdvisor = (ClassAdvisor) advisor;
            instance = classAdvisor.getFieldAspect(field, aspect);
         }
         else
         {
            instance = aspect.getFactory().createPerJoinpoint(advisor, joinpoint);  
         }
View Full Code Here

      else if (joinpoint instanceof FieldJoinpoint)
      {
         FieldJoinpoint field = (FieldJoinpoint) joinpoint;
         if (Modifier.isStatic(field.getField().getModifiers()))
         {
            ClassAdvisor classAdvisor = (ClassAdvisor) advisor;
            Object aspect = classAdvisor.getFieldAspect(field, def);
            return PerVmAdvice.generateInterceptor(joinpoint, aspect, adviceName);
         }
      }
      return new PerJoinpointAdvice(adviceName, def, advisor, joinpoint);
   }
View Full Code Here

            }
            if (!isTransformable(ctRef)) continue;

            it.addSuperClass(ctRef);

            ClassAdvisor advisor = manager.getTempClassAdvisor(ctRef);


            if (!manager.getInterceptionMarkers().shouldSkipFieldAccess(ref) && !ref.equals(clazz.getName()))
            {
               List fields = getAdvisableFields(ctRef);
View Full Code Here

TOP

Related Classes of org.jboss.aop.ClassAdvisor$ResolveConstructorCallerMethodInfoAction

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.