|
Copyright 2002 by aragost | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.aragost.lang.Classes
Utility class with variaous functions working on classes and interfaces
Constructor Summary | |
Classes()
|
Method Summary | |
static java.util.Iterator |
allInterfaces(java.lang.Class clazz)
Return an Iterator that will iterate over all interfaces implemented by the receiver. |
static int |
getArrayDimension(java.lang.Class c)
Return the dimension of the specified Array class. |
static java.io.File |
getBase(java.lang.Class clazz)
Try to figure out where the specified class is loaded from. |
static java.lang.String |
getName(java.lang.Class clazz)
Return the name of the specified Class. |
static java.lang.String |
getName(java.lang.Class clazz,
java.util.Collection names)
Return the name of the specified Class. |
static java.lang.String |
getName(java.lang.Object instance,
java.lang.Class clazz)
Return the name of the specified Class. |
static java.lang.String |
getName(java.lang.Object instance,
java.lang.Class clazz,
java.util.Collection names)
Return the name of the specified class. |
static java.lang.Class |
getPrimitiveClass(java.lang.Class clazz)
Return the primitive class associated with the specified wrapper class. |
static java.lang.String |
getResourceName(java.lang.Class clazz)
Return the name of the resource that was loaded to create this class. |
static java.lang.Class |
getRootComponentType(java.lang.Class c)
Return the "root" component type of the specified array class. |
static java.lang.Class |
getWrapperClass(java.lang.Class clazz)
Return the wrapper class associated with the specified primitive class. |
static boolean |
isWrapperClass(java.lang.Class clazz)
Check if the specified class is a wrapper class for a primitive class |
static java.lang.Class[] |
primitives()
Return an array with all primitive classes |
static java.util.Iterator |
superclasses(java.lang.Class clazz)
Return an Iterator that iterate from the specified class through the superclass chain to the class Object.class. |
static java.util.Iterator |
traverse(java.io.File root)
|
static java.util.Iterator |
traverseZip(java.io.File zipFile)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Classes()
Method Detail |
public static boolean isWrapperClass(java.lang.Class clazz)
clazz
- The Class to check
public static java.lang.Class getPrimitiveClass(java.lang.Class clazz)
clazz
-
public static java.lang.Class getWrapperClass(java.lang.Class clazz)
public static java.lang.Class[] primitives()
public static java.util.Iterator allInterfaces(java.lang.Class clazz)
public static java.util.Iterator superclasses(java.lang.Class clazz)
public static java.util.Iterator traverse(java.io.File root)
public static java.util.Iterator traverseZip(java.io.File zipFile) throws java.util.zip.ZipException, java.io.IOException
java.util.zip.ZipException
java.io.IOException
public static java.lang.String getName(java.lang.Object instance, java.lang.Class clazz, java.util.Collection names)
instance
- An instance of the specified class, can be nullclazz
- The class to return the name ofnames
- A Collection of package names.
public static java.lang.String getName(java.lang.Class clazz)
getName(Object, Class, Collection)
public static java.lang.String getName(java.lang.Class clazz, java.util.Collection names)
getName(Object, Class, Collection)
public static java.lang.String getName(java.lang.Object instance, java.lang.Class clazz)
getName(Object, Class, Collection)
public static int getArrayDimension(java.lang.Class c)
public static java.lang.Class getRootComponentType(java.lang.Class c)
public static java.lang.String getResourceName(java.lang.Class clazz)
public static java.io.File getBase(java.lang.Class clazz)
|
Copyright 2002 by aragost | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |