getTargets();
- public String getSourceHandle();
+ String getSourceHandle();
- public boolean hasRuntimeTest();
+ boolean hasRuntimeTest();
- public boolean isAffects();
+ boolean isAffects();
- public static class Kind implements Serializable { // typesafe enum
+ class Kind implements Serializable { // typesafe enum
private static final long serialVersionUID = -2691351740214705220L;
@@ -70,7 +70,7 @@ public interface IRelationship extends Serializable {
/**
* Return the Kind of the relationship that is passed in by name.
- *
+ *
* @param stringFormOfRelationshipKind the relationship name, eg. 'declare warning', 'declare error', etc.
* @return the Kind instance
*/
diff --git a/asm/src/main/java/org/aspectj/asm/IRelationshipMap.java b/asm/src/main/java/org/aspectj/asm/IRelationshipMap.java
index e4159dce8..fdaab0ad6 100644
--- a/asm/src/main/java/org/aspectj/asm/IRelationshipMap.java
+++ b/asm/src/main/java/org/aspectj/asm/IRelationshipMap.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2003 Contributors.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Mik Kersten initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Mik Kersten initial implementation
* ******************************************************************/
package org.aspectj.asm;
@@ -22,15 +22,15 @@ import java.util.Set;
* particular shadow (e.g. method call) can be retrieved by calling get
on the handle for that method. Symmetrically
* the method call shadows that an advice affects can be retrieved.
*
- *
+ *
*
* The elements can be stored and looked up as IProgramElement(s), in which cases the element corresponding to the handle is looked
* up in the containment hierarchy.
- *
+ *
*
* put/get methods taking IProgramElement as a parameter are for convenience only. They work identically to calling their
* counterparts with IProgramElement.getIdentifierHandle()
- *
+ *
* @author Mik Kersten
* @author Andy Clement
*/
@@ -39,49 +39,49 @@ public interface IRelationshipMap extends Serializable {
/**
* @return list of relationships or null if the source element has no relationships
*/
- public List get(IProgramElement sourceProgramElement);
+ List get(IProgramElement sourceProgramElement);
/**
* @return list of relationships or null if the source element has no relationships
*/
- public List get(String sourceHandle);
+ List get(String sourceHandle);
/**
* Return a relationship matching the kind and name for the given element.
- *
+ *
* @return null if the relationship is not found.
*/
- public IRelationship get(IProgramElement source, IRelationship.Kind kind, String relationshipName, boolean runtimeTest,
- boolean createIfMissing);
+ IRelationship get(IProgramElement source, IRelationship.Kind kind, String relationshipName, boolean runtimeTest,
+ boolean createIfMissing);
/**
* Return a relationship matching the kind and name for the given element.
- *
+ *
* @return null if the relationship is not found.
*/
- public IRelationship get(IProgramElement source, IRelationship.Kind kind, String relationshipName);
+ IRelationship get(IProgramElement source, IRelationship.Kind kind, String relationshipName);
/**
* Return a relationship matching the kind and name for the given element. Creates the relationship if not found.
- *
+ *
* @return null if the relationship is not found.
*/
- public IRelationship get(String source, IRelationship.Kind kind, String relationshipName, boolean runtimeTest,
- boolean createIfMissing);
+ IRelationship get(String source, IRelationship.Kind kind, String relationshipName, boolean runtimeTest,
+ boolean createIfMissing);
- public void put(IProgramElement source, IRelationship relationship);
+ void put(IProgramElement source, IRelationship relationship);
- public void put(String handle, IRelationship relationship);
+ void put(String handle, IRelationship relationship);
- public boolean remove(String handle, IRelationship relationship);
+ boolean remove(String handle, IRelationship relationship);
- public void removeAll(String source);
+ void removeAll(String source);
/**
* Clear all of the relationships in the map.
*/
- public void clear();
+ void clear();
- public Set getEntries();
+ Set getEntries();
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/Constants.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/Constants.java
index 03fda5d89..96fdfdf6f 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/Constants.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/Constants.java
@@ -64,116 +64,116 @@ import org.aspectj.apache.bcel.generic.Type;
*/
public interface Constants {
// Major and minor version of the code
- public final static short MAJOR_1_1 = 45;
- public final static short MINOR_1_1 = 3;
- public final static short MAJOR_1_2 = 46;
- public final static short MINOR_1_2 = 0;
- public final static short MAJOR_1_3 = 47;
- public final static short MINOR_1_3 = 0;
- public final static short MAJOR_1_4 = 48;
- public final static short MINOR_1_4 = 0;
- public final static short MAJOR_1_5 = 49;
- public final static short MINOR_1_5 = 0;
- public final static short MAJOR_1_6 = 50;
- public final static short MINOR_1_6 = 0;
- public final static short MAJOR_1_7 = 51;
- public final static short MINOR_1_7 = 0;
- public final static short MAJOR_1_8 = 52;
- public final static short MINOR_1_8 = 0;
- public final static short MAJOR_1_9 = 53;
- public final static short MINOR_1_9 = 0;
- public final static short MAJOR_10 = 54;
- public final static short MINOR_10 = 0;
- public final static short MAJOR_11 = 55;
- public final static short MINOR_11 = 0;
- public final static short MAJOR_12 = 56;
- public final static short MINOR_12 = 0;
- public final static short MAJOR_13 = 57;
- public final static short MINOR_13 = 0;
- public final static short MAJOR_14 = 58;
- public final static short MINOR_14 = 0;
-
- public final static int PREVIEW_MINOR_VERSION = 65535;
+ short MAJOR_1_1 = 45;
+ short MINOR_1_1 = 3;
+ short MAJOR_1_2 = 46;
+ short MINOR_1_2 = 0;
+ short MAJOR_1_3 = 47;
+ short MINOR_1_3 = 0;
+ short MAJOR_1_4 = 48;
+ short MINOR_1_4 = 0;
+ short MAJOR_1_5 = 49;
+ short MINOR_1_5 = 0;
+ short MAJOR_1_6 = 50;
+ short MINOR_1_6 = 0;
+ short MAJOR_1_7 = 51;
+ short MINOR_1_7 = 0;
+ short MAJOR_1_8 = 52;
+ short MINOR_1_8 = 0;
+ short MAJOR_1_9 = 53;
+ short MINOR_1_9 = 0;
+ short MAJOR_10 = 54;
+ short MINOR_10 = 0;
+ short MAJOR_11 = 55;
+ short MINOR_11 = 0;
+ short MAJOR_12 = 56;
+ short MINOR_12 = 0;
+ short MAJOR_13 = 57;
+ short MINOR_13 = 0;
+ short MAJOR_14 = 58;
+ short MINOR_14 = 0;
+
+ int PREVIEW_MINOR_VERSION = 65535;
// Defaults
- public final static short MAJOR = MAJOR_1_1;
- public final static short MINOR = MINOR_1_1;
+ short MAJOR = MAJOR_1_1;
+ short MINOR = MINOR_1_1;
/** Maximum value for an unsigned short */
- public final static int MAX_SHORT = 65535; // 2^16 - 1
+ int MAX_SHORT = 65535; // 2^16 - 1
/** Maximum value for an unsigned byte */
- public final static int MAX_BYTE = 255; // 2^8 - 1
+ int MAX_BYTE = 255; // 2^8 - 1
/** Access flags for classes, fields and methods */
- public final static short ACC_PUBLIC = 0x0001;
- public final static short ACC_PRIVATE = 0x0002;
- public final static short ACC_PROTECTED = 0x0004;
- public final static short ACC_STATIC = 0x0008;
+ short ACC_PUBLIC = 0x0001;
+ short ACC_PRIVATE = 0x0002;
+ short ACC_PROTECTED = 0x0004;
+ short ACC_STATIC = 0x0008;
- public final static short ACC_FINAL = 0x0010;
- public final static short ACC_SYNCHRONIZED = 0x0020;
- public final static short ACC_VOLATILE = 0x0040;
- public final static short ACC_TRANSIENT = 0x0080;
+ short ACC_FINAL = 0x0010;
+ short ACC_SYNCHRONIZED = 0x0020;
+ short ACC_VOLATILE = 0x0040;
+ short ACC_TRANSIENT = 0x0080;
- public final static short ACC_NATIVE = 0x0100;
- public final static short ACC_INTERFACE = 0x0200;
- public final static short ACC_ABSTRACT = 0x0400;
- public final static short ACC_STRICT = 0x0800;
+ short ACC_NATIVE = 0x0100;
+ short ACC_INTERFACE = 0x0200;
+ short ACC_ABSTRACT = 0x0400;
+ short ACC_STRICT = 0x0800;
- public final static short ACC_SYNTHETIC = 0x1000;
+ short ACC_SYNTHETIC = 0x1000;
- public final static short ACC_ANNOTATION = 0x2000;
- public final static short ACC_ENUM = 0x4000;
- public final static int ACC_MODULE = 0x8000;
- public final static short ACC_BRIDGE = 0x0040;
- public final static short ACC_VARARGS = 0x0080;
+ short ACC_ANNOTATION = 0x2000;
+ short ACC_ENUM = 0x4000;
+ int ACC_MODULE = 0x8000;
+ short ACC_BRIDGE = 0x0040;
+ short ACC_VARARGS = 0x0080;
// Module related
// Indicates that any module which depends on the current module,
// implicitly declares a dependence on the module indicated by this entry.
- public final static int MODULE_ACC_TRANSITIVE = 0x0020;
+ int MODULE_ACC_TRANSITIVE = 0x0020;
// Indicates that this dependence is mandatory in the static phase, i.e., at
// compile time, but is optional in the dynamic phase, i.e., at run time.
- public final static int MODULE_ACC_STATIC_PHASE = 0x0040;
+ int MODULE_ACC_STATIC_PHASE = 0x0040;
// Indicates that this dependence was not explicitly or implicitly declared
// in the source of the module declaration.
- public final static int MODULE_ACC_SYNTHETIC = 0x1000;
+ int MODULE_ACC_SYNTHETIC = 0x1000;
// Indicates that this dependence was implicitly declared in the source of
// the module declaration
- public final static int MODULE_ACC_MANDATED = 0x8000;
+ int MODULE_ACC_MANDATED = 0x8000;
// Applies to classes compiled by new compilers only
- public final static short ACC_SUPER = 0x0020;
+ short ACC_SUPER = 0x0020;
- public final static short MAX_ACC_FLAG = ACC_STRICT;
+ short MAX_ACC_FLAG = ACC_STRICT;
- public final static String[] ACCESS_NAMES = { "public", "private", "protected", "static", "final", "synchronized", "volatile",
+ String[] ACCESS_NAMES = { "public", "private", "protected", "static", "final", "synchronized", "volatile",
"transient", "native", "interface", "abstract", "strictfp" };
/** Tags in constant pool to denote type of constant */
- public final static byte CONSTANT_Utf8 = 1;
- public final static byte CONSTANT_Integer = 3;
- public final static byte CONSTANT_Float = 4;
- public final static byte CONSTANT_Long = 5;
- public final static byte CONSTANT_Double = 6;
- public final static byte CONSTANT_Class = 7;
- public final static byte CONSTANT_Fieldref = 9;
- public final static byte CONSTANT_String = 8;
- public final static byte CONSTANT_Methodref = 10;
- public final static byte CONSTANT_InterfaceMethodref = 11;
- public final static byte CONSTANT_NameAndType = 12;
-
- public final static byte CONSTANT_MethodHandle = 15;
- public final static byte CONSTANT_MethodType = 16;
- public final static byte CONSTANT_Dynamic = 17;
- public final static byte CONSTANT_InvokeDynamic = 18;
-
- public final static byte CONSTANT_Module = 19;
- public final static byte CONSTANT_Package = 20;
-
-
- public final static String[] CONSTANT_NAMES = { "", "CONSTANT_Utf8", "", "CONSTANT_Integer", "CONSTANT_Float", "CONSTANT_Long",
+ byte CONSTANT_Utf8 = 1;
+ byte CONSTANT_Integer = 3;
+ byte CONSTANT_Float = 4;
+ byte CONSTANT_Long = 5;
+ byte CONSTANT_Double = 6;
+ byte CONSTANT_Class = 7;
+ byte CONSTANT_Fieldref = 9;
+ byte CONSTANT_String = 8;
+ byte CONSTANT_Methodref = 10;
+ byte CONSTANT_InterfaceMethodref = 11;
+ byte CONSTANT_NameAndType = 12;
+
+ byte CONSTANT_MethodHandle = 15;
+ byte CONSTANT_MethodType = 16;
+ byte CONSTANT_Dynamic = 17;
+ byte CONSTANT_InvokeDynamic = 18;
+
+ byte CONSTANT_Module = 19;
+ byte CONSTANT_Package = 20;
+
+
+ String[] CONSTANT_NAMES = { "", "CONSTANT_Utf8", "", "CONSTANT_Integer", "CONSTANT_Float", "CONSTANT_Long",
"CONSTANT_Double", "CONSTANT_Class", "CONSTANT_String", "CONSTANT_Fieldref", "CONSTANT_Methodref",
"CONSTANT_InterfaceMethodref", "CONSTANT_NameAndType","","","CONSTANT_MethodHandle","CONSTANT_MethodType","","CONSTANT_InvokeDynamic",
// J9:
@@ -183,349 +183,349 @@ public interface Constants {
* The name of the static initializer, also called "class initialization method" or "interface initialization
* method". This is "<clinit>".
*/
- public final static String STATIC_INITIALIZER_NAME = "";
+ String STATIC_INITIALIZER_NAME = "";
/**
* The name of every constructor method in a class, also called "instance initialization method". This is
* "<init>".
*/
- public final static String CONSTRUCTOR_NAME = "";
+ String CONSTRUCTOR_NAME = "";
/** The names of the interfaces implemented by arrays */
- public final static String[] INTERFACES_IMPLEMENTED_BY_ARRAYS = { "java.lang.Cloneable", "java.io.Serializable" };
+ String[] INTERFACES_IMPLEMENTED_BY_ARRAYS = { "java.lang.Cloneable", "java.io.Serializable" };
/**
* Limitations of the Java Virtual Machine. See The Java Virtual Machine Specification, Second Edition, page 152, chapter 4.10.
*/
- public static final int MAX_CP_ENTRIES = 65535;
- public static final int MAX_CODE_SIZE = 65536; // bytes
+ int MAX_CP_ENTRIES = 65535;
+ int MAX_CODE_SIZE = 65536; // bytes
/**
* Java VM opcodes.
*/
- public static final short NOP = 0;
- public static final short ACONST_NULL = 1;
- public static final short ICONST_M1 = 2;
- public static final short ICONST_0 = 3;
- public static final short ICONST_1 = 4;
- public static final short ICONST_2 = 5;
- public static final short ICONST_3 = 6;
- public static final short ICONST_4 = 7;
- public static final short ICONST_5 = 8;
- public static final short LCONST_0 = 9;
- public static final short LCONST_1 = 10;
- public static final short FCONST_0 = 11;
- public static final short FCONST_1 = 12;
- public static final short FCONST_2 = 13;
- public static final short DCONST_0 = 14;
- public static final short DCONST_1 = 15;
- public static final short BIPUSH = 16;
- public static final short SIPUSH = 17;
- public static final short LDC = 18;
- public static final short LDC_W = 19;
- public static final short LDC2_W = 20;
- public static final short ILOAD = 21;
- public static final short LLOAD = 22;
- public static final short FLOAD = 23;
- public static final short DLOAD = 24;
- public static final short ALOAD = 25;
- public static final short ILOAD_0 = 26;
- public static final short ILOAD_1 = 27;
- public static final short ILOAD_2 = 28;
- public static final short ILOAD_3 = 29;
- public static final short LLOAD_0 = 30;
- public static final short LLOAD_1 = 31;
- public static final short LLOAD_2 = 32;
- public static final short LLOAD_3 = 33;
- public static final short FLOAD_0 = 34;
- public static final short FLOAD_1 = 35;
- public static final short FLOAD_2 = 36;
- public static final short FLOAD_3 = 37;
- public static final short DLOAD_0 = 38;
- public static final short DLOAD_1 = 39;
- public static final short DLOAD_2 = 40;
- public static final short DLOAD_3 = 41;
- public static final short ALOAD_0 = 42;
- public static final short ALOAD_1 = 43;
- public static final short ALOAD_2 = 44;
- public static final short ALOAD_3 = 45;
- public static final short IALOAD = 46;
- public static final short LALOAD = 47;
- public static final short FALOAD = 48;
- public static final short DALOAD = 49;
- public static final short AALOAD = 50;
- public static final short BALOAD = 51;
- public static final short CALOAD = 52;
- public static final short SALOAD = 53;
- public static final short ISTORE = 54;
- public static final short LSTORE = 55;
- public static final short FSTORE = 56;
- public static final short DSTORE = 57;
- public static final short ASTORE = 58;
- public static final short ISTORE_0 = 59;
- public static final short ISTORE_1 = 60;
- public static final short ISTORE_2 = 61;
- public static final short ISTORE_3 = 62;
- public static final short LSTORE_0 = 63;
- public static final short LSTORE_1 = 64;
- public static final short LSTORE_2 = 65;
- public static final short LSTORE_3 = 66;
- public static final short FSTORE_0 = 67;
- public static final short FSTORE_1 = 68;
- public static final short FSTORE_2 = 69;
- public static final short FSTORE_3 = 70;
- public static final short DSTORE_0 = 71;
- public static final short DSTORE_1 = 72;
- public static final short DSTORE_2 = 73;
- public static final short DSTORE_3 = 74;
- public static final short ASTORE_0 = 75;
- public static final short ASTORE_1 = 76;
- public static final short ASTORE_2 = 77;
- public static final short ASTORE_3 = 78;
- public static final short IASTORE = 79;
- public static final short LASTORE = 80;
- public static final short FASTORE = 81;
- public static final short DASTORE = 82;
- public static final short AASTORE = 83;
- public static final short BASTORE = 84;
- public static final short CASTORE = 85;
- public static final short SASTORE = 86;
- public static final short POP = 87;
- public static final short POP2 = 88;
- public static final short DUP = 89;
- public static final short DUP_X1 = 90;
- public static final short DUP_X2 = 91;
- public static final short DUP2 = 92;
- public static final short DUP2_X1 = 93;
- public static final short DUP2_X2 = 94;
- public static final short SWAP = 95;
- public static final short IADD = 96;
- public static final short LADD = 97;
- public static final short FADD = 98;
- public static final short DADD = 99;
- public static final short ISUB = 100;
- public static final short LSUB = 101;
- public static final short FSUB = 102;
- public static final short DSUB = 103;
- public static final short IMUL = 104;
- public static final short LMUL = 105;
- public static final short FMUL = 106;
- public static final short DMUL = 107;
- public static final short IDIV = 108;
- public static final short LDIV = 109;
- public static final short FDIV = 110;
- public static final short DDIV = 111;
- public static final short IREM = 112;
- public static final short LREM = 113;
- public static final short FREM = 114;
- public static final short DREM = 115;
- public static final short INEG = 116;
- public static final short LNEG = 117;
- public static final short FNEG = 118;
- public static final short DNEG = 119;
- public static final short ISHL = 120;
- public static final short LSHL = 121;
- public static final short ISHR = 122;
- public static final short LSHR = 123;
- public static final short IUSHR = 124;
- public static final short LUSHR = 125;
- public static final short IAND = 126;
- public static final short LAND = 127;
- public static final short IOR = 128;
- public static final short LOR = 129;
- public static final short IXOR = 130;
- public static final short LXOR = 131;
- public static final short IINC = 132;
- public static final short I2L = 133;
- public static final short I2F = 134;
- public static final short I2D = 135;
- public static final short L2I = 136;
- public static final short L2F = 137;
- public static final short L2D = 138;
- public static final short F2I = 139;
- public static final short F2L = 140;
- public static final short F2D = 141;
- public static final short D2I = 142;
- public static final short D2L = 143;
- public static final short D2F = 144;
- public static final short I2B = 145;
- public static final short INT2BYTE = 145; // Old notion
- public static final short I2C = 146;
- public static final short INT2CHAR = 146; // Old notion
- public static final short I2S = 147;
- public static final short INT2SHORT = 147; // Old notion
- public static final short LCMP = 148;
- public static final short FCMPL = 149;
- public static final short FCMPG = 150;
- public static final short DCMPL = 151;
- public static final short DCMPG = 152;
- public static final short IFEQ = 153;
- public static final short IFNE = 154;
- public static final short IFLT = 155;
- public static final short IFGE = 156;
- public static final short IFGT = 157;
- public static final short IFLE = 158;
- public static final short IF_ICMPEQ = 159;
- public static final short IF_ICMPNE = 160;
- public static final short IF_ICMPLT = 161;
- public static final short IF_ICMPGE = 162;
- public static final short IF_ICMPGT = 163;
- public static final short IF_ICMPLE = 164;
- public static final short IF_ACMPEQ = 165;
- public static final short IF_ACMPNE = 166;
- public static final short GOTO = 167;
- public static final short JSR = 168;
- public static final short RET = 169;
- public static final short TABLESWITCH = 170;
- public static final short LOOKUPSWITCH = 171;
- public static final short IRETURN = 172;
- public static final short LRETURN = 173;
- public static final short FRETURN = 174;
- public static final short DRETURN = 175;
- public static final short ARETURN = 176;
- public static final short RETURN = 177;
- public static final short GETSTATIC = 178;
- public static final short PUTSTATIC = 179;
- public static final short GETFIELD = 180;
- public static final short PUTFIELD = 181;
- public static final short INVOKEVIRTUAL = 182;
- public static final short INVOKESPECIAL = 183;
- public static final short INVOKENONVIRTUAL = 183; // Old name in JDK 1.0
- public static final short INVOKESTATIC = 184;
- public static final short INVOKEINTERFACE = 185;
- public static final short INVOKEDYNAMIC = 186;
- public static final short NEW = 187;
- public static final short NEWARRAY = 188;
- public static final short ANEWARRAY = 189;
- public static final short ARRAYLENGTH = 190;
- public static final short ATHROW = 191;
- public static final short CHECKCAST = 192;
- public static final short INSTANCEOF = 193;
- public static final short MONITORENTER = 194;
- public static final short MONITOREXIT = 195;
- public static final short WIDE = 196;
- public static final short MULTIANEWARRAY = 197;
- public static final short IFNULL = 198;
- public static final short IFNONNULL = 199;
- public static final short GOTO_W = 200;
- public static final short JSR_W = 201;
+ short NOP = 0;
+ short ACONST_NULL = 1;
+ short ICONST_M1 = 2;
+ short ICONST_0 = 3;
+ short ICONST_1 = 4;
+ short ICONST_2 = 5;
+ short ICONST_3 = 6;
+ short ICONST_4 = 7;
+ short ICONST_5 = 8;
+ short LCONST_0 = 9;
+ short LCONST_1 = 10;
+ short FCONST_0 = 11;
+ short FCONST_1 = 12;
+ short FCONST_2 = 13;
+ short DCONST_0 = 14;
+ short DCONST_1 = 15;
+ short BIPUSH = 16;
+ short SIPUSH = 17;
+ short LDC = 18;
+ short LDC_W = 19;
+ short LDC2_W = 20;
+ short ILOAD = 21;
+ short LLOAD = 22;
+ short FLOAD = 23;
+ short DLOAD = 24;
+ short ALOAD = 25;
+ short ILOAD_0 = 26;
+ short ILOAD_1 = 27;
+ short ILOAD_2 = 28;
+ short ILOAD_3 = 29;
+ short LLOAD_0 = 30;
+ short LLOAD_1 = 31;
+ short LLOAD_2 = 32;
+ short LLOAD_3 = 33;
+ short FLOAD_0 = 34;
+ short FLOAD_1 = 35;
+ short FLOAD_2 = 36;
+ short FLOAD_3 = 37;
+ short DLOAD_0 = 38;
+ short DLOAD_1 = 39;
+ short DLOAD_2 = 40;
+ short DLOAD_3 = 41;
+ short ALOAD_0 = 42;
+ short ALOAD_1 = 43;
+ short ALOAD_2 = 44;
+ short ALOAD_3 = 45;
+ short IALOAD = 46;
+ short LALOAD = 47;
+ short FALOAD = 48;
+ short DALOAD = 49;
+ short AALOAD = 50;
+ short BALOAD = 51;
+ short CALOAD = 52;
+ short SALOAD = 53;
+ short ISTORE = 54;
+ short LSTORE = 55;
+ short FSTORE = 56;
+ short DSTORE = 57;
+ short ASTORE = 58;
+ short ISTORE_0 = 59;
+ short ISTORE_1 = 60;
+ short ISTORE_2 = 61;
+ short ISTORE_3 = 62;
+ short LSTORE_0 = 63;
+ short LSTORE_1 = 64;
+ short LSTORE_2 = 65;
+ short LSTORE_3 = 66;
+ short FSTORE_0 = 67;
+ short FSTORE_1 = 68;
+ short FSTORE_2 = 69;
+ short FSTORE_3 = 70;
+ short DSTORE_0 = 71;
+ short DSTORE_1 = 72;
+ short DSTORE_2 = 73;
+ short DSTORE_3 = 74;
+ short ASTORE_0 = 75;
+ short ASTORE_1 = 76;
+ short ASTORE_2 = 77;
+ short ASTORE_3 = 78;
+ short IASTORE = 79;
+ short LASTORE = 80;
+ short FASTORE = 81;
+ short DASTORE = 82;
+ short AASTORE = 83;
+ short BASTORE = 84;
+ short CASTORE = 85;
+ short SASTORE = 86;
+ short POP = 87;
+ short POP2 = 88;
+ short DUP = 89;
+ short DUP_X1 = 90;
+ short DUP_X2 = 91;
+ short DUP2 = 92;
+ short DUP2_X1 = 93;
+ short DUP2_X2 = 94;
+ short SWAP = 95;
+ short IADD = 96;
+ short LADD = 97;
+ short FADD = 98;
+ short DADD = 99;
+ short ISUB = 100;
+ short LSUB = 101;
+ short FSUB = 102;
+ short DSUB = 103;
+ short IMUL = 104;
+ short LMUL = 105;
+ short FMUL = 106;
+ short DMUL = 107;
+ short IDIV = 108;
+ short LDIV = 109;
+ short FDIV = 110;
+ short DDIV = 111;
+ short IREM = 112;
+ short LREM = 113;
+ short FREM = 114;
+ short DREM = 115;
+ short INEG = 116;
+ short LNEG = 117;
+ short FNEG = 118;
+ short DNEG = 119;
+ short ISHL = 120;
+ short LSHL = 121;
+ short ISHR = 122;
+ short LSHR = 123;
+ short IUSHR = 124;
+ short LUSHR = 125;
+ short IAND = 126;
+ short LAND = 127;
+ short IOR = 128;
+ short LOR = 129;
+ short IXOR = 130;
+ short LXOR = 131;
+ short IINC = 132;
+ short I2L = 133;
+ short I2F = 134;
+ short I2D = 135;
+ short L2I = 136;
+ short L2F = 137;
+ short L2D = 138;
+ short F2I = 139;
+ short F2L = 140;
+ short F2D = 141;
+ short D2I = 142;
+ short D2L = 143;
+ short D2F = 144;
+ short I2B = 145;
+ short INT2BYTE = 145; // Old notion
+ short I2C = 146;
+ short INT2CHAR = 146; // Old notion
+ short I2S = 147;
+ short INT2SHORT = 147; // Old notion
+ short LCMP = 148;
+ short FCMPL = 149;
+ short FCMPG = 150;
+ short DCMPL = 151;
+ short DCMPG = 152;
+ short IFEQ = 153;
+ short IFNE = 154;
+ short IFLT = 155;
+ short IFGE = 156;
+ short IFGT = 157;
+ short IFLE = 158;
+ short IF_ICMPEQ = 159;
+ short IF_ICMPNE = 160;
+ short IF_ICMPLT = 161;
+ short IF_ICMPGE = 162;
+ short IF_ICMPGT = 163;
+ short IF_ICMPLE = 164;
+ short IF_ACMPEQ = 165;
+ short IF_ACMPNE = 166;
+ short GOTO = 167;
+ short JSR = 168;
+ short RET = 169;
+ short TABLESWITCH = 170;
+ short LOOKUPSWITCH = 171;
+ short IRETURN = 172;
+ short LRETURN = 173;
+ short FRETURN = 174;
+ short DRETURN = 175;
+ short ARETURN = 176;
+ short RETURN = 177;
+ short GETSTATIC = 178;
+ short PUTSTATIC = 179;
+ short GETFIELD = 180;
+ short PUTFIELD = 181;
+ short INVOKEVIRTUAL = 182;
+ short INVOKESPECIAL = 183;
+ short INVOKENONVIRTUAL = 183; // Old name in JDK 1.0
+ short INVOKESTATIC = 184;
+ short INVOKEINTERFACE = 185;
+ short INVOKEDYNAMIC = 186;
+ short NEW = 187;
+ short NEWARRAY = 188;
+ short ANEWARRAY = 189;
+ short ARRAYLENGTH = 190;
+ short ATHROW = 191;
+ short CHECKCAST = 192;
+ short INSTANCEOF = 193;
+ short MONITORENTER = 194;
+ short MONITOREXIT = 195;
+ short WIDE = 196;
+ short MULTIANEWARRAY = 197;
+ short IFNULL = 198;
+ short IFNONNULL = 199;
+ short GOTO_W = 200;
+ short JSR_W = 201;
/**
* Non-legal opcodes, may be used by JVM internally.
*/
- public static final short BREAKPOINT = 202;
- public static final short LDC_QUICK = 203;
- public static final short LDC_W_QUICK = 204;
- public static final short LDC2_W_QUICK = 205;
- public static final short GETFIELD_QUICK = 206;
- public static final short PUTFIELD_QUICK = 207;
- public static final short GETFIELD2_QUICK = 208;
- public static final short PUTFIELD2_QUICK = 209;
- public static final short GETSTATIC_QUICK = 210;
- public static final short PUTSTATIC_QUICK = 211;
- public static final short GETSTATIC2_QUICK = 212;
- public static final short PUTSTATIC2_QUICK = 213;
- public static final short INVOKEVIRTUAL_QUICK = 214;
- public static final short INVOKENONVIRTUAL_QUICK = 215;
- public static final short INVOKESUPER_QUICK = 216;
- public static final short INVOKESTATIC_QUICK = 217;
- public static final short INVOKEINTERFACE_QUICK = 218;
- public static final short INVOKEVIRTUALOBJECT_QUICK = 219;
- public static final short NEW_QUICK = 221;
- public static final short ANEWARRAY_QUICK = 222;
- public static final short MULTIANEWARRAY_QUICK = 223;
- public static final short CHECKCAST_QUICK = 224;
- public static final short INSTANCEOF_QUICK = 225;
- public static final short INVOKEVIRTUAL_QUICK_W = 226;
- public static final short GETFIELD_QUICK_W = 227;
- public static final short PUTFIELD_QUICK_W = 228;
- public static final short IMPDEP1 = 254;
- public static final short IMPDEP2 = 255;
+ short BREAKPOINT = 202;
+ short LDC_QUICK = 203;
+ short LDC_W_QUICK = 204;
+ short LDC2_W_QUICK = 205;
+ short GETFIELD_QUICK = 206;
+ short PUTFIELD_QUICK = 207;
+ short GETFIELD2_QUICK = 208;
+ short PUTFIELD2_QUICK = 209;
+ short GETSTATIC_QUICK = 210;
+ short PUTSTATIC_QUICK = 211;
+ short GETSTATIC2_QUICK = 212;
+ short PUTSTATIC2_QUICK = 213;
+ short INVOKEVIRTUAL_QUICK = 214;
+ short INVOKENONVIRTUAL_QUICK = 215;
+ short INVOKESUPER_QUICK = 216;
+ short INVOKESTATIC_QUICK = 217;
+ short INVOKEINTERFACE_QUICK = 218;
+ short INVOKEVIRTUALOBJECT_QUICK = 219;
+ short NEW_QUICK = 221;
+ short ANEWARRAY_QUICK = 222;
+ short MULTIANEWARRAY_QUICK = 223;
+ short CHECKCAST_QUICK = 224;
+ short INSTANCEOF_QUICK = 225;
+ short INVOKEVIRTUAL_QUICK_W = 226;
+ short GETFIELD_QUICK_W = 227;
+ short PUTFIELD_QUICK_W = 228;
+ short IMPDEP1 = 254;
+ short IMPDEP2 = 255;
/**
* For internal purposes only.
*/
- public static final short PUSH = 4711;
- public static final short SWITCH = 4712;
+ short PUSH = 4711;
+ short SWITCH = 4712;
/**
* Illegal codes
*/
- public static final short UNDEFINED = '/' - '0'; // -1;
- public static final short UNPREDICTABLE = '.' - '0';// -2;
- public static final short RESERVED = -3;
- public static final String ILLEGAL_OPCODE = "";
- public static final String ILLEGAL_TYPE = "";
-
- public static final byte T_BOOLEAN = 4;
- public static final byte T_CHAR = 5;
- public static final byte T_FLOAT = 6;
- public static final byte T_DOUBLE = 7;
- public static final byte T_BYTE = 8;
- public static final byte T_SHORT = 9;
- public static final byte T_INT = 10;
- public static final byte T_LONG = 11;
-
- public static final byte T_VOID = 12; // Non-standard
- public static final byte T_ARRAY = 13;
- public static final byte T_OBJECT = 14;
- public static final byte T_REFERENCE = 14; // Deprecated
- public static final byte T_UNKNOWN = 15;
- public static final byte T_ADDRESS = 16;
+ short UNDEFINED = '/' - '0'; // -1;
+ short UNPREDICTABLE = '.' - '0';// -2;
+ short RESERVED = -3;
+ String ILLEGAL_OPCODE = "";
+ String ILLEGAL_TYPE = "";
+
+ byte T_BOOLEAN = 4;
+ byte T_CHAR = 5;
+ byte T_FLOAT = 6;
+ byte T_DOUBLE = 7;
+ byte T_BYTE = 8;
+ byte T_SHORT = 9;
+ byte T_INT = 10;
+ byte T_LONG = 11;
+
+ byte T_VOID = 12; // Non-standard
+ byte T_ARRAY = 13;
+ byte T_OBJECT = 14;
+ byte T_REFERENCE = 14; // Deprecated
+ byte T_UNKNOWN = 15;
+ byte T_ADDRESS = 16;
/**
* The primitive type names corresponding to the T_XX constants, e.g., TYPE_NAMES[T_INT] = "int"
*/
- public static final String[] TYPE_NAMES = { ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, "boolean", "char", "float",
+ String[] TYPE_NAMES = { ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, "boolean", "char", "float",
"double", "byte", "short", "int", "long", "void", "array", "object", "unknown" // Non-standard
};
/**
* The primitive class names corresponding to the T_XX constants, e.g., CLASS_TYPE_NAMES[T_INT] = "java.lang.Integer"
*/
- public static final String[] CLASS_TYPE_NAMES = { ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, "java.lang.Boolean",
+ String[] CLASS_TYPE_NAMES = { ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, "java.lang.Boolean",
"java.lang.Character", "java.lang.Float", "java.lang.Double", "java.lang.Byte", "java.lang.Short", "java.lang.Integer",
"java.lang.Long", "java.lang.Void", ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE };
/**
* The signature characters corresponding to primitive types, e.g., SHORT_TYPE_NAMES[T_INT] = "I"
*/
- public static final String[] SHORT_TYPE_NAMES = { ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, "Z", "C", "F", "D",
+ String[] SHORT_TYPE_NAMES = { ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE, "Z", "C", "F", "D",
"B", "S", "I", "J", "V", ILLEGAL_TYPE, ILLEGAL_TYPE, ILLEGAL_TYPE };
- public static int PUSH_INST = 0x0001;
- public static int CONSTANT_INST = 0x0002;
- public static long LOADCLASS_INST = 0x0004;
- public static int CP_INST = 0x0008;
- public static int INDEXED = 0x0010;
- public static int LOAD_INST = 0x0020; // load instruction
- public static int LV_INST = 0x0040; // local variable instruction
- public static int POP_INST = 0x0080;
- public static int STORE_INST = 0x0100;
- public static long STACK_INST = 0x0200;
- public static long BRANCH_INSTRUCTION = 0x0400;
- public static long TARGETER_INSTRUCTION = 0x0800;
- public static long NEGATABLE = 0x1000;
- public static long IF_INST = 0x2000;
- public static long JSR_INSTRUCTION = 0x4000;
- public static long RET_INST = 0x8000;
- public static long EXCEPTION_THROWER = 0x10000;
-
- public static final byte[] iLen = new byte[256];
- public static final byte UNDEFINED_LENGTH = 'X' - '0';
- public static final byte VARIABLE_LENGTH = 'V' - '0';
- public static final byte[] stackEntriesProduced = new byte[256];
- public static final Type[] types = new Type[256];
- public static final long[] instFlags = new long[256];
-
- public static final Class[][] instExcs = new Class[256][];
-
- static final Object _unused = ConstantsInitializer.initialize();
+ int PUSH_INST = 0x0001;
+ int CONSTANT_INST = 0x0002;
+ long LOADCLASS_INST = 0x0004;
+ int CP_INST = 0x0008;
+ int INDEXED = 0x0010;
+ int LOAD_INST = 0x0020; // load instruction
+ int LV_INST = 0x0040; // local variable instruction
+ int POP_INST = 0x0080;
+ int STORE_INST = 0x0100;
+ long STACK_INST = 0x0200;
+ long BRANCH_INSTRUCTION = 0x0400;
+ long TARGETER_INSTRUCTION = 0x0800;
+ long NEGATABLE = 0x1000;
+ long IF_INST = 0x2000;
+ long JSR_INSTRUCTION = 0x4000;
+ long RET_INST = 0x8000;
+ long EXCEPTION_THROWER = 0x10000;
+
+ byte[] iLen = new byte[256];
+ byte UNDEFINED_LENGTH = 'X' - '0';
+ byte VARIABLE_LENGTH = 'V' - '0';
+ byte[] stackEntriesProduced = new byte[256];
+ Type[] types = new Type[256];
+ long[] instFlags = new long[256];
+
+ Class[][] instExcs = new Class[256][];
+
+ Object _unused = ConstantsInitializer.initialize();
/**
* How the byte code operands are to be interpreted.
*/
- public static final short[][] TYPE_OF_OPERANDS = { {}/* nop */, {}/* aconst_null */, {}/* iconst_m1 */, {}/* iconst_0 */,
+ short[][] TYPE_OF_OPERANDS = { {}/* nop */, {}/* aconst_null */, {}/* iconst_m1 */, {}/* iconst_0 */,
{}/* iconst_1 */, {}/* iconst_2 */, {}/* iconst_3 */, {}/* iconst_4 */, {}/* iconst_5 */, {}/* lconst_0 */, {}/* lconst_1 */,
{}/* fconst_0 */, {}/* fconst_1 */, {}/* fconst_2 */, {}/* dconst_0 */, {}/* dconst_1 */, { T_BYTE }/* bipush */,
{ T_SHORT }/* sipush */, { T_BYTE }/* ldc */, { T_SHORT }/* ldc_w */, { T_SHORT }/* ldc2_w */, { T_BYTE }/* iload */,
@@ -565,7 +565,7 @@ public interface Constants {
/**
* Names of opcodes.
*/
- public static final String[] OPCODE_NAMES = { "nop", "aconst_null", "iconst_m1", "iconst_0", "iconst_1", "iconst_2",
+ String[] OPCODE_NAMES = { "nop", "aconst_null", "iconst_m1", "iconst_0", "iconst_1", "iconst_2",
"iconst_3", "iconst_4", "iconst_5", "lconst_0", "lconst_1", "fconst_0", "fconst_1", "fconst_2", "dconst_0", "dconst_1",
"bipush", "sipush", "ldc", "ldc_w", "ldc2_w", "iload", "lload", "fload", "dload", "aload", "iload_0", "iload_1",
"iload_2", "iload_3", "lload_0", "lload_1", "lload_2", "lload_3", "fload_0", "fload_1", "fload_2", "fload_3",
@@ -595,7 +595,7 @@ public interface Constants {
/**
* Number of words consumed on operand stack by instructions.
*/
- public static final int[] CONSUME_STACK = { 0/* nop */, 0/* aconst_null */, 0/* iconst_m1 */, 0/* iconst_0 */, 0/* iconst_1 */,
+ int[] CONSUME_STACK = { 0/* nop */, 0/* aconst_null */, 0/* iconst_m1 */, 0/* iconst_0 */, 0/* iconst_1 */,
0/* iconst_2 */, 0/* iconst_3 */, 0/* iconst_4 */, 0/* iconst_5 */, 0/* lconst_0 */, 0/* lconst_1 */, 0/* fconst_0 */,
0/* fconst_1 */, 0/* fconst_2 */, 0/* dconst_0 */, 0/* dconst_1 */, 0/* bipush */, 0/* sipush */, 0/* ldc */,
0/* ldc_w */, 0/* ldc2_w */, 0/* iload */, 0/* lload */, 0/* fload */, 0/* dload */, 0/* aload */, 0/* iload_0 */, 0/* iload_1 */,
@@ -631,43 +631,43 @@ public interface Constants {
};
// Attributes and their corresponding names.
- public static final byte ATTR_UNKNOWN = -1;
- public static final byte ATTR_SOURCE_FILE = 0;
- public static final byte ATTR_CONSTANT_VALUE = 1;
- public static final byte ATTR_CODE = 2;
- public static final byte ATTR_EXCEPTIONS = 3;
- public static final byte ATTR_LINE_NUMBER_TABLE = 4;
- public static final byte ATTR_LOCAL_VARIABLE_TABLE = 5;
- public static final byte ATTR_INNER_CLASSES = 6;
- public static final byte ATTR_SYNTHETIC = 7;
- public static final byte ATTR_DEPRECATED = 8;
- public static final byte ATTR_PMG = 9;
- public static final byte ATTR_SIGNATURE = 10;
- public static final byte ATTR_STACK_MAP = 11;
- public static final byte ATTR_RUNTIME_VISIBLE_ANNOTATIONS = 12;
- public static final byte ATTR_RUNTIME_INVISIBLE_ANNOTATIONS = 13;
- public static final byte ATTR_RUNTIME_VISIBLE_PARAMETER_ANNOTATIONS = 14;
- public static final byte ATTR_RUNTIME_INVISIBLE_PARAMETER_ANNOTATIONS = 15;
- public static final byte ATTR_LOCAL_VARIABLE_TYPE_TABLE = 16;
- public static final byte ATTR_ENCLOSING_METHOD = 17;
- public static final byte ATTR_ANNOTATION_DEFAULT = 18;
- public static final byte ATTR_BOOTSTRAPMETHODS = 19;
- public static final byte ATTR_RUNTIME_VISIBLE_TYPE_ANNOTATIONS = 20;
- public static final byte ATTR_RUNTIME_INVISIBLE_TYPE_ANNOTATIONS = 21;
- public static final byte ATTR_METHOD_PARAMETERS = 22;
+ byte ATTR_UNKNOWN = -1;
+ byte ATTR_SOURCE_FILE = 0;
+ byte ATTR_CONSTANT_VALUE = 1;
+ byte ATTR_CODE = 2;
+ byte ATTR_EXCEPTIONS = 3;
+ byte ATTR_LINE_NUMBER_TABLE = 4;
+ byte ATTR_LOCAL_VARIABLE_TABLE = 5;
+ byte ATTR_INNER_CLASSES = 6;
+ byte ATTR_SYNTHETIC = 7;
+ byte ATTR_DEPRECATED = 8;
+ byte ATTR_PMG = 9;
+ byte ATTR_SIGNATURE = 10;
+ byte ATTR_STACK_MAP = 11;
+ byte ATTR_RUNTIME_VISIBLE_ANNOTATIONS = 12;
+ byte ATTR_RUNTIME_INVISIBLE_ANNOTATIONS = 13;
+ byte ATTR_RUNTIME_VISIBLE_PARAMETER_ANNOTATIONS = 14;
+ byte ATTR_RUNTIME_INVISIBLE_PARAMETER_ANNOTATIONS = 15;
+ byte ATTR_LOCAL_VARIABLE_TYPE_TABLE = 16;
+ byte ATTR_ENCLOSING_METHOD = 17;
+ byte ATTR_ANNOTATION_DEFAULT = 18;
+ byte ATTR_BOOTSTRAPMETHODS = 19;
+ byte ATTR_RUNTIME_VISIBLE_TYPE_ANNOTATIONS = 20;
+ byte ATTR_RUNTIME_INVISIBLE_TYPE_ANNOTATIONS = 21;
+ byte ATTR_METHOD_PARAMETERS = 22;
// J9:
- public static final byte ATTR_MODULE = 23;
- public static final byte ATTR_MODULE_PACKAGES = 24;
- public static final byte ATTR_MODULE_MAIN_CLASS = 25;
+ byte ATTR_MODULE = 23;
+ byte ATTR_MODULE_PACKAGES = 24;
+ byte ATTR_MODULE_MAIN_CLASS = 25;
// J11:
- public static final byte ATTR_NEST_HOST = 26;
- public static final byte ATTR_NEST_MEMBERS = 27;
+ byte ATTR_NEST_HOST = 26;
+ byte ATTR_NEST_MEMBERS = 27;
- public static final short KNOWN_ATTRIBUTES = 28;
+ short KNOWN_ATTRIBUTES = 28;
- public static final String[] ATTRIBUTE_NAMES = {
+ String[] ATTRIBUTE_NAMES = {
"SourceFile", "ConstantValue", "Code", "Exceptions", "LineNumberTable", "LocalVariableTable",
"InnerClasses", "Synthetic", "Deprecated", "PMGClass", "Signature", "StackMap",
"RuntimeVisibleAnnotations", "RuntimeInvisibleAnnotations", "RuntimeVisibleParameterAnnotations",
@@ -679,16 +679,16 @@ public interface Constants {
/**
* Constants used in the StackMap attribute.
*/
- public static final byte ITEM_Bogus = 0;
- public static final byte ITEM_Integer = 1;
- public static final byte ITEM_Float = 2;
- public static final byte ITEM_Double = 3;
- public static final byte ITEM_Long = 4;
- public static final byte ITEM_Null = 5;
- public static final byte ITEM_InitObject = 6;
- public static final byte ITEM_Object = 7;
- public static final byte ITEM_NewObject = 8;
-
- public static final String[] ITEM_NAMES = { "Bogus", "Integer", "Float", "Double", "Long", "Null", "InitObject", "Object",
+ byte ITEM_Bogus = 0;
+ byte ITEM_Integer = 1;
+ byte ITEM_Float = 2;
+ byte ITEM_Double = 3;
+ byte ITEM_Long = 4;
+ byte ITEM_Null = 5;
+ byte ITEM_InitObject = 6;
+ byte ITEM_Object = 7;
+ byte ITEM_NewObject = 8;
+
+ String[] ITEM_NAMES = { "Bogus", "Integer", "Float", "Double", "Long", "Null", "InitObject", "Object",
"NewObject" };
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/ExceptionConstants.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/ExceptionConstants.java
index a83199ee7..b03b3cd0c 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/ExceptionConstants.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/ExceptionConstants.java
@@ -65,86 +65,86 @@ public interface ExceptionConstants {
/**
* The mother of all exceptions
*/
- public static final Class THROWABLE = Throwable.class;
+ Class THROWABLE = Throwable.class;
/**
* Super class of any run-time exception
*/
- public static final Class RUNTIME_EXCEPTION = RuntimeException.class;
+ Class RUNTIME_EXCEPTION = RuntimeException.class;
/**
* Super class of any linking exception (aka Linkage Error)
*/
- public static final Class LINKING_EXCEPTION = LinkageError.class;
+ Class LINKING_EXCEPTION = LinkageError.class;
/**
* Linking Exceptions
*/
- public static final Class CLASS_CIRCULARITY_ERROR = ClassCircularityError.class;
- public static final Class CLASS_FORMAT_ERROR = ClassFormatError.class;
- public static final Class EXCEPTION_IN_INITIALIZER_ERROR = ExceptionInInitializerError.class;
- public static final Class INCOMPATIBLE_CLASS_CHANGE_ERROR = IncompatibleClassChangeError.class;
- public static final Class ABSTRACT_METHOD_ERROR = AbstractMethodError.class;
- public static final Class ILLEGAL_ACCESS_ERROR = IllegalAccessError.class;
- public static final Class INSTANTIATION_ERROR = InstantiationError.class;
- public static final Class NO_SUCH_FIELD_ERROR = NoSuchFieldError.class;
- public static final Class NO_SUCH_METHOD_ERROR = NoSuchMethodError.class;
- public static final Class NO_CLASS_DEF_FOUND_ERROR = NoClassDefFoundError.class;
- public static final Class UNSATISFIED_LINK_ERROR = UnsatisfiedLinkError.class;
- public static final Class VERIFY_ERROR = VerifyError.class;
+ Class CLASS_CIRCULARITY_ERROR = ClassCircularityError.class;
+ Class CLASS_FORMAT_ERROR = ClassFormatError.class;
+ Class EXCEPTION_IN_INITIALIZER_ERROR = ExceptionInInitializerError.class;
+ Class INCOMPATIBLE_CLASS_CHANGE_ERROR = IncompatibleClassChangeError.class;
+ Class ABSTRACT_METHOD_ERROR = AbstractMethodError.class;
+ Class ILLEGAL_ACCESS_ERROR = IllegalAccessError.class;
+ Class INSTANTIATION_ERROR = InstantiationError.class;
+ Class NO_SUCH_FIELD_ERROR = NoSuchFieldError.class;
+ Class NO_SUCH_METHOD_ERROR = NoSuchMethodError.class;
+ Class NO_CLASS_DEF_FOUND_ERROR = NoClassDefFoundError.class;
+ Class UNSATISFIED_LINK_ERROR = UnsatisfiedLinkError.class;
+ Class VERIFY_ERROR = VerifyError.class;
/* UnsupportedClassVersionError is new in JDK 1.2 */
// public static final Class UnsupportedClassVersionError = UnsupportedClassVersionError.class;
/**
* Run-Time Exceptions
*/
- public static final Class NULL_POINTER_EXCEPTION = NullPointerException.class;
- public static final Class ARRAY_INDEX_OUT_OF_BOUNDS_EXCEPTION = ArrayIndexOutOfBoundsException.class;
- public static final Class ARITHMETIC_EXCEPTION = ArithmeticException.class;
- public static final Class NEGATIVE_ARRAY_SIZE_EXCEPTION = NegativeArraySizeException.class;
- public static final Class CLASS_CAST_EXCEPTION = ClassCastException.class;
- public static final Class ILLEGAL_MONITOR_STATE = IllegalMonitorStateException.class;
+ Class NULL_POINTER_EXCEPTION = NullPointerException.class;
+ Class ARRAY_INDEX_OUT_OF_BOUNDS_EXCEPTION = ArrayIndexOutOfBoundsException.class;
+ Class ARITHMETIC_EXCEPTION = ArithmeticException.class;
+ Class NEGATIVE_ARRAY_SIZE_EXCEPTION = NegativeArraySizeException.class;
+ Class CLASS_CAST_EXCEPTION = ClassCastException.class;
+ Class ILLEGAL_MONITOR_STATE = IllegalMonitorStateException.class;
/**
* Pre-defined exception arrays according to chapters 5.1-5.4 of the Java Virtual Machine Specification
*/
- public static final Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION = { NO_CLASS_DEF_FOUND_ERROR, CLASS_FORMAT_ERROR, VERIFY_ERROR,
+ Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION = { NO_CLASS_DEF_FOUND_ERROR, CLASS_FORMAT_ERROR, VERIFY_ERROR,
ABSTRACT_METHOD_ERROR, EXCEPTION_IN_INITIALIZER_ERROR, ILLEGAL_ACCESS_ERROR }; // Chapter 5.1
- public static final Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_MULTIANEWARRAY = { NO_CLASS_DEF_FOUND_ERROR,
+ Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_MULTIANEWARRAY = { NO_CLASS_DEF_FOUND_ERROR,
CLASS_FORMAT_ERROR, VERIFY_ERROR, ABSTRACT_METHOD_ERROR, EXCEPTION_IN_INITIALIZER_ERROR, ILLEGAL_ACCESS_ERROR,
NEGATIVE_ARRAY_SIZE_EXCEPTION, ILLEGAL_ACCESS_ERROR };
- public static final Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_ANEWARRAY = { NO_CLASS_DEF_FOUND_ERROR, CLASS_FORMAT_ERROR,
+ Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_ANEWARRAY = { NO_CLASS_DEF_FOUND_ERROR, CLASS_FORMAT_ERROR,
VERIFY_ERROR, ABSTRACT_METHOD_ERROR, EXCEPTION_IN_INITIALIZER_ERROR, ILLEGAL_ACCESS_ERROR,
NEGATIVE_ARRAY_SIZE_EXCEPTION }; // Chapter 5.1
- public static final Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_CHECKCAST = { NO_CLASS_DEF_FOUND_ERROR, CLASS_FORMAT_ERROR,
+ Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_CHECKCAST = { NO_CLASS_DEF_FOUND_ERROR, CLASS_FORMAT_ERROR,
VERIFY_ERROR, ABSTRACT_METHOD_ERROR, EXCEPTION_IN_INITIALIZER_ERROR, ILLEGAL_ACCESS_ERROR, CLASS_CAST_EXCEPTION }; // Chapter
// 5.1
- public static final Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_FOR_ALLOCATIONS = { NO_CLASS_DEF_FOUND_ERROR,
+ Class[] EXCS_CLASS_AND_INTERFACE_RESOLUTION_FOR_ALLOCATIONS = { NO_CLASS_DEF_FOUND_ERROR,
CLASS_FORMAT_ERROR, VERIFY_ERROR, ABSTRACT_METHOD_ERROR, EXCEPTION_IN_INITIALIZER_ERROR, ILLEGAL_ACCESS_ERROR,
INSTANTIATION_ERROR, ILLEGAL_ACCESS_ERROR };
- public static final Class[] EXCS_FIELD_AND_METHOD_RESOLUTION = { NO_SUCH_FIELD_ERROR, ILLEGAL_ACCESS_ERROR,
+ Class[] EXCS_FIELD_AND_METHOD_RESOLUTION = { NO_SUCH_FIELD_ERROR, ILLEGAL_ACCESS_ERROR,
NO_SUCH_METHOD_ERROR }; // Chapter 5.2
- public static final Class[] EXCS_FIELD_AND_METHOD_RESOLUTION_GETFIELD_PUTFIELD = { NO_SUCH_FIELD_ERROR, ILLEGAL_ACCESS_ERROR,
+ Class[] EXCS_FIELD_AND_METHOD_RESOLUTION_GETFIELD_PUTFIELD = { NO_SUCH_FIELD_ERROR, ILLEGAL_ACCESS_ERROR,
NO_SUCH_METHOD_ERROR, INCOMPATIBLE_CLASS_CHANGE_ERROR, NULL_POINTER_EXCEPTION };
- public static final Class[] EXCS_FIELD_AND_METHOD_RESOLUTION_GETSTATIC_PUTSTATIC = { NO_SUCH_FIELD_ERROR, ILLEGAL_ACCESS_ERROR,
+ Class[] EXCS_FIELD_AND_METHOD_RESOLUTION_GETSTATIC_PUTSTATIC = { NO_SUCH_FIELD_ERROR, ILLEGAL_ACCESS_ERROR,
NO_SUCH_METHOD_ERROR, INCOMPATIBLE_CLASS_CHANGE_ERROR };
- public static final Class[] EXCS_INTERFACE_METHOD_RESOLUTION_INVOKEINTERFACE = { INCOMPATIBLE_CLASS_CHANGE_ERROR,
+ Class[] EXCS_INTERFACE_METHOD_RESOLUTION_INVOKEINTERFACE = { INCOMPATIBLE_CLASS_CHANGE_ERROR,
ILLEGAL_ACCESS_ERROR, ABSTRACT_METHOD_ERROR, UNSATISFIED_LINK_ERROR };
- public static final Class[] EXCS_INTERFACE_METHOD_RESOLUTION_INVOKESPECIAL_INVOKEVIRTUAL = { INCOMPATIBLE_CLASS_CHANGE_ERROR,
+ Class[] EXCS_INTERFACE_METHOD_RESOLUTION_INVOKESPECIAL_INVOKEVIRTUAL = { INCOMPATIBLE_CLASS_CHANGE_ERROR,
NULL_POINTER_EXCEPTION, ABSTRACT_METHOD_ERROR, UNSATISFIED_LINK_ERROR };
// public static final Class[] EXCS_INVOKEDYNAMIC = { BOOTSTRAP_METHOD_ERROR};
- public static final Class[] EXCS_INTERFACE_METHOD_RESOLUTION_INVOKESTATIC = { INCOMPATIBLE_CLASS_CHANGE_ERROR,
+ Class[] EXCS_INTERFACE_METHOD_RESOLUTION_INVOKESTATIC = { INCOMPATIBLE_CLASS_CHANGE_ERROR,
UNSATISFIED_LINK_ERROR };
- public static final Class[] EXCS_INTERFACE_METHOD_RESOLUTION = new Class[0]; // Chapter 5.3 (as below)
- public static final Class[] EXCS_STRING_RESOLUTION = new Class[0];
+ Class[] EXCS_INTERFACE_METHOD_RESOLUTION = new Class[0]; // Chapter 5.3 (as below)
+ Class[] EXCS_STRING_RESOLUTION = new Class[0];
// Chapter 5.4 (no errors but the ones that _always_ could happen! How stupid.)
- public static final Class[] EXCS_ARRAY_EXCEPTION = { NULL_POINTER_EXCEPTION, ARRAY_INDEX_OUT_OF_BOUNDS_EXCEPTION };
+ Class[] EXCS_ARRAY_EXCEPTION = { NULL_POINTER_EXCEPTION, ARRAY_INDEX_OUT_OF_BOUNDS_EXCEPTION };
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ClassVisitor.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ClassVisitor.java
index 5c60f818f..695c78c4e 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ClassVisitor.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ClassVisitor.java
@@ -64,117 +64,117 @@ import org.aspectj.apache.bcel.classfile.annotation.RuntimeVisTypeAnnos;
/**
* Interface to make use of the Visitor pattern programming style. I.e. a class that implements this interface can traverse the
* contents of a Java class just by calling the `accept' method which all classes have.
- *
+ *
* Implemented by wish of Boris Bokowski.
- *
+ *
* @version $Id: ClassVisitor.java,v 1.4 2009/09/15 19:40:13 aclement Exp $
* @author M. Dahm
*/
public interface ClassVisitor {
- public void visitCode(Code obj);
+ void visitCode(Code obj);
+
+ void visitCodeException(CodeException obj);
+
+ void visitConstantClass(ConstantClass obj);
+
+ void visitConstantDouble(ConstantDouble obj);
+
+ void visitConstantFieldref(ConstantFieldref obj);
+
+ void visitConstantFloat(ConstantFloat obj);
+
+ void visitConstantInteger(ConstantInteger obj);
- public void visitCodeException(CodeException obj);
+ void visitConstantInterfaceMethodref(ConstantInterfaceMethodref obj);
- public void visitConstantClass(ConstantClass obj);
+ void visitConstantLong(ConstantLong obj);
- public void visitConstantDouble(ConstantDouble obj);
+ void visitConstantMethodref(ConstantMethodref obj);
- public void visitConstantFieldref(ConstantFieldref obj);
+ void visitConstantMethodHandle(ConstantMethodHandle obj);
- public void visitConstantFloat(ConstantFloat obj);
+ void visitConstantNameAndType(ConstantNameAndType obj);
- public void visitConstantInteger(ConstantInteger obj);
+ void visitConstantMethodType(ConstantMethodType obj);
- public void visitConstantInterfaceMethodref(ConstantInterfaceMethodref obj);
+ void visitConstantInvokeDynamic(ConstantInvokeDynamic obj);
- public void visitConstantLong(ConstantLong obj);
+ void visitConstantDynamic(ConstantDynamic obj);
- public void visitConstantMethodref(ConstantMethodref obj);
-
- public void visitConstantMethodHandle(ConstantMethodHandle obj);
+ void visitConstantPool(ConstantPool obj);
- public void visitConstantNameAndType(ConstantNameAndType obj);
-
- public void visitConstantMethodType(ConstantMethodType obj);
-
- public void visitConstantInvokeDynamic(ConstantInvokeDynamic obj);
-
- public void visitConstantDynamic(ConstantDynamic obj);
+ void visitConstantString(ConstantString obj);
- public void visitConstantPool(ConstantPool obj);
+ void visitConstantModule(ConstantModule obj);
- public void visitConstantString(ConstantString obj);
+ void visitConstantPackage(ConstantPackage obj);
- public void visitConstantModule(ConstantModule obj);
+ void visitConstantUtf8(ConstantUtf8 obj);
- public void visitConstantPackage(ConstantPackage obj);
+ void visitConstantValue(ConstantValue obj);
- public void visitConstantUtf8(ConstantUtf8 obj);
+ void visitDeprecated(Deprecated obj);
- public void visitConstantValue(ConstantValue obj);
+ void visitExceptionTable(ExceptionTable obj);
- public void visitDeprecated(Deprecated obj);
+ void visitField(Field obj);
- public void visitExceptionTable(ExceptionTable obj);
+ void visitInnerClass(InnerClass obj);
- public void visitField(Field obj);
+ void visitInnerClasses(InnerClasses obj);
- public void visitInnerClass(InnerClass obj);
+ void visitJavaClass(JavaClass obj);
- public void visitInnerClasses(InnerClasses obj);
+ void visitLineNumber(LineNumber obj);
- public void visitJavaClass(JavaClass obj);
+ void visitLineNumberTable(LineNumberTable obj);
- public void visitLineNumber(LineNumber obj);
+ void visitLocalVariable(LocalVariable obj);
- public void visitLineNumberTable(LineNumberTable obj);
+ void visitLocalVariableTable(LocalVariableTable obj);
- public void visitLocalVariable(LocalVariable obj);
+ void visitMethod(Method obj);
- public void visitLocalVariableTable(LocalVariableTable obj);
+ void visitSignature(Signature obj);
- public void visitMethod(Method obj);
+ void visitSourceFile(SourceFile obj);
- public void visitSignature(Signature obj);
+ void visitSynthetic(Synthetic obj);
- public void visitSourceFile(SourceFile obj);
+ void visitBootstrapMethods(BootstrapMethods obj);
- public void visitSynthetic(Synthetic obj);
-
- public void visitBootstrapMethods(BootstrapMethods obj);
+ void visitUnknown(Unknown obj);
- public void visitUnknown(Unknown obj);
+ void visitStackMap(StackMap obj);
- public void visitStackMap(StackMap obj);
+ void visitStackMapEntry(StackMapEntry obj);
- public void visitStackMapEntry(StackMapEntry obj);
+ void visitEnclosingMethod(EnclosingMethod obj);
- public void visitEnclosingMethod(EnclosingMethod obj);
+ void visitRuntimeVisibleAnnotations(RuntimeVisAnnos obj);
- public void visitRuntimeVisibleAnnotations(RuntimeVisAnnos obj);
+ void visitRuntimeInvisibleAnnotations(RuntimeInvisAnnos obj);
- public void visitRuntimeInvisibleAnnotations(RuntimeInvisAnnos obj);
+ void visitRuntimeVisibleParameterAnnotations(RuntimeVisParamAnnos obj);
- public void visitRuntimeVisibleParameterAnnotations(RuntimeVisParamAnnos obj);
+ void visitRuntimeInvisibleParameterAnnotations(RuntimeInvisParamAnnos obj);
- public void visitRuntimeInvisibleParameterAnnotations(RuntimeInvisParamAnnos obj);
+ void visitRuntimeVisibleTypeAnnotations(RuntimeVisTypeAnnos obj);
- public void visitRuntimeVisibleTypeAnnotations(RuntimeVisTypeAnnos obj);
+ void visitRuntimeInvisibleTypeAnnotations(RuntimeInvisTypeAnnos obj);
- public void visitRuntimeInvisibleTypeAnnotations(RuntimeInvisTypeAnnos obj);
+ void visitAnnotationDefault(AnnotationDefault obj);
- public void visitAnnotationDefault(AnnotationDefault obj);
+ void visitLocalVariableTypeTable(LocalVariableTypeTable obj);
- public void visitLocalVariableTypeTable(LocalVariableTypeTable obj);
+ void visitMethodParameters(MethodParameters methodParameters);
- public void visitMethodParameters(MethodParameters methodParameters);
-
// J9:
- public void visitModule(Module module);
- public void visitModulePackages(ModulePackages modulePackage);
- public void visitModuleMainClass(ModuleMainClass moduleMainClass);
+ void visitModule(Module module);
+ void visitModulePackages(ModulePackages modulePackage);
+ void visitModuleMainClass(ModuleMainClass moduleMainClass);
// J11:
- public void visitNestHost(NestHost nestHost);
- public void visitNestMembers(NestMembers nestMembers);
+ void visitNestHost(NestHost nestHost);
+ void visitNestMembers(NestMembers nestMembers);
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ConstantObject.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ConstantObject.java
index 70e9b1d0d..d9e342a66 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ConstantObject.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/ConstantObject.java
@@ -56,11 +56,11 @@ package org.aspectj.apache.bcel.classfile;
/**
* This interface denotes those constants that have a "natural" value, such as ConstantLong, ConstantString, etc..
- *
+ *
* @version $Id: ConstantObject.java,v 1.4 2009/09/10 03:59:33 aclement Exp $
* @author M. Dahm
* @see Constant
*/
public interface ConstantObject {
- public abstract Object getConstantValue(ConstantPool cp);
+ Object getConstantValue(ConstantPool cp);
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/Node.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/Node.java
index 5bef82979..6bc1da6ef 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/Node.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/Node.java
@@ -61,5 +61,5 @@ package org.aspectj.apache.bcel.classfile;
* @author M. Dahm
*/
public interface Node {
- public void accept(ClassVisitor obj);
+ void accept(ClassVisitor obj);
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/SimpleConstant.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/SimpleConstant.java
index 84ff40cf9..d775d1f0a 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/SimpleConstant.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/classfile/SimpleConstant.java
@@ -54,5 +54,5 @@
package org.aspectj.apache.bcel.classfile;
public interface SimpleConstant {
- public String getStringValue();
+ String getStringValue();
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstVisitor.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstVisitor.java
index 424ff4a66..b4eaa488d 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstVisitor.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstVisitor.java
@@ -64,184 +64,184 @@ package org.aspectj.apache.bcel.generic;
* @author M. Dahm
*/
public interface InstVisitor {
- public void visitStackInstruction(Instruction obj);
- public void visitLocalVariableInstruction(InstructionLV obj);
- public void visitBranchInstruction(InstructionBranch obj);
- public void visitLoadClass(Instruction obj);
- public void visitFieldInstruction(Instruction obj);
- public void visitIfInstruction(Instruction obj);
- public void visitConversionInstruction(Instruction obj);
- public void visitPopInstruction(Instruction obj);
- public void visitStoreInstruction(Instruction obj);
- public void visitTypedInstruction(Instruction obj);
- public void visitSelect(InstructionSelect obj);
- public void visitJsrInstruction(InstructionBranch obj);
- public void visitGotoInstruction(Instruction obj);
- public void visitUnconditionalBranch(Instruction obj);
- public void visitPushInstruction(Instruction obj);
- public void visitArithmeticInstruction(Instruction obj);
- public void visitCPInstruction(Instruction obj);
- public void visitInvokeInstruction(InvokeInstruction obj);
- public void visitArrayInstruction(Instruction obj);
- public void visitAllocationInstruction(Instruction obj);
- public void visitReturnInstruction(Instruction obj);
- public void visitFieldOrMethod(Instruction obj);
- public void visitConstantPushInstruction(Instruction obj);
- public void visitExceptionThrower(Instruction obj);
- public void visitLoadInstruction(Instruction obj);
- public void visitVariableLengthInstruction(Instruction obj);
- public void visitStackProducer(Instruction obj);
- public void visitStackConsumer(Instruction obj);
- public void visitACONST_NULL(Instruction obj);
- public void visitGETSTATIC(FieldInstruction obj);
- public void visitIF_ICMPLT(Instruction obj);
- public void visitMONITOREXIT(Instruction obj);
- public void visitIFLT(Instruction obj);
- public void visitLSTORE(Instruction obj);
- public void visitPOP2(Instruction obj);
- public void visitBASTORE(Instruction obj);
- public void visitISTORE(Instruction obj);
- public void visitCHECKCAST(Instruction obj);
- public void visitFCMPG(Instruction obj);
- public void visitI2F(Instruction obj);
- public void visitATHROW(Instruction obj);
- public void visitDCMPL(Instruction obj);
- public void visitARRAYLENGTH(Instruction obj);
- public void visitDUP(Instruction obj);
- public void visitINVOKESTATIC(InvokeInstruction obj);
- public void visitLCONST(Instruction obj);
- public void visitDREM(Instruction obj);
- public void visitIFGE(Instruction obj);
- public void visitCALOAD(Instruction obj);
- public void visitLASTORE(Instruction obj);
- public void visitI2D(Instruction obj);
- public void visitDADD(Instruction obj);
- public void visitINVOKESPECIAL(InvokeInstruction obj);
- public void visitIAND(Instruction obj);
- public void visitPUTFIELD(FieldInstruction obj);
- public void visitILOAD(Instruction obj);
- public void visitDLOAD(Instruction obj);
- public void visitDCONST(Instruction obj);
- public void visitNEW(Instruction obj);
- public void visitIFNULL(Instruction obj);
- public void visitLSUB(Instruction obj);
- public void visitL2I(Instruction obj);
- public void visitISHR(Instruction obj);
- public void visitTABLESWITCH(TABLESWITCH obj);
- public void visitIINC(IINC obj);
- public void visitDRETURN(Instruction obj);
- public void visitFSTORE(Instruction obj);
- public void visitDASTORE(Instruction obj);
- public void visitIALOAD(Instruction obj);
- public void visitDDIV(Instruction obj);
- public void visitIF_ICMPGE(Instruction obj);
- public void visitLAND(Instruction obj);
- public void visitIDIV(Instruction obj);
- public void visitLOR(Instruction obj);
- public void visitCASTORE(Instruction obj);
- public void visitFREM(Instruction obj);
- public void visitLDC(Instruction obj);
- public void visitBIPUSH(Instruction obj);
- public void visitDSTORE(Instruction obj);
- public void visitF2L(Instruction obj);
- public void visitFMUL(Instruction obj);
- public void visitLLOAD(Instruction obj);
- public void visitJSR(InstructionBranch obj);
- public void visitFSUB(Instruction obj);
- public void visitSASTORE(Instruction obj);
- public void visitALOAD(Instruction obj);
- public void visitDUP2_X2(Instruction obj);
- public void visitRETURN(Instruction obj);
- public void visitDALOAD(Instruction obj);
- public void visitSIPUSH(Instruction obj);
- public void visitDSUB(Instruction obj);
- public void visitL2F(Instruction obj);
- public void visitIF_ICMPGT(Instruction obj);
- public void visitF2D(Instruction obj);
- public void visitI2L(Instruction obj);
- public void visitIF_ACMPNE(Instruction obj);
- public void visitPOP(Instruction obj);
- public void visitI2S(Instruction obj);
- public void visitIFEQ(Instruction obj);
- public void visitSWAP(Instruction obj);
- public void visitIOR(Instruction obj);
- public void visitIREM(Instruction obj);
- public void visitIASTORE(Instruction obj);
- public void visitNEWARRAY(Instruction obj);
- public void visitINVOKEINTERFACE(INVOKEINTERFACE obj);
- public void visitINEG(Instruction obj);
- public void visitLCMP(Instruction obj);
- public void visitJSR_W(InstructionBranch obj);
- public void visitMULTIANEWARRAY(MULTIANEWARRAY obj);
- public void visitDUP_X2(Instruction obj);
- public void visitSALOAD(Instruction obj);
- public void visitIFNONNULL(Instruction obj);
- public void visitDMUL(Instruction obj);
- public void visitIFNE(Instruction obj);
- public void visitIF_ICMPLE(Instruction obj);
- public void visitLDC2_W(Instruction obj);
- public void visitGETFIELD(FieldInstruction obj);
- public void visitLADD(Instruction obj);
- public void visitNOP(Instruction obj);
- public void visitFALOAD(Instruction obj);
- public void visitINSTANCEOF(Instruction obj);
- public void visitIFLE(Instruction obj);
- public void visitLXOR(Instruction obj);
- public void visitLRETURN(Instruction obj);
- public void visitFCONST(Instruction obj);
- public void visitIUSHR(Instruction obj);
- public void visitBALOAD(Instruction obj);
- public void visitDUP2(Instruction obj);
- public void visitIF_ACMPEQ(Instruction obj);
- public void visitIMPDEP1(Instruction obj);
- public void visitMONITORENTER(Instruction obj);
- public void visitLSHL(Instruction obj);
- public void visitDCMPG(Instruction obj);
- public void visitD2L(Instruction obj);
- public void visitIMPDEP2(Instruction obj);
- public void visitL2D(Instruction obj);
- public void visitRET(RET obj);
- public void visitIFGT(Instruction obj);
- public void visitIXOR(Instruction obj);
- public void visitINVOKEVIRTUAL(InvokeInstruction obj);
- public void visitFASTORE(Instruction obj);
- public void visitIRETURN(Instruction obj);
- public void visitIF_ICMPNE(Instruction obj);
- public void visitFLOAD(Instruction obj);
- public void visitLDIV(Instruction obj);
- public void visitPUTSTATIC(FieldInstruction obj);
- public void visitAALOAD(Instruction obj);
- public void visitD2I(Instruction obj);
- public void visitIF_ICMPEQ(Instruction obj);
- public void visitAASTORE(Instruction obj);
- public void visitARETURN(Instruction obj);
- public void visitDUP2_X1(Instruction obj);
- public void visitFNEG(Instruction obj);
- public void visitGOTO_W(Instruction obj);
- public void visitD2F(Instruction obj);
- public void visitGOTO(Instruction obj);
- public void visitISUB(Instruction obj);
- public void visitF2I(Instruction obj);
- public void visitDNEG(Instruction obj);
- public void visitICONST(Instruction obj);
- public void visitFDIV(Instruction obj);
- public void visitI2B(Instruction obj);
- public void visitLNEG(Instruction obj);
- public void visitLREM(Instruction obj);
- public void visitIMUL(Instruction obj);
- public void visitIADD(Instruction obj);
- public void visitLSHR(Instruction obj);
- public void visitLOOKUPSWITCH(LOOKUPSWITCH obj);
- public void visitDUP_X1(Instruction obj);
- public void visitFCMPL(Instruction obj);
- public void visitI2C(Instruction obj);
- public void visitLMUL(Instruction obj);
- public void visitLUSHR(Instruction obj);
- public void visitISHL(Instruction obj);
- public void visitLALOAD(Instruction obj);
- public void visitASTORE(Instruction obj);
- public void visitANEWARRAY(Instruction obj);
- public void visitFRETURN(Instruction obj);
- public void visitFADD(Instruction obj);
- public void visitBREAKPOINT(Instruction obj);
+ void visitStackInstruction(Instruction obj);
+ void visitLocalVariableInstruction(InstructionLV obj);
+ void visitBranchInstruction(InstructionBranch obj);
+ void visitLoadClass(Instruction obj);
+ void visitFieldInstruction(Instruction obj);
+ void visitIfInstruction(Instruction obj);
+ void visitConversionInstruction(Instruction obj);
+ void visitPopInstruction(Instruction obj);
+ void visitStoreInstruction(Instruction obj);
+ void visitTypedInstruction(Instruction obj);
+ void visitSelect(InstructionSelect obj);
+ void visitJsrInstruction(InstructionBranch obj);
+ void visitGotoInstruction(Instruction obj);
+ void visitUnconditionalBranch(Instruction obj);
+ void visitPushInstruction(Instruction obj);
+ void visitArithmeticInstruction(Instruction obj);
+ void visitCPInstruction(Instruction obj);
+ void visitInvokeInstruction(InvokeInstruction obj);
+ void visitArrayInstruction(Instruction obj);
+ void visitAllocationInstruction(Instruction obj);
+ void visitReturnInstruction(Instruction obj);
+ void visitFieldOrMethod(Instruction obj);
+ void visitConstantPushInstruction(Instruction obj);
+ void visitExceptionThrower(Instruction obj);
+ void visitLoadInstruction(Instruction obj);
+ void visitVariableLengthInstruction(Instruction obj);
+ void visitStackProducer(Instruction obj);
+ void visitStackConsumer(Instruction obj);
+ void visitACONST_NULL(Instruction obj);
+ void visitGETSTATIC(FieldInstruction obj);
+ void visitIF_ICMPLT(Instruction obj);
+ void visitMONITOREXIT(Instruction obj);
+ void visitIFLT(Instruction obj);
+ void visitLSTORE(Instruction obj);
+ void visitPOP2(Instruction obj);
+ void visitBASTORE(Instruction obj);
+ void visitISTORE(Instruction obj);
+ void visitCHECKCAST(Instruction obj);
+ void visitFCMPG(Instruction obj);
+ void visitI2F(Instruction obj);
+ void visitATHROW(Instruction obj);
+ void visitDCMPL(Instruction obj);
+ void visitARRAYLENGTH(Instruction obj);
+ void visitDUP(Instruction obj);
+ void visitINVOKESTATIC(InvokeInstruction obj);
+ void visitLCONST(Instruction obj);
+ void visitDREM(Instruction obj);
+ void visitIFGE(Instruction obj);
+ void visitCALOAD(Instruction obj);
+ void visitLASTORE(Instruction obj);
+ void visitI2D(Instruction obj);
+ void visitDADD(Instruction obj);
+ void visitINVOKESPECIAL(InvokeInstruction obj);
+ void visitIAND(Instruction obj);
+ void visitPUTFIELD(FieldInstruction obj);
+ void visitILOAD(Instruction obj);
+ void visitDLOAD(Instruction obj);
+ void visitDCONST(Instruction obj);
+ void visitNEW(Instruction obj);
+ void visitIFNULL(Instruction obj);
+ void visitLSUB(Instruction obj);
+ void visitL2I(Instruction obj);
+ void visitISHR(Instruction obj);
+ void visitTABLESWITCH(TABLESWITCH obj);
+ void visitIINC(IINC obj);
+ void visitDRETURN(Instruction obj);
+ void visitFSTORE(Instruction obj);
+ void visitDASTORE(Instruction obj);
+ void visitIALOAD(Instruction obj);
+ void visitDDIV(Instruction obj);
+ void visitIF_ICMPGE(Instruction obj);
+ void visitLAND(Instruction obj);
+ void visitIDIV(Instruction obj);
+ void visitLOR(Instruction obj);
+ void visitCASTORE(Instruction obj);
+ void visitFREM(Instruction obj);
+ void visitLDC(Instruction obj);
+ void visitBIPUSH(Instruction obj);
+ void visitDSTORE(Instruction obj);
+ void visitF2L(Instruction obj);
+ void visitFMUL(Instruction obj);
+ void visitLLOAD(Instruction obj);
+ void visitJSR(InstructionBranch obj);
+ void visitFSUB(Instruction obj);
+ void visitSASTORE(Instruction obj);
+ void visitALOAD(Instruction obj);
+ void visitDUP2_X2(Instruction obj);
+ void visitRETURN(Instruction obj);
+ void visitDALOAD(Instruction obj);
+ void visitSIPUSH(Instruction obj);
+ void visitDSUB(Instruction obj);
+ void visitL2F(Instruction obj);
+ void visitIF_ICMPGT(Instruction obj);
+ void visitF2D(Instruction obj);
+ void visitI2L(Instruction obj);
+ void visitIF_ACMPNE(Instruction obj);
+ void visitPOP(Instruction obj);
+ void visitI2S(Instruction obj);
+ void visitIFEQ(Instruction obj);
+ void visitSWAP(Instruction obj);
+ void visitIOR(Instruction obj);
+ void visitIREM(Instruction obj);
+ void visitIASTORE(Instruction obj);
+ void visitNEWARRAY(Instruction obj);
+ void visitINVOKEINTERFACE(INVOKEINTERFACE obj);
+ void visitINEG(Instruction obj);
+ void visitLCMP(Instruction obj);
+ void visitJSR_W(InstructionBranch obj);
+ void visitMULTIANEWARRAY(MULTIANEWARRAY obj);
+ void visitDUP_X2(Instruction obj);
+ void visitSALOAD(Instruction obj);
+ void visitIFNONNULL(Instruction obj);
+ void visitDMUL(Instruction obj);
+ void visitIFNE(Instruction obj);
+ void visitIF_ICMPLE(Instruction obj);
+ void visitLDC2_W(Instruction obj);
+ void visitGETFIELD(FieldInstruction obj);
+ void visitLADD(Instruction obj);
+ void visitNOP(Instruction obj);
+ void visitFALOAD(Instruction obj);
+ void visitINSTANCEOF(Instruction obj);
+ void visitIFLE(Instruction obj);
+ void visitLXOR(Instruction obj);
+ void visitLRETURN(Instruction obj);
+ void visitFCONST(Instruction obj);
+ void visitIUSHR(Instruction obj);
+ void visitBALOAD(Instruction obj);
+ void visitDUP2(Instruction obj);
+ void visitIF_ACMPEQ(Instruction obj);
+ void visitIMPDEP1(Instruction obj);
+ void visitMONITORENTER(Instruction obj);
+ void visitLSHL(Instruction obj);
+ void visitDCMPG(Instruction obj);
+ void visitD2L(Instruction obj);
+ void visitIMPDEP2(Instruction obj);
+ void visitL2D(Instruction obj);
+ void visitRET(RET obj);
+ void visitIFGT(Instruction obj);
+ void visitIXOR(Instruction obj);
+ void visitINVOKEVIRTUAL(InvokeInstruction obj);
+ void visitFASTORE(Instruction obj);
+ void visitIRETURN(Instruction obj);
+ void visitIF_ICMPNE(Instruction obj);
+ void visitFLOAD(Instruction obj);
+ void visitLDIV(Instruction obj);
+ void visitPUTSTATIC(FieldInstruction obj);
+ void visitAALOAD(Instruction obj);
+ void visitD2I(Instruction obj);
+ void visitIF_ICMPEQ(Instruction obj);
+ void visitAASTORE(Instruction obj);
+ void visitARETURN(Instruction obj);
+ void visitDUP2_X1(Instruction obj);
+ void visitFNEG(Instruction obj);
+ void visitGOTO_W(Instruction obj);
+ void visitD2F(Instruction obj);
+ void visitGOTO(Instruction obj);
+ void visitISUB(Instruction obj);
+ void visitF2I(Instruction obj);
+ void visitDNEG(Instruction obj);
+ void visitICONST(Instruction obj);
+ void visitFDIV(Instruction obj);
+ void visitI2B(Instruction obj);
+ void visitLNEG(Instruction obj);
+ void visitLREM(Instruction obj);
+ void visitIMUL(Instruction obj);
+ void visitIADD(Instruction obj);
+ void visitLSHR(Instruction obj);
+ void visitLOOKUPSWITCH(LOOKUPSWITCH obj);
+ void visitDUP_X1(Instruction obj);
+ void visitFCMPL(Instruction obj);
+ void visitI2C(Instruction obj);
+ void visitLMUL(Instruction obj);
+ void visitLUSHR(Instruction obj);
+ void visitISHL(Instruction obj);
+ void visitLALOAD(Instruction obj);
+ void visitASTORE(Instruction obj);
+ void visitANEWARRAY(Instruction obj);
+ void visitFRETURN(Instruction obj);
+ void visitFADD(Instruction obj);
+ void visitBREAKPOINT(Instruction obj);
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionConstants.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionConstants.java
index e6f884793..8b5a0da5c 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionConstants.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionConstants.java
@@ -56,7 +56,7 @@ package org.aspectj.apache.bcel.generic;
import org.aspectj.apache.bcel.Constants;
-/**
+/**
* This interface contains shareable instruction objects.
*
* In order to save memory you can use some instructions multiply,
@@ -76,172 +76,172 @@ import org.aspectj.apache.bcel.Constants;
public interface InstructionConstants {
/** Predefined instruction objects
*/
- public static final Instruction NOP = new Instruction(Constants.NOP);
- public static final Instruction ACONST_NULL = new Instruction(Constants.ACONST_NULL);
- public static final Instruction ICONST_M1 = new Instruction(Constants.ICONST_M1);
- public static final Instruction ICONST_0 = new Instruction(Constants.ICONST_0);
- public static final Instruction ICONST_1 = new Instruction(Constants.ICONST_1);
- public static final Instruction ICONST_2 = new Instruction(Constants.ICONST_2);
- public static final Instruction ICONST_3 = new Instruction(Constants.ICONST_3);
- public static final Instruction ICONST_4 = new Instruction(Constants.ICONST_4);
- public static final Instruction ICONST_5 = new Instruction(Constants.ICONST_5);
- public static final Instruction LCONST_0 = new Instruction(Constants.LCONST_0);
- public static final Instruction LCONST_1 = new Instruction(Constants.LCONST_1);
- public static final Instruction FCONST_0 = new Instruction(Constants.FCONST_0);
- public static final Instruction FCONST_1 = new Instruction(Constants.FCONST_1);
- public static final Instruction FCONST_2 = new Instruction(Constants.FCONST_2);
- public static final Instruction DCONST_0 = new Instruction(Constants.DCONST_0);
- public static final Instruction DCONST_1 = new Instruction(Constants.DCONST_1);
- public static final Instruction IALOAD = new Instruction(Constants.IALOAD);
- public static final Instruction LALOAD = new Instruction(Constants.LALOAD);
- public static final Instruction FALOAD = new Instruction(Constants.FALOAD);
- public static final Instruction DALOAD = new Instruction(Constants.DALOAD);
- public static final Instruction AALOAD = new Instruction(Constants.AALOAD);
- public static final Instruction BALOAD = new Instruction(Constants.BALOAD);
- public static final Instruction CALOAD = new Instruction(Constants.CALOAD);
- public static final Instruction SALOAD = new Instruction(Constants.SALOAD);
- public static final Instruction IASTORE = new Instruction(Constants.IASTORE);
- public static final Instruction LASTORE = new Instruction(Constants.LASTORE);
- public static final Instruction FASTORE = new Instruction(Constants.FASTORE);
- public static final Instruction DASTORE = new Instruction(Constants.DASTORE);
- public static final Instruction AASTORE = new Instruction(Constants.AASTORE);
- public static final Instruction BASTORE = new Instruction(Constants.BASTORE);
- public static final Instruction CASTORE = new Instruction(Constants.CASTORE);
- public static final Instruction SASTORE = new Instruction(Constants.SASTORE);
- public static final Instruction POP = new Instruction(Constants.POP);
- public static final Instruction POP2 = new Instruction(Constants.POP2);
- public static final Instruction DUP = new Instruction(Constants.DUP);
- public static final Instruction DUP_X1 = new Instruction(Constants.DUP_X1);
- public static final Instruction DUP_X2 = new Instruction(Constants.DUP_X2);
- public static final Instruction DUP2 = new Instruction(Constants.DUP2);
- public static final Instruction DUP2_X1 = new Instruction(Constants.DUP2_X1);
- public static final Instruction DUP2_X2 = new Instruction(Constants.DUP2_X2);
- public static final Instruction SWAP = new Instruction(Constants.SWAP);
- public static final Instruction IADD = new Instruction(Constants.IADD);
- public static final Instruction LADD = new Instruction(Constants.LADD);
- public static final Instruction FADD = new Instruction(Constants.FADD);
- public static final Instruction DADD = new Instruction(Constants.DADD);
- public static final Instruction ISUB = new Instruction(Constants.ISUB);
- public static final Instruction LSUB = new Instruction(Constants.LSUB);
- public static final Instruction FSUB = new Instruction(Constants.FSUB);
- public static final Instruction DSUB = new Instruction(Constants.DSUB);
- public static final Instruction IMUL = new Instruction(Constants.IMUL);
- public static final Instruction LMUL = new Instruction(Constants.LMUL);
- public static final Instruction FMUL = new Instruction(Constants.FMUL);
- public static final Instruction DMUL = new Instruction(Constants.DMUL);
- public static final Instruction IDIV = new Instruction(Constants.IDIV);
- public static final Instruction LDIV = new Instruction(Constants.LDIV);
- public static final Instruction FDIV = new Instruction(Constants.FDIV);
- public static final Instruction DDIV = new Instruction(Constants.DDIV);
- public static final Instruction IREM = new Instruction(Constants.IREM);
- public static final Instruction LREM = new Instruction(Constants.LREM);
- public static final Instruction FREM = new Instruction(Constants.FREM);
- public static final Instruction DREM = new Instruction(Constants.DREM);
- public static final Instruction INEG = new Instruction(Constants.INEG);
- public static final Instruction LNEG = new Instruction(Constants.LNEG);
- public static final Instruction FNEG = new Instruction(Constants.FNEG);
- public static final Instruction DNEG = new Instruction(Constants.DNEG);
- public static final Instruction ISHL = new Instruction(Constants.ISHL);
- public static final Instruction LSHL = new Instruction(Constants.LSHL);
- public static final Instruction ISHR = new Instruction(Constants.ISHR);
- public static final Instruction LSHR = new Instruction(Constants.LSHR);
- public static final Instruction IUSHR = new Instruction(Constants.IUSHR);
- public static final Instruction LUSHR = new Instruction(Constants.LUSHR);
- public static final Instruction IAND = new Instruction(Constants.IAND);
- public static final Instruction LAND = new Instruction(Constants.LAND);
- public static final Instruction IOR = new Instruction(Constants.IOR);
- public static final Instruction LOR = new Instruction(Constants.LOR);
- public static final Instruction IXOR = new Instruction(Constants.IXOR);
- public static final Instruction LXOR = new Instruction(Constants.LXOR);
- public static final Instruction I2L = new Instruction(Constants.I2L);
- public static final Instruction I2F = new Instruction(Constants.I2F);
- public static final Instruction I2D = new Instruction(Constants.I2D);
- public static final Instruction L2I = new Instruction(Constants.L2I);
- public static final Instruction L2F = new Instruction(Constants.L2F);
- public static final Instruction L2D = new Instruction(Constants.L2D);
- public static final Instruction F2I = new Instruction(Constants.F2I);
- public static final Instruction F2L = new Instruction(Constants.F2L);
- public static final Instruction F2D = new Instruction(Constants.F2D);
- public static final Instruction D2I = new Instruction(Constants.D2I);
- public static final Instruction D2L = new Instruction(Constants.D2L);
- public static final Instruction D2F = new Instruction(Constants.D2F);
- public static final Instruction I2B = new Instruction(Constants.I2B);
- public static final Instruction I2C = new Instruction(Constants.I2C);
- public static final Instruction I2S = new Instruction(Constants.I2S);
- public static final Instruction LCMP = new Instruction(Constants.LCMP);
- public static final Instruction FCMPL = new Instruction(Constants.FCMPL);
- public static final Instruction FCMPG = new Instruction(Constants.FCMPG);
- public static final Instruction DCMPL = new Instruction(Constants.DCMPL);
- public static final Instruction DCMPG = new Instruction(Constants.DCMPG);
- public static final Instruction IRETURN = new Instruction(Constants.IRETURN);
- public static final Instruction LRETURN = new Instruction(Constants.LRETURN);
- public static final Instruction FRETURN = new Instruction(Constants.FRETURN);
- public static final Instruction DRETURN = new Instruction(Constants.DRETURN);
- public static final Instruction ARETURN = new Instruction(Constants.ARETURN);
- public static final Instruction RETURN = new Instruction(Constants.RETURN);
- public static final Instruction ARRAYLENGTH = new Instruction(Constants.ARRAYLENGTH);
- public static final Instruction ATHROW = new Instruction(Constants.ATHROW);
- public static final Instruction MONITORENTER = new Instruction(Constants.MONITORENTER);
- public static final Instruction MONITOREXIT = new Instruction(Constants.MONITOREXIT);
- public static final Instruction IMPDEP1 = new Instruction(Constants.IMPDEP1);
- public static final Instruction IMPDEP2 = new Instruction(Constants.IMPDEP2);
+ Instruction NOP = new Instruction(Constants.NOP);
+ Instruction ACONST_NULL = new Instruction(Constants.ACONST_NULL);
+ Instruction ICONST_M1 = new Instruction(Constants.ICONST_M1);
+ Instruction ICONST_0 = new Instruction(Constants.ICONST_0);
+ Instruction ICONST_1 = new Instruction(Constants.ICONST_1);
+ Instruction ICONST_2 = new Instruction(Constants.ICONST_2);
+ Instruction ICONST_3 = new Instruction(Constants.ICONST_3);
+ Instruction ICONST_4 = new Instruction(Constants.ICONST_4);
+ Instruction ICONST_5 = new Instruction(Constants.ICONST_5);
+ Instruction LCONST_0 = new Instruction(Constants.LCONST_0);
+ Instruction LCONST_1 = new Instruction(Constants.LCONST_1);
+ Instruction FCONST_0 = new Instruction(Constants.FCONST_0);
+ Instruction FCONST_1 = new Instruction(Constants.FCONST_1);
+ Instruction FCONST_2 = new Instruction(Constants.FCONST_2);
+ Instruction DCONST_0 = new Instruction(Constants.DCONST_0);
+ Instruction DCONST_1 = new Instruction(Constants.DCONST_1);
+ Instruction IALOAD = new Instruction(Constants.IALOAD);
+ Instruction LALOAD = new Instruction(Constants.LALOAD);
+ Instruction FALOAD = new Instruction(Constants.FALOAD);
+ Instruction DALOAD = new Instruction(Constants.DALOAD);
+ Instruction AALOAD = new Instruction(Constants.AALOAD);
+ Instruction BALOAD = new Instruction(Constants.BALOAD);
+ Instruction CALOAD = new Instruction(Constants.CALOAD);
+ Instruction SALOAD = new Instruction(Constants.SALOAD);
+ Instruction IASTORE = new Instruction(Constants.IASTORE);
+ Instruction LASTORE = new Instruction(Constants.LASTORE);
+ Instruction FASTORE = new Instruction(Constants.FASTORE);
+ Instruction DASTORE = new Instruction(Constants.DASTORE);
+ Instruction AASTORE = new Instruction(Constants.AASTORE);
+ Instruction BASTORE = new Instruction(Constants.BASTORE);
+ Instruction CASTORE = new Instruction(Constants.CASTORE);
+ Instruction SASTORE = new Instruction(Constants.SASTORE);
+ Instruction POP = new Instruction(Constants.POP);
+ Instruction POP2 = new Instruction(Constants.POP2);
+ Instruction DUP = new Instruction(Constants.DUP);
+ Instruction DUP_X1 = new Instruction(Constants.DUP_X1);
+ Instruction DUP_X2 = new Instruction(Constants.DUP_X2);
+ Instruction DUP2 = new Instruction(Constants.DUP2);
+ Instruction DUP2_X1 = new Instruction(Constants.DUP2_X1);
+ Instruction DUP2_X2 = new Instruction(Constants.DUP2_X2);
+ Instruction SWAP = new Instruction(Constants.SWAP);
+ Instruction IADD = new Instruction(Constants.IADD);
+ Instruction LADD = new Instruction(Constants.LADD);
+ Instruction FADD = new Instruction(Constants.FADD);
+ Instruction DADD = new Instruction(Constants.DADD);
+ Instruction ISUB = new Instruction(Constants.ISUB);
+ Instruction LSUB = new Instruction(Constants.LSUB);
+ Instruction FSUB = new Instruction(Constants.FSUB);
+ Instruction DSUB = new Instruction(Constants.DSUB);
+ Instruction IMUL = new Instruction(Constants.IMUL);
+ Instruction LMUL = new Instruction(Constants.LMUL);
+ Instruction FMUL = new Instruction(Constants.FMUL);
+ Instruction DMUL = new Instruction(Constants.DMUL);
+ Instruction IDIV = new Instruction(Constants.IDIV);
+ Instruction LDIV = new Instruction(Constants.LDIV);
+ Instruction FDIV = new Instruction(Constants.FDIV);
+ Instruction DDIV = new Instruction(Constants.DDIV);
+ Instruction IREM = new Instruction(Constants.IREM);
+ Instruction LREM = new Instruction(Constants.LREM);
+ Instruction FREM = new Instruction(Constants.FREM);
+ Instruction DREM = new Instruction(Constants.DREM);
+ Instruction INEG = new Instruction(Constants.INEG);
+ Instruction LNEG = new Instruction(Constants.LNEG);
+ Instruction FNEG = new Instruction(Constants.FNEG);
+ Instruction DNEG = new Instruction(Constants.DNEG);
+ Instruction ISHL = new Instruction(Constants.ISHL);
+ Instruction LSHL = new Instruction(Constants.LSHL);
+ Instruction ISHR = new Instruction(Constants.ISHR);
+ Instruction LSHR = new Instruction(Constants.LSHR);
+ Instruction IUSHR = new Instruction(Constants.IUSHR);
+ Instruction LUSHR = new Instruction(Constants.LUSHR);
+ Instruction IAND = new Instruction(Constants.IAND);
+ Instruction LAND = new Instruction(Constants.LAND);
+ Instruction IOR = new Instruction(Constants.IOR);
+ Instruction LOR = new Instruction(Constants.LOR);
+ Instruction IXOR = new Instruction(Constants.IXOR);
+ Instruction LXOR = new Instruction(Constants.LXOR);
+ Instruction I2L = new Instruction(Constants.I2L);
+ Instruction I2F = new Instruction(Constants.I2F);
+ Instruction I2D = new Instruction(Constants.I2D);
+ Instruction L2I = new Instruction(Constants.L2I);
+ Instruction L2F = new Instruction(Constants.L2F);
+ Instruction L2D = new Instruction(Constants.L2D);
+ Instruction F2I = new Instruction(Constants.F2I);
+ Instruction F2L = new Instruction(Constants.F2L);
+ Instruction F2D = new Instruction(Constants.F2D);
+ Instruction D2I = new Instruction(Constants.D2I);
+ Instruction D2L = new Instruction(Constants.D2L);
+ Instruction D2F = new Instruction(Constants.D2F);
+ Instruction I2B = new Instruction(Constants.I2B);
+ Instruction I2C = new Instruction(Constants.I2C);
+ Instruction I2S = new Instruction(Constants.I2S);
+ Instruction LCMP = new Instruction(Constants.LCMP);
+ Instruction FCMPL = new Instruction(Constants.FCMPL);
+ Instruction FCMPG = new Instruction(Constants.FCMPG);
+ Instruction DCMPL = new Instruction(Constants.DCMPL);
+ Instruction DCMPG = new Instruction(Constants.DCMPG);
+ Instruction IRETURN = new Instruction(Constants.IRETURN);
+ Instruction LRETURN = new Instruction(Constants.LRETURN);
+ Instruction FRETURN = new Instruction(Constants.FRETURN);
+ Instruction DRETURN = new Instruction(Constants.DRETURN);
+ Instruction ARETURN = new Instruction(Constants.ARETURN);
+ Instruction RETURN = new Instruction(Constants.RETURN);
+ Instruction ARRAYLENGTH = new Instruction(Constants.ARRAYLENGTH);
+ Instruction ATHROW = new Instruction(Constants.ATHROW);
+ Instruction MONITORENTER = new Instruction(Constants.MONITORENTER);
+ Instruction MONITOREXIT = new Instruction(Constants.MONITOREXIT);
+ Instruction IMPDEP1 = new Instruction(Constants.IMPDEP1);
+ Instruction IMPDEP2 = new Instruction(Constants.IMPDEP2);
// You can use these constants in multiple places safely, any attempt to change the index
// for these constants will cause an exception
- public static final InstructionLV THIS = new InstructionCLV(Constants.ALOAD,0);
- public static final InstructionLV ALOAD_0 = new InstructionCLV(Constants.ALOAD_0);
- public static final InstructionLV ALOAD_1 = new InstructionCLV(Constants.ALOAD_1);
- public static final InstructionLV ALOAD_2 = new InstructionCLV(Constants.ALOAD_2);
- public static final InstructionLV ALOAD_3 = new InstructionCLV(Constants.ALOAD_3);
- public static final InstructionLV ILOAD_0 = new InstructionCLV(Constants.ILOAD_0);
- public static final InstructionLV ILOAD_1 = new InstructionCLV(Constants.ILOAD_1);
- public static final InstructionLV ILOAD_2 = new InstructionCLV(Constants.ILOAD_2);
- public static final InstructionLV ILOAD_3 = new InstructionCLV(Constants.ILOAD_3);
- public static final InstructionLV DLOAD_0 = new InstructionCLV(Constants.DLOAD_0);
- public static final InstructionLV DLOAD_1 = new InstructionCLV(Constants.DLOAD_1);
- public static final InstructionLV DLOAD_2 = new InstructionCLV(Constants.DLOAD_2);
- public static final InstructionLV DLOAD_3 = new InstructionCLV(Constants.DLOAD_3);
- public static final InstructionLV FLOAD_0 = new InstructionCLV(Constants.FLOAD_0);
- public static final InstructionLV FLOAD_1 = new InstructionCLV(Constants.FLOAD_1);
- public static final InstructionLV FLOAD_2 = new InstructionCLV(Constants.FLOAD_2);
- public static final InstructionLV FLOAD_3 = new InstructionCLV(Constants.FLOAD_3);
- public static final InstructionLV LLOAD_0 = new InstructionCLV(Constants.LLOAD_0);
- public static final InstructionLV LLOAD_1 = new InstructionCLV(Constants.LLOAD_1);
- public static final InstructionLV LLOAD_2 = new InstructionCLV(Constants.LLOAD_2);
- public static final InstructionLV LLOAD_3 = new InstructionCLV(Constants.LLOAD_3);
- public static final InstructionLV ASTORE_0 = new InstructionCLV(Constants.ASTORE_0);
- public static final InstructionLV ASTORE_1 = new InstructionCLV(Constants.ASTORE_1);
- public static final InstructionLV ASTORE_2 = new InstructionCLV(Constants.ASTORE_2);
- public static final InstructionLV ASTORE_3 = new InstructionCLV(Constants.ASTORE_3);
- public static final InstructionLV ISTORE_0 = new InstructionCLV(Constants.ISTORE_0);
- public static final InstructionLV ISTORE_1 = new InstructionCLV(Constants.ISTORE_1);
- public static final InstructionLV ISTORE_2 = new InstructionCLV(Constants.ISTORE_2);
- public static final InstructionLV ISTORE_3 = new InstructionCLV(Constants.ISTORE_3);
- public static final InstructionLV LSTORE_0 = new InstructionCLV(Constants.LSTORE_0);
- public static final InstructionLV LSTORE_1 = new InstructionCLV(Constants.LSTORE_1);
- public static final InstructionLV LSTORE_2 = new InstructionCLV(Constants.LSTORE_2);
- public static final InstructionLV LSTORE_3 = new InstructionCLV(Constants.LSTORE_3);
- public static final InstructionLV FSTORE_0 = new InstructionCLV(Constants.FSTORE_0);
- public static final InstructionLV FSTORE_1 = new InstructionCLV(Constants.FSTORE_1);
- public static final InstructionLV FSTORE_2 = new InstructionCLV(Constants.FSTORE_2);
- public static final InstructionLV FSTORE_3 = new InstructionCLV(Constants.FSTORE_3);
- public static final InstructionLV DSTORE_0 = new InstructionCLV(Constants.DSTORE_0);
- public static final InstructionLV DSTORE_1 = new InstructionCLV(Constants.DSTORE_1);
- public static final InstructionLV DSTORE_2 = new InstructionCLV(Constants.DSTORE_2);
- public static final InstructionLV DSTORE_3 = new InstructionCLV(Constants.DSTORE_3);
+ InstructionLV THIS = new InstructionCLV(Constants.ALOAD,0);
+ InstructionLV ALOAD_0 = new InstructionCLV(Constants.ALOAD_0);
+ InstructionLV ALOAD_1 = new InstructionCLV(Constants.ALOAD_1);
+ InstructionLV ALOAD_2 = new InstructionCLV(Constants.ALOAD_2);
+ InstructionLV ALOAD_3 = new InstructionCLV(Constants.ALOAD_3);
+ InstructionLV ILOAD_0 = new InstructionCLV(Constants.ILOAD_0);
+ InstructionLV ILOAD_1 = new InstructionCLV(Constants.ILOAD_1);
+ InstructionLV ILOAD_2 = new InstructionCLV(Constants.ILOAD_2);
+ InstructionLV ILOAD_3 = new InstructionCLV(Constants.ILOAD_3);
+ InstructionLV DLOAD_0 = new InstructionCLV(Constants.DLOAD_0);
+ InstructionLV DLOAD_1 = new InstructionCLV(Constants.DLOAD_1);
+ InstructionLV DLOAD_2 = new InstructionCLV(Constants.DLOAD_2);
+ InstructionLV DLOAD_3 = new InstructionCLV(Constants.DLOAD_3);
+ InstructionLV FLOAD_0 = new InstructionCLV(Constants.FLOAD_0);
+ InstructionLV FLOAD_1 = new InstructionCLV(Constants.FLOAD_1);
+ InstructionLV FLOAD_2 = new InstructionCLV(Constants.FLOAD_2);
+ InstructionLV FLOAD_3 = new InstructionCLV(Constants.FLOAD_3);
+ InstructionLV LLOAD_0 = new InstructionCLV(Constants.LLOAD_0);
+ InstructionLV LLOAD_1 = new InstructionCLV(Constants.LLOAD_1);
+ InstructionLV LLOAD_2 = new InstructionCLV(Constants.LLOAD_2);
+ InstructionLV LLOAD_3 = new InstructionCLV(Constants.LLOAD_3);
+ InstructionLV ASTORE_0 = new InstructionCLV(Constants.ASTORE_0);
+ InstructionLV ASTORE_1 = new InstructionCLV(Constants.ASTORE_1);
+ InstructionLV ASTORE_2 = new InstructionCLV(Constants.ASTORE_2);
+ InstructionLV ASTORE_3 = new InstructionCLV(Constants.ASTORE_3);
+ InstructionLV ISTORE_0 = new InstructionCLV(Constants.ISTORE_0);
+ InstructionLV ISTORE_1 = new InstructionCLV(Constants.ISTORE_1);
+ InstructionLV ISTORE_2 = new InstructionCLV(Constants.ISTORE_2);
+ InstructionLV ISTORE_3 = new InstructionCLV(Constants.ISTORE_3);
+ InstructionLV LSTORE_0 = new InstructionCLV(Constants.LSTORE_0);
+ InstructionLV LSTORE_1 = new InstructionCLV(Constants.LSTORE_1);
+ InstructionLV LSTORE_2 = new InstructionCLV(Constants.LSTORE_2);
+ InstructionLV LSTORE_3 = new InstructionCLV(Constants.LSTORE_3);
+ InstructionLV FSTORE_0 = new InstructionCLV(Constants.FSTORE_0);
+ InstructionLV FSTORE_1 = new InstructionCLV(Constants.FSTORE_1);
+ InstructionLV FSTORE_2 = new InstructionCLV(Constants.FSTORE_2);
+ InstructionLV FSTORE_3 = new InstructionCLV(Constants.FSTORE_3);
+ InstructionLV DSTORE_0 = new InstructionCLV(Constants.DSTORE_0);
+ InstructionLV DSTORE_1 = new InstructionCLV(Constants.DSTORE_1);
+ InstructionLV DSTORE_2 = new InstructionCLV(Constants.DSTORE_2);
+ InstructionLV DSTORE_3 = new InstructionCLV(Constants.DSTORE_3);
/** Get object via its opcode, for immutable instructions like
* branch instructions entries are set to null.
*/
- public static final Instruction[] INSTRUCTIONS = new Instruction[256];
-
+ Instruction[] INSTRUCTIONS = new Instruction[256];
+
/** Interfaces may have no static initializers, so we simulate this
* with an inner class.
*/
- static final Clinit bla = new Clinit();
+ Clinit bla = new Clinit();
- static class Clinit {
+ class Clinit {
Clinit() {
INSTRUCTIONS[Constants.NOP] = NOP;
INSTRUCTIONS[Constants.ACONST_NULL] = ACONST_NULL;
@@ -352,7 +352,7 @@ public interface InstructionConstants {
INSTRUCTIONS[Constants.MONITOREXIT] = MONITOREXIT;
INSTRUCTIONS[Constants.IMPDEP1] = IMPDEP1;
INSTRUCTIONS[Constants.IMPDEP2] = IMPDEP2;
-
+
INSTRUCTIONS[Constants.ALOAD_0] = ALOAD_0;INSTRUCTIONS[Constants.ALOAD_1] = ALOAD_1;
INSTRUCTIONS[Constants.ALOAD_2] = ALOAD_2;INSTRUCTIONS[Constants.ALOAD_3] = ALOAD_3;
INSTRUCTIONS[Constants.LLOAD_0] = LLOAD_0;INSTRUCTIONS[Constants.LLOAD_1] = LLOAD_1;
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionTargeter.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionTargeter.java
index 950ed3fa9..27bace608 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionTargeter.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/generic/InstructionTargeter.java
@@ -65,6 +65,6 @@ package org.aspectj.apache.bcel.generic;
* @author M. Dahm
*/
public interface InstructionTargeter {
- public boolean containsTarget(InstructionHandle ih);
- public void updateTarget(InstructionHandle old_ih, InstructionHandle new_ih);
+ boolean containsTarget(InstructionHandle ih);
+ void updateTarget(InstructionHandle old_ih, InstructionHandle new_ih);
}
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/ClassPath.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/ClassPath.java
index c39d2195b..35666b334 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/ClassPath.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/ClassPath.java
@@ -366,28 +366,28 @@ public class ClassPath implements Serializable {
/**
* @return input stream for class file.
*/
- public abstract InputStream getInputStream() throws IOException;
+ InputStream getInputStream() throws IOException;
/**
* @return canonical path to class file.
*/
- public abstract String getPath();
+ String getPath();
/**
* @return base path of found class, i.e. class is contained relative to
* that path, which may either denote a directory, or zip file
*/
- public abstract String getBase();
+ String getBase();
/**
* @return modification time of class file.
*/
- public abstract long getTime();
+ long getTime();
/**
* @return size of class file.
*/
- public abstract long getSize();
+ long getSize();
}
private static class Dir extends PathEntry {
diff --git a/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/Repository.java b/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/Repository.java
index eea889e61..1f6031b71 100644
--- a/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/Repository.java
+++ b/bcel-builder/src/main/java/org/aspectj/apache/bcel/util/Repository.java
@@ -59,7 +59,7 @@ import org.aspectj.apache.bcel.classfile.JavaClass;
/**
* Abstract definition of a class repository. Instances may be used to load classes from different sources and may be used in the
* Repository.setRepository method.
- *
+ *
* @see org.aspectj.apache.bcel.Repository
* @version $Id: Repository.java,v 1.5 2009/09/09 19:56:20 aclement Exp $
* @author M. Dahm
@@ -69,30 +69,30 @@ public interface Repository {
/**
* Store the provided class under "clazz.getClassName()"
*/
- public void storeClass(JavaClass clazz);
+ void storeClass(JavaClass clazz);
/**
* Remove class from repository
*/
- public void removeClass(JavaClass clazz);
+ void removeClass(JavaClass clazz);
/**
* Find the class with the name provided, if the class isn't there, return NULL.
*/
- public JavaClass findClass(String className);
+ JavaClass findClass(String className);
/**
* Find the class with the name provided, if the class isn't there, make an attempt to load it.
*/
- public JavaClass loadClass(String className) throws java.lang.ClassNotFoundException;
+ JavaClass loadClass(String className) throws java.lang.ClassNotFoundException;
/**
* Find the JavaClass instance for the given run-time class object
*/
- public JavaClass loadClass(Class clazz) throws java.lang.ClassNotFoundException;
+ JavaClass loadClass(Class clazz) throws java.lang.ClassNotFoundException;
/**
* Clear all entries from cache.
*/
- public void clear();
+ void clear();
}
diff --git a/bridge/src/main/java/org/aspectj/bridge/IMessage.java b/bridge/src/main/java/org/aspectj/bridge/IMessage.java
index a32a631e6..694da8af0 100644
--- a/bridge/src/main/java/org/aspectj/bridge/IMessage.java
+++ b/bridge/src/main/java/org/aspectj/bridge/IMessage.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.bridge;
@@ -23,18 +23,18 @@ import java.util.List;
*/
public interface IMessage {
/** no messages */
- public static final IMessage[] RA_IMessage = new IMessage[0];
+ IMessage[] RA_IMessage = new IMessage[0];
// int values must sync with KINDS order below
- public static final Kind WEAVEINFO = new Kind("weaveinfo", 5);
- public static final Kind INFO = new Kind("info", 10);
- public static final Kind DEBUG = new Kind("debug", 20);
- public static final Kind TASKTAG = new Kind("task", 25); // represents a 'TODO' from eclipse - producted by the compiler and
+ Kind WEAVEINFO = new Kind("weaveinfo", 5);
+ Kind INFO = new Kind("info", 10);
+ Kind DEBUG = new Kind("debug", 20);
+ Kind TASKTAG = new Kind("task", 25); // represents a 'TODO' from eclipse - producted by the compiler and
// consumed by AJDT
- public static final Kind WARNING = new Kind("warning", 30);
- public static final Kind ERROR = new Kind("error", 40);
- public static final Kind FAIL = new Kind("fail", 50);
- public static final Kind ABORT = new Kind("abort", 60);
+ Kind WARNING = new Kind("warning", 30);
+ Kind ERROR = new Kind("error", 40);
+ Kind FAIL = new Kind("fail", 50);
+ Kind ABORT = new Kind("abort", 60);
// XXX prefer another Kind to act as selector for "any",
// but can't prohibit creating messages with it.
// public static final Kind ANY = new Kind("any-selector", 0);
@@ -42,7 +42,7 @@ public interface IMessage {
/**
* list of Kind in precedence order. 0 is less than IMessage.Kind.COMPARATOR.compareTo(KINDS.get(i), KINDS.get(i + 1))
*/
- public static final List KINDS = Collections.unmodifiableList(Arrays.asList(new Kind[] { WEAVEINFO, INFO, DEBUG, TASKTAG,
+ List KINDS = Collections.unmodifiableList(Arrays.asList(new Kind[] { WEAVEINFO, INFO, DEBUG, TASKTAG,
WARNING, ERROR, FAIL, ABORT }));
/** @return non-null String with simple message */
@@ -90,7 +90,7 @@ public interface IMessage {
/** @return source location associated with this message, or null if none */
ISourceLocation getSourceLocation();
- public static final class Kind implements Comparable {
+ final class Kind implements Comparable {
public static final Comparator COMPARATOR = new Comparator() {
public int compare(IMessage.Kind one, IMessage.Kind two) {
if (null == one) {
@@ -134,17 +134,17 @@ public interface IMessage {
* @return Detailed information about the message. For example, for declare error/warning messages this returns information
* about the corresponding join point's static part.
*/
- public String getDetails();
+ String getDetails();
/**
* @return List of ISourceLocation
instances that indicate additional source locations relevent to this message as
* specified by the message creator. The list should not include the primary source location associated with the message
- * which can be obtained from getSourceLocation().
- *
- * An example of using extra locations would be in a warning message that
- * flags all shadow locations that will go unmatched due to a pointcut definition
+ * which can be obtained from getSourceLocation().
+ *
+ * An example of using extra locations would be in a warning message that
+ * flags all shadow locations that will go unmatched due to a pointcut definition
* being based on a subtype of a defining type.
* @see AspectJ bug 41952
*/
- public List getExtraSourceLocations();
+ List getExtraSourceLocations();
}
diff --git a/bridge/src/main/java/org/aspectj/bridge/IMessageContext.java b/bridge/src/main/java/org/aspectj/bridge/IMessageContext.java
index 2f5512a1d..e3e0d0962 100644
--- a/bridge/src/main/java/org/aspectj/bridge/IMessageContext.java
+++ b/bridge/src/main/java/org/aspectj/bridge/IMessageContext.java
@@ -1,10 +1,10 @@
/*******************************************************************************
* Copyright (c) 2006 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
+ * All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* Matthew Webster - initial implementation
*******************************************************************************/
@@ -12,5 +12,5 @@ package org.aspectj.bridge;
public interface IMessageContext {
- public String getContextId ();
+ String getContextId();
}
diff --git a/bridge/src/main/java/org/aspectj/bridge/IMessageHandler.java b/bridge/src/main/java/org/aspectj/bridge/IMessageHandler.java
index 6dcdfeafb..9baf23465 100644
--- a/bridge/src/main/java/org/aspectj/bridge/IMessageHandler.java
+++ b/bridge/src/main/java/org/aspectj/bridge/IMessageHandler.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
@@ -19,8 +19,8 @@ import java.io.PrintWriter;
/**
* Handle messages, logging and/or aborting as appropriate.
* Implementations define which messages are logged and whether
- * the handler aborts the process.
- * For messages that are costly to construct, clients may query
+ * the handler aborts the process.
+ * For messages that are costly to construct, clients may query
* {@link #isIgnoring(IMessage.Kind)}
* to avoid construction if the message will be ignored.
* Clients passing messages to an IMessageHandler should not
@@ -29,15 +29,15 @@ import java.io.PrintWriter;
*/
public interface IMessageHandler {
/** print all to System.err and throw AbortException on failure or abort messages */
- public static final IMessageHandler SYSTEM_ERR =
+ IMessageHandler SYSTEM_ERR =
new MessageWriter(new PrintWriter(System.err, true), true);
/** print all to System.out but do not throw AbortException on failure or abort messages */
- public static final IMessageHandler SYSTEM_OUT =
+ IMessageHandler SYSTEM_OUT =
new MessageWriter(new PrintWriter(System.out, true), false);
/** Throw exceptions for anything with ERROR or greater severity */
- public static final IMessageHandler THROW =
+ IMessageHandler THROW =
new IMessageHandler() {
public boolean handleMessage(IMessage message) {
if (message.getKind().compareTo(IMessage.ERROR) >= 0) {
@@ -50,13 +50,13 @@ public interface IMessageHandler {
return false;
}
public void dontIgnore(IMessage.Kind kind) {
-
+
}
public void ignore(IMessage.Kind kind) {
}
};
- /**
+ /**
* Handle message, by reporting and/or throwing an AbortException.
* @param message the IMessage to handle - never null
* @return true if this message was handled by this handler
@@ -75,14 +75,14 @@ public interface IMessageHandler {
/**
* Allow fine grained configuration after initialization. Minaly used in LTW. Most of the
* implementation can have this method be a no-op.
- *
+ *
* @param kind
*/
void dontIgnore(IMessage.Kind kind);
-
+
/**
- * Allow fine grained configuration after initialization.
- *
+ * Allow fine grained configuration after initialization.
+ *
* @param kind
*/
void ignore(IMessage.Kind kind);
diff --git a/bridge/src/main/java/org/aspectj/bridge/IMessageHolder.java b/bridge/src/main/java/org/aspectj/bridge/IMessageHolder.java
index fdf2a6779..c438b8350 100644
--- a/bridge/src/main/java/org/aspectj/bridge/IMessageHolder.java
+++ b/bridge/src/main/java/org/aspectj/bridge/IMessageHolder.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.bridge;
@@ -21,14 +21,14 @@ import java.util.List;
public interface IMessageHolder extends IMessageHandler { // XXX do not extend - mix instead
// XXX go to LT EQ GT GE LE rather than simple orGreater
/** value for orGreater parameter */
- public static final boolean ORGREATER = true;
+ boolean ORGREATER = true;
/** value for orGreater parameter */
- public static final boolean EQUAL = false;
+ boolean EQUAL = false;
/**
* Tell whether this holder has any message of this kind (optionally or greater).
- *
+ *
* @param kind the IMessage.Kind to check for - accept any if null
* @param orGreater if true, also any greater than the target kind as determined by IMessage.Kind.COMPARATOR
* @return true if this holder has any message of this kind, or if orGreater and any message has a greater kind, as determined
@@ -38,7 +38,7 @@ public interface IMessageHolder extends IMessageHandler { // XXX do not extend -
/**
* Count the messages currently held by this holder. Pass null to get all kinds.
- *
+ *
* @param kind the IMessage.Kind expected, or null for all messages
* @param orGreater if true, also any greater than the target kind as determined by IMessage.Kind.COMPARATOR
* @return number of IMessage held (now) by this holder
@@ -47,7 +47,7 @@ public interface IMessageHolder extends IMessageHandler { // XXX do not extend -
/**
* Get all messages or those of a specific kind. Pass null to get all kinds.
- *
+ *
* @param kind the IMessage.Kind expected, or null for all messages
* @param orGreater if true, also get any greater than the target kind as determined by IMessage.Kind.COMPARATOR
* @return IMessage[] of messages of the right kind, or IMessage.NONE
@@ -59,7 +59,7 @@ public interface IMessageHolder extends IMessageHandler { // XXX do not extend -
/**
* Clear any messages.
- *
+ *
* @throws UnsupportedOperationException if message list is read-only
*/
void clearMessages() throws UnsupportedOperationException;
diff --git a/bridge/src/main/java/org/aspectj/bridge/IProgressListener.java b/bridge/src/main/java/org/aspectj/bridge/IProgressListener.java
index 4326f7263..21eb6eeb4 100644
--- a/bridge/src/main/java/org/aspectj/bridge/IProgressListener.java
+++ b/bridge/src/main/java/org/aspectj/bridge/IProgressListener.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2003 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
@@ -20,21 +20,21 @@ public interface IProgressListener {
/**
* @param text the current phase of processing
*/
- public void setText(String text);
-
+ void setText(String text);
+
/**
* @param percentDone how much work is completed so far
*/
- public void setProgress(double percentDone);
-
+ void setProgress(double percentDone);
+
/**
* @param cancelRequested true if the caller wants the current compilation to stop asap
*/
- public void setCancelledRequested(boolean cancelRequested);
-
+ void setCancelledRequested(boolean cancelRequested);
+
/**
* @return true if the consumer of the progress info would like the compileation to stop
*/
- public boolean isCancelledRequested();
-
+ boolean isCancelledRequested();
+
}
diff --git a/bridge/src/main/java/org/aspectj/bridge/ISourceLocation.java b/bridge/src/main/java/org/aspectj/bridge/ISourceLocation.java
index 7ad9423c2..80ed94e33 100644
--- a/bridge/src/main/java/org/aspectj/bridge/ISourceLocation.java
+++ b/bridge/src/main/java/org/aspectj/bridge/ISourceLocation.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.bridge;
@@ -18,24 +18,24 @@ import java.io.File;
/**
* Represent source location as a starting line/column and ending line in a source file. Implementations should be immutable. XXX
* why?
- *
+ *
* @see org.aspectj.lang.reflect.SourceLocation
* @see org.aspectj.compiler.base.parser.SourceInfo
* @see org.aspectj.tools.ide.SourceLine
* @see org.aspectj.testing.harness.ErrorLine
*/
public interface ISourceLocation extends java.io.Serializable {
- static final int MAX_LINE = Integer.MAX_VALUE / 2;
- static final int MAX_COLUMN = MAX_LINE;
+ int MAX_LINE = Integer.MAX_VALUE / 2;
+ int MAX_COLUMN = MAX_LINE;
/** non-null but empty (nonexisting) File constant */
- static final File NO_FILE = new File("ISourceLocation.NO_FILE");
+ File NO_FILE = new File("ISourceLocation.NO_FILE");
/** signal that column is not known */
- static final int NO_COLUMN = Integer.MIN_VALUE + 1;
+ int NO_COLUMN = Integer.MIN_VALUE + 1;
/** non-null but empty constant source location */
- static final ISourceLocation EMPTY = new SourceLocation(NO_FILE, 0, 0, 0);
+ ISourceLocation EMPTY = new SourceLocation(NO_FILE, 0, 0, 0);
/**
* @return File source or NO_FILE if the implementation requires a non-null result or null otherwise
@@ -64,7 +64,7 @@ public interface ISourceLocation extends java.io.Serializable {
/**
* In the cases where getSourceFile().getName() returns a class file (for example when we have a binary aspect) this should
* return the name of the source file (for example BinaryAspect.aj)
- *
+ *
* @return the name of the source file
*/
String getSourceFileName();
diff --git a/bridge/src/main/java/org/aspectj/bridge/MessageUtil.java b/bridge/src/main/java/org/aspectj/bridge/MessageUtil.java
index 0ebe113e0..0385ba696 100644
--- a/bridge/src/main/java/org/aspectj/bridge/MessageUtil.java
+++ b/bridge/src/main/java/org/aspectj/bridge/MessageUtil.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.bridge;
@@ -135,7 +135,7 @@ public class MessageUtil {
/**
* Create fail message. If message is empty but thrown is not, use thrown.getMessage() as the message. If message is empty and
* thrown is null, return FAIL_NOMESSAGE.
- *
+ *
* @return FAIL_NOMESSAGE if thrown is null and message is empty or IMessage FAIL with message and thrown otherwise
*/
public static IMessage fail(String message, Throwable thrown) {
@@ -231,7 +231,7 @@ public class MessageUtil {
// ------------------------ printing messages
/**
* Print total counts message to the print stream, starting each on a new line
- *
+ *
* @param messageHolder
* @param out
*/
@@ -248,7 +248,7 @@ public class MessageUtil {
/**
* Print all message to the print stream, starting each on a new line
- *
+ *
* @param messageHolder
* @param out
* @see #print(PrintStream, String, IMessageHolder, IMessageRenderer, IMessageHandler)
@@ -259,7 +259,7 @@ public class MessageUtil {
/**
* Print all message to the print stream, starting each on a new line, with a prefix.
- *
+ *
* @param messageHolder
* @param out
* @see #print(PrintStream, String, IMessageHolder, IMessageRenderer, IMessageHandler)
@@ -270,7 +270,7 @@ public class MessageUtil {
/**
* Print all message to the print stream, starting each on a new line, with a prefix and using a renderer.
- *
+ *
* @param messageHolder
* @param out
* @param renderer IMessageRender to render result - use MESSAGE_LINE if null
@@ -283,14 +283,14 @@ public class MessageUtil {
/**
* Print all message to the print stream, starting each on a new line, with a prefix and using a renderer. The first line
* renders a summary: {prefix}MessageHolder: {summary} Each message line has the following form:
- *
+ *
*
* {prefix}[{kind} {index}]: {rendering}
*
- *
+ *
* (where "{index}" (length 3) is the position within the set of like-kinded messages, ignoring selector omissions. Renderers
* are free to render multi-line output.
- *
+ *
* @param out the PrintStream sink - return silently if null
* @param messageHolder the IMessageHolder with the messages to print
* @param renderer IMessageRender to render result - use MESSAGE_ALL if null
@@ -351,7 +351,7 @@ public class MessageUtil {
/**
* Select all messages in holder except those of the same kind (optionally or greater). If kind is null, then all messages are
* rejected, so an empty list is returned.
- *
+ *
* @return unmodifiable list of specified IMessage
*/
public static IMessage[] getMessagesExcept(IMessageHolder holder, final IMessage.Kind kind, final boolean orGreater) {
@@ -397,7 +397,7 @@ public class MessageUtil {
/**
* Extract messages of type kind from the input list.
- *
+ *
* @param messages if null, return EMPTY_LIST
* @param kind if null, return messages
* @see MessageHandler#getMessages(Kind)
@@ -423,7 +423,7 @@ public class MessageUtil {
/**
* Map to the kind of messages associated with this string key.
- *
+ *
* @param kind the String representing the kind of message (IMessage.Kind.toString())
* @return Kind the associated IMessage.Kind, or null if not found
*/
@@ -463,7 +463,7 @@ public class MessageUtil {
/**
* Run visitor over a collection of messages, optionally accumulating those accepted by the visitor
- *
+ *
* @param messages if null or empty, return IMessage.RA_IMessage
* @param visitor run visitor.handleMessage(message) on each message - if null and messages not empty, IllegalArgumentException
* @param accumulate if true, then return accepted IMessage[]
@@ -497,7 +497,7 @@ public class MessageUtil {
/**
* Make an IMessageHandler that handles IMessage if they have the right kind (or greater) and contain some infix String.
- *
+ *
* @param kind the IMessage.Kind required of the message
* @param orGreater if true, also accept messages with greater kinds, as defined by IMessage.Kind.COMPARATOR
* @param infix the String text to require in the message - may be null or empty to accept any message with the specified kind.
@@ -596,7 +596,7 @@ public class MessageUtil {
// ------------------ components to render messages
/** parameterize rendering behavior for messages */
- public static interface IMessageRenderer {
+ public interface IMessageRenderer {
String renderToString(IMessage message);
}
@@ -778,7 +778,7 @@ public class MessageUtil {
/**
* This renders IMessage as String, ignoring empty elements and eliding any thrown stack traces.
- *
+ *
* @return "((IMessage) null)" if null or String rendering otherwise, including everything (esp. throwable stack trace)
* @see renderSourceLocation(ISourceLocation loc)
*/
@@ -788,7 +788,7 @@ public class MessageUtil {
/**
* This renders IMessage as String, ignoring empty elements and eliding any thrown.
- *
+ *
* @return "((IMessage) null)" if null or String rendering otherwise, including everything (esp. throwable stack trace)
* @see renderSourceLocation(ISourceLocation loc)
*/
@@ -838,13 +838,13 @@ public class MessageUtil {
/**
* Render ISourceLocation to String, ignoring empty elements (null or ISourceLocation.NO_FILE or ISourceLocation.NO_COLUMN
* (though implementations may return 0 from getColumn() when passed NO_COLUMN as input)).
- *
+ *
* @return "((ISourceLocation) null)" if null or String rendering
- *
+ *
*
* {file:}line{:column}
*
- *
+ *
*/
public static String renderSourceLocation(ISourceLocation loc) {
if (null == loc) {
@@ -872,7 +872,7 @@ public class MessageUtil {
* Render message in a line. IMessage.Kind is always printed, then any unqualified exception class, then the remainder of text
* and location according to their relative scale, all to fit in max characters or less. This does not render thrown except for
* the unqualified class name
- *
+ *
* @param max the number of characters - forced to 32..10000
* @param textScale relative proportion to spend on message and/or exception message, relative to source location - if 0,
* message is suppressed
@@ -999,7 +999,7 @@ public class MessageUtil {
/**
* Factory for handler adapted to PrintStream XXX weak - only handles println(String)
- *
+ *
* @param handler the IMessageHandler sink for the messages generated
* @param kind the IMessage.Kind of message to create
* @param overage the OuputStream for text not captured by the handler (if null, System.out used)
@@ -1037,7 +1037,7 @@ public class MessageUtil {
/**
* Handle all messages in the second handler using the first
- *
+ *
* @param handler the IMessageHandler sink for all messages in source
* @param holder the IMessageHolder source for all messages to handle
* @param fastFail if true, stop on first failure
@@ -1049,7 +1049,7 @@ public class MessageUtil {
/**
* Handle messages in the second handler using the first
- *
+ *
* @param handler the IMessageHandler sink for all messages in source
* @param holder the IMessageHolder source for all messages to handle
* @param kind the IMessage.Kind to select, if not null
@@ -1067,7 +1067,7 @@ public class MessageUtil {
/**
* Handle messages in the second handler using the first if they are NOT of this kind (optionally, or greater). If you pass null
* as the kind, then all messages are ignored and this returns true.
- *
+ *
* @param handler the IMessageHandler sink for all messages in source
* @param holder the IMessageHolder source for all messages to handle
* @param kind the IMessage.Kind to reject, if not null
@@ -1088,7 +1088,7 @@ public class MessageUtil {
/**
* Handle messages in the sink.
- *
+ *
* @param handler the IMessageHandler sink for all messages in source
* @param sources the IMessage[] messages to handle
* @param fastFail if true, stop on first failure
diff --git a/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/compiler/ast/AspectDeclaration.java b/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/compiler/ast/AspectDeclaration.java
index f81e5bf95..b24012963 100644
--- a/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/compiler/ast/AspectDeclaration.java
+++ b/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/compiler/ast/AspectDeclaration.java
@@ -403,8 +403,8 @@ public class AspectDeclaration extends TypeDeclaration {
}
}
- private static interface BodyGenerator {
- public void generate(CodeStream codeStream);
+ private interface BodyGenerator {
+ void generate(CodeStream codeStream);
}
private void generateMethod(ClassFile classFile, ResolvedMember member, BodyGenerator gen) {
diff --git a/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/core/builder/IStateListener.java b/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/core/builder/IStateListener.java
index 97a2a2baf..87c24374d 100644
--- a/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/core/builder/IStateListener.java
+++ b/org.aspectj.ajdt.core/src/main/java/org/aspectj/ajdt/internal/core/builder/IStateListener.java
@@ -1,13 +1,13 @@
/**
* Copyright (c) 2005 IBM and other contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Andy Clement initial implementation
* ******************************************************************/
package org.aspectj.ajdt.internal.core.builder;
@@ -22,34 +22,34 @@ import java.util.List;
*
* Not yet complete, will expand as we determine what extra useful information
* should be recorded.
- *
+ *
* @author AndyClement
*/
public interface IStateListener {
- public void detectedClassChangeInThisDir(File f);
+ void detectedClassChangeInThisDir(File f);
+
+ void aboutToCompareClasspaths(List oldClasspath, List newClasspath);
- public void aboutToCompareClasspaths(List oldClasspath, List newClasspath);
+ void pathChangeDetected();
- public void pathChangeDetected();
-
/**
* Called if state processing detects a file was deleted that contained an aspect declaration.
* Incremental compilation will not be attempted if this occurs.
*/
- public void detectedAspectDeleted(File f);
+ void detectedAspectDeleted(File f);
+
+ void buildSuccessful(boolean wasFullBuild);
- public void buildSuccessful(boolean wasFullBuild);
-
/**
* When a decision is made during compilation (such as needing to recompile some new file, or drop back to batch) this
* method is called with the decision.
*/
- public void recordDecision(String decision);
-
+ void recordDecision(String decision);
+
/**
* Provides feedback during compilation on what stage we are at
*/
- public void recordInformation(String info);
+ void recordInformation(String info);
}
diff --git a/org.aspectj.ajdt.core/src/test/java/org/aspectj/tools/ajc/AjASTTestCase.java b/org.aspectj.ajdt.core/src/test/java/org/aspectj/tools/ajc/AjASTTestCase.java
index 304a7996b..a28308bb1 100644
--- a/org.aspectj.ajdt.core/src/test/java/org/aspectj/tools/ajc/AjASTTestCase.java
+++ b/org.aspectj.ajdt.core/src/test/java/org/aspectj/tools/ajc/AjASTTestCase.java
@@ -1,10 +1,10 @@
/********************************************************************
- * Copyright (c) 2006, 2010 Contributors. All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
- *
+ * Copyright (c) 2006, 2010 Contributors. All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
+ *
* Contributors: Helen Hawkins - initial implementation
* Matthew Webster - initial implementation
*******************************************************************/
@@ -59,7 +59,7 @@ public abstract class AjASTTestCase extends TestCase {
}
/**
- *
+ *
* @param source
* to parse and visit
* @param expectedSourceRanges
@@ -72,7 +72,7 @@ public abstract class AjASTTestCase extends TestCase {
}
/**
- *
+ *
* @param source
* to parse and visit
* @param expectedCategory
@@ -96,37 +96,37 @@ public abstract class AjASTTestCase extends TestCase {
}
/*
- *
- *
+ *
+ *
* Testing Classes and Interfaces
*/
/**
* Tests the results of a visitor when walking the AST
- *
+ *
*/
interface ITypePatternTester {
/**
- *
+ *
* @return visitor to walk the AST. Must not be null.
*/
- public AjASTVisitor createVisitor();
+ AjASTVisitor createVisitor();
/**
* Tests a condition after the visitor has visited the AST. This means
* the visitor should contain the results of the visitation.
- *
+ *
* @return true if test condition passed. False otherwise
*/
- public void testCondition(AjASTVisitor visitor);
+ void testCondition(AjASTVisitor visitor);
}
/**
* Tests whether a particular type category type pattern (InnerType,
* InterfaceType, ClassType, etc..) is encountered when visiting nodes in an
* AST.
- *
+ *
*/
class TypeCategoryTester implements ITypePatternTester {
@@ -163,7 +163,7 @@ public abstract class AjASTTestCase extends TestCase {
/**
* Tests the starting location and source length of each TypePattern node
* encountered while walking the AST.
- *
+ *
*/
class TypePatternSourceRangeTester implements ITypePatternTester {
@@ -204,7 +204,7 @@ public abstract class AjASTTestCase extends TestCase {
/**
* Tests whether a particular AST node starts at a given expected location
* and has an expected length
- *
+ *
*/
class SourceRangeTester implements ITypePatternTester {
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/AnnotationAJ.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/AnnotationAJ.java
index 311b12e1f..a5199164f 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/AnnotationAJ.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/AnnotationAJ.java
@@ -1,11 +1,11 @@
/* *******************************************************************
* Copyright (c) 2006-2008 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
* ******************************************************************/
package org.aspectj.weaver;
@@ -13,90 +13,90 @@ import java.util.Set;
/**
* Simple representation of an annotation that the weaver can work with.
- *
+ *
* @author AndyClement
*/
public interface AnnotationAJ {
- public static final AnnotationAJ[] EMPTY_ARRAY = new AnnotationAJ[0];
+ AnnotationAJ[] EMPTY_ARRAY = new AnnotationAJ[0];
/**
* @return the signature for the annotation type, eg. Lcom/foo/MyAnno;
*/
- public String getTypeSignature();
+ String getTypeSignature();
/**
* @return the type name for the annotation, eg. com.foo.MyAnno
*/
- public String getTypeName();
+ String getTypeName();
/**
* @return the type of the annotation
*/
- public ResolvedType getType();
+ ResolvedType getType();
/**
* return true if this annotation can target an annotation type
*/
- public boolean allowedOnAnnotationType();
+ boolean allowedOnAnnotationType();
/**
* @return true if this annotation can be put on a field
*/
- public boolean allowedOnField();
+ boolean allowedOnField();
/**
* @return true if this annotation can target a 'regular' type. A 'regular' type is enum/class/interface - it is *not*
* annotation.
*/
- public boolean allowedOnRegularType();
+ boolean allowedOnRegularType();
/**
* @return for the @target annotation, this will return a set of the element-types it can be applied to. For other annotations ,
* it returns the empty set.
*/
- public Set getTargets();
+ Set getTargets();
/**
* @param name the name of the value
* @return true if there is a value with that name
*/
- public boolean hasNamedValue(String name);
+ boolean hasNamedValue(String name);
/**
* @param name the name of the annotation field
* @param value the value of the annotation field
* @return true if there is a value with the specified name and value
*/
- public boolean hasNameValuePair(String name, String value);
+ boolean hasNameValuePair(String name, String value);
/**
* @return String representation of the valid targets for this annotation, eg. "{TYPE,FIELD}"
*/
- public String getValidTargets();
+ String getValidTargets();
/**
* @return String form of the annotation and any values, eg. @Foo(a=b,c=d)
*/
- public String stringify();
+ String stringify();
/**
* @return true if this annotation is marked with @target
*/
- public boolean specifiesTarget();
+ boolean specifiesTarget();
/**
* @return true if the annotation is marked for runtime visibility
*/
- public boolean isRuntimeVisible();
+ boolean isRuntimeVisible();
/**
* Determine the string representation of the value of a field. For example in @SuppressAjWarnings({"adviceDidNotMatch"}) the
* return value for getStringFormOfValue("value") would be "[adviceDidNotMatch]".
- *
+ *
* @param name the name of the annotation field being looked up
* @return string representation of the value of that field, may be null if no such field set
*/
- public String getStringFormOfValue(String name);
+ String getStringFormOfValue(String name);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Constants.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Constants.java
index bdbde3853..6e99e33fa 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Constants.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Constants.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2004 IBM
+ * Copyright (c) 2004 IBM
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -12,18 +12,18 @@ package org.aspectj.weaver;
/**
* Some useful weaver constants.
- *
+ *
* Current uses: 1. Holds values that are necessary for working with 1.5 code but which don't exist in a 1.4 world.
*/
public interface Constants {
- public final static int ACC_BRIDGE = 0x0040;
- public final static int ACC_VARARGS = 0x0080;
+ int ACC_BRIDGE = 0x0040;
+ int ACC_VARARGS = 0x0080;
- public final static String RUNTIME_LEVEL_12 = "1.2";
- public final static String RUNTIME_LEVEL_15 = "1.5";
- public final static String RUNTIME_LEVEL_19 = "1.9";
+ String RUNTIME_LEVEL_12 = "1.2";
+ String RUNTIME_LEVEL_15 = "1.5";
+ String RUNTIME_LEVEL_19 = "1.9";
// Default for 1.5.0
- public final static String RUNTIME_LEVEL_DEFAULT = RUNTIME_LEVEL_15;
+ String RUNTIME_LEVEL_DEFAULT = RUNTIME_LEVEL_15;
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/CustomMungerFactory.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/CustomMungerFactory.java
index 91bcbdf6b..f11e02451 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/CustomMungerFactory.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/CustomMungerFactory.java
@@ -1,12 +1,12 @@
/* *******************************************************************
* Copyright (c) 2007 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
* Linton Ye https://bugs.eclipse.org/bugs/show_bug.cgi?id=193065
* ******************************************************************/
@@ -28,9 +28,9 @@ import java.util.Collection;
* weaver and participate the weaving process. For example, the match method of each custom shadow munger will be called against
* each shadow.
*
- *
+ *
* @author lintonye
- *
+ *
*/
public interface CustomMungerFactory {
@@ -38,15 +38,15 @@ public interface CustomMungerFactory {
* @param aspectType
* @return a Collection<ShadowMunger> of custom shadow mungers for the given aspect
*/
- public Collection createCustomShadowMungers(ResolvedType aspectType);
+ Collection createCustomShadowMungers(ResolvedType aspectType);
/**
* @param aspectType
* @return a Collection<ConcreteTypeMunger> of custom type mungers for the given aspect
*/
- public Collection createCustomTypeMungers(ResolvedType aspectType);
+ Collection createCustomTypeMungers(ResolvedType aspectType);
- public Collection getAllCreatedCustomShadowMungers();
+ Collection getAllCreatedCustomShadowMungers();
- public Collection getAllCreatedCustomTypeMungers();
+ Collection getAllCreatedCustomTypeMungers();
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Dump.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Dump.java
index b177d7ec6..e6c4274e5 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Dump.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Dump.java
@@ -1,12 +1,12 @@
/* *******************************************************************
* Copyright (c) 2004,2010 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
* Matthew Webster, IBM
* ******************************************************************/
package org.aspectj.weaver;
@@ -505,15 +505,15 @@ public class Dump {
public interface INode {
- public void accept(IVisitor visior);
+ void accept(IVisitor visior);
}
public interface IVisitor {
- public void visitObject(Object s);
+ void visitObject(Object s);
- public void visitList(List list);
+ void visitList(List list);
}
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IEclipseSourceContext.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IEclipseSourceContext.java
index d691c503d..95615d13a 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IEclipseSourceContext.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IEclipseSourceContext.java
@@ -1,15 +1,15 @@
/********************************************************************
- * Copyright (c) 2006 Contributors. All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
- *
- * Contributors: IBM Corporation - initial API and implementation
+ * Copyright (c) 2006 Contributors. All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
+ *
+ * Contributors: IBM Corporation - initial API and implementation
* Helen Hawkins - iniital version
*******************************************************************/
package org.aspectj.weaver;
public interface IEclipseSourceContext extends ISourceContext {
- public void removeUnnecessaryProblems(Member method, int problemLineNumber);
+ void removeUnnecessaryProblems(Member method, int problemLineNumber);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ISourceContext.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ISourceContext.java
index 0f2f0aba1..5af15d6f5 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ISourceContext.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ISourceContext.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * PARC initial implementation
* ******************************************************************/
package org.aspectj.weaver;
@@ -15,11 +15,11 @@ package org.aspectj.weaver;
import org.aspectj.bridge.ISourceLocation;
public interface ISourceContext {
- public ISourceLocation makeSourceLocation(IHasPosition position);
+ ISourceLocation makeSourceLocation(IHasPosition position);
- public ISourceLocation makeSourceLocation(int line, int offset);
+ ISourceLocation makeSourceLocation(int line, int offset);
- public int getOffset();
+ int getOffset();
- public void tidy();
+ void tidy();
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IWeavingSupport.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IWeavingSupport.java
index 3f259c66c..5fe48a520 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IWeavingSupport.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/IWeavingSupport.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2008 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Andy Clement initial implementation
* ******************************************************************/
package org.aspectj.weaver;
@@ -18,28 +18,28 @@ import org.aspectj.weaver.patterns.Pointcut;
/**
* Encapsulates operations that a world will need to support if it is actually going to modify bytecode rather than just match
* against it. {@see BcelWeavingSupport}
- *
+ *
* @author Andy Clement
*/
public interface IWeavingSupport {
- public Advice createAdviceMunger(AjAttribute.AdviceAttribute attribute, Pointcut pointcut, Member signature,
- ResolvedType concreteAspect);
+ Advice createAdviceMunger(AjAttribute.AdviceAttribute attribute, Pointcut pointcut, Member signature,
+ ResolvedType concreteAspect);
- public abstract ConcreteTypeMunger makeCflowStackFieldAdder(ResolvedMember cflowField);
+ ConcreteTypeMunger makeCflowStackFieldAdder(ResolvedMember cflowField);
- public abstract ConcreteTypeMunger makeCflowCounterFieldAdder(ResolvedMember cflowField);
+ ConcreteTypeMunger makeCflowCounterFieldAdder(ResolvedMember cflowField);
/**
* Register a munger for perclause @AJ aspect so that we add aspectOf(..) to them as needed
- *
+ *
* @see org.aspectj.weaver.bcel.BcelWorld#makePerClauseAspect(ResolvedType, org.aspectj.weaver.patterns.PerClause.Kind)
*/
- public abstract ConcreteTypeMunger makePerClauseAspect(ResolvedType aspect, PerClause.Kind kind);
+ ConcreteTypeMunger makePerClauseAspect(ResolvedType aspect, PerClause.Kind kind);
- public abstract ConcreteTypeMunger concreteTypeMunger(ResolvedTypeMunger munger, ResolvedType aspectType);
+ ConcreteTypeMunger concreteTypeMunger(ResolvedTypeMunger munger, ResolvedType aspectType);
- public ConcreteTypeMunger createAccessForInlineMunger(ResolvedType inAspect);
+ ConcreteTypeMunger createAccessForInlineMunger(ResolvedType inAspect);
- public Var makeCflowAccessVar(ResolvedType formalType, Member cflowField, int arrayIndex);
+ Var makeCflowAccessVar(ResolvedType formalType, Member cflowField, int arrayIndex);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Member.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Member.java
index 8134e8df2..c11dad556 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Member.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/Member.java
@@ -1,10 +1,10 @@
/* *******************************************************************
* Copyright (c) 2002-2010
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
* ******************************************************************/
package org.aspectj.weaver;
@@ -12,82 +12,82 @@ import java.util.Collection;
/**
* Abstract representation of a member (field/constructor/method) within a type.
- *
+ *
* @author PARC
* @author Adrian Colyer
* @author Andy Clement
*/
public interface Member extends Comparable {
- public static final Member[] NONE = new Member[0];
+ Member[] NONE = new Member[0];
- public static final MemberKind METHOD = new MemberKind("METHOD", 1);
- public static final MemberKind FIELD = new MemberKind("FIELD", 2);
- public static final MemberKind CONSTRUCTOR = new MemberKind("CONSTRUCTOR", 3);
- public static final MemberKind STATIC_INITIALIZATION = new MemberKind("STATIC_INITIALIZATION", 4);
- public static final MemberKind POINTCUT = new MemberKind("POINTCUT", 5);
- public static final MemberKind ADVICE = new MemberKind("ADVICE", 6);
- public static final MemberKind HANDLER = new MemberKind("HANDLER", 7);
- public static final MemberKind MONITORENTER = new MemberKind("MONITORENTER", 8);
- public static final MemberKind MONITOREXIT = new MemberKind("MONITOREXIT", 9);
+ MemberKind METHOD = new MemberKind("METHOD", 1);
+ MemberKind FIELD = new MemberKind("FIELD", 2);
+ MemberKind CONSTRUCTOR = new MemberKind("CONSTRUCTOR", 3);
+ MemberKind STATIC_INITIALIZATION = new MemberKind("STATIC_INITIALIZATION", 4);
+ MemberKind POINTCUT = new MemberKind("POINTCUT", 5);
+ MemberKind ADVICE = new MemberKind("ADVICE", 6);
+ MemberKind HANDLER = new MemberKind("HANDLER", 7);
+ MemberKind MONITORENTER = new MemberKind("MONITORENTER", 8);
+ MemberKind MONITOREXIT = new MemberKind("MONITOREXIT", 9);
- public static final AnnotationAJ[][] NO_PARAMETER_ANNOTATIONXS = new AnnotationAJ[][] {};
- public static final ResolvedType[][] NO_PARAMETER_ANNOTATION_TYPES = new ResolvedType[][] {};
+ AnnotationAJ[][] NO_PARAMETER_ANNOTATIONXS = new AnnotationAJ[][] {};
+ ResolvedType[][] NO_PARAMETER_ANNOTATION_TYPES = new ResolvedType[][] {};
/**
* @return the kind of member from those listed as MemberKind instances
*/
- public MemberKind getKind();
+ MemberKind getKind();
- public String getName();
+ String getName();
- public UnresolvedType getDeclaringType();
+ UnresolvedType getDeclaringType();
- public UnresolvedType[] getParameterTypes();
+ UnresolvedType[] getParameterTypes();
- public UnresolvedType[] getGenericParameterTypes();
+ UnresolvedType[] getGenericParameterTypes();
- public UnresolvedType getType();
+ UnresolvedType getType();
- public UnresolvedType getReturnType();
+ UnresolvedType getReturnType();
- public UnresolvedType getGenericReturnType();
+ UnresolvedType getGenericReturnType();
/**
* Return full signature, including return type, e.g. "()LFastCar;". For a signature without the return type, use
* getParameterSignature() - it is important to choose the right one in the face of covariance.
*/
- public String getSignature();
+ String getSignature();
- public JoinPointSignatureIterator getJoinPointSignatures(World world);
+ JoinPointSignatureIterator getJoinPointSignatures(World world);
- public int getArity();
+ int getArity();
/**
* Return signature without return type, e.g. "()" for a signature *with* the return type, use getSignature() - it is important
* to choose the right one in the face of covariance.
*/
- public String getParameterSignature();
+ String getParameterSignature();
- public int getModifiers(World world);
+ int getModifiers(World world);
- public int getModifiers();
+ int getModifiers();
/**
* Returns true iff the member is generic (NOT parameterized)
*/
- public boolean canBeParameterized();
+ boolean canBeParameterized();
- public AnnotationAJ[] getAnnotations();
+ AnnotationAJ[] getAnnotations();
- public Collection getDeclaringTypes(World world);
+ Collection getDeclaringTypes(World world);
- public String[] getParameterNames(World world);
+ String[] getParameterNames(World world);
- public UnresolvedType[] getExceptions(World world);
+ UnresolvedType[] getExceptions(World world);
- public ResolvedMember resolve(World world);
+ ResolvedMember resolve(World world);
- public int compareTo(Member other);
+ int compareTo(Member other);
-}
\ No newline at end of file
+}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ReferenceTypeDelegate.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ReferenceTypeDelegate.java
index e07c032e6..3dcea23b9 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ReferenceTypeDelegate.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ReferenceTypeDelegate.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2002 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * PARC initial implementation
* Andy Clement - June 2005 - separated out from ResolvedType
* ******************************************************************/
package org.aspectj.weaver;
@@ -25,124 +25,124 @@ import org.aspectj.weaver.patterns.PerClause;
public interface ReferenceTypeDelegate {
- public boolean isAspect();
+ boolean isAspect();
/**
* @return true if the type is an annotation style aspect (a type marked @Aspect)
*/
- public boolean isAnnotationStyleAspect();
+ boolean isAnnotationStyleAspect();
- public boolean isInterface();
+ boolean isInterface();
- public boolean isEnum();
+ boolean isEnum();
- public boolean isAnnotation();
+ boolean isAnnotation();
- public String getRetentionPolicy();
+ String getRetentionPolicy();
/**
* @return true if this annotation type can be on a regular type (ie. it doesn't specify anything or it specifies TYPE)
*/
- public boolean canAnnotationTargetType();
+ boolean canAnnotationTargetType();
/**
* @return all the possible targets that this annotation can be placed upon
*/
- public AnnotationTargetKind[] getAnnotationTargetKinds();
+ AnnotationTargetKind[] getAnnotationTargetKinds();
/**
* @return true if this annotation type has a retention policy of RUNTIME
*/
- public boolean isAnnotationWithRuntimeRetention();
+ boolean isAnnotationWithRuntimeRetention();
- public boolean isClass();
+ boolean isClass();
- public boolean isGeneric();
+ boolean isGeneric();
- public boolean isAnonymous();
+ boolean isAnonymous();
/**
* @return true if this class is nested (this includes: member classes, local classes, anonymous classes)
*/
- public boolean isNested();
+ boolean isNested();
- public boolean hasAnnotation(UnresolvedType ofType);
+ boolean hasAnnotation(UnresolvedType ofType);
- public AnnotationAJ[] getAnnotations();
+ AnnotationAJ[] getAnnotations();
- public ResolvedType[] getAnnotationTypes();
+ ResolvedType[] getAnnotationTypes();
- public ResolvedMember[] getDeclaredFields();
+ ResolvedMember[] getDeclaredFields();
- public ResolvedType[] getDeclaredInterfaces();
+ ResolvedType[] getDeclaredInterfaces();
- public ResolvedMember[] getDeclaredMethods();
+ ResolvedMember[] getDeclaredMethods();
- public ResolvedMember[] getDeclaredPointcuts();
+ ResolvedMember[] getDeclaredPointcuts();
- public TypeVariable[] getTypeVariables();
+ TypeVariable[] getTypeVariables();
- public int getModifiers();
+ int getModifiers();
// aspect declaration related members
/**
* @return for an aspect declaration, return the
*/
- public PerClause getPerClause();
+ PerClause getPerClause();
- public Collection getDeclares();
+ Collection getDeclares();
- public Collection getTypeMungers();
+ Collection getTypeMungers();
- public Collection getPrivilegedAccesses();
+ Collection getPrivilegedAccesses();
// end of aspect declaration related members
- public ResolvedType getSuperclass();
+ ResolvedType getSuperclass();
- public WeaverStateInfo getWeaverState();
+ WeaverStateInfo getWeaverState();
- public ReferenceType getResolvedTypeX();
+ ReferenceType getResolvedTypeX();
// needs renaming isWeavable or removing from here
- public boolean isExposedToWeaver();
+ boolean isExposedToWeaver();
- public boolean doesNotExposeShadowMungers();
+ boolean doesNotExposeShadowMungers();
- public ISourceContext getSourceContext();
+ ISourceContext getSourceContext();
- public String getSourcefilename();
+ String getSourcefilename();
- public String getDeclaredGenericSignature();
+ String getDeclaredGenericSignature();
- public ResolvedType getOuterClass();
+ ResolvedType getOuterClass();
- public boolean copySourceContext();
+ boolean copySourceContext();
/**
* TODO Caching of methods besides getDeclaredInterfaces() may also be dependent on this flag - which?
- *
+ *
* @return true if something the result of getDeclaredInterfaces() can be cached by the caller
*/
- public boolean isCacheable();
+ boolean isCacheable();
/**
* If known, return the compiler/weaver version used to build this delegate. Default is the most recent level as specified in
* {@link WeaverVersionInfo}.
- *
+ *
* @return the major version
*/
- public int getCompilerVersion();
+ int getCompilerVersion();
/**
* Implementations need to clear state
*/
- public void ensureConsistent();
+ void ensureConsistent();
- public boolean isWeavable();
+ boolean isWeavable();
- public boolean hasBeenWoven();
+ boolean hasBeenWoven();
- public boolean hasAnnotations();
+ boolean hasAnnotations();
-}
\ No newline at end of file
+}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ResolvedMember.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ResolvedMember.java
index 0b5def29a..39ab054b2 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ResolvedMember.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/ResolvedMember.java
@@ -1,15 +1,15 @@
/* *******************************************************************
* Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
* 2005 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
* PARC initial implementation
- * AMC extracted as interface
+ * AMC extracted as interface
* ******************************************************************/
package org.aspectj.weaver;
@@ -21,138 +21,138 @@ import org.aspectj.bridge.ISourceLocation;
public interface ResolvedMember extends Member, AnnotatedElement, TypeVariableDeclaringElement {
- public static final ResolvedMember[] NONE = new ResolvedMember[0];
+ ResolvedMember[] NONE = new ResolvedMember[0];
- public int getModifiers(World world);
+ int getModifiers(World world);
- public int getModifiers();
+ int getModifiers();
- public UnresolvedType[] getExceptions(World world);
+ UnresolvedType[] getExceptions(World world);
- public UnresolvedType[] getExceptions();
+ UnresolvedType[] getExceptions();
- public ShadowMunger getAssociatedShadowMunger();
+ ShadowMunger getAssociatedShadowMunger();
- public boolean isAjSynthetic();
+ boolean isAjSynthetic();
- public boolean isCompatibleWith(Member am);
+ boolean isCompatibleWith(Member am);
- public boolean hasAnnotation(UnresolvedType ofType);
+ boolean hasAnnotation(UnresolvedType ofType);
- public AnnotationAJ[] getAnnotations();
+ AnnotationAJ[] getAnnotations();
- public ResolvedType[] getAnnotationTypes();
+ ResolvedType[] getAnnotationTypes();
- public void setAnnotationTypes(ResolvedType[] annotationtypes);
+ void setAnnotationTypes(ResolvedType[] annotationtypes);
- public void addAnnotation(AnnotationAJ annotation);
+ void addAnnotation(AnnotationAJ annotation);
- public boolean isBridgeMethod();
+ boolean isBridgeMethod();
- public boolean isVarargsMethod();
+ boolean isVarargsMethod();
- public boolean isSynthetic();
+ boolean isSynthetic();
- public void write(CompressingDataOutputStream s) throws IOException;
+ void write(CompressingDataOutputStream s) throws IOException;
- public ISourceContext getSourceContext(World world);
+ ISourceContext getSourceContext(World world);
- public String[] getParameterNames();
+ String[] getParameterNames();
- public void setParameterNames(String[] names);
+ void setParameterNames(String[] names);
- public AnnotationAJ[][] getParameterAnnotations();
+ AnnotationAJ[][] getParameterAnnotations();
- public ResolvedType[][] getParameterAnnotationTypes();
+ ResolvedType[][] getParameterAnnotationTypes();
- public String getAnnotationDefaultValue();
+ String getAnnotationDefaultValue();
- public String getParameterSignatureErased();
+ String getParameterSignatureErased();
- public String getSignatureErased();
+ String getSignatureErased();
- public String[] getParameterNames(World world);
+ String[] getParameterNames(World world);
- public AjAttribute.EffectiveSignatureAttribute getEffectiveSignature();
+ AjAttribute.EffectiveSignatureAttribute getEffectiveSignature();
- public ISourceLocation getSourceLocation();
+ ISourceLocation getSourceLocation();
- public int getStart();
+ int getStart();
- public int getEnd();
+ int getEnd();
- public ISourceContext getSourceContext();
+ ISourceContext getSourceContext();
- public void setPosition(int sourceStart, int sourceEnd);
+ void setPosition(int sourceStart, int sourceEnd);
- public void setSourceContext(ISourceContext sourceContext);
+ void setSourceContext(ISourceContext sourceContext);
- public boolean isAbstract();
+ boolean isAbstract();
- public boolean isPublic();
+ boolean isPublic();
- public boolean isDefault();
+ boolean isDefault();
- public boolean isVisible(ResolvedType fromType);
+ boolean isVisible(ResolvedType fromType);
- public void setCheckedExceptions(UnresolvedType[] checkedExceptions);
+ void setCheckedExceptions(UnresolvedType[] checkedExceptions);
- public void setAnnotatedElsewhere(boolean b);
+ void setAnnotatedElsewhere(boolean b);
- public boolean isAnnotatedElsewhere();
+ boolean isAnnotatedElsewhere();
// like toString but include generic signature info
- public String toGenericString();
+ String toGenericString();
- public String toDebugString();
+ String toDebugString();
- public boolean hasBackingGenericMember();
+ boolean hasBackingGenericMember();
- public ResolvedMember getBackingGenericMember();
+ ResolvedMember getBackingGenericMember();
/**
* Get the UnresolvedType for the return type, taking generic signature into account
*/
- public UnresolvedType getGenericReturnType();
+ UnresolvedType getGenericReturnType();
/**
* Get the TypeXs of the parameter types, taking generic signature into account
*/
- public UnresolvedType[] getGenericParameterTypes();
+ UnresolvedType[] getGenericParameterTypes();
- public boolean equalsApartFromDeclaringType(Object other);
+ boolean equalsApartFromDeclaringType(Object other);
// return a resolved member in which all type variables in the signature of
// this member have been replaced with the given bindings. the isParameterized flag tells us whether we are creating a raw type
// version or not
// if isParameterized List will turn into List (for example),
// but if !isParameterized List will turn into List.
- public ResolvedMemberImpl parameterizedWith(UnresolvedType[] typeParameters, ResolvedType newDeclaringType,
- boolean isParameterized);
+ ResolvedMemberImpl parameterizedWith(UnresolvedType[] typeParameters, ResolvedType newDeclaringType,
+ boolean isParameterized);
// this variant allows for aliases for type variables (i.e. allowing them to
// have another name)
// this is used for processing ITDs that share type variables with their
// target generic type
- public ResolvedMemberImpl parameterizedWith(UnresolvedType[] typeParameters, ResolvedType newDeclaringType,
- boolean isParameterized, List aliases);
+ ResolvedMemberImpl parameterizedWith(UnresolvedType[] typeParameters, ResolvedType newDeclaringType,
+ boolean isParameterized, List aliases);
- public void setTypeVariables(TypeVariable[] types);
+ void setTypeVariables(TypeVariable[] types);
- public TypeVariable[] getTypeVariables();
+ TypeVariable[] getTypeVariables();
/**
* Returns true if this member matches the other. The matching takes into account name and parameter types only. When comparing
* parameter types, we allow any type variable to match any other type variable regardless of bounds.
*/
- public boolean matches(ResolvedMember aCandidateMatch, boolean ignoreGenerics);
+ boolean matches(ResolvedMember aCandidateMatch, boolean ignoreGenerics);
- public void evictWeavingState();
+ void evictWeavingState();
- public ResolvedMember parameterizedWith(Map m, World w);
+ ResolvedMember parameterizedWith(Map m, World w);
- public boolean isDefaultConstructor();
+ boolean isDefaultConstructor();
- public void setAnnotations(AnnotationAJ[] annotations);
+ void setAnnotations(AnnotationAJ[] annotations);
-}
\ No newline at end of file
+}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/TypeVariableDeclaringElement.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/TypeVariableDeclaringElement.java
index ae41fd09c..a8729bae5 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/TypeVariableDeclaringElement.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/TypeVariableDeclaringElement.java
@@ -1,12 +1,12 @@
/* *******************************************************************
* Copyright (c) 2005 Contributors.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
- *
- * Contributors:
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
* Andy Clement Initial implementation
* ******************************************************************/
@@ -17,5 +17,5 @@ package org.aspectj.weaver;
* declaring element
*/
public interface TypeVariableDeclaringElement {
- public TypeVariable getTypeVariableNamed(String name);
+ TypeVariable getTypeVariableNamed(String name);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IToken.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IToken.java
index aa925fd69..824bc602f 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IToken.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IToken.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * PARC initial implementation
* ******************************************************************/
@@ -16,38 +16,38 @@ package org.aspectj.weaver.patterns;
import org.aspectj.weaver.IHasPosition;
public interface IToken extends IHasPosition {
- public static final IToken EOF = BasicToken.makeOperator("", 0, 0);
-
+ IToken EOF = BasicToken.makeOperator("", 0, 0);
+
/**
* Returns the string value of this token.
- *
+ *
* If isIdentifier is false, then this string must be intern'd
* so that == matching can be used.
- *
+ *
* If isIdentifier is true, interning is not required.
*/
- public String getString();
-
+ String getString();
+
/**
* Whether this should be treated as a token or a generic identifier
*/
- public boolean isIdentifier();
-
+ boolean isIdentifier();
+
/**
* Whether this should be treated as a literal value
- *
+ *
* Kinds == "string", ???
- *
+ *
* returns null if this isn't a literal
*/
- public String getLiteralKind();
-
-
+ String getLiteralKind();
+
+
/**
* If this token represents a pre-parsed Pointcut, then return it;
* otherwise returns null.
- *
+ *
* Needed for the implementation of 'if'
*/
- public Pointcut maybeGetParsedPointcut();
+ Pointcut maybeGetParsedPointcut();
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/ITokenSource.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/ITokenSource.java
index 4649b046f..577c97b2c 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/ITokenSource.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/ITokenSource.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * PARC initial implementation
* ******************************************************************/
@@ -17,11 +17,11 @@ import org.aspectj.weaver.ISourceContext;
public interface ITokenSource {
- public IToken next();
- public IToken peek();
- public IToken peek(int offset);
- public int getIndex();
- public void setIndex(int newIndex);
- public ISourceContext getSourceContext();
- public boolean hasMoreTokens();
+ IToken next();
+ IToken peek();
+ IToken peek(int offset);
+ int getIndex();
+ void setIndex(int newIndex);
+ ISourceContext getSourceContext();
+ boolean hasMoreTokens();
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IVerificationRequired.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IVerificationRequired.java
index f1ce19eff..4247f6714 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IVerificationRequired.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/patterns/IVerificationRequired.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2006 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement IBM initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Andy Clement IBM initial implementation
* ******************************************************************/
package org.aspectj.weaver.patterns;
@@ -18,5 +18,5 @@ package org.aspectj.weaver.patterns;
* @see WildTypePattern.VerifyBoundsForTypePattern
*/
public interface IVerificationRequired {
- public void verify();
-}
\ No newline at end of file
+ void verify();
+}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/AnnotationFinder.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/AnnotationFinder.java
index 90ce368d9..040d73d49 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/AnnotationFinder.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/AnnotationFinder.java
@@ -1,12 +1,12 @@
/* *******************************************************************
* Copyright (c) 2005, 2017 Contributors.
- *
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
- *
+ *
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
+ *
* ******************************************************************/
package org.aspectj.weaver.reflect;
@@ -31,9 +31,9 @@ public interface AnnotationFinder {
Object getAnnotationFromMember(ResolvedType annotationType, Member aMember);
- public AnnotationAJ getAnnotationOfType(UnresolvedType ofType, Member onMember);
+ AnnotationAJ getAnnotationOfType(UnresolvedType ofType, Member onMember);
- public String getAnnotationDefaultValue(Member onMember);
+ String getAnnotationDefaultValue(Member onMember);
Object getAnnotationFromClass(ResolvedType annotationType, Class> aClass);
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/IReflectionWorld.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/IReflectionWorld.java
index 60d90d357..e835c4664 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/IReflectionWorld.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/reflect/IReflectionWorld.java
@@ -1,19 +1,19 @@
/* *******************************************************************
* Copyright (c) 2005 Contributors
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Ron Bodkin initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Ron Bodkin initial implementation
* ******************************************************************/
package org.aspectj.weaver.reflect;
import org.aspectj.weaver.ResolvedType;
public interface IReflectionWorld {
- public AnnotationFinder getAnnotationFinder();
- public ResolvedType resolve(Class aClass);
+ AnnotationFinder getAnnotationFinder();
+ ResolvedType resolve(Class aClass);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/GeneratedClassHandler.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/GeneratedClassHandler.java
index 6dd4fec18..97fc994b3 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/GeneratedClassHandler.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/GeneratedClassHandler.java
@@ -1,14 +1,14 @@
/* *******************************************************************
* Copyright (c) 2004 IBM Corporation
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Matthew Webster, Adrian Colyer,
- * Martin Lippert initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Matthew Webster, Adrian Colyer,
+ * Martin Lippert initial implementation
* ******************************************************************/
package org.aspectj.weaver.tools;
@@ -17,7 +17,7 @@ package org.aspectj.weaver.tools;
* the weaving process to be defined.
*/
public interface GeneratedClassHandler {
-
+
/**
* Accept class generated by WeavingAdaptor. The class loader should store
* the class definition in its local cache until called upon to load it.
@@ -25,6 +25,6 @@ public interface GeneratedClassHandler {
* @param originalBytes original class bytes
* @param weavedBytes woven class bytes
*/
- public void acceptClass (String name, byte[] originalBytes, byte[] weavedBytes);
+ void acceptClass(String name, byte[] originalBytes, byte[] weavedBytes);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/ISupportsMessageContext.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/ISupportsMessageContext.java
index 69e55b143..2201964e4 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/ISupportsMessageContext.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/ISupportsMessageContext.java
@@ -1,10 +1,10 @@
/*******************************************************************************
* Copyright (c) 2006 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
+ * All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* Matthew Webster - initial implementation
*******************************************************************************/
@@ -14,5 +14,5 @@ import org.aspectj.bridge.IMessageContext;
public interface ISupportsMessageContext {
- public void setMessageContext (IMessageContext messageContext);
+ void setMessageContext(IMessageContext messageContext);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Trace.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Trace.java
index 8b20032aa..c0ce182a2 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Trace.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Trace.java
@@ -1,10 +1,10 @@
/*******************************************************************************
* Copyright (c) 2006 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
+ * All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* Matthew Webster - initial implementation
*******************************************************************************/
@@ -12,47 +12,47 @@ package org.aspectj.weaver.tools;
public interface Trace {
- public void enter(String methodName, Object thiz, Object[] args);
+ void enter(String methodName, Object thiz, Object[] args);
- public void enter(String methodName, Object thiz);
+ void enter(String methodName, Object thiz);
- public void exit(String methodName, Object ret);
+ void exit(String methodName, Object ret);
- public void exit(String methodName, Throwable th);
+ void exit(String methodName, Throwable th);
- public void exit(String methodName);
+ void exit(String methodName);
- public void event(String methodName);
+ void event(String methodName);
- public void event(String methodName, Object thiz, Object[] args);
+ void event(String methodName, Object thiz, Object[] args);
- public void debug(String message);
+ void debug(String message);
- public void info(String message);
+ void info(String message);
- public void warn(String message);
+ void warn(String message);
- public void warn(String message, Throwable th);
+ void warn(String message, Throwable th);
- public void error(String message);
+ void error(String message);
- public void error(String message, Throwable th);
+ void error(String message, Throwable th);
- public void fatal(String message);
+ void fatal(String message);
- public void fatal(String message, Throwable th);
+ void fatal(String message, Throwable th);
- public void enter(String methodName, Object thiz, Object arg);
+ void enter(String methodName, Object thiz, Object arg);
- public void enter(String methodName, Object thiz, boolean z);
+ void enter(String methodName, Object thiz, boolean z);
- public void exit(String methodName, boolean b);
+ void exit(String methodName, boolean b);
- public void exit(String methodName, int i);
+ void exit(String methodName, int i);
- public void event(String methodName, Object thiz, Object arg);
+ void event(String methodName, Object thiz, Object arg);
- public boolean isTraceEnabled();
+ boolean isTraceEnabled();
- public void setTraceEnabled(boolean b);
-}
\ No newline at end of file
+ void setTraceEnabled(boolean b);
+}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Traceable.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Traceable.java
index 957786e48..5971e9eb4 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Traceable.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/Traceable.java
@@ -1,10 +1,10 @@
/*******************************************************************************
* Copyright (c) 2006 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
+ * All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* Matthew Webster - initial implementation
*******************************************************************************/
@@ -12,6 +12,6 @@ package org.aspectj.weaver.tools;
public interface Traceable {
- public String toTraceString ();
-
+ String toTraceString();
+
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/TypePatternMatcher.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/TypePatternMatcher.java
index be3b84025..3ea8a756e 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/TypePatternMatcher.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/TypePatternMatcher.java
@@ -1,11 +1,11 @@
/* *******************************************************************
* Copyright (c) 2004 IBM Corporation.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
* ******************************************************************/
package org.aspectj.weaver.tools;
@@ -19,5 +19,5 @@ public interface TypePatternMatcher {
* Does this type pattern matcher match the
* given type (Class).
*/
- public boolean matches(Class aClass);
+ boolean matches(Class aClass);
}
diff --git a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/WeavingClassLoader.java b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/WeavingClassLoader.java
index 84987e19b..38e801616 100644
--- a/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/WeavingClassLoader.java
+++ b/org.aspectj.matcher/src/main/java/org/aspectj/weaver/tools/WeavingClassLoader.java
@@ -1,14 +1,14 @@
/* *******************************************************************
* Copyright (c) 2004 IBM Corporation
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Matthew Webster, Adrian Colyer,
- * Martin Lippert initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Matthew Webster, Adrian Colyer,
+ * Martin Lippert initial implementation
* ******************************************************************/
package org.aspectj.weaver.tools;
@@ -20,12 +20,12 @@ import java.net.URL;
* WeavingAdaptor.
*/
public interface WeavingClassLoader extends GeneratedClassHandler {
-
+
/**
* Returns the aspects to be used by a WeavingAdaptor to weave classes
* defined by the class loader.
* @return the aspects used for weaving classes.
*/
- public URL[] getAspectURLs ();
+ URL[] getAspectURLs();
}
diff --git a/runtime/src/main/java/org/aspectj/lang/JoinPoint.java b/runtime/src/main/java/org/aspectj/lang/JoinPoint.java
index 78ffce265..03c834e7a 100644
--- a/runtime/src/main/java/org/aspectj/lang/JoinPoint.java
+++ b/runtime/src/main/java/org/aspectj/lang/JoinPoint.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
@@ -56,7 +56,7 @@ public interface JoinPoint {
*
* Returns null when there is no currently executing object available.
* This includes all join points that occur in a static context.
- *
+ *
* @return the currently executing object (or null if not available - e.g. static context)
*/
Object getThis();
@@ -69,7 +69,7 @@ public interface JoinPoint {
* get at this object for better static typing and performance.
*
* Returns null when there is no target object
- *
+ *
* @return the target object (or null if there isn't one)
*/
Object getTarget();
@@ -85,21 +85,21 @@ public interface JoinPoint {
*/
Signature getSignature();
- /**
+ /**
*
* If there is no source location available, returns null.
*
* Returns the SourceLocation of the defining class for default constructors.
*
* getStaticPart().getSourceLocation()
returns the same object.
- *
+ *
* @return the source location corresponding to the join point.
*/
SourceLocation getSourceLocation();
/** This string is guaranteed to be interned.
* getStaticPart().getKind()
returns the same object.
- *
+ *
* @return a string representing the kind of join point.
*/
String getKind();
@@ -129,7 +129,7 @@ public interface JoinPoint {
*
* @see JoinPoint#getStaticPart()
*/
- public interface StaticPart {
+ interface StaticPart {
/** @return the signature at the join point. */
Signature getSignature();
@@ -145,14 +145,14 @@ public interface JoinPoint {
* is guaranteed to be interned
*/
String getKind();
-
+
/**
* Return the id for this JoinPoint.StaticPart. All JoinPoint.StaticPart
- * instances are assigned an id number upon creation. For each advised type
+ * instances are assigned an id number upon creation. For each advised type
* the id numbers start at 0.
*
- * The id is guaranteed to remain constant across repeated executions
- * of a program but may change if the code is recompiled.
+ * The id is guaranteed to remain constant across repeated executions
+ * of a program but may change if the code is recompiled.
*
* The benefit of having an id is that it can be used for array index
* purposes which can be quicker than using the JoinPoint.StaticPart
@@ -162,7 +162,7 @@ public interface JoinPoint {
* the same id, then if the id is being used to index some joinpoint specific
* state then that state must be maintained on a pertype basis - either by
* using pertypewithin() or an ITD.
- *
+ *
* @return the id of this joinpoint
*/
int getId();
@@ -180,7 +180,7 @@ public interface JoinPoint {
String toLongString();
}
- public interface EnclosingStaticPart extends StaticPart {}
+ interface EnclosingStaticPart extends StaticPart {}
/**
* @return an object that encapsulates the static parts of this join point.
@@ -191,19 +191,19 @@ public interface JoinPoint {
/**
* The legal return values from getKind()
*/
- static String METHOD_EXECUTION = "method-execution";
- static String METHOD_CALL = "method-call";
- static String CONSTRUCTOR_EXECUTION = "constructor-execution";
- static String CONSTRUCTOR_CALL = "constructor-call";
- static String FIELD_GET = "field-get";
- static String FIELD_SET = "field-set";
- static String STATICINITIALIZATION = "staticinitialization";
- static String PREINITIALIZATION = "preinitialization";
- static String INITIALIZATION = "initialization";
- static String EXCEPTION_HANDLER = "exception-handler";
- static String SYNCHRONIZATION_LOCK = "lock";
- static String SYNCHRONIZATION_UNLOCK = "unlock";
-
- static String ADVICE_EXECUTION = "adviceexecution";
+ String METHOD_EXECUTION = "method-execution";
+ String METHOD_CALL = "method-call";
+ String CONSTRUCTOR_EXECUTION = "constructor-execution";
+ String CONSTRUCTOR_CALL = "constructor-call";
+ String FIELD_GET = "field-get";
+ String FIELD_SET = "field-set";
+ String STATICINITIALIZATION = "staticinitialization";
+ String PREINITIALIZATION = "preinitialization";
+ String INITIALIZATION = "initialization";
+ String EXCEPTION_HANDLER = "exception-handler";
+ String SYNCHRONIZATION_LOCK = "lock";
+ String SYNCHRONIZATION_UNLOCK = "unlock";
+
+ String ADVICE_EXECUTION = "adviceexecution";
}
diff --git a/runtime/src/main/java/org/aspectj/lang/ProceedingJoinPoint.java b/runtime/src/main/java/org/aspectj/lang/ProceedingJoinPoint.java
index ac85681ef..8d4d2fe57 100644
--- a/runtime/src/main/java/org/aspectj/lang/ProceedingJoinPoint.java
+++ b/runtime/src/main/java/org/aspectj/lang/ProceedingJoinPoint.java
@@ -48,31 +48,31 @@ public interface ProceedingJoinPoint extends JoinPoint {
* @return the result of proceeding
* @throws Throwable if the invoked proceed throws anything
*/
- public Object proceed() throws Throwable;
+ Object proceed() throws Throwable;
/**
* Proceed with the next advice or target method invocation.
*
- * Unlike code style, proceed(..) in annotation style places different requirements on the
+ * Unlike code style, proceed(..) in annotation style places different requirements on the
* parameters passed to it. The proceed(..) call takes, in this order:
*
* - If 'this()' was used in the pointcut for binding, it must be passed first in proceed(..).
- *
- If 'target()' was used in the pointcut for binding, it must be passed next in proceed(..) -
+ *
- If 'target()' was used in the pointcut for binding, it must be passed next in proceed(..) -
* it will be the first argument to proceed(..) if this() was not used for binding.
- *
- Finally come all the arguments expected at the join point, in the order they are supplied
- * at the join point. Effectively the advice signature is ignored - it doesn't matter
- * if a subset of arguments were bound or the ordering was changed in the advice signature,
- * the proceed(..) calls takes all of them in the right order for the join point.
+ *
- Finally come all the arguments expected at the join point, in the order they are supplied
+ * at the join point. Effectively the advice signature is ignored - it doesn't matter
+ * if a subset of arguments were bound or the ordering was changed in the advice signature,
+ * the proceed(..) calls takes all of them in the right order for the join point.
*
- * Since proceed(..) in this case takes an Object array, AspectJ cannot do as much
- * compile time checking as it can for code style. If the rules above aren't obeyed
- * then it will unfortunately manifest as a runtime error.
+ * Since proceed(..) in this case takes an Object array, AspectJ cannot do as much
+ * compile time checking as it can for code style. If the rules above aren't obeyed
+ * then it will unfortunately manifest as a runtime error.
*
* @param args the arguments to proceed with
* @return the result of proceeding
* @throws Throwable if the invoked proceed throws anything
*/
- public Object proceed(Object[] args) throws Throwable;
+ Object proceed(Object[] args) throws Throwable;
}
diff --git a/runtime/src/main/java/org/aspectj/lang/annotation/Aspect.java b/runtime/src/main/java/org/aspectj/lang/annotation/Aspect.java
index 7e50fa75b..7db0814ad 100644
--- a/runtime/src/main/java/org/aspectj/lang/annotation/Aspect.java
+++ b/runtime/src/main/java/org/aspectj/lang/annotation/Aspect.java
@@ -29,5 +29,5 @@ public @interface Aspect {
* @return the per clause expression, defaults to singleton aspect.
* Valid values are "" (singleton), "perthis(...)", etc
*/
- public String value() default "";
+ String value() default "";
}
diff --git a/runtime/src/main/java/org/aspectj/lang/annotation/DeclareAnnotation.java b/runtime/src/main/java/org/aspectj/lang/annotation/DeclareAnnotation.java
index f0c564dd3..d6b730be6 100644
--- a/runtime/src/main/java/org/aspectj/lang/annotation/DeclareAnnotation.java
+++ b/runtime/src/main/java/org/aspectj/lang/annotation/DeclareAnnotation.java
@@ -1,11 +1,11 @@
/*******************************************************************************
* Copyright (c) 2005 Contributors.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
- *
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
+ *
* Contributors:
* Alexandre Vasseur initial implementation
*******************************************************************************/
@@ -26,6 +26,6 @@ public @interface DeclareAnnotation {
/**
* @return the pointcut (type pattern for type, or method/ctor/field signature pattern)
*/
- public String value();
-
+ String value();
+
}
diff --git a/runtime/src/main/java/org/aspectj/lang/reflect/AjType.java b/runtime/src/main/java/org/aspectj/lang/reflect/AjType.java
index 2ceddb952..a4b3aab4c 100644
--- a/runtime/src/main/java/org/aspectj/lang/reflect/AjType.java
+++ b/runtime/src/main/java/org/aspectj/lang/reflect/AjType.java
@@ -1,12 +1,12 @@
/* *******************************************************************
* Copyright (c) 2005 Contributors.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
- *
- * Contributors:
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
* Adrian Colyer Initial implementation
* ******************************************************************/
package org.aspectj.lang.reflect;
@@ -23,134 +23,134 @@ import java.lang.reflect.TypeVariable;
* program.
*/
public interface AjType extends Type, AnnotatedElement {
-
+
/**
* @return the name of this type, in the same format as returned by Class.getName()
*/
- public String getName();
-
+ String getName();
+
/**
* @return the package in which this type is declared
*/
- public Package getPackage();
-
+ Package getPackage();
+
/**
* @return the interfaces implemented by this type
*/
- public AjType>[] getInterfaces();
-
+ AjType>[] getInterfaces();
+
/**
* @return the modifiers declared for this type. The return value can be interpreted
* using java.lang.reflect.Modifier
*/
- public int getModifiers();
-
+ int getModifiers();
+
/**
* @return the java.lang.Class that corresponds to this AjType
*/
- public Class getJavaClass();
+ Class getJavaClass();
// scope
-
+
/**
* @return the supertype of this type. If this type represents Object or a primitive type
* then null is returned.
*/
- public AjType> getSupertype();
+ AjType> getSupertype();
/**
* @return the generic supertype of this type, as defined by Class.getGenericSupertype
*/
- public Type getGenericSupertype();
+ Type getGenericSupertype();
/**
* @return the enclosing Method if this type represents a local or anonymous type declared within a method
*/
- public Method getEnclosingMethod();
-
+ Method getEnclosingMethod();
+
/**
* @return the enclosing Method if this type represents a local or anonymous type declared within a constructor
*/
- public Constructor getEnclosingConstructor();
+ Constructor getEnclosingConstructor();
/**
* @return the immediately enclosing type of this type.
*/
- public AjType> getEnclosingType();
-
+ AjType> getEnclosingType();
+
/**
* @return the AjType representing the typei n which it was declared (if this type is a member of another type)
*/
- public AjType> getDeclaringType();
+ AjType> getDeclaringType();
/**
* @return the per-clause if this is an aspect, otherwise null
*/
- public PerClause getPerClause();
-
+ PerClause getPerClause();
+
// inner types
/**
* @return an array containing all the public types that are members of this type
*/
- public AjType>[] getAjTypes();
-
+ AjType>[] getAjTypes();
+
/**
* @return an array containing all the types declared by this type
*/
- public AjType>[] getDeclaredAjTypes();
-
+ AjType>[] getDeclaredAjTypes();
+
// constructors
-
+
/**
* @param parameterTypes the types of the constructor parameters
* @return the constructor object for the specified public constructor of this type
* @throws NoSuchMethodException if constructor not found
*/
- public Constructor getConstructor(AjType>... parameterTypes) throws NoSuchMethodException;
-
+ Constructor getConstructor(AjType>... parameterTypes) throws NoSuchMethodException;
+
/**
* @return all of the public constructors of this type
*/
- public Constructor[] getConstructors();
-
+ Constructor[] getConstructors();
+
/**
* @param parameterTypes the types of the constructor parameters
* @return the constructor object for the specified constructor of this type
* @throws NoSuchMethodException if constructor not found
*/
- public Constructor getDeclaredConstructor(AjType>... parameterTypes) throws NoSuchMethodException;
+ Constructor getDeclaredConstructor(AjType>... parameterTypes) throws NoSuchMethodException;
/**
* @return all the constructors declared in this type
*/
- public Constructor[] getDeclaredConstructors();
-
+ Constructor[] getDeclaredConstructors();
+
// fields
-
+
/**
* @param name the field name
* @return the declared field
* @throws NoSuchFieldException if no field of that name is found
*/
- public Field getDeclaredField(String name) throws NoSuchFieldException;
-
- /**
+ Field getDeclaredField(String name) throws NoSuchFieldException;
+
+ /**
* @return all the fields declared in this type
*/
- public Field[] getDeclaredFields();
-
+ Field[] getDeclaredFields();
+
/**
* @param name the field name
- * @return the public field with the given name
+ * @return the public field with the given name
* @throws NoSuchFieldException if field not found
*/
- public Field getField(String name) throws NoSuchFieldException;
-
+ Field getField(String name) throws NoSuchFieldException;
+
/**
* @return the public fields declared by this type
*/
- public Field[] getFields();
-
+ Field[] getFields();
+
// methods
/**
@@ -159,52 +159,52 @@ public interface AjType extends Type, AnnotatedElement {
* @return the method object for the specified method declared in this type
* @throws NoSuchMethodException if the method cannot be found
*/
- public Method getDeclaredMethod(String name, AjType>... parameterTypes) throws NoSuchMethodException;
-
+ Method getDeclaredMethod(String name, AjType>... parameterTypes) throws NoSuchMethodException;
+
/**
* @param name the method name
* @param parameterTypes the types of the method parameters
- * @return the method object for the specified public method declared in this type
+ * @return the method object for the specified public method declared in this type
* @throws NoSuchMethodException if the method cannot be found
*/
- public Method getMethod(String name, AjType>... parameterTypes) throws NoSuchMethodException;
-
+ Method getMethod(String name, AjType>... parameterTypes) throws NoSuchMethodException;
+
/**
* @return all the methods declared by this type
*/
- public Method[] getDeclaredMethods();
-
+ Method[] getDeclaredMethods();
+
/**
* @return all the public methods of this type
*/
- public Method[] getMethods();
-
+ Method[] getMethods();
+
// pointcuts
-
+
/**
* @param name the pointcut name
* @return the pointcut object representing the specified pointcut declared by this type
* @throws NoSuchPointcutException if no pointcut of that name can be found
*/
- public Pointcut getDeclaredPointcut(String name) throws NoSuchPointcutException;
-
+ Pointcut getDeclaredPointcut(String name) throws NoSuchPointcutException;
+
/**
* @param name the pointcut name
* @return the pointcut object representing the specified public pointcut
* @throws NoSuchPointcutException if no pointcut of that name can be found
*/
- public Pointcut getPointcut(String name) throws NoSuchPointcutException;
+ Pointcut getPointcut(String name) throws NoSuchPointcutException;
/**
* @return all of the pointcuts declared by this type
*/
- public Pointcut[] getDeclaredPointcuts();
+ Pointcut[] getDeclaredPointcuts();
/**
* @return all of the public pointcuts of this type
*/
- public Pointcut[] getPointcuts();
-
+ Pointcut[] getPointcuts();
+
// advice
/**
@@ -212,38 +212,38 @@ public interface AjType extends Type, AnnotatedElement {
* @return all of the advice declared by this type, of an advice kind contained in the
* parameter list.
*/
- public Advice[] getDeclaredAdvice(AdviceKind... ofTypes);
-
+ Advice[] getDeclaredAdvice(AdviceKind... ofTypes);
+
/**
* @param ofTypes the {@link AdviceKind}s of interest
* @return all of the advice for this type, of an advice kind contained in the parameter
- * list.
+ * list.
*/
- public Advice[] getAdvice(AdviceKind... ofTypes);
-
+ Advice[] getAdvice(AdviceKind... ofTypes);
+
/**
* For an annotation style advice member,
* this is the name of the annotated method. For a code-style advice declaration, this
* is the name given in the @AdviceName annotation if present.
- *
+ *
* @param name the advice name
* @return the advice with the given name.
* @throws NoSuchAdviceException if no advice can be found with that name
*/
- public Advice getAdvice(String name) throws NoSuchAdviceException;
-
+ Advice getAdvice(String name) throws NoSuchAdviceException;
+
/** For an annotation style advice member,
* this is the name of the annotated method. For a code-style advice declaration, this
* is the name given in the @AdviceName annotation if present.
- *
+ *
* @param name the advice name
* @return the advice declared in this type with the given name.
* @throws NoSuchAdviceException if no advice can be found with that name
*/
- public Advice getDeclaredAdvice(String name) throws NoSuchAdviceException;
-
+ Advice getDeclaredAdvice(String name) throws NoSuchAdviceException;
+
// inter-type declarations
-
+
/**
* @param name the method name
* @param target the target of the inter-type declaration
@@ -251,12 +251,12 @@ public interface AjType extends Type, AnnotatedElement {
* @return the inter-type method declared by this type matching the given specification
* @throws NoSuchMethodException if the inter-type declaration cannot be found
*/
- public InterTypeMethodDeclaration getDeclaredITDMethod(String name, AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
-
+ InterTypeMethodDeclaration getDeclaredITDMethod(String name, AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
+
/**
* @return all of the inter-type methods declared by this type
*/
- public InterTypeMethodDeclaration[] getDeclaredITDMethods();
+ InterTypeMethodDeclaration[] getDeclaredITDMethods();
/**
* @param name the method name
@@ -265,25 +265,25 @@ public interface AjType extends Type, AnnotatedElement {
* @return the public inter-type method of this type matching the given specification
* @throws NoSuchMethodException if the inter-type declaration cannot be found
*/
- public InterTypeMethodDeclaration getITDMethod(String name, AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
-
+ InterTypeMethodDeclaration getITDMethod(String name, AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
+
/**
* @return all of the public inter-type declared methods of this type
*/
- public InterTypeMethodDeclaration[] getITDMethods();
-
+ InterTypeMethodDeclaration[] getITDMethods();
+
/**
* @param target the target of the inter-type constructor of interest
* @param parameterTypes the types of the parameter of the inter-type constructor of interest
* @return the inter-type constructor declared by this type matching the given specification
* @throws NoSuchMethodException if the inter-type declaration cannot be found
*/
- public InterTypeConstructorDeclaration getDeclaredITDConstructor(AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
-
+ InterTypeConstructorDeclaration getDeclaredITDConstructor(AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
+
/**
* @return all of the inter-type constructors declared by this type
*/
- public InterTypeConstructorDeclaration[] getDeclaredITDConstructors();
+ InterTypeConstructorDeclaration[] getDeclaredITDConstructors();
/**
* @param target the target of the inter-type constructor of interest
@@ -291,12 +291,12 @@ public interface AjType extends Type, AnnotatedElement {
* @return the public inter-type constructor matching the given specification
* @throws NoSuchMethodException if the inter-type declaration cannot be found
*/
- public InterTypeConstructorDeclaration getITDConstructor(AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
+ InterTypeConstructorDeclaration getITDConstructor(AjType> target, AjType>... parameterTypes) throws NoSuchMethodException;
/**
* @return all of the public inter-type constructors of this type
*/
- public InterTypeConstructorDeclaration[] getITDConstructors();
+ InterTypeConstructorDeclaration[] getITDConstructors();
/**
* @param name the field name
@@ -304,12 +304,12 @@ public interface AjType extends Type, AnnotatedElement {
* @return the inter-type field declared in this type with the given specification
* @throws NoSuchFieldException if the inter-type declaration cannot be found
*/
- public InterTypeFieldDeclaration getDeclaredITDField(String name, AjType> target) throws NoSuchFieldException;
+ InterTypeFieldDeclaration getDeclaredITDField(String name, AjType> target) throws NoSuchFieldException;
/**
* @return all of the inter-type fields declared in this type
*/
- public InterTypeFieldDeclaration[] getDeclaredITDFields();
+ InterTypeFieldDeclaration[] getDeclaredITDFields();
/**
* @param name the field name
@@ -317,108 +317,108 @@ public interface AjType extends Type, AnnotatedElement {
* @return the public inter-type field matching the given specification
* @throws NoSuchFieldException if the inter-type declaration cannot be found
*/
- public InterTypeFieldDeclaration getITDField(String name, AjType> target) throws NoSuchFieldException;
+ InterTypeFieldDeclaration getITDField(String name, AjType> target) throws NoSuchFieldException;
/**
* @return all of the public inter-type fields for this type
*/
- public InterTypeFieldDeclaration[] getITDFields();
-
+ InterTypeFieldDeclaration[] getITDFields();
+
// declare statements
/**
* @return all of the declare error and declare warning members of this type,
* including declare error/warning members inherited from super-types
*/
- public DeclareErrorOrWarning[] getDeclareErrorOrWarnings();
-
+ DeclareErrorOrWarning[] getDeclareErrorOrWarnings();
+
/**
* @return all of the declare parents members of this type, including
* declare parent members inherited from super-types
*/
- public DeclareParents[] getDeclareParents();
-
+ DeclareParents[] getDeclareParents();
+
/**
* @return all of the declare soft members of this type, including declare
* soft members inherited from super-types
*/
- public DeclareSoft[] getDeclareSofts();
+ DeclareSoft[] getDeclareSofts();
/**
* @return all of the declare annotation members of this type, including declare
* annotation members inherited from super-types
*/
- public DeclareAnnotation[] getDeclareAnnotations();
-
+ DeclareAnnotation[] getDeclareAnnotations();
+
/**
* @return all of the declare precedence members of this type, including declare
* precedence members inherited from super-types
*/
- public DeclarePrecedence[] getDeclarePrecedence();
-
+ DeclarePrecedence[] getDeclarePrecedence();
+
// misc
-
+
/**
* @return the elements of this enum class, or null if this type does not represent
* an enum type.
*/
- public T[] getEnumConstants();
-
+ T[] getEnumConstants();
+
/**
* @return an array of TypeVariable objects that represent the type variables declared by
* this type (if any)
*/
- public TypeVariable>[] getTypeParameters();
+ TypeVariable>[] getTypeParameters();
/**
* @return true if this is an enum type
*/
- public boolean isEnum();
+ boolean isEnum();
/**
* @param o the object to check for assignment compatibility
* @return true if the given object is assignment-compatible with an object of the type represented
* by this AjType
*/
- public boolean isInstance(Object o);
+ boolean isInstance(Object o);
/**
* @return true if this is an interface type
*/
- public boolean isInterface();
+ boolean isInterface();
/**
* @return true if and only if the underlying type is a local class
*/
- public boolean isLocalClass();
-
+ boolean isLocalClass();
+
/**
* @return true if and only if the underlying type is a member class
*/
- public boolean isMemberClass();
-
+ boolean isMemberClass();
+
/**
* @return true if this is an array type
*/
- public boolean isArray();
+ boolean isArray();
/**
* @return true if this object represents a primitive type
*/
- public boolean isPrimitive();
+ boolean isPrimitive();
/**
* @return true if this is an aspect type
*/
- public boolean isAspect();
-
+ boolean isAspect();
+
/**
* @return true if and only if the underlying type is a member aspect
*/
- public boolean isMemberAspect();
+ boolean isMemberAspect();
/**
* @return true if and only if the underlying type is a privileged aspect
*/
- public boolean isPrivileged();
-
+ boolean isPrivileged();
+
}
diff --git a/runtime/src/main/java/org/aspectj/lang/reflect/DeclareAnnotation.java b/runtime/src/main/java/org/aspectj/lang/reflect/DeclareAnnotation.java
index 1d7ba34a7..17f8637d7 100644
--- a/runtime/src/main/java/org/aspectj/lang/reflect/DeclareAnnotation.java
+++ b/runtime/src/main/java/org/aspectj/lang/reflect/DeclareAnnotation.java
@@ -1,12 +1,12 @@
/* *******************************************************************
* Copyright (c) 2005 Contributors.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
- *
- * Contributors:
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
* Adrian Colyer Initial implementation
* ******************************************************************/
package org.aspectj.lang.reflect;
@@ -18,39 +18,39 @@ import java.lang.annotation.Annotation;
*
*/
public interface DeclareAnnotation {
-
- public enum Kind { Field, Method, Constructor, Type };
-
+
+ enum Kind { Field, Method, Constructor, Type };
+
/**
* @return the aspect that declared this member.
*/
AjType> getDeclaringType();
-
+
/**
* @return the target element kind
*/
Kind getKind();
-
+
/**
- * @return the target signature pattern. Returns null if getKind() == Type
+ * @return the target signature pattern. Returns null if getKind() == Type
*/
SignaturePattern getSignaturePattern();
-
+
/**
* @return the target type pattern. Returns null if getKind() != Type
*/
TypePattern getTypePattern();
-
+
/**
* @return the declared annotation. If the declared annotation does not have runtime retention,
* this method returns null.
*/
Annotation getAnnotation();
-
+
/**
* @return the text of the annotation as declared in this member. Available for
* both runtime and class-file retention annotations
*/
String getAnnotationAsText();
-
+
}
diff --git a/runtime/src/main/java/org/aspectj/lang/reflect/FieldSignature.java b/runtime/src/main/java/org/aspectj/lang/reflect/FieldSignature.java
index df1c57656..5e4c4a55f 100644
--- a/runtime/src/main/java/org/aspectj/lang/reflect/FieldSignature.java
+++ b/runtime/src/main/java/org/aspectj/lang/reflect/FieldSignature.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
@@ -16,6 +16,6 @@ package org.aspectj.lang.reflect;
import java.lang.reflect.Field;
public interface FieldSignature extends MemberSignature {
- public Class getFieldType();
- public Field getField();
+ Class getFieldType();
+ Field getField();
}
diff --git a/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadCounter.java b/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadCounter.java
index 1fa064cee..f4a34260e 100644
--- a/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadCounter.java
+++ b/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadCounter.java
@@ -1,22 +1,22 @@
/* *******************************************************************
* Copyright (c) 2004 IBM Corporation
- *
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement initial implementation
+ *
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Andy Clement initial implementation
* ******************************************************************/
package org.aspectj.runtime.internal.cflowstack;
public interface ThreadCounter {
- public void inc();
- public void dec();
- public boolean isNotZero();
- public void removeThreadCounter();
-}
\ No newline at end of file
+ void inc();
+ void dec();
+ boolean isNotZero();
+ void removeThreadCounter();
+}
diff --git a/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStack.java b/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStack.java
index 7290163d2..3ae58d97d 100644
--- a/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStack.java
+++ b/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStack.java
@@ -1,14 +1,14 @@
/* *******************************************************************
* Copyright (c) 2004 IBM Corporation
- *
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement initial implementation
+ *
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Andy Clement initial implementation
* ******************************************************************/
package org.aspectj.runtime.internal.cflowstack;
@@ -17,7 +17,7 @@ import java.util.Stack;
public interface ThreadStack {
- public Stack getThreadStack();
- public void removeThreadStack();
+ Stack getThreadStack();
+ void removeThreadStack();
}
diff --git a/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStackFactory.java b/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStackFactory.java
index 38ba0ccbd..a752aef67 100644
--- a/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStackFactory.java
+++ b/runtime/src/main/java/org/aspectj/runtime/internal/cflowstack/ThreadStackFactory.java
@@ -1,20 +1,20 @@
/* *******************************************************************
* Copyright (c) 2004 IBM Corporation
- *
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement initial implementation
+ *
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Andy Clement initial implementation
* ******************************************************************/
package org.aspectj.runtime.internal.cflowstack;
public interface ThreadStackFactory {
-
- public ThreadStack getNewThreadStack();
- public ThreadCounter getNewThreadCounter();
-
+
+ ThreadStack getNewThreadStack();
+ ThreadCounter getNewThreadCounter();
+
}
diff --git a/runtime/src/main/java/org/aspectj/runtime/reflect/SignatureImpl.java b/runtime/src/main/java/org/aspectj/runtime/reflect/SignatureImpl.java
index 68079b444..0f9232bdd 100644
--- a/runtime/src/main/java/org/aspectj/runtime/reflect/SignatureImpl.java
+++ b/runtime/src/main/java/org/aspectj/runtime/reflect/SignatureImpl.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
@@ -21,21 +21,21 @@ import java.util.StringTokenizer;
abstract class SignatureImpl implements Signature {
private static boolean useCache = true;
-
+
int modifiers = -1;
String name;
String declaringTypeName;
Class declaringType;
Cache stringCache;
-
+
SignatureImpl(int modifiers, String name, Class declaringType) {
this.modifiers = modifiers;
this.name = name;
this.declaringType = declaringType;
}
-
+
protected abstract String createToString (StringMaker sm);
-
+
/* Use a soft cache for the short, middle and long String representations */
String toString (StringMaker sm) {
String result = null;
@@ -58,7 +58,7 @@ abstract class SignatureImpl implements Signature {
}
return result;
}
-
+
public final String toString() { return toString(StringMaker.middleStringMaker); }
public final String toShortString() { return toString(StringMaker.shortStringMaker); }
public final String toLongString() { return toString(StringMaker.longStringMaker); }
@@ -81,64 +81,64 @@ abstract class SignatureImpl implements Signature {
}
return declaringTypeName;
}
-
+
String fullTypeName(Class type) {
if (type == null) return "ANONYMOUS";
if (type.isArray()) return fullTypeName(type.getComponentType()) + "[]";
return type.getName().replace('$', '.');
}
-
+
String stripPackageName(String name) {
int dot = name.lastIndexOf('.');
if (dot == -1) return name;
return name.substring(dot+1);
}
-
+
String shortTypeName(Class type) {
if (type == null) return "ANONYMOUS";
if (type.isArray()) return shortTypeName(type.getComponentType()) + "[]";
return stripPackageName(type.getName()).replace('$', '.');
}
-
+
void addFullTypeNames(StringBuffer buf, Class[] types) {
for (int i = 0; i < types.length; i++) {
if (i > 0) buf.append(", ");
buf.append(fullTypeName(types[i]));
}
- }
+ }
void addShortTypeNames(StringBuffer buf, Class[] types) {
for (int i = 0; i < types.length; i++) {
if (i > 0) buf.append(", ");
buf.append(shortTypeName(types[i]));
}
}
-
+
void addTypeArray(StringBuffer buf, Class[] types) {
addFullTypeNames(buf, types);
}
-
+
// lazy version
private String stringRep;
ClassLoader lookupClassLoader = null;
-
+
public void setLookupClassLoader(ClassLoader loader) {
this.lookupClassLoader = loader;
}
-
+
private ClassLoader getLookupClassLoader() {
if (lookupClassLoader == null) lookupClassLoader = this.getClass().getClassLoader();
return lookupClassLoader;
}
-
+
public SignatureImpl(String stringRep) {
this.stringRep = stringRep;
}
-
+
static final char SEP = '-';
-
+
String extractString(int n) {
- //System.out.println(n + ": from " + stringRep);
-
+ //System.out.println(n + ": from " + stringRep);
+
int startIndex = 0;
int endIndex = stringRep.indexOf(SEP);
while (n-- > 0) {
@@ -146,29 +146,29 @@ abstract class SignatureImpl implements Signature {
endIndex = stringRep.indexOf(SEP, startIndex);
}
if (endIndex == -1) endIndex = stringRep.length();
-
+
//System.out.println(" " + stringRep.substring(startIndex, endIndex));
-
- return stringRep.substring(startIndex, endIndex);
+
+ return stringRep.substring(startIndex, endIndex);
}
-
+
int extractInt(int n) {
String s = extractString(n);
return Integer.parseInt(s, 16);
}
-
+
Class extractType(int n) {
String s = extractString(n);
return Factory.makeClass(s,getLookupClassLoader());
}
-
-
-
+
+
+
static String[] EMPTY_STRING_ARRAY = new String[0];
static Class[] EMPTY_CLASS_ARRAY = new Class[0];
-
+
static final String INNER_SEP = ":";
-
+
String[] extractStrings(int n) {
String s = extractString(n);
StringTokenizer st = new StringTokenizer(s, INNER_SEP);
@@ -197,14 +197,14 @@ abstract class SignatureImpl implements Signature {
return useCache;
}
- private static interface Cache {
+ private interface Cache {
String get(int cacheOffset);
- void set(int cacheOffset, String result);
-
+ void set(int cacheOffset, String result);
+
}
-
+
// separate implementation so we don't need SoftReference to hold the field...
private static final class CacheImpl implements Cache {
private java.lang.ref.SoftReference toStringCacheRef;
diff --git a/taskdefs/src/main/java/org/aspectj/tools/ant/taskdefs/Ajdoc.java b/taskdefs/src/main/java/org/aspectj/tools/ant/taskdefs/Ajdoc.java
index 8343027a7..24293d506 100644
--- a/taskdefs/src/main/java/org/aspectj/tools/ant/taskdefs/Ajdoc.java
+++ b/taskdefs/src/main/java/org/aspectj/tools/ant/taskdefs/Ajdoc.java
@@ -1,13 +1,13 @@
/* *******************************************************************
- * Copyright (c) 2000-2001 Xerox Corporation.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * Copyright (c) 2000-2001 Xerox Corporation.
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* 2006, Arno Schmidmeier, (reactivated the source and removed deprecated calls)
* ******************************************************************/
@@ -120,7 +120,7 @@ public class Ajdoc extends MatchingTask {
if (setif(b, flag)) cmd.createArgument().setValue(val);
return b;
}
-
+
public void setSource(String input) {
source = input;
}
@@ -162,11 +162,11 @@ public class Ajdoc extends MatchingTask {
public void addFileset(FileSet fs) {
fileSets.addElement(fs);
}
-
+
private void addFileSets() {
if(sourcefiles == null)
sourcefiles = new ArrayList<>();
-
+
Enumeration e = fileSets.elements();
while (e.hasMoreElements()) {
FileSet fs = (FileSet) e.nextElement();
@@ -183,17 +183,17 @@ public class Ajdoc extends MatchingTask {
}
}
}
-
+
public void setPackagenames(String list) {
(packagenames == null ?
packagenames = new ArrayList<>() :
packagenames).addAll(strings(list, true));
}
-
+
public void setAccess(AccessType at) {
cmd.createArgument().setValue("-" + at.getValue());
}
-
+
public void setPackageList(String packageList) {
this.packageList = getProject().resolveFile(packageList);
}
@@ -211,11 +211,11 @@ public class Ajdoc extends MatchingTask {
classpath = new Path(getProject()) :
classpath).createPath();
}
-
+
public void setClasspathref(Reference id) {
createClasspath().setRefid(id);
}
-
+
public void setBootclasspath(Path path) { // todo: unsupported
if (bootclasspath == null) {
bootclasspath = path;
@@ -229,12 +229,12 @@ public class Ajdoc extends MatchingTask {
bootclasspath = new Path(getProject()) :
bootclasspath).createPath();
}
-
+
public void setBootclasspathref(Reference bootclasspathref) { // todo: unsupported
createBootclasspath().setRefid(bootclasspathref);
}
- public void setInternalclasspath(Path internalclasspath) {
+ public void setInternalclasspath(Path internalclasspath) {
if (this.internalclasspath == null) {
this.internalclasspath = internalclasspath;
} else {
@@ -248,12 +248,12 @@ public class Ajdoc extends MatchingTask {
}
return internalclasspath.createPath();
}
-
-
+
+
public void setInternalclasspathref(Reference internalclasspathref) {
createInternalclasspath().setRefid(internalclasspathref);
}
-
+
public void setExtdirs(Path path) {
if (extdirs == null) {
extdirs = path;
@@ -333,7 +333,7 @@ public class Ajdoc extends MatchingTask {
public void addBottom(Html text) {
bottom = text;
}
-
+
public void setVerbose(boolean b) {
setif(b, "-verbose");
}
@@ -416,7 +416,7 @@ public class Ajdoc extends MatchingTask {
}
}
}
-
+
public Group createGroup() {
Group group = new Group();
groups.add(group);
@@ -448,7 +448,7 @@ public class Ajdoc extends MatchingTask {
}
public void setSerialwarn(boolean serialwarn) {
- setif(serialwarn, "-serialwarn");
+ setif(serialwarn, "-serialwarn");
}
public void setHelpfile(String helpfile) {
@@ -582,7 +582,7 @@ public class Ajdoc extends MatchingTask {
cmd.createArgument().setValue("-bottom");
cmd.createArgument().setValue(getProject().replaceProperties(bottom.getText()));
}
-
+
for (Link link: links) {
if (link.href == null) {
throw new BuildException("Link href cannot be null!", getLocation());
@@ -699,14 +699,14 @@ public class Ajdoc extends MatchingTask {
protected int compile() throws BuildException { // todo: doc that fork is ignored
try {
- String[] args = cmd.getArguments();
+ String[] args = cmd.getArguments();
if (fork) {
log("Warning: fork is ignored ", Project.MSG_WARN);
}
- Main.main(args);
+ Main.main(args);
if (Main.hasAborted())
return 1;
- else
+ else
return 0;
} catch (Throwable t) {
throw new BuildException(t);
@@ -714,7 +714,7 @@ public class Ajdoc extends MatchingTask {
}
protected interface Mapper {
- public T map(String str);
+ T map(String str);
}
protected final List list(String str, Mapper mapper) {
diff --git a/testing-util/src/main/java/org/aspectj/testing/util/TestUtil.java b/testing-util/src/main/java/org/aspectj/testing/util/TestUtil.java
index cf2ae8ef0..508f71550 100644
--- a/testing-util/src/main/java/org/aspectj/testing/util/TestUtil.java
+++ b/testing-util/src/main/java/org/aspectj/testing/util/TestUtil.java
@@ -774,12 +774,12 @@ public final class TestUtil {
}
/** component that reduces file to CanonicalLine[] */
- public static interface ILineator {
+ public interface ILineator {
/** Lineator suitable for text files */
- public static final ILineator TEXT = new TextLineator();
+ ILineator TEXT = new TextLineator();
/** Lineator suitable for class files (disassembles first) */
- public static final ILineator CLASS = new ClassLineator();
+ ILineator CLASS = new ClassLineator();
/**
* Reduce file to CanonicalLine[].
diff --git a/testing/src/test/java/org/aspectj/testing/harness/bridge/DirChanges.java b/testing/src/test/java/org/aspectj/testing/harness/bridge/DirChanges.java
index 5a3ad13ab..c19618a3d 100644
--- a/testing/src/test/java/org/aspectj/testing/harness/bridge/DirChanges.java
+++ b/testing/src/test/java/org/aspectj/testing/harness/bridge/DirChanges.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.testing.harness.bridge;
@@ -40,7 +40,7 @@ import org.aspectj.util.LangUtil;
*
* - Set up with any expected changes and/or an expected directory
* - Set up with any file checker
- * - start(..) before changes.
+ *
- start(..) before changes.
* This issues messages for any removed files not found,
* which represent an error in the expected changes.
* - Do whatever operations will change the directory
@@ -52,7 +52,7 @@ import org.aspectj.util.LangUtil;
* When comparing directories, this ignores any paths containing "CVS".
*/
public class DirChanges {
-
+
public static final String DELAY_NAME = "dir-changes.delay";
private static final long DELAY;
static {
@@ -71,22 +71,22 @@ public class DirChanges {
private static final boolean EXISTS = true;
final Spec spec;
-
+
/** start time, in milliseconds - valid only from start(..)..end(..) */
long startTime;
-
+
/** base directory of actual files - valid only from start(..)..end(..) */
File baseDir;
-
+
/** if set, this is run against any resulting existing files
* specified in added/updated lists.
* This does not affect expected-directory comparison.
*/
IFileChecker fileChecker;
-
+
/** handler valid from start..end of start(..) and end(..) methods */
IMessageHandler handler;
-
+
/**
* Constructor for DirChanges.
*/
@@ -109,23 +109,23 @@ public class DirChanges {
this.baseDir = baseDir;
startTime = 0l;
final boolean doCompare = false;
- boolean result
- = exists("at start, did not expect added file to exist", !EXISTS, spec.added, doCompare);
- result &= exists("at start, expected unchanged file to exist", EXISTS, spec.unchanged, doCompare);
- result &= exists("at start, expected updated file to exist", EXISTS, spec.updated, doCompare);
- result &= exists("at start, expected removed file to exist", EXISTS, spec.removed, doCompare);
+ boolean result
+ = exists("at start, did not expect added file to exist", !EXISTS, spec.added, doCompare);
+ result &= exists("at start, expected unchanged file to exist", EXISTS, spec.unchanged, doCompare);
+ result &= exists("at start, expected updated file to exist", EXISTS, spec.updated, doCompare);
+ result &= exists("at start, expected removed file to exist", EXISTS, spec.removed, doCompare);
startTime = System.currentTimeMillis();
// ensure tests don't complete in < 1 second, otherwise can confuse fast machines.
try {
- Thread.sleep(1000);
+ Thread.sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
this.handler = oldHandler;
- return result;
+ return result;
}
-
+
/**
* Inspect the base dir, issue any messages for
* files not added, files not updated, and files not removed,
@@ -158,22 +158,22 @@ public class DirChanges {
final boolean doCompare = (null != fileChecker);
final boolean fastFail = spec.fastFail;
boolean result
- = exists("at end, expected file was not added", EXISTS, spec.added, doCompare);
+ = exists("at end, expected file was not added", EXISTS, spec.added, doCompare);
if (result || !fastFail) {
- result &= exists("at end, expected file was not unchanged", EXISTS, spec.unchanged, doCompare, false);
+ result &= exists("at end, expected file was not unchanged", EXISTS, spec.unchanged, doCompare, false);
}
if (result || !fastFail) {
- result &= exists("at end, expected file was not updated", EXISTS, spec.updated, doCompare);
+ result &= exists("at end, expected file was not updated", EXISTS, spec.updated, doCompare);
}
if (result || !fastFail) {
- result &= exists("at end, file exists, was not removed", !EXISTS, spec.removed, doCompare);
+ result &= exists("at end, file exists, was not removed", !EXISTS, spec.removed, doCompare);
}
// if (result || !fastFail) {
// // XXX validate that unchanged mod-time did not change
// }
// variant 1: compare expected directory
if (result || !fastFail) {
- result &= compareDir(srcBaseDir);
+ result &= compareDir(srcBaseDir);
}
return result;
} finally {
@@ -197,7 +197,7 @@ public class DirChanges {
}
File expDir = new File(srcBaseDir, spec.expDir);
File actDir = baseDir;
- //System.err.println("XXX comparing actDir=" + actDir + " expDir=" + expDir);
+ //System.err.println("XXX comparing actDir=" + actDir + " expDir=" + expDir);
return TestUtil.sameDirectoryContents(handler, expDir, actDir, spec.fastFail);
}
@@ -206,7 +206,7 @@ public class DirChanges {
protected void setFileComparer(IFileChecker comp) {
this.fileChecker = comp;
}
-
+
/**
@@ -224,7 +224,7 @@ public class DirChanges {
List pathList,
boolean doCompare) {
// boolean expectStartEarlier = true;
- return exists(label, exists, pathList,doCompare, true);
+ return exists(label, exists, pathList,doCompare, true);
}
protected boolean exists(
String label,
@@ -235,7 +235,7 @@ public class DirChanges {
boolean result = true;
if (!LangUtil.isEmpty(pathList)) {
// final File expDir = ((!doCompare || (null == spec.expDir))
-// ? null
+// ? null
// : new File(baseDir, spec.expDir));
for (Object o : pathList) {
final String entry = (String) o;
@@ -269,21 +269,21 @@ public class DirChanges {
/**
* Generate fail message "{un}expected {label} file {path} in {baseDir}".
* @param handler the IMessageHandler sink
- * @param label String message infix
+ * @param label String message infix
* @param path the path to the file
*/
protected void failMessage(
IMessageHandler handler,
boolean exists,
String label,
- String path,
+ String path,
File file) {
- MessageUtil.fail(handler, label + " \"" + path + "\" in " + baseDir);
+ MessageUtil.fail(handler, label + " \"" + path + "\" in " + baseDir);
}
/** Check actual File found at a path, usually to diff expected/actual contents */
- public static interface IFileChecker {
- /**
+ public interface IFileChecker {
+ /**
* Check file found at path.
* Implementations should return false when adding fail (or worse)
* message to the handler, and true otherwise.
@@ -293,10 +293,10 @@ public class DirChanges {
* @return false if check failed and messages added to handler
*/
boolean checkFile(IMessageHandler handler, String path, File actualFile);
- }
-// File-comparison code with a bit more generality -- too unweildy
+ }
+// File-comparison code with a bit more generality -- too unweildy
// /**
-// * Default FileChecker compares files literally, transforming any
+// * Default FileChecker compares files literally, transforming any
// * with registered normalizers.
// */
// public static class FileChecker implements IFileChecker {
@@ -304,7 +304,7 @@ public class DirChanges {
// NormalizedCompareFiles fileComparer;
//
// public FileChecker(File baseExpectedDir) {
-// this.baseExpectedDir = baseExpectedDir;
+// this.baseExpectedDir = baseExpectedDir;
// fileComparer = new NormalizedCompareFiles();
// }
// public boolean checkFile(IMessageHandler handler, String path, File actualFile) {
@@ -324,8 +324,8 @@ public class DirChanges {
// }
//
// protected boolean doCheckFile(
-// IMessageHandler handler,
-// File expectedFile,
+// IMessageHandler handler,
+// File expectedFile,
// File actualFile,
// String path) {
// fileComparer.setHandler(handler);
@@ -333,9 +333,9 @@ public class DirChanges {
// return false;
// }
// }
-
+
// /**
-// * CompareFiles implementation that pre-processes input
+// * CompareFiles implementation that pre-processes input
// * to normalize it. Currently it reads all files except
// * .class files, which it disassembles first.
// */
@@ -347,13 +347,13 @@ public class DirChanges {
// }
// return file.getAbsolutePath().replace('\\', '/');
// }
-//
+//
// private String[] baseDirs;
// private IMessageHandler handler;
-//
+//
// public NormalizedCompareFiles() {
// }
-//
+//
// void init(IMessageHandler handler, File[] baseDirs) {
// this.handler = handler;
// if (null == baseDirs) {
@@ -364,16 +364,16 @@ public class DirChanges {
// this.baseDirs[i] = normalPath(baseDirs[i]) + "/";
// }
// }
-// }
-//
+// }
+//
// private String getClassName(File file) {
// String result = null;
// String path = normalPath(file);
// if (!path.endsWith(".class")) {
-// MessageUtil.error(handler,
-// "NormalizedCompareFiles expected "
+// MessageUtil.error(handler,
+// "NormalizedCompareFiles expected "
// + file
-// + " to end with .class");
+// + " to end with .class");
// } else {
// path = path.substring(0, path.length()-6);
// for (int i = 0; i < baseDirs.length; i++) {
@@ -381,29 +381,29 @@ public class DirChanges {
// return path.substring(baseDirs[i].length()).replace('/', '.');
// }
// }
-// MessageUtil.error(handler,
-// "NormalizedCompareFiles expected "
+// MessageUtil.error(handler,
+// "NormalizedCompareFiles expected "
// + file
-// + " to start with one of "
+// + " to start with one of "
// + LangUtil.arrayAsList(baseDirs));
// }
-//
+//
// return result;
// }
-//
-// /**
+//
+// /**
// * Read file as normalized lines, sending handler any messages
// * ERROR for input failures and FAIL for processing failures.
-// * @return NOLINES on error or normalized lines from file otherwise
+// * @return NOLINES on error or normalized lines from file otherwise
// */
// public FileLine[] getFileLines(File file) {
// FileLineator capture = new FileLineator();
// InputStream in = null;
-// try {
+// try {
// if (!file.getPath().endsWith(".class")) {
// in = new FileInputStream(file);
// FileUtil.copyStream(
-// new BufferedReader(new InputStreamReader(in)),
+// new BufferedReader(new InputStreamReader(in)),
// new PrintWriter(capture));
// } else {
// String name = getClassName(file);
@@ -416,7 +416,7 @@ public class DirChanges {
// LazyClassGen.disassemble(path, name, capture);
// }
// } catch (IOException e) {
-// MessageUtil.fail(handler,
+// MessageUtil.fail(handler,
// "NormalizedCompareFiles IOException reading " + file, e);
// return null;
// } finally {
@@ -429,44 +429,44 @@ public class DirChanges {
// }
// String missed = capture.getMissed();
// if (!LangUtil.isEmpty(missed)) {
-// MessageUtil.fail(handler,
-// "NormalizedCompareFiles missed input: "
+// MessageUtil.fail(handler,
+// "NormalizedCompareFiles missed input: "
// + missed);
// return null;
// } else {
// return capture.getFileLines();
-// }
-// }
-//
-//
-// }
-
+// }
+// }
+//
+//
+// }
+
/**
* Specification for a set of File added, removed, or updated
- * in a given directory, or for a directory base for a tree of expected files.
+ * in a given directory, or for a directory base for a tree of expected files.
* If defaultSuffix is specified, entries may be added without it.
* Currently the directory tree
- * only is used to verify files that are expected
- * and found after the process completes.
+ * only is used to verify files that are expected
+ * and found after the process completes.
*/
public static class Spec implements IXmlWritable {
/** XML element name */
public static final String XMLNAME = "dir-changes";
-
+
/** a symbolic name for the base directory */
String dirToken; // XXX default to class?
-
- /** if set, then append to specified paths when seeking files */
+
+ /** if set, then append to specified paths when seeking files */
String defaultSuffix;
-
- /** relative path of dir with expected files for comparison */
+
+ /** relative path of dir with expected files for comparison */
String expDir;
-
+
long delayInMilliseconds = DELAY;
-
+
/** if true, fail on first mis-match */
boolean fastFail;
-
+
/** relative paths (String) of expected files added */
final List added;
@@ -476,26 +476,26 @@ public class DirChanges {
/** relative paths (String) of expected files updated/changed */
final List updated;
- /** relative paths (String) of expected files NOT
- * added, removed, or changed
+ /** relative paths (String) of expected files NOT
+ * added, removed, or changed
* XXX unchanged unimplemented
*/
final List unchanged;
-
+
public Spec() {
added = new ArrayList<>();
removed = new ArrayList<>();
updated = new ArrayList<>();
unchanged = new ArrayList<>();
}
-
+
/**
* @param dirToken the symbol name of the base directory (classes, run)
*/
public void setDirToken(String dirToken) {
this.dirToken = dirToken;
}
-
+
/**
* Set the directory containing the expected files.
* @param expectedDirRelativePath path relative to the test base
@@ -504,7 +504,7 @@ public class DirChanges {
public void setExpDir(String expectedDirRelativePath) {
expDir = expectedDirRelativePath;
}
-
+
public void setDelay(String delay) {
if (null != delay) {
// let NumberFormatException propogate up
@@ -514,43 +514,43 @@ public class DirChanges {
}
}
}
-
+
/**
* @param clipSuffix the String suffix, if any, to clip automatically
*/
public void setDefaultSuffix(String defaultSuffix) {
this.defaultSuffix = defaultSuffix;
}
-
+
public void setAdded(String items) {
XMLWriter.addFlattenedItems(added, items);
}
-
+
public void setRemoved(String items) {
XMLWriter.addFlattenedItems(removed, items);
}
-
+
public void setUpdated(String items) {
XMLWriter.addFlattenedItems(updated, items);
}
-
+
public void setUnchanged(String items) {
XMLWriter.addFlattenedItems(unchanged, items);
}
public void setFastfail(boolean fastFail) {
this.fastFail = fastFail;
}
-
+
/** @return true if some list was specified */
private boolean hasFileList() {
- return (!LangUtil.isEmpty(added)
+ return (!LangUtil.isEmpty(added)
|| !LangUtil.isEmpty(removed)
|| !LangUtil.isEmpty(updated)
|| !LangUtil.isEmpty(unchanged)
);
}
-
- /**
+
+ /**
* Emit specification in XML form if not empty.
* This writes nothing if there is no expected dir
* and there are no added, removed, or changed.
@@ -588,7 +588,7 @@ public class DirChanges {
}
out.endElement(XMLNAME);
}
-
+
/**
* Write list as elements to XMLWriter.
* @param out XMLWriter output sink
@@ -604,7 +604,7 @@ public class DirChanges {
continue;
}
spec.writeXml(out);
- }
+ }
}
} // class Spec
diff --git a/testing/src/test/java/org/aspectj/testing/harness/bridge/IAjcRun.java b/testing/src/test/java/org/aspectj/testing/harness/bridge/IAjcRun.java
index e685df5dd..a7a44a75c 100644
--- a/testing/src/test/java/org/aspectj/testing/harness/bridge/IAjcRun.java
+++ b/testing/src/test/java/org/aspectj/testing/harness/bridge/IAjcRun.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.testing.harness.bridge;
@@ -21,9 +21,9 @@ import org.aspectj.testing.xml.XMLWriter;
public interface IAjcRun extends IRun {
boolean setupAjcRun(Sandbox sandbox, Validator validator);
// XXX add for result eval? ArrayList getExpectedMessages();
-
+
/** this IAjcRun does nothing, returning true always */
- public static final IAjcRun NULLRUN = new IAjcRun() {
+ IAjcRun NULLRUN = new IAjcRun() {
public boolean setupAjcRun(Sandbox sandbox, Validator validator) {
return true;
}
@@ -40,5 +40,5 @@ public interface IAjcRun extends IRun {
}
public String toString() { return "IAjcRun.NULLRUN"; }
};
-
+
}
diff --git a/testing/src/test/java/org/aspectj/testing/run/IRun.java b/testing/src/test/java/org/aspectj/testing/run/IRun.java
index 57639016b..e09fcbb9d 100644
--- a/testing/src/test/java/org/aspectj/testing/run/IRun.java
+++ b/testing/src/test/java/org/aspectj/testing/run/IRun.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
@@ -19,12 +19,12 @@ package org.aspectj.testing.run;
* @author isberg
*/
public interface IRun {
- public static final IRun[] RA_IRun = new IRun[0];
+ IRun[] RA_IRun = new IRun[0];
/** Positive wrapper for the status parameter */
- public static final IRun OK
+ IRun OK
= new IRun() {
- /** This returns false when the status is null
+ /** This returns false when the status is null
* or runResult is false */
public boolean run(IRunStatus status) {
return ((null != status) && status.runResult());
@@ -33,7 +33,7 @@ public interface IRun {
};
/** Negative wrapper for the status parameter */
- public static final IRun NOTOK
+ IRun NOTOK
= new IRun() {
public boolean run(IRunStatus status) {
return ((null == status) || !status.runResult());
@@ -50,11 +50,11 @@ public interface IRun {
* callees ensure starting, and responsible
* callers ensure completed after the call.
* Anyone setting completion should ensure it
- * is set recursively for all children,
+ * is set recursively for all children,
* and anyone starting child runs should
* ensure children are registered and initialized
* appropriately.
- * @param status the IRunStatus representing the
+ * @param status the IRunStatus representing the
* outcome of the process (collecting parameter).
* @see Runners
*/
diff --git a/testing/src/test/java/org/aspectj/testing/run/IRunStatus.java b/testing/src/test/java/org/aspectj/testing/run/IRunStatus.java
index 9c8665728..652c1a802 100644
--- a/testing/src/test/java/org/aspectj/testing/run/IRunStatus.java
+++ b/testing/src/test/java/org/aspectj/testing/run/IRunStatus.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
@@ -21,30 +21,30 @@ import org.aspectj.bridge.MessageUtil;
/**
* Encapsulate status and results for a run.
* A run starts and then completes normally
- * (finished(Object result)),
+ * (finished(Object result)),
* abruptly (thrown(Throwable thrown)),
* or by user request (abort(Object request)).
* @author isberg
*/
public interface IRunStatus extends IMessageHolder {
/** clients use this when signalling completion without a specific result */
- public static final Object VOID = Boolean.TRUE;
+ Object VOID = Boolean.TRUE;
/** result object for successful (unset) boolean run result */
- public static final Boolean PASS = Boolean.TRUE;
-
+ Boolean PASS = Boolean.TRUE;
+
/** result object for failed (unset) boolean run result */
- public static final Boolean FAIL = Boolean.FALSE;
-
+ Boolean FAIL = Boolean.FALSE;
+
/** clients use this when signalling abort without any specific request */
- public static final Object ABORT = Boolean.FALSE;
-
+ Object ABORT = Boolean.FALSE;
+
/** clients use this when signalling abort because no object to run */
- public static final Object ABORT_NORUN = MessageUtil.ABORT_NOTHING_TO_RUN;
-
+ Object ABORT_NORUN = MessageUtil.ABORT_NOTHING_TO_RUN;
+
/** returned from getChildren when there are no children */
- public static final IRunStatus[] EMPTY_NEST = new IRunStatus[0];
-
+ IRunStatus[] EMPTY_NEST = new IRunStatus[0];
+
//------------------- process controls
/**
* Set identifier associated with this run, if any
@@ -57,19 +57,19 @@ public interface IRunStatus extends IMessageHolder {
/**
* Call before any start() or after isCompleted() would return true
* to reset this to its pre-start state
- * @throws IllegalStateException if start() has been called
+ * @throws IllegalStateException if start() has been called
* and isCompleted() is not true.
*/
void reset();
-
- /**
+
+ /**
* Call only once to signal this run has started.
* @throws IllegalStateException if start() has been called
*/
void start();
-
- /**
- * Call this or thrown only once after start()
+
+ /**
+ * Call this or thrown only once after start()
* to signal this run has ended.
* If this represents a void process, use VOID.
* @param result the Object returned by this run.
@@ -77,8 +77,8 @@ public interface IRunStatus extends IMessageHolder {
* or if either completed(Object) or thrown(Throwable) have been called.
*/
void finish(Object result);
-
- /**
+
+ /**
* Call to signal this run is ending by request.
* If there is no message, use ABORT.
* @param request the Object request to abort,
@@ -87,20 +87,20 @@ public interface IRunStatus extends IMessageHolder {
* or if either completed(Object) or thrown(Throwable) have been called.
*/
void abort(Object request);
-
- /**
- * Call this or completed only once after start()
+
+ /**
+ * Call this or completed only once after start()
* to signal this run has ended.
* @throws IllegalStateException if start() was not called first
* or if either completed(Object) or thrown(Throwable) have been called.
*/
void thrown(Throwable thrown);
-
-
+
+
/**
* Call this for the status to throw an unchecked exception
* of the type that its controller understands.
- * It is an error for a IRunStatus to continue normally
+ * It is an error for a IRunStatus to continue normally
* after this is invoked.
*/
void completeAbruptly();
@@ -119,39 +119,39 @@ public interface IRunStatus extends IMessageHolder {
* Pass null to get all kinds.
* @param kind the IMessage.Kind expected, or null for all messages
* @param orGreater if true, also get any greater than the target kind
- * as determined by IMessage.Kind.COMPARATOR
+ * as determined by IMessage.Kind.COMPARATOR
* @param includeChildren if true, then also search in any child IRunStatus
* @return IMessage[] of messages of the right kind, or IMessage.NONE
*/
IMessage[] getMessages(IMessage.Kind kind, boolean orGreater, boolean includeChildren);
-
- /**
+
+ /**
* Call this any time to signal any messages.
* (In particular, the IRun caller may use this to register messages
* about the mishandling of the run by the ResultStatusI by the callee.)
* This is a shortcut for getMessageHandler().handleMessage(..);
*/
//boolean handleMessage(IMessage message);
-
+
//------------------- process display
/** @return true if this run has started */
boolean started();
-
+
/** @return true if one of the result, abort request, or thrown is available */
boolean isCompleted();
/** @return true if this got an abort request */
boolean aborted();
-
- /**
- * @return true if completed and not aborted and no thrown
+
+ /**
+ * @return true if completed and not aborted and no thrown
* or messages with kind ABORT or FAIL or ERROR
*/
boolean runResult();
/** get the invoker for any subruns */
Runner getRunner();
-
+
/** @return the Object result, if any, of this run */
Object getResult();
@@ -159,16 +159,16 @@ public interface IRunStatus extends IMessageHolder {
Object getAbortRequest();
/** @return the Throwable thrown, if any, by this run */
- Throwable getThrown();
-
+ Throwable getThrown();
+
/** @return any Message[] signalled, or SILENCE if none */
IMessage[] getMessages();
-
+
/** @return the identifier set for this run, if any */
Object getIdentifier();
-
+
//------------------- subprocess
- /**
+ /**
* Add a record for a child run
* and install self as parent.
* @throws IllegalArgumentException if child is null
@@ -183,7 +183,7 @@ public interface IRunStatus extends IMessageHolder {
*/
void registerParent(IRunStatus parent);
- /**
+ /**
* @return the current children of this run, or EMPTY_NEST if none
*/
IRunStatus[] getChildren();
diff --git a/testing/src/test/java/org/aspectj/testing/util/IntValidator.java b/testing/src/test/java/org/aspectj/testing/util/IntValidator.java
index e3697d1aa..6b0766e4e 100644
--- a/testing/src/test/java/org/aspectj/testing/util/IntValidator.java
+++ b/testing/src/test/java/org/aspectj/testing/util/IntValidator.java
@@ -1,13 +1,13 @@
/* *******************************************************************
* Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.testing.util;
@@ -17,5 +17,5 @@ package org.aspectj.testing.util;
*/
public interface IntValidator {
/** @return true if this is a valid value */
- public boolean acceptInt(int value);
+ boolean acceptInt(int value);
}
diff --git a/testing/src/test/java/org/aspectj/testing/util/ObjectChecker.java b/testing/src/test/java/org/aspectj/testing/util/ObjectChecker.java
index e1f771b9d..284014e4f 100644
--- a/testing/src/test/java/org/aspectj/testing/util/ObjectChecker.java
+++ b/testing/src/test/java/org/aspectj/testing/util/ObjectChecker.java
@@ -1,38 +1,38 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.testing.util;
/**
- * Check input for validity.
+ * Check input for validity.
*/
public interface ObjectChecker {
/** this returns true for any input, even if null */
- public static final ObjectChecker ANY = new ObjectChecker() {
+ ObjectChecker ANY = new ObjectChecker() {
public final boolean isValid(Object input) { return true; }
public final String toString() { return "ObjectChecker.ANY"; }
};
-
+
/** this returns true for any non-null object */
- public static final ObjectChecker NOT_NULL = new ObjectChecker() {
+ ObjectChecker NOT_NULL = new ObjectChecker() {
public boolean isValid(Object input) { return (null != input); }
public String toString() { return "ObjectChecker.NOT_NULL"; }
};
-
+
/** @return true if input is 0 Integer or any other non-Integer reference. */
- public static final ObjectChecker ANY_ZERO = new ObjectChecker() {
- public boolean isValid(Object input) {
+ ObjectChecker ANY_ZERO = new ObjectChecker() {
+ public boolean isValid(Object input) {
if (input instanceof Integer) {
return (0 == (Integer) input);
} else {
@@ -41,11 +41,11 @@ public interface ObjectChecker {
}
public String toString() { return "ObjectChecker.ANY_ZERO"; }
};
-
+
/**
- * Check input for validity.
+ * Check input for validity.
* @param input the Object to check
- * @return true if input is ok
+ * @return true if input is ok
*/
- public boolean isValid(Object input);
+ boolean isValid(Object input);
}
diff --git a/testing/src/test/java/org/aspectj/testing/util/RunUtils.java b/testing/src/test/java/org/aspectj/testing/util/RunUtils.java
index df889f222..21e1b6ebf 100644
--- a/testing/src/test/java/org/aspectj/testing/util/RunUtils.java
+++ b/testing/src/test/java/org/aspectj/testing/util/RunUtils.java
@@ -195,7 +195,7 @@ public class RunUtils {
}
/** renderer for IRunStatus */
- public static interface IRunStatusPrinter {
+ public interface IRunStatusPrinter {
void printRunStatus(PrintStream out, IRunStatus status);
}
diff --git a/testing/src/test/java/org/aspectj/testing/util/SFileReader.java b/testing/src/test/java/org/aspectj/testing/util/SFileReader.java
index afa66d46f..1dc5352df 100644
--- a/testing/src/test/java/org/aspectj/testing/util/SFileReader.java
+++ b/testing/src/test/java/org/aspectj/testing/util/SFileReader.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.testing.util;
@@ -29,11 +29,11 @@ import org.aspectj.util.LangUtil;
* and EOL comments # or //.
* This duplicates ConfigFileUtil in some sense.
*/
-public class SFileReader {
+public class SFileReader {
// XXX move into LineReader, but that forces util to depend on AbortException?
// Formerly in SuiteReader
-
- /**
+
+ /**
* Read args as config files and echo to stderr.
* @param args String[] of fully-qualified paths to config files
*/
@@ -52,19 +52,19 @@ public class SFileReader {
}
}
}
-
+
/*
* readSuite(..) reads .txt file, and for each test case specification
- * creates a spec using readTestSpecifications
+ * creates a spec using readTestSpecifications
* and (if the specifications match the constraints)
* creates a test case using creatTestCase.
*/
/** pass this to protected methods requiring String[] if you have none */
protected static final String[] NONE = new String[0];
-
+
final Maker maker;
-
+
/** @param maker the Maker factory to use - if null, use Maker.ECHO */
public SFileReader(Maker maker) {
this.maker = (null == maker ? Maker.ECHO : maker);
@@ -104,7 +104,7 @@ public class SFileReader {
throw new IOException("no reader for " + file);
}
final String baseDir = file.getParent();
-
+
String line;
boolean skipEmpties = true;
while (null != (line = reader.nextLine(skipEmpties))) {
@@ -126,7 +126,7 @@ public class SFileReader {
try {
Object made = maker.make(reader);
if ((null == selector) || (selector.isValid(made))) {
- if (!result.add(made)) {
+ if (!result.add(made)) {
break; // XXX signal error?
}
}
@@ -146,7 +146,7 @@ public class SFileReader {
}
reader.readToBlankLine();
}
- }
+ }
}
} finally {
try {
@@ -156,25 +156,25 @@ public class SFileReader {
} catch (IOException e) {
} // ignore
}
-
+
return result;
}
-
+
/** factory produces objects by reading LineReader */
public interface Maker {
- /**
+ /**
* Make the result using the input from the LineReader,
* starting with lastLine().
*/
Object make(UtilLineReader reader) throws AbortException, IOException;
-
+
/** @return type of the Object made */
Class getType();
-
+
/** This echoes each line, prefixed by the reader.
* @return file:line: {line}
*/
- static final Maker ECHO = new Maker() {
+ Maker ECHO = new Maker() {
public Object make(UtilLineReader reader) {
return reader + ": " + reader.lastLine();
}
diff --git a/testing/src/test/java/org/aspectj/testing/util/StringVisitor.java b/testing/src/test/java/org/aspectj/testing/util/StringVisitor.java
index 123376df4..02f7459c3 100644
--- a/testing/src/test/java/org/aspectj/testing/util/StringVisitor.java
+++ b/testing/src/test/java/org/aspectj/testing/util/StringVisitor.java
@@ -1,21 +1,21 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
// todo: non-distribution license?
package org.aspectj.testing.util;
-/**
+/**
* Visitor interface for String
*/
public interface StringVisitor {
@@ -23,6 +23,6 @@ public interface StringVisitor {
* @param input the String to evaluate - may be null
* @return true if input is accepted and/or process should continue
*/
- public boolean accept(String input);
+ boolean accept(String input);
}
diff --git a/util/src/main/java/org/aspectj/util/PartialOrder.java b/util/src/main/java/org/aspectj/util/PartialOrder.java
index be59104a0..ec3ddae28 100644
--- a/util/src/main/java/org/aspectj/util/PartialOrder.java
+++ b/util/src/main/java/org/aspectj/util/PartialOrder.java
@@ -1,14 +1,14 @@
/* *******************************************************************
- * Copyright (c) 1999-2001 Xerox Corporation,
+ * Copyright (c) 1999-2001 Xerox Corporation,
* 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Xerox/PARC initial implementation
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Xerox/PARC initial implementation
* ******************************************************************/
package org.aspectj.util;
@@ -20,7 +20,7 @@ import java.util.List;
/**
* This class implements a partial order
- *
+ *
* It includes routines for doing a topo-sort
*/
@@ -29,24 +29,24 @@ public class PartialOrder {
/**
* All classes that want to be part of a partial order must implement PartialOrder.PartialComparable.
*/
- public static interface PartialComparable {
+ public interface PartialComparable {
/**
* @returns
* - +1 if this is greater than other
* - -1 if this is less than other
* - 0 if this is not comparable to other
*
- *
+ *
* Note: returning 0 from this method doesn't mean the same thing as returning 0 from
* java.util.Comparable.compareTo()
*/
- public int compareTo(Object other);
+ int compareTo(Object other);
/**
* This method can provide a deterministic ordering for elements that are strictly not comparable. If you have no need for
* this, this method can just return 0 whenever called.
*/
- public int fallbackCompareTo(Object other);
+ int fallbackCompareTo(Object other);
}
private static class SortObject {
@@ -109,9 +109,9 @@ public class PartialOrder {
/**
* @param objects must all implement PartialComparable
- *
+ *
* @returns the same members as objects, but sorted according to their partial order. returns null if the objects are cyclical
- *
+ *
*/
public static List sort(List objects) {
// lists of size 0 or 1 don't need any sorting
diff --git a/weaver/src/main/java/org/aspectj/weaver/loadtime/IWeavingContext.java b/weaver/src/main/java/org/aspectj/weaver/loadtime/IWeavingContext.java
index 51b781e86..2a6523bb5 100644
--- a/weaver/src/main/java/org/aspectj/weaver/loadtime/IWeavingContext.java
+++ b/weaver/src/main/java/org/aspectj/weaver/loadtime/IWeavingContext.java
@@ -21,23 +21,23 @@ import org.aspectj.weaver.tools.WeavingAdaptor;
/**
* This class adds support to AspectJ for an OSGi environment
- *
+ *
* @author David Knibb
*/
public interface IWeavingContext {
-
+
/**
* Allows the standard ClassLoader.getResources() mechanisms to be
* replaced with a different implementation.
- * In an OSGi environment, this will allow for filtering to take
+ * In an OSGi environment, this will allow for filtering to take
* place on the results of ClassLoader.getResources(). In a non-OSGi
* environment, ClassLoader.getResources should be returned.
* @param name the name of the resource to search for
* @return an enumeration containing all of the matching resources found
* @throws IOException
*/
- public Enumeration getResources(String name) throws IOException;
-
+ Enumeration getResources(String name) throws IOException;
+
/**
* In an OSGi environment, determin which bundle a URL originated from.
* In a non-OSGi environment, implementors should return null.
@@ -45,30 +45,30 @@ public interface IWeavingContext {
* @return
* @deprecated use getFile() or getClassLoaderName()
*/
- public String getBundleIdFromURL(URL url);
-
+ String getBundleIdFromURL(URL url);
+
/**
* In an environment with multiple class loaders allows each to be
* identified using something safer and possibly shorter than toString
* @return name of the associated class loader
*/
- public String getClassLoaderName ();
+ String getClassLoaderName();
- public ClassLoader getClassLoader();
+ ClassLoader getClassLoader();
/**
* Format a URL
* @return filename
*/
- public String getFile(URL url);
-
+ String getFile(URL url);
+
/**
* In an environment with multiple class loaders allows messages
* to identified according to the weaving context
- * @return short name
+ * @return short name
*/
- public String getId ();
-
+ String getId();
+
/**
* Return true if the classloader associated with this weaving context
* is the one that will define the class with the specified name.
@@ -77,16 +77,16 @@ public interface IWeavingContext {
* @param classname name of the class, eg. "java.lang.String"
* @return true if the associated classloader will define the class
*/
- public boolean isLocallyDefined(String classname);
+ boolean isLocallyDefined(String classname);
/**
- * Allow custom parsing of aop.xml or alternative mechanism for providing
+ * Allow custom parsing of aop.xml or alternative mechanism for providing
* Definitions
- *
+ *
* @param loader
* @param adaptor
* @return List containing 0 or more Definition instances
*/
- public List getDefinitions(final ClassLoader loader, WeavingAdaptor adaptor);
+ List getDefinitions(final ClassLoader loader, WeavingAdaptor adaptor);
}
diff --git a/weaver/src/main/java/org/aspectj/weaver/tools/cache/AsynchronousFileCacheBacking.java b/weaver/src/main/java/org/aspectj/weaver/tools/cache/AsynchronousFileCacheBacking.java
index bc0b678f4..8dada73f9 100644
--- a/weaver/src/main/java/org/aspectj/weaver/tools/cache/AsynchronousFileCacheBacking.java
+++ b/weaver/src/main/java/org/aspectj/weaver/tools/cache/AsynchronousFileCacheBacking.java
@@ -41,11 +41,11 @@ import org.aspectj.weaver.tools.TraceFactory;
* The in-memory cache is updated so that subsequent calls to {@link #get(CachedClassReference)}
* will not return the mapped value.
*
- *
+ *
* -
* An "update index" {@link AsyncCommand} is posted to the background
* thread so that the newly mapped value will be persisted (eventually)
- *
+ *
*
* The actual persistence is implemented by the concrete classes
*/
@@ -161,7 +161,7 @@ public abstract class AsynchronousFileCacheBacking extends AbstractIndexedFileCa
logger.error("remove(" + getCacheDirectory() + ") Failed to post remove command for " + key);
}
}
-
+
if (entry != null) {
if (!key.equals(entry.key)) {
if ((logger != null) && logger.isTraceEnabled()) {
@@ -331,7 +331,7 @@ public abstract class AsynchronousFileCacheBacking extends AbstractIndexedFileCa
return commandsQ.offer(cmd);
}
- public static interface AsynchronousFileCacheBackingCreator {
+ public interface AsynchronousFileCacheBackingCreator {
T create (File cacheDir);
}
/**
@@ -339,7 +339,7 @@ public abstract class AsynchronousFileCacheBacking extends AbstractIndexedFileCa
* {@link AsynchronousFileCacheBacking} instance to be executed
* on it asynchronously
*/
- public static interface AsyncCommand {
+ public interface AsyncCommand {
/**
* @return The {@link AsynchronousFileCacheBacking} on which
* this command is supposed to be executed
@@ -359,7 +359,7 @@ public abstract class AsynchronousFileCacheBacking extends AbstractIndexedFileCa
public final AsynchronousFileCacheBacking getCache () {
return cache;
}
-
+
@Override
public String toString() {
return getClass().getSimpleName() + "[" + getCache() + "]";
@@ -385,7 +385,7 @@ public abstract class AsynchronousFileCacheBacking extends AbstractIndexedFileCa
private final String key;
protected KeyedCommand (AsynchronousFileCacheBacking cache, String keyValue) {
super(cache);
-
+
if (LangUtil.isEmpty(keyValue)) {
throw new IllegalStateException("No key value");
}
@@ -408,7 +408,7 @@ public abstract class AsynchronousFileCacheBacking extends AbstractIndexedFileCa
super(cache, keyValue);
}
}
-
+
public static class InsertCommand extends KeyedCommand {
private final byte[] bytes;
diff --git a/weaver/src/main/java/org/aspectj/weaver/tools/cache/CacheBacking.java b/weaver/src/main/java/org/aspectj/weaver/tools/cache/CacheBacking.java
index bcf7c0b60..0a018d9c8 100644
--- a/weaver/src/main/java/org/aspectj/weaver/tools/cache/CacheBacking.java
+++ b/weaver/src/main/java/org/aspectj/weaver/tools/cache/CacheBacking.java
@@ -28,36 +28,36 @@ public interface CacheBacking {
* @param regex
* @return
*/
- public String[] getKeys(String regex);
+ String[] getKeys(String regex);
/**
* Remove an entry from the cache
*
* @param ref
*/
- public void remove(CachedClassReference ref);
+ void remove(CachedClassReference ref);
/**
* Clear the entire cache
*/
- public void clear();
+ void clear();
/**
* Get a cache entry
*
* @param ref entry to retrieve
* @param originalBytes Pre-weaving class bytes - required in order to
- * ensure that the cached entry refers to the same original class
+ * ensure that the cached entry refers to the same original class
* @return the cached bytes or null, if the entry does not exist
*/
- public CachedClassEntry get(CachedClassReference ref, byte[] originalBytes);
+ CachedClassEntry get(CachedClassReference ref, byte[] originalBytes);
/**
* Put an entry in the cache
*
* @param entry key of the entry
* @param originalBytes Pre-weaving class bytes - required in order to
- * ensure that the cached entry refers to the same original class
+ * ensure that the cached entry refers to the same original class
*/
- public void put(CachedClassEntry entry, byte[] originalBytes);
+ void put(CachedClassEntry entry, byte[] originalBytes);
}
diff --git a/weaver/src/test/java/org/aspectj/weaver/reflect/ReflectionWorldTest.java b/weaver/src/test/java/org/aspectj/weaver/reflect/ReflectionWorldTest.java
index ede4e26d1..1143f6d99 100644
--- a/weaver/src/test/java/org/aspectj/weaver/reflect/ReflectionWorldTest.java
+++ b/weaver/src/test/java/org/aspectj/weaver/reflect/ReflectionWorldTest.java
@@ -1,10 +1,10 @@
/* *******************************************************************
* Copyright (c) 2005,2017 Contributors.
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://eclipse.org/legal/epl-v10.html
+ * All rights reserved.
+ * This program and the accompanying materials are made available
+ * under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution and is available at
+ * http://eclipse.org/legal/epl-v10.html
* ******************************************************************/
package org.aspectj.weaver.reflect;
@@ -39,7 +39,7 @@ public class ReflectionWorldTest extends TestCase {
assertNotNull(rt);
assertEquals("Ljava/lang/Object;", rt.getSignature());
}
-
+
// Removed for now. In Spring the reflection worlds are customized by introducing new
// PCD handlers. It means more thought needs to be put into reusing worlds.
public void xtestReflectionWorldFactory() throws Exception {
@@ -53,31 +53,31 @@ public class ReflectionWorldTest extends TestCase {
ResolvedType stringClass1 = a.resolve(String.class);
assertNotNull(stringClass1);
-
+
ReflectionWorld b = ReflectionWorld.getReflectionWorldFor(wcl1);
-
+
// They should be the same because the classloader has not gone away
assertTrue(a==b);
-
+
cl1 = null;
for (int i=0;i<100;i++) {
System.gc(); // How robust is it that this should be causing the reference to be collected?
}
b = ReflectionWorld.getReflectionWorldFor(wcl1);
-
+
assertFalse(a==b);
-
+
cl1 = new URLClassLoader(new URL[] {}, parent);
wcl1 = new WeakClassLoaderReference(cl1);
a = ReflectionWorld.getReflectionWorldFor(wcl1);
b = ReflectionWorld.getReflectionWorldFor(wcl2);
assertFalse(a==b);
-
+
Field declaredField = ReflectionWorld.class.getDeclaredField("rworlds");
declaredField.setAccessible(true);
Map worlds = (Map)declaredField.get(null);
assertEquals(2, worlds.size());
-
+
cl2 = null;
for (int i=0;i<100;i++) {
System.gc(); // How robust is it that this should be causing the reference to be collected?
@@ -91,12 +91,12 @@ public class ReflectionWorldTest extends TestCase {
}
ReflectionWorld.getReflectionWorldFor(wcl1); // need to call this to trigger tidyup
assertEquals(0, worlds.size());
-
+
cl1 = new URLClassLoader(new URL[] {}, parent);
wcl1 = new WeakClassLoaderReference(cl1);
ReflectionWorld reflectionWorldFor = ReflectionWorld.getReflectionWorldFor(wcl1);
assertEquals(1, worlds.size());
- ReflectionWorld.cleanUpWorlds();
+ ReflectionWorld.cleanUpWorlds();
assertEquals(0, worlds.size());
}
@@ -112,10 +112,10 @@ public class ReflectionWorldTest extends TestCase {
assertEquals("int", UnresolvedType.INT, world.resolve(int.class));
assertEquals("void", UnresolvedType.VOID, world.resolve(void.class));
}
-
+
static class AbstractSuperClass {}
- static interface InterfaceOne {}
- static interface InterfaceTwo {}
+ interface InterfaceOne {}
+ interface InterfaceTwo {}
static class ID {}
static abstract class AbstractTestClass extends AbstractSuperClass implements InterfaceOne, InterfaceTwo {
@@ -124,9 +124,9 @@ public class ReflectionWorldTest extends TestCase {
// static class ConcreteClass extends AbstractTestClass {
static class ConcreteClass extends AbstractTestClass> {
}
-
+
static class Bar extends ConcreteClass {}
-
+
public void testGenerics() {
ReflectionWorld world = new ReflectionWorld(getClass().getClassLoader());
// world.lookupOrCreateName(UnresolvedType.forName(AbstractTestClass.class.getName()));
@@ -145,14 +145,14 @@ public class ReflectionWorldTest extends TestCase {
assertEquals("java.lang.String",stringType.getTypeName());
ResolvedType stringResolvedType = converter.fromType(stringType);
assertEquals("java.lang.String",stringResolvedType.getName());
-
+
// public String m() { return ""; }
method = TestClass2.class.getDeclaredMethod("m");
stringType = method.getGenericReturnType();
assertEquals("java.lang.String",stringType.getTypeName());
stringResolvedType = converter.fromType(stringType);
assertEquals("java.lang.String",stringResolvedType.getName());
-
+
// Verify that the conversion process creates the same thing as the bcel unpacking
// Here the return type is a non-static inner of a generic class
@@ -165,13 +165,13 @@ public class ReflectionWorldTest extends TestCase {
assertEquals(UnresolvedType.TypeKind.SIMPLE,rType_Inner.getTypekind());
ResolvedType rType_Outer = rType_Inner.getOuterClass();
assertEquals("Lorg/aspectj/weaver/reflect/ReflectionWorldTest$TestClass2;",rType_Outer.getSignature());
-
+
BcelWorld bWorld = new BcelWorld(getClass().getClassLoader(), IMessageHandler.THROW, null);
bWorld.setBehaveInJava5Way(true);
UnresolvedType javaUtilHashMap = UnresolvedType.forName("java.util.HashMap");
ReferenceType rawType = (ReferenceType) bWorld.resolve(javaUtilHashMap);
assertNotNull(rawType);
-
+
// Now use bcel to resolve the same m2 method, and compare the signatures of the return types
ResolvedType bResolved_TestClass2 = bWorld.resolve(UnresolvedType.forName(TestClass2.class.getName()));
assertNotNull(bResolved_TestClass2);
@@ -185,17 +185,17 @@ public class ReflectionWorldTest extends TestCase {
assertEquals(bType_Inner.getSignature(),rType_Inner.getSignature());
assertEquals(bType_Outer.getSignature(),rType_Outer.getSignature());
}
-
+
public void xtestTypeConversions_509327_2() throws Exception {
ReflectionWorld world = new ReflectionWorld(getClass().getClassLoader());
JavaLangTypeToResolvedTypeConverter converter = new JavaLangTypeToResolvedTypeConverter(world);
BcelWorld bWorld = new BcelWorld(getClass().getClassLoader(), IMessageHandler.THROW, null);
bWorld.setBehaveInJava5Way(true);
-
+
// Slightly more advanced, now the method is returning a parameterized form of the outer
// generic class
-
+
// public TestClass2.Inner m3() { return new TestClass2.Inner("Foo"); }
Method method = TestClass2.class.getDeclaredMethod("m3");
Type type_ParameterizedInner = method.getGenericReturnType();
@@ -213,7 +213,7 @@ public class ReflectionWorldTest extends TestCase {
assertEquals(UnresolvedType.TypeKind.SIMPLE,bType_Inner.getTypekind());
ResolvedType bType_Outer = bType_Inner.getOuterClass();
-
+
// Fields seem to lose it too, although the backinggenericmember has the info
// ResolvedMember bField_f = findField(bResolved_TestClass2,"f");
// ResolvedMember backingGenericMember = bField_f.getBackingGenericMember();
@@ -223,29 +223,29 @@ public class ReflectionWorldTest extends TestCase {
// System.out.println(bField_f.getSignature());
// System.out.println(bField_f.getGenericReturnType());
}
-
+
// public void testbar() throws Exception {
// ReflectionWorld world = new ReflectionWorld(getClass().getClassLoader());
// JavaLangTypeToResolvedTypeConverter converter = new JavaLangTypeToResolvedTypeConverter(world);
-//
+//
// // public TestClass2.Inner m3() { return new TestClass2.Inner("Foo"); }
// Method method = TestClass2.class.getDeclaredMethod("m3");
// Type type_ParameterizedInner = method.getGenericReturnType();
// assertEquals("org.aspectj.weaver.reflect.ReflectionWorldTest.org.aspectj.weaver.reflect.ReflectionWorldTest$TestClass2.Inner",type_ParameterizedInner.getTypeName());
// ResolvedType rType_ParameterizedInner = converter.fromType(type_ParameterizedInner);
-// System.out.println(rType_ParameterizedInner);
+// System.out.println(rType_ParameterizedInner);
// System.out.println(type_ParameterizedInner.getTypeName());
// }
-//
+//
// public void testfoo() {
// ReflectionWorld world = new ReflectionWorld(getClass().getClassLoader());
// JavaLangTypeToResolvedTypeConverter converter = new JavaLangTypeToResolvedTypeConverter(world);
// BcelWorld bWorld = new BcelWorld(getClass().getClassLoader(), IMessageHandler.THROW, null);
// bWorld.setBehaveInJava5Way(true);
-//
+//
//
// ResolvedType bResolved_TestClass2 = bWorld.resolve(UnresolvedType.forName(TestClass2.class.getName()));
-// ResolvedMember bField_f = findField(bResolved_TestClass2,"f");
+// ResolvedMember bField_f = findField(bResolved_TestClass2,"f");
// System.out.println(bField_f);
// System.out.println(bField_f.getGenericReturnType());
// System.out.println(bField_f.getReturnType());
@@ -255,7 +255,7 @@ public class ReflectionWorldTest extends TestCase {
static class TestClass {
public String m() { return ""; }
}
-
+
static class TestClass2 {
class Inner {
T t;
@@ -277,7 +277,7 @@ public class ReflectionWorldTest extends TestCase {
}
return null;
}
-
+
private ResolvedMember findField(ResolvedType resolvedType, String fieldName) {
for (ResolvedMember field: resolvedType.getDeclaredFields()) {
if (field.getName().equals(fieldName)) {
--
cgit v1.2.3