org.apache.commons.classscan.builtin
Enum PrimitiveClass

java.lang.Object
  extended by java.lang.Enum<PrimitiveClass>
      extended by org.apache.commons.classscan.builtin.PrimitiveClass
All Implemented Interfaces:
Serializable, Comparable<PrimitiveClass>, HasName, MetaClass, MetaType, HasResolve, SpiMetaClass

public enum PrimitiveClass
extends Enum<PrimitiveClass>
implements SpiMetaClass


Enum Constant Summary
B
           
C
           
D
           
F
           
I
           
J
           
S
           
V
           
Z
           
 
Method Summary
 MetaAnnotation getAnnotation(String annotationName)
          Get metadata about a particular annotation on the corresponding Class.
 Set<? extends MetaAnnotation> getAnnotations()
          Get metadata about the annotations on the corresponding Class.
 MetaClassPathElement getClassLocation()
          Get the ClassLocation from which the corresponding class came.
 Set<MetaField> getFields()
          Get metadata about the corresponding Class's methods and constructors.
 Set<MetaClass> getInterfaces()
          Get metadata about the interfaces which the corresponding Class implements.
 Set<MetaMethod> getMethods()
          Get metadata about the corresponding Class's methods and constructors.
 String getName()
          Get the canonical name of the corresponding Class.
 MetaClass getParent()
          Get metadata about the corresponding Class's parent
 boolean isAssignableFrom(MetaClass assignor)
          Is the associated Class assignable from the class associated with the given MetaClass.
 boolean resolve(SpiMetaClassLoader classLoader)
          Resolve names into model entries
static PrimitiveClass valueOf(String name)
          Returns the enum constant of this type with the specified name.
static PrimitiveClass[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

B

public static final PrimitiveClass B

C

public static final PrimitiveClass C

D

public static final PrimitiveClass D

F

public static final PrimitiveClass F

I

public static final PrimitiveClass I

J

public static final PrimitiveClass J

S

public static final PrimitiveClass S

Z

public static final PrimitiveClass Z

V

public static final PrimitiveClass V
Method Detail

values

public static PrimitiveClass[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (PrimitiveClass c : PrimitiveClass.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static PrimitiveClass valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getClassLocation

public MetaClassPathElement getClassLocation()
Description copied from interface: MetaClass
Get the ClassLocation from which the corresponding class came. For primitive types, this will return null.

Specified by:
getClassLocation in interface MetaClass

getName

public String getName()
Description copied from interface: MetaClass
Get the canonical name of the corresponding Class. For primitive types, this will be the primitive type name. e.g. char

Specified by:
getName in interface HasName
Specified by:
getName in interface MetaClass

getParent

public MetaClass getParent()
Description copied from interface: MetaClass
Get metadata about the corresponding Class's parent

Specified by:
getParent in interface MetaClass
Returns:
The MetaClass, or null if the corresponding Class is a primitive type or Object.class

getInterfaces

public Set<MetaClass> getInterfaces()
Description copied from interface: MetaClass
Get metadata about the interfaces which the corresponding Class implements. No inherited interfaces will be in the set.

Specified by:
getInterfaces in interface MetaClass
Returns:
A read-only set of the interface information

getAnnotations

public Set<? extends MetaAnnotation> getAnnotations()
Description copied from interface: MetaClass
Get metadata about the annotations on the corresponding Class.

Specified by:
getAnnotations in interface MetaClass
Returns:
A read-only set of the annotation information

getAnnotation

public MetaAnnotation getAnnotation(String annotationName)
Description copied from interface: MetaClass
Get metadata about a particular annotation on the corresponding Class.

Specified by:
getAnnotation in interface MetaClass
Parameters:
annotationName - The name of the annotation desired
Returns:
The annotation information, or null if not specified on the corresponding Class

getMethods

public Set<MetaMethod> getMethods()
Description copied from interface: MetaClass
Get metadata about the corresponding Class's methods and constructors. No inherited methods will be in the set.

Specified by:
getMethods in interface MetaClass
Returns:
A read-only set of the method information

getFields

public Set<MetaField> getFields()
Description copied from interface: MetaClass
Get metadata about the corresponding Class's methods and constructors. No inherited fields will be in the set.

Specified by:
getFields in interface MetaClass
Returns:
A read-only set of the field information

isAssignableFrom

public boolean isAssignableFrom(MetaClass assignor)
Description copied from interface: MetaClass
Is the associated Class assignable from the class associated with the given MetaClass.

Specified by:
isAssignableFrom in interface MetaClass
Parameters:
assignor - The non-null MetaClass (associated with class or interface)
Returns:
true, if and only if instances represented by implementor can be assigned to instances represented by this MetaClass

resolve

public boolean resolve(SpiMetaClassLoader classLoader)
Description copied from interface: HasResolve
Resolve names into model entries

Specified by:
resolve in interface HasResolve


Copyright © 2012 The Apache Software Foundation. All Rights Reserved.