|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--at.dms.classfile.Member | +--at.dms.classfile.FieldInfo
VMS 4.5: Fields Each field is described by this structure. Used to make up new field entries. Fields for a class can have an additional "ConstantValue" attribute associated them, which the java compiler uses to represent things like static final int blah = foo;
Constructor Summary | |
FieldInfo(java.io.DataInput in,
ConstantPool cp)
Constructs a field entry from a class file stream. |
|
FieldInfo(short modifiers,
java.lang.String name,
java.lang.String type,
java.lang.Object value,
boolean deprecated,
boolean synthetic)
Constructs a field entry. |
Method Summary | |
java.lang.Object |
getConstantValue()
Returns the value of the this field. |
java.lang.String |
getName()
Returns the name of the this field. |
java.lang.String |
getSignature()
Returns the type of the this field. |
void |
getSignature(java.lang.String type)
Returns the type of the this field. |
boolean |
isDeprecated()
Returns true if the field is deprecated. |
boolean |
isSynthetic()
Returns true if the field is synthetic. |
(package private) void |
resolveConstants(ConstantPool cp)
Insert or check location of constant value on constant pool. |
void |
setConstantValue(java.lang.Object value)
Sets the value of the this field. |
void |
setDeprecated(boolean deprecated)
Sets the deprecated attribute of this field. |
void |
setName(java.lang.String name)
Sets the name of the this field. |
void |
setSynthetic(boolean synthetic)
Returns true if the field is synthetic. |
(package private) void |
write(ConstantPool cp,
java.io.DataOutput out)
Write this class into the the file (out) getting data position from the constant pool. |
Methods inherited from class at.dms.classfile.Member |
getModifiers, setModifiers |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public FieldInfo(short modifiers, java.lang.String name, java.lang.String type, java.lang.Object value, boolean deprecated, boolean synthetic)
modifiers
- Access permission to and properties of the field.name
- The name of the field.type
- The type signature.value
- The value of a constant field that must be (explicitly or implicitly)
static.deprecated
- Is this field deprecated?synthetic
- Is this field synthesized by the compiler?public FieldInfo(java.io.DataInput in, ConstantPool cp) throws java.io.IOException, ClassFileFormatException
in
- the stream to read fromcp
- the constant pooljava.io.IOException
- an io problem has occuredClassFileFormatException
- attempt to
write a bad classfile infoMethod Detail |
public java.lang.String getName()
getName
in class Member
public void setName(java.lang.String name)
public java.lang.String getSignature()
getSignature
in class Member
public void getSignature(java.lang.String type)
public java.lang.Object getConstantValue()
public void setConstantValue(java.lang.Object value)
public boolean isDeprecated()
public void setDeprecated(boolean deprecated)
public boolean isSynthetic()
public void setSynthetic(boolean synthetic)
void resolveConstants(ConstantPool cp) throws ClassFileFormatException
cp
- the constant pool for this classvoid write(ConstantPool cp, java.io.DataOutput out) throws java.io.IOException, ClassFileFormatException
cp
- The constant pool that contain all data.out
- The file where to write this object info.java.io.IOException
- An io problem has occured.ClassFileFormatException
- Attempt to write a bad classfile info.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |