org.fife.rsta.ac.java.classreader
Class MemberInfo

java.lang.Object
  extended by org.fife.rsta.ac.java.classreader.MemberInfo
Direct Known Subclasses:
FieldInfo, MethodInfo

public abstract class MemberInfo
extends Object

Base class for information about members (fields and methods).

Version:
1.0
Author:
Robert Futrell
See Also:
FieldInfo, MethodInfo

Field Summary
protected  ClassFile cf
          The class file in which this method is defined.
static String DEPRECATED
          Attribute marking a member as deprecated.
 
Constructor Summary
protected MemberInfo(ClassFile cf, int accessFlags)
          Constructor.
 
Method Summary
 int getAccessFlags()
          Returns the access flags for this field.
 ClassFile getClassFile()
          Returns the parent class file.
abstract  String getDescriptor()
          Returns the descriptor of this member.
abstract  String getName()
          Returns the name of this member.
 boolean isDeprecated()
          Returns whether this member is deprecated.
 boolean isFinal()
          Returns whether this member is final.
 boolean isStatic()
          Returns whether this member is static.
protected  AttributeInfo readAttribute(DataInputStream in, String attrName, int attrLength)
          Reads attributes common to all members.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

cf

protected ClassFile cf
The class file in which this method is defined.


DEPRECATED

public static final String DEPRECATED
Attribute marking a member as deprecated.

See Also:
Constant Field Values
Constructor Detail

MemberInfo

protected MemberInfo(ClassFile cf,
                     int accessFlags)
Constructor.

Parameters:
cf - The class file defining this member.
Method Detail

getAccessFlags

public int getAccessFlags()
Returns the access flags for this field.

Returns:
The access flags, as a bit field.
See Also:
AccessFlags

getClassFile

public ClassFile getClassFile()
Returns the parent class file.

Returns:
The parent class file.

getName

public abstract String getName()
Returns the name of this member.

Returns:
The name of this member.

isDeprecated

public boolean isDeprecated()
Returns whether this member is deprecated.

Returns:
Whether this member is deprecated.

getDescriptor

public abstract String getDescriptor()
Returns the descriptor of this member.

Returns:
The descriptor of this member.

isFinal

public boolean isFinal()
Returns whether this member is final.

Returns:
Whether this member is final.

isStatic

public boolean isStatic()
Returns whether this member is static.

Returns:
Whether this member is static.

readAttribute

protected AttributeInfo readAttribute(DataInputStream in,
                                      String attrName,
                                      int attrLength)
                               throws IOException
Reads attributes common to all members. If the specified attribute is not common to members, the attribute returned is an "unsupported" attribute.

Parameters:
in -
attrName -
attrLength -
Returns:
Throws:
IOException


Copyright © 2003-2011. All Rights Reserved.