|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.aspectj.apache.bcel.classfile.Modifiers
org.aspectj.apache.bcel.generic.FieldGenOrMethodGen
org.aspectj.apache.bcel.generic.FieldGen
public class FieldGen
Template class for building up a field. The only extraordinary thing one can do is to add a constant value attribute to a field (which must of course be compatible with the declared type).
Field
Constructor Summary | |
---|---|
FieldGen(Field field,
ConstantPool cp)
Instantiate from existing field. |
|
FieldGen(int modifiers,
Type type,
java.lang.String name,
ConstantPool cpool)
Declare a field. |
Method Summary | |
---|---|
Field |
getField()
Get field object after having set up all necessary values. |
java.lang.String |
getInitialValue()
|
java.lang.String |
getSignature()
|
void |
setInitialStringValue(java.lang.String value)
|
void |
setValue(int index)
|
void |
setValue(java.lang.String constantString)
|
java.lang.String |
toString()
Return string representation close to declaration format, `public static final short MAX = 100', e.g.. |
void |
wipeValue()
|
Methods inherited from class org.aspectj.apache.bcel.generic.FieldGenOrMethodGen |
---|
addAnnotation, addAttribute, getAnnotations, getAttributes, getAttributesImmutable, getConstantPool, getName, getType, removeAnnotation, removeAnnotations, removeAttribute, removeAttributes, setConstantPool, setName, setType |
Methods inherited from class org.aspectj.apache.bcel.classfile.Modifiers |
---|
getModifiers, isAbstract, isBridge, isFinal, isInterface, isNative, isPrivate, isProtected, isPublic, isStatic, isStrictfp, isSynchronized, isTransient, isVarargs, isVolatile, setModifiers |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public FieldGen(int modifiers, Type type, java.lang.String name, ConstantPool cpool)
modifiers
- access qualifierstype
- field typename
- field namecpool
- constant poolpublic FieldGen(Field field, ConstantPool cp)
field
- Field objectcp
- constant pool (must contain the same entries as the field's constant pool)Method Detail |
---|
public void setValue(int index)
public void setValue(java.lang.String constantString)
public void wipeValue()
public Field getField()
public java.lang.String getSignature()
getSignature
in class FieldGenOrMethodGen
public java.lang.String getInitialValue()
public void setInitialStringValue(java.lang.String value)
public final java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |