Package org.jboss.aop.advice

Examples of org.jboss.aop.advice.PrecedenceDefEntry


               String iname = interceptorElement.getAttribute("name");
               if (iname == null || iname.length() == 0)
               {
                  throw new RuntimeException("name must be specified for interceptor-ref in precedence declaration");
               }
               precedenceEntries.add(new PrecedenceDefEntry(iname, null));
            }
            else if (tag2.equals("advice"))
            {
               String method = interceptorElement.getAttribute("name");
               String aspect = interceptorElement.getAttribute("aspect");

               if (method == null || method.length() == 0)
               {
                  throw new RuntimeException("name must be specified for advice in precedence declaration");
               }

               if (aspect == null || aspect.length() == 0)
               {
                  throw new RuntimeException("aspect must be specified for advice in precedence declaration");
               }

               precedenceEntries.add(new PrecedenceDefEntry(aspect, method));
            }
            else
            {
               throw new RuntimeException("Invalid child element of precedence : " + tag2);
            }
View Full Code Here


            if (mgroup == null) continue;
            javassist.bytecode.annotation.Annotation binfo = mgroup.getAnnotation(PrecedenceInterceptor.class.getName());
            if (binfo != null)
            {
               //TODO Make sure it is an interceptor
               entries.add(new PrecedenceDefEntry(getFieldType(finfo), null));
            }
            else
            {
               binfo = mgroup.getAnnotation(PrecedenceAdvice.class.getName());
               if (binfo != null)
               {
                  PrecedenceAdvice advice = (PrecedenceAdvice) AnnotationProxy.createProxy(binfo, PrecedenceAdvice.class);
                  String method = advice.value();
                  entries.add(new PrecedenceDefEntry(getFieldType(finfo), method));
               }
            }
         }
         PrecedenceDefEntry[] pentries = entries.toArray(new PrecedenceDefEntry[entries.size()]);
         loaderStrategy.deployPrecedence(this, cf.getName(), pentries);
View Full Code Here

               String iname = interceptorElement.getAttribute("name");
               if (iname == null || iname.length() == 0)
               {
                  throw new RuntimeException("name must be specified for interceptor-ref in precedence declaration");
               }
               precedenceEntries.add(new PrecedenceDefEntry(iname, null));
            }
            else if (tag2.equals("advice"))
            {
               String method = interceptorElement.getAttribute("name");
               String aspect = interceptorElement.getAttribute("aspect");

               if (method == null || method.length() == 0)
               {
                  throw new RuntimeException("name must be specified for advice in precedence declaration");
               }

               if (aspect == null || aspect.length() == 0)
               {
                  throw new RuntimeException("aspect must be specified for advice in precedence declaration");
               }

               precedenceEntries.add(new PrecedenceDefEntry(aspect, method));
            }
            else
            {
               throw new RuntimeException("Invalid child element of precedence : " + tag2);
            }
View Full Code Here

            if (mgroup == null) continue;
            javassist.bytecode.annotation.Annotation binfo = mgroup.getAnnotation(PrecedenceInterceptor.class.getName());
            if (binfo != null)
            {
               //TODO Make sure it is an interceptor
               entries.add(new PrecedenceDefEntry(getFieldType(finfo), null));
            }
            else
            {
               binfo = mgroup.getAnnotation(PrecedenceAdvice.class.getName());
               if (binfo != null)
               {
                  PrecedenceAdvice advice = (PrecedenceAdvice) AnnotationProxy.createProxy(binfo, PrecedenceAdvice.class);
                  String method = advice.value();
                  entries.add(new PrecedenceDefEntry(getFieldType(finfo), method));
               }
            }
         }
         PrecedenceDefEntry[] pentries = entries.toArray(new PrecedenceDefEntry[entries.size()]);
         PrecedenceDef precedenceDef = new PrecedenceDef(cf.getName(), pentries);
View Full Code Here

               String iname = interceptorElement.getAttribute("name");
               if (iname == null || iname.length() == 0)
               {
                  throw new RuntimeException("name must be specified for interceptor-ref in precedence declaration");
               }
               precedenceEntries.add(new PrecedenceDefEntry(iname, null));
            }
            else if (tag2.equals("advice"))
            {
               String method = interceptorElement.getAttribute("name");
               String aspect = interceptorElement.getAttribute("aspect");

               if (method == null || method.length() == 0)
               {
                  throw new RuntimeException("name must be specified for advice in precedence declaration");
               }

               if (aspect == null || aspect.length() == 0)
               {
                  throw new RuntimeException("aspect must be specified for advice in precedence declaration");
               }

               precedenceEntries.add(new PrecedenceDefEntry(aspect, method));
            }
            else
            {
               throw new RuntimeException("Invalid child element of precedence : " + tag2);
            }
