Package org.jboss.reflect.spi

Examples of org.jboss.reflect.spi.TypeInfo


      HashSet<PropertyInfo> properties = new HashSet<PropertyInfo>();
      if (methods != null && methods.isEmpty() == false)
      {
         for (MethodInfo method : methods)
         {
            TypeInfo returnType = method.getReturnType();
            TypeInfo[] parameters = method.getParameterTypes();
            if (parameters.length == 0 && PrimitiveInfo.VOID.equals(returnType) == false)
            {
               String name = method.getName();
               properties.add(new DefaultPropertyInfo(name, name, returnType, method, null, method.getAnnotations()));
View Full Code Here


      {
         CtClass ctClass = getCtClass(clazz.getName());

         if (clazz.isArray())
         {
            TypeInfo componentType = getTypeInfo(clazz.getComponentType());
            return new JavassistArrayInfoImpl(this, ctClass, clazz, componentType);
         }

         if (ctClass.isAnnotation())
         {
View Full Code Here

   public TypeInfo getTypeInfo(Class<?> clazz)
   {
      if (clazz == null)
         throw new IllegalArgumentException("Null class");

      TypeInfo primitive = PrimitiveInfo.valueOf(clazz.getName());
      if (primitive != null)
         return primitive;

      NumberInfo number = NumberInfo.valueOf(clazz.getName());
      if (number != null)
View Full Code Here

      if (name == null)
         throw new IllegalArgumentException("Null class name");
      if (cl == null)
         cl = Thread.currentThread().getContextClassLoader();

      TypeInfo primitive = PrimitiveInfo.valueOf(name);
      if (primitive != null)
         return primitive;

      NumberInfo number = NumberInfo.valueOf(name);
      if (number != null)
View Full Code Here

   public TypeInfo getTypeInfo(Class<?> clazz)
   {
      if (clazz == null)
         throw new IllegalArgumentException("Null class");

      TypeInfo primitive = PrimitiveInfo.valueOf(clazz.getName());
      if (primitive != null)
         return primitive;

      NumberInfo number = NumberInfo.valueOf(clazz.getName());
      if (number != null)
View Full Code Here

      String name = null;
      if (type instanceof Class)
         name = ((Class<?>) type).getName();
      if (name != null)
      {
         TypeInfo primitive = PrimitiveInfo.valueOf(name);
         if (primitive != null)
            return primitive;

         NumberInfo number = NumberInfo.valueOf(name);
         if (number != null)
View Full Code Here

   public TypeInfo getTypeInfo(String name, ClassLoader cl) throws ClassNotFoundException
   {
      if (name == null)
         throw new IllegalArgumentException("Null class name");

      TypeInfo primitive = PrimitiveInfo.valueOf(name);
      if (primitive != null)
         return primitive;

      NumberInfo number = NumberInfo.valueOf(name);
      if (number != null)
View Full Code Here

    */
   @Override
   protected TypeInfo getGenericArrayType(GenericArrayType type)
   {
      Type compType = type.getGenericComponentType();
      TypeInfo componentType = getTypeInfo(compType);
      return new ArrayInfoImpl(componentType);
   }
View Full Code Here

   protected TypeInfo instantiate(Class<?> clazz)
   {
      ClassInfoImpl result;
      if (clazz.isArray())
      {
         TypeInfo componentType = getTypeInfo(clazz.getComponentType());
         result = new ArrayInfoImpl(componentType);
      }
      else if (clazz.isEnum())
      {
         EnumInfoImpl enumInfoImpl = new EnumInfoImpl(clazz.getName(), clazz.getModifiers());
View Full Code Here

      if (obj == this)
         return true;
      if (obj == null || obj instanceof TypeInfo == false)
         return false;

      TypeInfo other = (TypeInfo) obj;
      return getName().equals(other.getName());
   }
View Full Code Here

TOP

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

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.