fr.lifl.magique.platform.classloader
Class ClassInspectorImpl
java.lang.Object
fr.lifl.magique.platform.classloader.ClassInspectorImpl
- All Implemented Interfaces:
- ClassInspector
- public class ClassInspectorImpl
- extends java.lang.Object
- implements ClassInspector
This class is the default implementation of the ClassInspector interface.
It relies on the API for bytecode manipulation of KOPI (kjc)
|
Field Summary |
protected at.dms.classfile.ClassInfo |
classInfo
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
classInfo
protected at.dms.classfile.ClassInfo classInfo
ClassInspectorImpl
public ClassInspectorImpl(java.lang.String filename)
throws java.io.FileNotFoundException,
at.dms.classfile.ClassFileFormatException,
java.io.IOException
ClassInspectorImpl
public ClassInspectorImpl(java.io.DataInput input)
throws at.dms.classfile.ClassFileFormatException,
java.io.IOException
getClassName
public java.lang.String getClassName()
- Specified by:
getClassName in interface ClassInspector
hasASuperClassOtherThanObject
public boolean hasASuperClassOtherThanObject()
- Specified by:
hasASuperClassOtherThanObject in interface ClassInspector
getSuperClassName
public java.lang.String getSuperClassName()
- Specified by:
getSuperClassName in interface ClassInspector
hasInterfaces
public boolean hasInterfaces()
- Specified by:
hasInterfaces in interface ClassInspector
getInterfacesNames
public java.lang.String[] getInterfacesNames()
- Specified by:
getInterfacesNames in interface ClassInspector
hasInnerClasses
public boolean hasInnerClasses()
- Specified by:
hasInnerClasses in interface ClassInspector
getInnerClassesNames
public java.lang.String[] getInnerClassesNames()
- Specified by:
getInnerClassesNames in interface ClassInspector
hasFields
public boolean hasFields()
- Specified by:
hasFields in interface ClassInspector
getFieldsClassesNames
public java.lang.String[] getFieldsClassesNames()
- Specified by:
getFieldsClassesNames in interface ClassInspector
hasMethods
public boolean hasMethods()
- Return true if thos class declares at least one method.
- Specified by:
hasMethods in interface ClassInspector
- Returns:
- true if this class declares at least one method
parseMethodSignature
protected java.util.ArrayList parseMethodSignature(java.lang.String signature)
- This methods parses String which have this template :
(Lclassname1;Lclassname2)Lreturntype;
- Parameters:
signature -
getClassesNamesInsideMethods
public java.lang.String[] getClassesNamesInsideMethods()
- Specified by:
getClassesNamesInsideMethods in interface ClassInspector
toStringArray
protected java.lang.String[] toStringArray(java.util.HashMap listOfStrings)
getAllReferencedClasses
public java.lang.String[] getAllReferencedClasses()
- Specified by:
getAllReferencedClasses in interface ClassInspector
replaceSlash
protected java.lang.String replaceSlash(java.lang.String s)
cleanFieldSignature
protected java.lang.String cleanFieldSignature(java.lang.String fieldSignature)
dump
public void dump(at.dms.classfile.ClassInfo ci)