Top Description Fields Constructors Methods
org.aspectj.apache.bcel.classfile

public final Class StackMap

extends Attribute
Class Inheritance
Imports
java.io.DataInputStream, .DataOutputStream, .IOException, org.aspectj.apache.bcel.Constants

This class represents a stack map attribute used for preverification of Java classes for the Java 2 Micro Edition (J2ME). This attribute is used by the KVM and contained within the Code attribute of a method. See CLDC specification 5.3.1.2
Author
M. Dahm
Version
$Id: StackMap.java,v 1.6 2009/09/15 19:40:12 aclement Exp $
See Also
Code, StackMapEntry, StackMapType

Field Summary

Modifier and TypeField and Description
private StackMapEntry[]
private int
Inherited from org.aspectj.apache.bcel.classfile.Attribute:
cpoollengthnameIndexNoAttributestag

Constructor Summary

AccessConstructor and Description
public
StackMap(int name_index, int length, StackMapEntry[] map, ConstantPool constant_pool)

pack-priv
StackMap(int
Index of name
name_index
,
int
Content length in bytes
length
,
DataInputStream
Input stream
file
,
ConstantPool
Array of constants
constant_pool
)

Construct object from file stream.

Method Summary

Modifier and TypeMethod and Description
public void
accept(ClassVisitor
Visitor object
v
)

Implements abstract org.aspectj.apache.bcel.classfile.Attribute.accept.

Implements org.aspectj.apache.bcel.classfile.Node.accept.

Called by objects that are traversing the nodes of the tree implicitely defined by the contents of a Java class.
public final void
dump(DataOutputStream
Output file stream
file
)

Overrides org.aspectj.apache.bcel.classfile.Attribute.dump.

Dump line number table attribute to file stream in binary format.
public final int
public final StackMapEntry[]

Returns:

Array of stack map entries
getStackMap
()

public final void
setStackMap(StackMapEntry[]
Array of stack map entries
map
)

public final String

Returns:

String representation.
toString
()

Overrides org.aspectj.apache.bcel.classfile.Attribute.toString.

Returns a string representation of the object.
Inherited from org.aspectj.apache.bcel.classfile.Attribute:
getConstantPoolgetLengthgetNamegetNameIndexgetTagreadAttribute

Field Detail

mapback to summary
private StackMapEntry[] map
map_lengthback to summary
private int map_length

Constructor Detail

StackMapback to summary
public StackMap(int name_index, int length, StackMapEntry[] map, ConstantPool constant_pool)
StackMapback to summary
pack-priv StackMap(int name_index, int length, DataInputStream file, ConstantPool constant_pool) throws IOException

Construct object from file stream.

Parameters
name_index:int

Index of name

length:int

Content length in bytes

file:DataInputStream

Input stream

constant_pool:ConstantPool

Array of constants

Method Detail

acceptback to summary
public void accept(ClassVisitor v)

Implements abstract org.aspectj.apache.bcel.classfile.Attribute.accept.

Implements org.aspectj.apache.bcel.classfile.Node.accept.

Called by objects that are traversing the nodes of the tree implicitely defined by the contents of a Java class. I.e., the hierarchy of methods, fields, attributes, etc. spawns a tree of objects.

Parameters
v:ClassVisitor

Visitor object

Annotations
@Override
dumpback to summary
public final void dump(DataOutputStream file) throws IOException

Overrides org.aspectj.apache.bcel.classfile.Attribute.dump.

Dump line number table attribute to file stream in binary format.

Parameters
file:DataOutputStream

Output file stream

Annotations
@Override
getMapLengthback to summary
public final int getMapLength()
getStackMapback to summary
public final StackMapEntry[] getStackMap()
Returns:StackMapEntry[]

Array of stack map entries

setStackMapback to summary
public final void setStackMap(StackMapEntry[] map)
Parameters
map:StackMapEntry[]

Array of stack map entries

toStringback to summary
public final String toString()

Overrides org.aspectj.apache.bcel.classfile.Attribute.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object.

Returns:String

String representation.

Annotations
@Override