fr.umlv.corosol.classfile.attribute.impl
Class AbstractJAttribute

java.lang.Object
  extended by fr.umlv.corosol.classfile.attribute.impl.AbstractJAttribute
All Implemented Interfaces:
JAttribute, JClassFileItem, JObject
Direct Known Subclasses:
DefaultJCodeAttribute, DefaultJConstantValueAttribute, DefaultJExceptionsAttribute, JUnknownAttribute

public abstract class AbstractJAttribute
extends java.lang.Object
implements JAttribute

The base class of classes implementing an classfile attribute.

Author:
Christophe Deleray

Field Summary
 
Fields inherited from interface fr.umlv.corosol.classfile.attribute.JAttribute
CODE, CONSTANT_VALUE, DEPRECATED, EXCEPTIONS, INNER_CLASSES, LINE_NUMBER_TABLE, LOCAL_VARIABLE_TABLE, SOURCE_FILE, SYNTHETIC
 
Method Summary
 JConstantPool getConstantPool()
          Returns the constant pool of this classfile attribute.
 java.lang.String getName()
          Returns the attribute name.
abstract  int getSize()
          Returns the size of the attribute in bytes.
 void setConstantPool(JConstantPool constantPool)
          Sets the constant pool of this classfile attribute.
abstract  java.lang.String toString()
          Returns a string representation of this classfile attribute.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface fr.umlv.corosol.classfile.JClassFileItem
readItem, writeItem
 

Method Detail

getConstantPool

public JConstantPool getConstantPool()
Returns the constant pool of this classfile attribute.

Specified by:
getConstantPool in interface JClassFileItem

setConstantPool

public void setConstantPool(JConstantPool constantPool)
Sets the constant pool of this classfile attribute.

Specified by:
setConstantPool in interface JClassFileItem
Parameters:
constantPool - the constant Pool

getName

public java.lang.String getName()
Returns the attribute name.

Specified by:
getName in interface JAttribute

getSize

public abstract int getSize()
Returns the size of the attribute in bytes.

Specified by:
getSize in interface JAttribute

toString

public abstract java.lang.String toString()
Returns a string representation of this classfile attribute.

Specified by:
toString in interface JAttribute
Overrides:
toString in class java.lang.Object
Returns:
a string representing this classfile attribute