aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--api/src/main/java/org/osjava/jardiff/ClassInfoVisitor.java27
1 files changed, 13 insertions, 14 deletions
diff --git a/api/src/main/java/org/osjava/jardiff/ClassInfoVisitor.java b/api/src/main/java/org/osjava/jardiff/ClassInfoVisitor.java
index a01edd4..be7d08b 100644
--- a/api/src/main/java/org/osjava/jardiff/ClassInfoVisitor.java
+++ b/api/src/main/java/org/osjava/jardiff/ClassInfoVisitor.java
@@ -24,7 +24,7 @@ import org.objectweb.asm.MethodVisitor;
import org.objectweb.asm.Opcodes;
/**
- * A reusable class which uses the ASM to build up ClassInfo about a
+ * A reusable class which uses the ASM to build up ClassInfo about a
* java class file.
*
* @author <a href="mailto:[email protected]">Antony Riley</a>
@@ -51,7 +51,7 @@ public class ClassInfoVisitor extends ClassVisitor
* The signature of the class
*/
private String signature;
-
+
/**
* The internal name of the superclass.
*/
@@ -71,28 +71,28 @@ public class ClassInfoVisitor extends ClassVisitor
* A map of field signature to a FieldInfo describing the field.
*/
private Map<String, FieldInfo> fieldMap;
-
+
public ClassInfoVisitor() {
super(Opcodes.ASM5);
}
-
+
/**
* Reset this ClassInfoVisitor so that it can be used to visit another
* class.
*/
public void reset() {
- this.methodMap = new HashMap<String, MethodInfo>();
- this.fieldMap = new HashMap<String, FieldInfo>();
+ methodMap = new HashMap<String, MethodInfo>();
+ fieldMap = new HashMap<String, FieldInfo>();
}
-
+
/**
* The the classInfo this ClassInfoVisitor has built up about a class
*/
public ClassInfo getClassInfo() {
- return new ClassInfo(this.version, this.access, this.name, this.signature, this.supername,
- this.interfaces, this.methodMap, this.fieldMap);
+ return new ClassInfo(version, access, name, signature, supername,
+ interfaces, methodMap, fieldMap);
}
-
+
/**
* Receive notification of information about a class from ASM.
*
@@ -103,7 +103,6 @@ public class ClassInfoVisitor extends ClassVisitor
* @param supername the internal name of the super class.
* @param interfaces the internal names of interfaces implemented.
*/
- @Override
public void visit(int version, int access, String name, String signature,
String supername, String[] interfaces) {
this.version = version;
@@ -117,15 +116,15 @@ public class ClassInfoVisitor extends ClassVisitor
@Override
public MethodVisitor visitMethod(int access, String name, String desc,
String signature, String[] exceptions) {
- this.methodMap.put(name + desc, new MethodInfo(access, name, desc,
+ methodMap.put(name + desc, new MethodInfo(access, name, desc,
signature, exceptions));
return null;
}
-
+
@Override
public FieldVisitor visitField(int access, String name, String desc,
String signature, Object value) {
- this.fieldMap.put(name,
+ fieldMap.put(name,
new FieldInfo(access, name, desc, signature, value));
return null;
}