View Full Code Here

            if (mgroup == null) continue;
            javassist.bytecode.annotation.Annotation binfo = mgroup.getAnnotation(PrecedenceInterceptor.class.getName());
            if (binfo != null)
            {
               //TODO Make sure it is an interceptor
               entries.add(new PrecedenceDefEntry(getFieldType(finfo), null));
            }
            else
            {
               binfo = mgroup.getAnnotation(PrecedenceAdvice.class.getName());
               if (binfo != null)
               {
                  PrecedenceAdvice advice = (PrecedenceAdvice) AnnotationProxy.createProxy(binfo, PrecedenceAdvice.class);
                  String method = advice.value();
                  entries.add(new PrecedenceDefEntry(getFieldType(finfo), method));
               }
            }
         }
         PrecedenceDefEntry[] pentries = entries.toArray(new PrecedenceDefEntry[entries.size()]);
         loaderStrategy.deployPrecedence(this, cf.getName(), pentries);
View Full Code Here

               String iname = interceptorElement.getAttribute("name");
               if (iname == null || iname.length() == 0)
               {
                  throw new RuntimeException("name must be specified for interceptor-ref in precedence declaration");
               }
               precedenceEntries.add(new PrecedenceDefEntry(iname, null));
            }
            else if (tag2.equals("advice"))
            {
               String method = interceptorElement.getAttribute("name");
               String aspect = interceptorElement.getAttribute("aspect");

               if (method == null || method.length() == 0)
               {
                  throw new RuntimeException("name must be specified for advice in precedence declaration");
               }

               if (aspect == null || aspect.length() == 0)
               {
                  throw new RuntimeException("aspect must be specified for advice in precedence declaration");
               }

               precedenceEntries.add(new PrecedenceDefEntry(aspect, method));
            }
            else
            {
               throw new RuntimeException("Invalid child element of precedence : " + tag2);
            }
View Full Code Here

            if (mgroup == null) continue;
            javassist.bytecode.annotation.Annotation binfo = mgroup.getAnnotation(PrecedenceInterceptor.class.getName());
            if (binfo != null)
            {
               //TODO Make sure it is an interceptor
               entries.add(new PrecedenceDefEntry(getFieldType(finfo), null));
            }
            else
            {
               binfo = mgroup.getAnnotation(PrecedenceAdvice.class.getName());
               if (binfo != null)
               {
                  PrecedenceAdvice advice = (PrecedenceAdvice) AnnotationProxy.createProxy(binfo, PrecedenceAdvice.class);
                  String method = advice.value();
                  entries.add(new PrecedenceDefEntry(getFieldType(finfo), method));
               }
            }
         }
         PrecedenceDefEntry[] pentries = entries.toArray(new PrecedenceDefEntry[entries.size()]);
         loaderStrategy.deployPrecedence(this, cf.getName(), pentries);
View Full Code Here

/*  348 */         String iname = interceptorElement.getAttribute("name");
/*  349 */         if ((iname == null) || (iname.length() == 0))
/*      */         {
/*  351 */           throw new RuntimeException("name must be specified for interceptor-ref in precedence declaration");
/*      */         }
/*  353 */         precedenceEntries.add(new PrecedenceDefEntry(iname, null));
/*      */       }
/*  355 */       else if (tag2.equals("advice"))
/*      */       {
/*  357 */         String method = interceptorElement.getAttribute("name");
/*  358 */         String aspect = interceptorElement.getAttribute("aspect");
/*      */
/*  360 */         if ((method == null) || (method.length() == 0))
/*      */         {
/*  362 */           throw new RuntimeException("name must be specified for advice in precedence declaration");
/*      */         }
/*      */
/*  365 */         if ((aspect == null) || (aspect.length() == 0))
/*      */         {
/*  367 */           throw new RuntimeException("aspect must be specified for advice in precedence declaration");
/*      */         }
/*      */
/*  370 */         precedenceEntries.add(new PrecedenceDefEntry(aspect, method));
/*      */       }
/*      */       else
/*      */       {
/*  374 */         throw new RuntimeException("Invalid child element of precedence : " + tag2);
/*      */       }
View Full Code Here

/*  404 */         AnnotationsAttribute mgroup = (AnnotationsAttribute)finfo.getAttribute("RuntimeVisibleAnnotations");
/*  405 */         if (mgroup != null) {
/*  406 */           Annotation binfo = mgroup.getAnnotation(PrecedenceInterceptor.class.getName());
/*  407 */           if (binfo != null)
/*      */           {
/*  410 */             entries.add(new PrecedenceDefEntry(getFieldType(finfo), null));
/*      */           }
/*      */           else
/*      */           {
/*  414 */             binfo = mgroup.getAnnotation(PrecedenceAdvice.class.getName());
/*  415 */             if (binfo != null)
/*      */             {
/*  417 */               PrecedenceAdvice advice = (PrecedenceAdvice)AnnotationProxy.createProxy(binfo, PrecedenceAdvice.class);
/*  418 */               String method = advice.value();
/*  419 */               entries.add(new PrecedenceDefEntry(getFieldType(finfo), method));
/*      */             }
/*      */           }
/*      */         }
/*      */       }
/*  423 */       PrecedenceDefEntry[] pentries = (PrecedenceDefEntry[])(PrecedenceDefEntry[])entries.toArray(new PrecedenceDefEntry[entries.size()]);
View Full Code Here

TOP

Related Classes of org.jboss.aop.advice.PrecedenceDefEntry

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.