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

public final Class ConstantMethodHandle

extends Constant
Class Inheritance
Imports
java.io.DataInput, .DataOutputStream, .IOException, org.apache.bcel.Const

This class is derived from the abstract Constant and represents a reference to a method handle.
Since
6.0
See Also
Constant

Field Summary

Modifier and TypeField and Description
private int
private int
Inherited from org.apache.bcel.classfile.Constant:
tag

Constructor Summary

AccessConstructor and Description
public
ConstantMethodHandle(final ConstantMethodHandle
Source to copy.
c
)

Initialize from another object.

pack-priv
ConstantMethodHandle(final DataInput
Input stream
file
)

Initialize instance from file data.

public
ConstantMethodHandle(final int referenceKind, final int referenceIndex)

Method Summary

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

Implements abstract org.apache.bcel.classfile.Constant.accept.

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

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

Implements abstract org.apache.bcel.classfile.Constant.dump.

Dump method kind and index to file stream in binary format.
public int
public int
public void
setReferenceIndex(final int referenceIndex)

public void
setReferenceKind(final int referenceKind)

public String

Returns:

String representation
toString
()

Overrides org.apache.bcel.classfile.Constant.toString.

Returns a string representation of the object.
Inherited from org.apache.bcel.classfile.Constant:
clonecopyequalsgetComparatorgetTaghashCodereadConstantsetComparator

Field Detail

referenceIndexback to summary
private int referenceIndex
referenceKindback to summary
private int referenceKind

Constructor Detail

ConstantMethodHandleback to summary
public ConstantMethodHandle(final ConstantMethodHandle c)

Initialize from another object.

Parameters
c:ConstantMethodHandle

Source to copy.

ConstantMethodHandleback to summary
pack-priv ConstantMethodHandle(final DataInput file) throws IOException

Initialize instance from file data.

Parameters
file:DataInput

Input stream

Exceptions
IOException:
if an I/O error occurs.
ConstantMethodHandleback to summary
public ConstantMethodHandle(final int referenceKind, final int referenceIndex)

Method Detail

acceptback to summary
public void accept(final Visitor v)

Implements abstract org.apache.bcel.classfile.Constant.accept.

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

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

Parameters
v:Visitor

Visitor object

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

Implements abstract org.apache.bcel.classfile.Constant.dump.

Dump method kind and index to file stream in binary format.

Parameters
file:DataOutputStream

Output file stream

Annotations
@Override
Exceptions
IOException:
if an I/O error occurs.
getReferenceIndexback to summary
public int getReferenceIndex()
getReferenceKindback to summary
public int getReferenceKind()
setReferenceIndexback to summary
public void setReferenceIndex(final int referenceIndex)
setReferenceKindback to summary
public void setReferenceKind(final int referenceKind)
toStringback to summary
public String toString()

Overrides org.apache.bcel.classfile.Constant.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object.

Returns:String

String representation

Annotations
@Override