ProGuard

proguard.classfile
Class RefCpInfo

java.lang.Object
  extended byproguard.classfile.CpInfo
      extended byproguard.classfile.RefCpInfo
All Implemented Interfaces:
VisitorAccepter
Direct Known Subclasses:
FieldrefCpInfo, InterfaceMethodrefCpInfo, MethodrefCpInfo

public abstract class RefCpInfo
extends CpInfo

Representation of a 'ref'-type entry in the ConstantPool.


Field Summary
 ClassFile referencedClassFile
          An extra field pointing to the referenced ClassFile object.
 MemberInfo referencedMemberInfo
          An extra field optionally pointing to the referenced MemberInfo object.
 int u2classIndex
           
 int u2nameAndTypeIndex
           
 
Fields inherited from class proguard.classfile.CpInfo
visitorInfo
 
Constructor Summary
protected RefCpInfo()
           
 
Method Summary
 int getClassIndex()
          Returns the class index.
 String getClassName(ClassFile classFile)
          Returns the class name.
 String getName(ClassFile classFile)
          Returns the method/field name.
 int getNameAndTypeIndex()
          Returns the name-and-type index.
 String getType(ClassFile classFile)
          Returns the type.
protected  void readInfo(DataInput din)
          Reads the 'info' data following the u1tag byte.
 void referencedClassAccept(ClassFileVisitor classFileVisitor)
          Lets the referenced class file accept the given visitor.
 void referencedMemberInfoAccept(MemberInfoVisitor memberInfoVisitor)
          Lets the referenced class member accept the given visitor.
 void setNameAndTypeIndex(int index)
          Sets the name-and-type index.
protected  void writeInfo(DataOutput dout)
          Writes the 'info' data following the u1tag byte.
 
Methods inherited from class proguard.classfile.CpInfo
accept, create, createOrShare, getTag, getVisitorInfo, setVisitorInfo, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

u2classIndex

public int u2classIndex

u2nameAndTypeIndex

public int u2nameAndTypeIndex

referencedClassFile

public ClassFile referencedClassFile
An extra field pointing to the referenced ClassFile object. This field is typically filled out by the ClassFileReferenceInitializer.


referencedMemberInfo

public MemberInfo referencedMemberInfo
An extra field optionally pointing to the referenced MemberInfo object. This field is typically filled out by the ClassFileReferenceInitializer.

Constructor Detail

RefCpInfo

protected RefCpInfo()
Method Detail

getClassIndex

public int getClassIndex()
Returns the class index.


getNameAndTypeIndex

public int getNameAndTypeIndex()
Returns the name-and-type index.


setNameAndTypeIndex

public void setNameAndTypeIndex(int index)
Sets the name-and-type index.


getClassName

public String getClassName(ClassFile classFile)
Returns the class name.


getName

public String getName(ClassFile classFile)
Returns the method/field name.


getType

public String getType(ClassFile classFile)
Returns the type.


readInfo

protected void readInfo(DataInput din)
                 throws IOException
Description copied from class: CpInfo
Reads the 'info' data following the u1tag byte.

Specified by:
readInfo in class CpInfo
Throws:
IOException

writeInfo

protected void writeInfo(DataOutput dout)
                  throws IOException
Description copied from class: CpInfo
Writes the 'info' data following the u1tag byte.

Specified by:
writeInfo in class CpInfo
Throws:
IOException

referencedClassAccept

public void referencedClassAccept(ClassFileVisitor classFileVisitor)
Lets the referenced class file accept the given visitor.


referencedMemberInfoAccept

public void referencedMemberInfoAccept(MemberInfoVisitor memberInfoVisitor)
Lets the referenced class member accept the given visitor.


ProGuard