Author: ebourg
Date: Thu Feb 5 14:46:49 2015
New Revision: 1657593
URL: http://svn.apache.org/r1657593
Log:
Moved the copy() method of Runtime*ParameterAnnotations in the parent class
(BCEL-203)
Modified:
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/ParameterAnnotations.java
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeInvisibleParameterAnnotations.java
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeVisibleParameterAnnotations.java
Modified:
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/ParameterAnnotations.java
URL:
http://svn.apache.org/viewvc/commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/ParameterAnnotations.java?rev=1657593&r1=1657592&r2=1657593&view=diff
==============================================================================
---
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/ParameterAnnotations.java
(original)
+++
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/ParameterAnnotations.java
Thu Feb 5 14:46:49 2015
@@ -127,4 +127,13 @@ public abstract class ParameterAnnotatio
}
}
+
+ /**
+ * @return deep copy of this attribute
+ */
+ @Override
+ public Attribute copy( ConstantPool constant_pool ) {
+ ParameterAnnotations c = (ParameterAnnotations) clone();
+ return c;
+ }
}
Modified:
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeInvisibleParameterAnnotations.java
URL:
http://svn.apache.org/viewvc/commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeInvisibleParameterAnnotations.java?rev=1657593&r1=1657592&r2=1657593&view=diff
==============================================================================
---
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeInvisibleParameterAnnotations.java
(original)
+++
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeInvisibleParameterAnnotations.java
Thu Feb 5 14:46:49 2015
@@ -22,7 +22,7 @@ import java.io.IOException;
import org.apache.bcel.Constants;
/**
- * represents a parameter annotation that is represented in the class file
+ * Represents a parameter annotation that is represented in the class file
* but is not provided to the JVM.
*
* @version $Id: RuntimeInvisibleParameterAnnotations
@@ -32,27 +32,15 @@ import org.apache.bcel.Constants;
public class RuntimeInvisibleParameterAnnotations extends ParameterAnnotations
{
private static final long serialVersionUID = 270153155050617200L;
-
-
+
/**
* @param name_index Index pointing to the name <em>Code</em>
* @param length Content length in bytes
* @param input Input stream
* @param constant_pool Array of constants
*/
- RuntimeInvisibleParameterAnnotations(int name_index, int length, DataInput
input,
- ConstantPool constant_pool) throws IOException {
- super(Constants.ATTR_RUNTIME_INVISIBLE_PARAMETER_ANNOTATIONS,
name_index, length, input,
- constant_pool);
- }
-
-
- /**
- * @return deep copy of this attribute
- */
- @Override
- public Attribute copy( ConstantPool constant_pool ) {
- Annotations c = (Annotations) clone();
- return c;
+ RuntimeInvisibleParameterAnnotations(int name_index, int length, DataInput
input, ConstantPool constant_pool)
+ throws IOException {
+ super(Constants.ATTR_RUNTIME_INVISIBLE_PARAMETER_ANNOTATIONS,
name_index, length, input, constant_pool);
}
}
Modified:
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeVisibleParameterAnnotations.java
URL:
http://svn.apache.org/viewvc/commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeVisibleParameterAnnotations.java?rev=1657593&r1=1657592&r2=1657593&view=diff
==============================================================================
---
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeVisibleParameterAnnotations.java
(original)
+++
commons/proper/bcel/trunk/src/main/java/org/apache/bcel/classfile/RuntimeVisibleParameterAnnotations.java
Thu Feb 5 14:46:49 2015
@@ -22,7 +22,7 @@ import java.io.IOException;
import org.apache.bcel.Constants;
/**
- * represents a parameter annotation that is represented in the class file
+ * Represents a parameter annotation that is represented in the class file
* and is provided to the JVM.
*
* @version $Id: RuntimeVisibleParameterAnnotations
@@ -32,8 +32,7 @@ import org.apache.bcel.Constants;
public class RuntimeVisibleParameterAnnotations extends ParameterAnnotations {
private static final long serialVersionUID = -4266572854750267070L;
-
-
+
/**
* @param name_index Index pointing to the name <em>Code</em>
* @param length Content length in bytes
@@ -44,14 +43,4 @@ public class RuntimeVisibleParameterAnno
throws IOException {
super(Constants.ATTR_RUNTIME_VISIBLE_PARAMETER_ANNOTATIONS,
name_index, length, input, constant_pool);
}
-
-
- /**
- * @return deep copy of this attribute
- */
- @Override
- public Attribute copy( ConstantPool constant_pool ) {
- Annotations c = (Annotations) clone();
- return c;
- }
}