ProGuard

proguard.classfile
Class StringCpInfo

java.lang.Object
  extended byproguard.classfile.CpInfo
      extended byproguard.classfile.StringCpInfo
All Implemented Interfaces:
VisitorAccepter

public class StringCpInfo
extends CpInfo

Representation of a 'string' entry in the ConstantPool.


Field Summary
 ClassFile referencedClassFile
          An extra field pointing to the referenced ClassFile object, if this string is being used in Class.forName() or .class constructs.
 int u2stringIndex
           
 
Fields inherited from class proguard.classfile.CpInfo
visitorInfo
 
Constructor Summary
protected StringCpInfo()
           
 
Method Summary
 void accept(ClassFile classFile, CpInfoVisitor cpInfoVisitor)
          Accepts the given visitor.
 String getString(ClassFile classFile)
          Returns the string value.
 int getTag()
          Returns the class pool info tag that specifies the entry 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.
protected  void writeInfo(DataOutput dout)
          Writes the 'info' data following the u1tag byte.
 
Methods inherited from class proguard.classfile.CpInfo
create, createOrShare, getVisitorInfo, setVisitorInfo, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

u2stringIndex

public int u2stringIndex

referencedClassFile

public ClassFile referencedClassFile
An extra field pointing to the referenced ClassFile object, if this string is being used in Class.forName() or .class constructs. This field is filled out by the ClassFileReferenceInitializer. References to library class files are not filled out.

Constructor Detail

StringCpInfo

protected StringCpInfo()
Method Detail

getString

public String getString(ClassFile classFile)
Returns the string value.


getTag

public int getTag()
Description copied from class: CpInfo
Returns the class pool info tag that specifies the entry type.

Specified by:
getTag in class CpInfo

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

accept

public void accept(ClassFile classFile,
                   CpInfoVisitor cpInfoVisitor)
Description copied from class: CpInfo
Accepts the given visitor.

Specified by:
accept in class CpInfo

referencedClassAccept

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


ProGuard