com.vladium.jcd.cls.attribute
Class SourceFileAttribute_info

java.lang.Object
  extended by com.vladium.jcd.cls.attribute.Attribute_info
      extended by com.vladium.jcd.cls.attribute.SourceFileAttribute_info
All Implemented Interfaces:
IClassFormatOutput, java.lang.Cloneable

public final class SourceFileAttribute_info
extends Attribute_info

Author:
(C) 2001, Vlad Roubtsov

Field Summary
 int m_sourcefile_index
           
 
Fields inherited from class com.vladium.jcd.cls.attribute.Attribute_info
ATTRIBUTE_BRIDGE, ATTRIBUTE_CODE, ATTRIBUTE_CONSTANT_VALUE, ATTRIBUTE_EXCEPTIONS, ATTRIBUTE_INNERCLASSES, ATTRIBUTE_LINE_NUMBER_TABLE, ATTRIBUTE_SOURCEFILE, ATTRIBUTE_SYNTHETIC, m_attribute_length, m_name_index
 
Constructor Summary
SourceFileAttribute_info(int attribute_name_index)
           
SourceFileAttribute_info(int attribute_name_index, long attribute_length, UDataInputStream bytes)
           
 
Method Summary
 void accept(IAttributeVisitor visitor, java.lang.Object ctx)
           
 java.lang.Object clone()
          Performs a deep copy.
 CONSTANT_Utf8_info getSourceFile(ClassDef cls)
           
 long length()
          Returns the total length of this attribute when converted to .class format [including the 6-byte header]
 java.lang.String toString()
           
 void writeInClassFormat(UDataOutputStream out)
           
 
Methods inherited from class com.vladium.jcd.cls.attribute.Attribute_info
getName, new_Attribute_info
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

m_sourcefile_index

public int m_sourcefile_index
Constructor Detail

SourceFileAttribute_info

public SourceFileAttribute_info(int attribute_name_index)

SourceFileAttribute_info

SourceFileAttribute_info(int attribute_name_index,
                         long attribute_length,
                         UDataInputStream bytes)
                   throws java.io.IOException
Throws:
java.io.IOException
Method Detail

length

public long length()
Description copied from class: Attribute_info
Returns the total length of this attribute when converted to .class format [including the 6-byte header]

Specified by:
length in class Attribute_info

getSourceFile

public CONSTANT_Utf8_info getSourceFile(ClassDef cls)

accept

public void accept(IAttributeVisitor visitor,
                   java.lang.Object ctx)
Specified by:
accept in class Attribute_info

toString

public java.lang.String toString()
Specified by:
toString in class Attribute_info

clone

public java.lang.Object clone()
Performs a deep copy.

Overrides:
clone in class Attribute_info

writeInClassFormat

public void writeInClassFormat(UDataOutputStream out)
                        throws java.io.IOException
Specified by:
writeInClassFormat in interface IClassFormatOutput
Overrides:
writeInClassFormat in class Attribute_info
Throws:
java.io.IOException