org.apache.tomcat.util.bcel.classfile
Class Unknown
java.lang.Object
org.apache.tomcat.util.bcel.classfile.Attribute
org.apache.tomcat.util.bcel.classfile.Unknown
- All Implemented Interfaces:
- Serializable, Cloneable
public final class Unknown
- extends Attribute
This class represents a reference to an unknown (i.e.,
application-specific) attribute of a class. It is instantiated from the
Attribute.readAttribute() method. Applications that need to
read in application-specific attributes should create an AttributeReader implementation and
attach it via Attribute.addAttributeReader.
- Version:
- $Id: Unknown.java 1057670 2011-01-11 14:52:05Z markt $
- Author:
- M. Dahm
- See Also:
Attribute
,
AttributeReader
,
Serialized Form
Constructor Summary |
Unknown(int name_index,
int length,
byte[] bytes,
ConstantPool constant_pool)
Create a non-standard attribute. |
Unknown
public Unknown(int name_index,
int length,
byte[] bytes,
ConstantPool constant_pool)
- Create a non-standard attribute.
- Parameters:
name_index
- Index in constant poollength
- Content length in bytesbytes
- Attribute contentsconstant_pool
- Array of constants
dump
public final void dump(DataOutputStream file)
throws IOException
- Dump unknown bytes to file stream.
- Overrides:
dump
in class Attribute
- Parameters:
file
- Output file stream
- Throws:
IOException
getName
public final String getName()
- Overrides:
getName
in class Attribute
- Returns:
- name of attribute.
toString
public final String toString()
- Overrides:
toString
in class Attribute
- Returns:
- String representation.
copy
public Attribute copy(ConstantPool _constant_pool)
- Specified by:
copy
in class Attribute
- Returns:
- deep copy of this attribute
Copyright © 2000-2012 Apache Software Foundation. All Rights Reserved.