< prev index next >
src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Method.java
Print this page
@@ -31,11 +31,10 @@
/**
* This class represents the method info structure, i.e., the representation
* for a method in the class. See JVM specification for details.
* A method has access flags, a name, a signature and a number of attributes.
*
- * @version $Id$
*/
public final class Method extends FieldOrMethod {
private static BCELComparator bcelComparator = new BCELComparator() {
@@ -114,11 +113,11 @@
/**
* @return Code attribute of method, if any
*/
- public final Code getCode() {
+ public Code getCode() {
for (final Attribute attribute : super.getAttributes()) {
if (attribute instanceof Code) {
return (Code) attribute;
}
}
@@ -128,11 +127,11 @@
/**
* @return ExceptionTable attribute of method, if any, i.e., list all
* exceptions the method may throw not exception handlers!
*/
- public final ExceptionTable getExceptionTable() {
+ public ExceptionTable getExceptionTable() {
for (final Attribute attribute : super.getAttributes()) {
if (attribute instanceof ExceptionTable) {
return (ExceptionTable) attribute;
}
}
@@ -141,11 +140,11 @@
/** @return LocalVariableTable of code attribute if any, i.e. the call is forwarded
* to the Code atribute.
*/
- public final LocalVariableTable getLocalVariableTable() {
+ public LocalVariableTable getLocalVariableTable() {
final Code code = getCode();
if (code == null) {
return null;
}
return code.getLocalVariableTable();
@@ -153,11 +152,11 @@
/** @return LineNumberTable of code attribute if any, i.e. the call is forwarded
* to the Code atribute.
*/
- public final LineNumberTable getLineNumberTable() {
+ public LineNumberTable getLineNumberTable() {
final Code code = getCode();
if (code == null) {
return null;
}
return code.getLineNumberTable();
@@ -169,11 +168,11 @@
* `public static void main(String[] args) throws IOException', e.g.
*
* @return String representation of the method.
*/
@Override
- public final String toString() {
+ public String toString() {
final String access = Utility.accessToString(super.getAccessFlags());
// Get name and signature from constant pool
ConstantUtf8 c = (ConstantUtf8) super.getConstantPool().getConstant(super.getSignatureIndex(), Const.CONSTANT_Utf8);
String signature = c.getBytes();
c = (ConstantUtf8) super.getConstantPool().getConstant(super.getNameIndex(), Const.CONSTANT_Utf8);
@@ -198,11 +197,11 @@
/**
* @return deep copy of this method
*/
- public final Method copy( final ConstantPool _constant_pool ) {
+ public Method copy( final ConstantPool _constant_pool ) {
return (Method) copy_(_constant_pool);
}
/**
< prev index next >