Top Description Fields Constructors Methods
org.jboss.classfilewriter.code

public Class LocalVariableState

extends Object
Class Inheritance
Imports
java.util.ArrayList, .Collections, .List, org.jboss.classfilewriter.ClassMethod, .InvalidBytecodeException, org.jboss.classfilewriter.constpool.ConstPool

In immutable local variable state
Author
Stuart Douglas

Field Summary

Modifier and TypeField and Description
private final ConstPool
private final List<StackEntry>
contents

The contents, null is used to represent the additional spot taken up by a wide variable.

Constructor Summary

AccessConstructor and Description
public
LocalVariableState(ClassMethod method)

construct the initial local variable state for a method

public
LocalVariableState(final ConstPool pool, final String... entries)

private
LocalVariableState(final List<StackEntry> contents, ConstPool constPool)

Method Summary

Modifier and TypeMethod and Description
public LocalVariableState
public StackEntry
get(int index)

public List<StackEntry>
public int
size()

public LocalVariableState
store(int index, StackEntry entry)

public LocalVariableState
storeWide(int index, StackEntry entry)

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.
public LocalVariableState
updateMerged(int pos, StackEntry frame)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

constPoolback to summary
private final ConstPool constPool
contentsback to summary
private final List<StackEntry> contents

The contents, null is used to represent the additional spot taken up by a wide variable.

This list may be shared between frames, so it must never be modified

The very first element represents the first local variable (this for non static methods)

Constructor Detail

LocalVariableStateback to summary
public LocalVariableState(ClassMethod method)

construct the initial local variable state for a method

LocalVariableStateback to summary
public LocalVariableState(final ConstPool pool, final String... entries)
LocalVariableStateback to summary
private LocalVariableState(final List<StackEntry> contents, ConstPool constPool)

Method Detail

constructorCallback to summary
public LocalVariableState constructorCall(StackEntry entry)
getback to summary
public StackEntry get(int index)
getContentsback to summary
public List<StackEntry> getContents()
sizeback to summary
public int size()
storeback to summary
public LocalVariableState store(int index, StackEntry entry)
storeWideback to summary
public LocalVariableState storeWide(int index, StackEntry entry)
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object.

Returns:String

a string representation of the object.

Annotations
@Override
updateMergedback to summary
public LocalVariableState updateMerged(int pos, StackEntry frame)