Package org.jboss.reflect.plugins

Examples of org.jboss.reflect.plugins.FieldInfoImpl


     
      FieldInfoImpl[] infos = new FieldInfoImpl[fields.length];
      for (int i = 0; i < fields.length; ++i)
      {
         AnnotationValue[] annotations = getAnnotations(fields[i]);
         infos[i] = new FieldInfoImpl(annotations, fields[i].getName(), getTypeInfo(fields[i].getType()), fields[i].getModifiers(), (ClassInfo) getTypeInfo(fields[i].getDeclaringClass()));
         infos[i].setField(fields[i]);
      }
      return infos;
   }
View Full Code Here


      ClassInfo simpleInterface = (ClassInfo) factory.getTypeInfo(SimpleInterface.class);
     
      TypeInfo objectType = factory.getTypeInfo(Object.class);
     
      HashSet result = new HashSet();
      result.add(new FieldInfoImpl(null, "A_CONSTANT", objectType, ModifierInfo.PUBLIC_CONSTANT, simpleInterface));
      return result;
   }
View Full Code Here

      ClassInfo simpleBean = (ClassInfo) factory.getTypeInfo(SimpleBean.class);
     
      TypeInfo objectType = factory.getTypeInfo(Object.class);
     
      HashSet result = new HashSet();
      result.add(new FieldInfoImpl(null, "PUBLIC_CONSTANT", objectType, ModifierInfo.PUBLIC_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "PACKAGE_PRIVATE_CONSTANT", objectType, ModifierInfo.PACKAGE_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "PROTECTED_CONSTANT", objectType, ModifierInfo.PROTECTED_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "PRIVATE_CONSTANT", objectType, ModifierInfo.PRIVATE_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "serialVersionUID", longType, ModifierInfo.PRIVATE_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "publicAttribute", objectType, ModifierInfo.PUBLIC, simpleBean));
      result.add(new FieldInfoImpl(null, "packagePrivateAttribute", objectType, ModifierInfo.PACKAGE, simpleBean));
      result.add(new FieldInfoImpl(null, "protectedAttribute", objectType, ModifierInfo.PROTECTED, simpleBean));
      result.add(new FieldInfoImpl(null, "privateAttribute", objectType, ModifierInfo.PRIVATE, simpleBean));
      return result;
   }
View Full Code Here

      TypeInfoFactory factory = getTypeInfoFactory();
      Set<FieldInfo> expected = new HashSet<FieldInfo>();
      for (Field field : clazz.getDeclaredFields())
      {
         TypeInfo type = factory.getTypeInfo(field.getGenericType());
         FieldInfo f = new FieldInfoImpl(null, field.getName(), type, field.getModifiers(), classInfo);
         expected.add(f);
      }
     
      FieldInfo[] result = classInfo.getDeclaredFields();
      if (expected.isEmpty())
View Full Code Here

      ClassInfo simpleInterface = (ClassInfo) factory.getTypeInfo(SimpleInterface.class);
     
      TypeInfo objectType = factory.getTypeInfo(Object.class);
     
      HashSet<FieldInfo> result = new HashSet<FieldInfo>();
      result.add(new FieldInfoImpl(null, "A_CONSTANT", objectType, ModifierInfo.PUBLIC_CONSTANT, simpleInterface));
      return result;
   }
View Full Code Here

      ClassInfo simpleBean = (ClassInfo) factory.getTypeInfo(SimpleBean.class);
     
      TypeInfo objectType = factory.getTypeInfo(Object.class);
     
      HashSet<FieldInfo> result = new HashSet<FieldInfo>();
      result.add(new FieldInfoImpl(null, "PUBLIC_CONSTANT", objectType, ModifierInfo.PUBLIC_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "PACKAGE_PRIVATE_CONSTANT", objectType, ModifierInfo.PACKAGE_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "PROTECTED_CONSTANT", objectType, ModifierInfo.PROTECTED_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "PRIVATE_CONSTANT", objectType, ModifierInfo.PRIVATE_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "serialVersionUID", longType, ModifierInfo.PRIVATE_CONSTANT, simpleBean));
      result.add(new FieldInfoImpl(null, "publicAttribute", objectType, ModifierInfo.PUBLIC, simpleBean));
      result.add(new FieldInfoImpl(null, "packagePrivateAttribute", objectType, ModifierInfo.PACKAGE, simpleBean));
      result.add(new FieldInfoImpl(null, "protectedAttribute", objectType, ModifierInfo.PROTECTED, simpleBean));
      result.add(new FieldInfoImpl(null, "privateAttribute", objectType, ModifierInfo.PRIVATE, simpleBean));
      return result;
   }
View Full Code Here

TOP

Related Classes of org.jboss.reflect.plugins.FieldInfoImpl

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.