Package org.apache.bcel.classfile
Class BootstrapMethod
java.lang.Object
org.apache.bcel.classfile.BootstrapMethod
- All Implemented Interfaces:
Cloneable
This class represents a bootstrap method attribute, i.e., the bootstrap method ref, the number of bootstrap arguments
and an array of the bootstrap arguments.
- Since:
- 6.0
- See Also:
-
Constructor Summary
ConstructorDescriptionBootstrapMethod
(int bootstrapMethodRef, int[] bootstrapArguments) Initialize from another object. -
Method Summary
Modifier and TypeMethodDescriptioncopy()
final void
dump
(DataOutputStream file) Dump object to file stream in binary format.int[]
int
int
void
setBootstrapArguments
(int[] bootstrapArguments) void
setBootstrapMethodRef
(int bootstrapMethodRef) final String
toString()
final String
toString
(ConstantPool constantPool)
-
Constructor Details
-
BootstrapMethod
Initialize from another object.- Parameters:
c
- Source to copy.
-
BootstrapMethod
- Parameters:
bootstrapMethodRef
- int index into constant_pool of CONSTANT_MethodHandlebootstrapArguments
- int[] indices into constant_pool of CONSTANT_[type]_info
-
-
Method Details
-
copy
- Returns:
- deep copy of this object
-
dump
Dump object to file stream in binary format.- Parameters:
file
- Output file stream- Throws:
IOException
- if an I/O error occurs.
-
getBootstrapArguments
- Returns:
- int[] of bootstrap_method indices into constant_pool of CONSTANT_[type]_info
-
getBootstrapMethodRef
- Returns:
- index into constant_pool of bootstrap_method
-
getNumBootstrapArguments
- Returns:
- count of number of boostrap arguments
-
setBootstrapArguments
- Parameters:
bootstrapArguments
- int[] indices into constant_pool of CONSTANT_[type]_info
-
setBootstrapMethodRef
- Parameters:
bootstrapMethodRef
- int index into constant_pool of CONSTANT_MethodHandle
-
toString
-
toString
- Returns:
- Resolved string representation
-