Package org.jboss.aop

Examples of org.jboss.aop.ConByConInfo


                  {
                     TLongObjectHashMap calledCons = (TLongObjectHashMap) calledClassesMap.get(constructor.getDeclaringClass().getName());
                     if (calledCons != null)
                     {
                        long calledHash = MethodHashing.constructorHash(constructor);
                        ConByConInfo info = (ConByConInfo) calledCons.get(calledHash);

                        if (info != null && info.hasAdvices())
                        {
                           return advisor.invokeConCalledByCon(info, inv.getCallingObject(), args);
                        }
                     }
                  }
               }
            }
         }
      }
      else if (invocation instanceof MethodCalledByMethodInvocation)
      {
         MethodCalledByMethodInvocation inv = (MethodCalledByMethodInvocation) invocation;
         Method callingMethod = inv.getCallingMethod();
         if (isAdvised(callingMethod.getDeclaringClass()))
         {
            ClassAdvisor advisor = AspectManager.instance().getAdvisor(callingMethod.getDeclaringClass());
            if (advisor != null)
            {
               long callingMethodHash = MethodHashing.calculateHash(callingMethod);
               long calledHash = MethodHashing.constructorHash(constructor);

               HashMap calledClassesMap = (HashMap) advisor.getConCalledByMethodInterceptors().get(callingMethodHash);
               if (calledClassesMap != null)
               {
                  TLongObjectHashMap calledCons = (TLongObjectHashMap) calledClassesMap.get(constructor.getDeclaringClass().getName());
                  if (calledCons != null)
                  {
                     //CallerConstructorInfo info = (CallerConstructorInfo) calledCons.get(calledHash);
                     ConByMethodInfo info = (ConByMethodInfo) calledCons.get(calledHash);

                     if (info != null && info.hasAdvices())
                     {
                        //return advisor.invokeConCalledByMethod(callingMethodHash, args, info, inv.getCallingObject());
                        return advisor.invokeConCalledByMethod(info, inv.getCallingObject(), args);
                     }
                  }
View Full Code Here


      returnType = new WeakReference<Class<?>>(((ConByConInfo)info).getCalledClass());
   }

   protected void initialiseJoinPointNames(JoinPointInfo info)
   {
      ConByConInfo cinfo = (ConByConInfo)info;
      joinpointClassName = getGeneratedJoinPointClassName(
               callingIndex(cinfo),
               calledClass(cinfo),
               calledConHash(cinfo));
View Full Code Here

                  {
                     TLongObjectHashMap calledCons = calledClassesMap.get(constructor.getDeclaringClass().getName());
                     if (calledCons != null)
                     {
                        long calledHash = MethodHashing.constructorHash(constructor);
                        ConByConInfo info = (ConByConInfo) calledCons.get(calledHash);

                        if (info != null && info.hasAdvices())
                        {
                           return advisor.invokeConCalledByCon(info, inv.getCallingObject(), args);
                        }
                     }
                  }
               }
            }
         }
      }
      else if (invocation instanceof MethodCalledByMethodInvocation)
      {
         MethodCalledByMethodInvocation inv = (MethodCalledByMethodInvocation) invocation;
         Method callingMethod = inv.getCallingMethod();
         if (isAdvised(callingMethod.getDeclaringClass()))
         {
            ClassAdvisor advisor = AspectManager.instance().getAdvisor(callingMethod.getDeclaringClass());
            if (advisor != null)
            {
               long callingMethodHash = MethodHashing.calculateHash(callingMethod);
               long calledHash = MethodHashing.constructorHash(constructor);

               @SuppressWarnings("unchecked")
               HashMap calledClassesMap = (HashMap) advisor.getConCalledByMethodInterceptors().get(callingMethodHash);
               if (calledClassesMap != null)
               {
                  TLongObjectHashMap calledCons = (TLongObjectHashMap) calledClassesMap.get(constructor.getDeclaringClass().getName());
                  if (calledCons != null)
                  {
                     //CallerConstructorInfo info = (CallerConstructorInfo) calledCons.get(calledHash);
                     ConByMethodInfo info = (ConByMethodInfo) calledCons.get(calledHash);

                     if (info != null && info.hasAdvices())
                     {
                        //return advisor.invokeConCalledByMethod(callingMethodHash, args, info, inv.getCallingObject());
                        return advisor.invokeConCalledByMethod(info, inv.getCallingObject(), args);
                     }
                  }
View Full Code Here

      returnType = new WeakReference<Class<?>>(((ConByConInfo)info).getCalledClass());
   }

   protected void initialiseJoinPointNames(JoinPointInfo info)
   {
      ConByConInfo cinfo = (ConByConInfo)info;
      joinpointClassName = getGeneratedJoinPointClassName(
               callingIndex(cinfo),
               calledClass(cinfo),
               calledConHash(cinfo));
View Full Code Here

/*  78 */     this.returnType = new WeakReference(((ConByConInfo)info).getCalledClass());
/*     */   }
/*     */
/*     */   protected void initialiseJoinPointNames(JoinPointInfo info)
/*     */   {
/*  83 */     ConByConInfo cinfo = (ConByConInfo)info;
/*  84 */     this.joinpointClassName = getGeneratedJoinPointClassName(callingIndex(cinfo), calledClass(cinfo), calledConHash(cinfo));
/*     */
/*  89 */     this.joinpointFieldName = getGeneratedJoinPointFieldName(callingIndex(cinfo), calledClass(cinfo), calledConHash(cinfo));
/*     */   }
View Full Code Here

/*      */             {
/* 1182 */               TLongObjectHashMap calledCons = (TLongObjectHashMap)calledClassesMap.get(constructor.getDeclaringClass().getName());
/* 1183 */               if (calledCons != null)
/*      */               {
/* 1185 */                 long calledHash = MethodHashing.constructorHash(constructor);
/* 1186 */                 ConByConInfo info = (ConByConInfo)calledCons.get(calledHash);
/*      */
/* 1188 */                 if ((info != null) && (info.hasAdvices()))
/*      */                 {
/* 1190 */                   return advisor.invokeConCalledByCon(info, inv.getCallingObject(), args);
/*      */                 }
/*      */               }
/*      */             }
/*      */           }
/*      */         }
/*      */       }
/*      */     }
/* 1198 */     else if ((invocation instanceof MethodCalledByMethodInvocation))
/*      */     {
/* 1200 */       MethodCalledByMethodInvocation inv = (MethodCalledByMethodInvocation)invocation;
/* 1201 */       Method callingMethod = inv.getCallingMethod();
/* 1202 */       if (isAdvised(callingMethod.getDeclaringClass()))
/*      */       {
/* 1204 */         ClassAdvisor advisor = AspectManager.instance().getAdvisor(callingMethod.getDeclaringClass());
/* 1205 */         if (advisor != null)
/*      */         {
/* 1207 */           long callingMethodHash = MethodHashing.calculateHash(callingMethod);
/* 1208 */           long calledHash = MethodHashing.constructorHash(constructor);
/*      */
/* 1210 */           HashMap calledClassesMap = (HashMap)advisor.getConCalledByMethodInterceptors().get(callingMethodHash);
/* 1211 */           if (calledClassesMap != null)
/*      */           {
/* 1213 */             TLongObjectHashMap calledCons = (TLongObjectHashMap)calledClassesMap.get(constructor.getDeclaringClass().getName());
/* 1214 */             if (calledCons != null)
/*      */             {
/* 1217 */               ConByMethodInfo info = (ConByMethodInfo)calledCons.get(calledHash);
/*      */
/* 1219 */               if ((info != null) && (info.hasAdvices()))
/*      */               {
/* 1222 */                 return advisor.invokeConCalledByMethod(info, inv.getCallingObject(), args);
/*      */               }
/*      */             }
/*      */           }
View Full Code Here

                  {
                     TLongObjectHashMap calledCons = (TLongObjectHashMap) calledClassesMap.get(constructor.getDeclaringClass().getName());
                     if (calledCons != null)
                     {
                        long calledHash = MethodHashing.constructorHash(constructor);
                        ConByConInfo info = (ConByConInfo) calledCons.get(calledHash);

                        if (info != null && info.hasAdvices())
                        {
                           return advisor.invokeConCalledByCon(info, inv.getCallingObject(), args);
                        }
                     }
                  }
               }
            }
         }
      }
      else if (invocation instanceof MethodCalledByMethodInvocation)
      {
         MethodCalledByMethodInvocation inv = (MethodCalledByMethodInvocation) invocation;
         Method callingMethod = inv.getCallingMethod();
         if (isAdvised(callingMethod.getDeclaringClass()))
         {
            ClassAdvisor advisor = AspectManager.instance().getAdvisor(callingMethod.getDeclaringClass());
            if (advisor != null)
            {
               long callingMethodHash = MethodHashing.calculateHash(callingMethod);
               long calledHash = MethodHashing.constructorHash(constructor);

               HashMap calledClassesMap = (HashMap) advisor.getConCalledByMethodInterceptors().get(callingMethodHash);
               if (calledClassesMap != null)
               {
                  TLongObjectHashMap calledCons = (TLongObjectHashMap) calledClassesMap.get(constructor.getDeclaringClass().getName());
                  if (calledCons != null)
                  {
                     //CallerConstructorInfo info = (CallerConstructorInfo) calledCons.get(calledHash);
                     ConByMethodInfo info = (ConByMethodInfo) calledCons.get(calledHash);

                     if (info != null && info.hasAdvices())
                     {
                        //return advisor.invokeConCalledByMethod(callingMethodHash, args, info, inv.getCallingObject());
                        return advisor.invokeConCalledByMethod(info, inv.getCallingObject(), args);
                     }
                  }
View Full Code Here

TOP

Related Classes of org.jboss.aop.ConByConInfo

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.