Package org.jboss.reflect.spi

Examples of org.jboss.reflect.spi.FieldInfo


   {
      boolean trace = log.isTraceEnabled();
      if (trace)
         log.trace("Get field get Joinpoint jpf=" + jpf + " target=" + object + " name=" + name);
     
      FieldInfo fieldInfo = findFieldInfo(jpf.getClassInfo(), name);
      FieldGetJoinpoint joinpoint = jpf.getFieldGetJoinpoint(fieldInfo);
      joinpoint.setTarget(object);
      return joinpoint;
   }
View Full Code Here


   {
      boolean trace = log.isTraceEnabled();
      if (trace)
         log.trace("Get field set Joinpoint jpf=" + jpf + " target=" + object + " name=" + name + " value=" + value);
     
      FieldInfo fieldInfo = findFieldInfo(jpf.getClassInfo(), name);
      FieldSetJoinpoint joinpoint = jpf.getFieldSetJoinpoint(fieldInfo);
      joinpoint.setTarget(object);
      joinpoint.setValue(value);
      return joinpoint;
   }
View Full Code Here

   public static FieldInfo findFieldInfo(ClassInfo classInfo, String name) throws JoinpointException
   {
      ClassInfo current = classInfo;
      while (current != null)
      {
         FieldInfo result = locateFieldInfo(current, name);
         if (result != null)
            return result;
         current = current.getSuperclass();
      }
      throw new JoinpointException("Field not found '" + name + "' for class " + classInfo.getName());
View Full Code Here

      expectClone = new HashSet(expected);
      actualClone = new ArrayList(Arrays.asList(actually));
      for (Iterator i = expectClone.iterator(); i.hasNext();)
      {
         FieldInfo expect = (FieldInfo) i.next();
         int j = actualClone.indexOf(expect);
         FieldInfo actual = (FieldInfo) actualClone.get(j);
         compareField(expect, actual);
      }
   }
View Full Code Here

         MethodInfo method = MethodInfo.class.cast(member);
         return new MethodSignature(method);
      }
      if (member instanceof FieldInfo)
      {
         FieldInfo field = FieldInfo.class.cast(member);
         return new FieldSignature(field);
      }
      if (member instanceof ConstructorInfo)
      {
         ConstructorInfo constructor = ConstructorInfo.class.cast(member);
View Full Code Here

      Method m = getMethod();
      MethodInfo mi = getMethodInfo();
      Signature sm = new MethodSignature(m);
      checkAnnotationCycle(sm, m, mi);
      Field f = getField();
      FieldInfo fi = getFieldInfo();
      Signature sf = new FieldSignature(f);
      checkAnnotationCycle(sf, f, fi);
   }
View Full Code Here

      Method m = getMethod();
      MethodInfo mi = getMethodInfo();
      Signature sm = new MethodSignature(m);
      checkMetaDataCycle(sm, m, mi);
      Field f = getField();
      FieldInfo fi = getFieldInfo();
      Signature sf = new FieldSignature(f);
      checkMetaDataCycle(sf, f, fi);
   }
View Full Code Here

      Set<PropertyInfo> properties = info.getProperties();
      if (properties != null && properties.isEmpty() == false)
      {
         for(PropertyInfo pi : properties)
         {
            FieldInfo field = pi.getFieldInfo();
            if (field != null)
            {
               Signature sis = new FieldSignature(field);
               MetaData cmdr = retrieval.getComponentMetaData(sis);
               if (cmdr != null)
               {
                  for(T plugin : getPlugins(ElementType.FIELD, null, annotationClasses))
                  {
                     if (isApplyPhase)
                        applyPlugin(plugin, field, cmdr, handle);
                     else
                        cleanPlugin(plugin, field, cmdr, handle);
                  }
               }
               else if (trace)
                  log.trace("No annotations for field " + field.getName());
            }
            // apply setter and getter as well - if they exist
            handleMethod(retrieval, handle, isApplyPhase, trace, visitedMethods, pi, pi.getSetter(), "setter", annotationClasses);
            handleMethod(retrieval, handle, isApplyPhase, trace, visitedMethods, pi, pi.getGetter(), "getter", annotationClasses);
         }
View Full Code Here

   {
      boolean trace = log.isTraceEnabled();
      if (trace)
         log.trace("Get field get Joinpoint jpf=" + jpf + " target=" + object + " name=" + name);

      FieldInfo fieldInfo = findFieldInfo(jpf.getClassInfo(), name);
      FieldGetJoinpoint joinpoint = jpf.getFieldGetJoinpoint(fieldInfo);
      joinpoint.setTarget(object);
      return joinpoint;
   }
View Full Code Here

   {
      boolean trace = log.isTraceEnabled();
      if (trace)
         log.trace("Get field set Joinpoint jpf=" + jpf + " target=" + object + " name=" + name + " value=" + value);

      FieldInfo fieldInfo = findFieldInfo(jpf.getClassInfo(), name);
      FieldSetJoinpoint joinpoint = jpf.getFieldSetJoinpoint(fieldInfo);
      joinpoint.setTarget(object);
      joinpoint.setValue(value);
      return joinpoint;
   }
View Full Code Here

TOP

Related Classes of org.jboss.reflect.spi.FieldInfo

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.