X-Git-Url: http://git.megacz.com/?p=org.ibex.classgen.git;a=blobdiff_plain;f=src%2Forg%2Fibex%2Fclassgen%2FType.java;h=21b2f03a06a5c73f80c10b092aa6ba6edcdfb7e1;hp=491cc1227a2194dee33741d1f7e929f441d684ae;hb=ca1b3654e5d2e7bf09933b565fb118571ca61258;hpb=69b2d27ebab56f1b0e4df2a3a301f4d852439e8e diff --git a/src/org/ibex/classgen/Type.java b/src/org/ibex/classgen/Type.java index 491cc12..21b2f03 100644 --- a/src/org/ibex/classgen/Type.java +++ b/src/org/ibex/classgen/Type.java @@ -69,6 +69,13 @@ public class Type { public boolean isRef() { return true; } } + public static class Array extends Type.Ref { + protected Array(Type t) { super("[" + t.getDescriptor(), t.toString() + "[]"); } + public Type.Array asArray() { return this; } + public boolean isArray() { return true; } + public int dimension() { return getDescriptor().lastIndexOf('['); } + } + public static class Class extends Type.Ref { protected Class(String s) { super(_initHelper(s), _initHelper2(s)); } public Type.Class asClass() { return this; } @@ -109,7 +116,6 @@ public class Type { } public class Field extends Member { - /** Create a reference to field name of class c with the type t */ public final Type type; private Field(String name, Type t) { super(name); this.type = t; } public String getDescriptor() { return name; } @@ -134,12 +140,4 @@ public class Type { } } - - public static class Array extends Type.Ref { - protected Array(Type t) { super("[" + t.getDescriptor(), t.toString() + "[]"); } - public Type.Array asArray() { return this; } - public boolean isArray() { return true; } - public int dimension() { return getDescriptor().lastIndexOf('['); } - } - }