returnType

Returns the return type,
as specified in the declaration of this method.

Note: if the return type of this method is a reference type (class,
interface, or array) and it has not been created or loaded
by the declaring type's class loader - that is,
declaringType().classLoader(),
then ClassNotLoadedException will be thrown.
Also, a reference type may have been loaded but not yet prepared,
in which case the type will be returned
but attempts to perform some operations on the returned type
(e.g. fields()) will throw
a ClassNotPreparedException.
Use ReferenceType.isPrepared() to determine if
a reference type is prepared.

argumentTypeNames

Returns a list containing a text representation of the type
of each formal parameter of this method.

This list is always available even if
the types have not yet been created or loaded.

Returns:

a List of String,
one List element for each parameter of this method.
Each element represents the type of a formal parameter
as specified at compile-time.
If the formal parameter was declared with an ellipsis, then
it is represented as an array of the type before the ellipsis.

argumentTypes

Returns a list containing the type
of each formal parameter of this method.

Note: if there is any parameter whose type
is a reference type (class, interface, or array)
and it has not been created or loaded
by the declaring type's class loader - that is,
declaringType().classLoader(),
then ClassNotLoadedException will be thrown.
Also, a reference type may have been loaded but not yet prepared,
in which case the list will be returned
but attempts to perform some operations on the type
(e.g. fields()) will throw
a ClassNotPreparedException.
Use ReferenceType.isPrepared() to determine if
a reference type is prepared.

Returns:

return a List of Type,
one List element for each parameter of this method.
Each element represents the type of a formal parameter
as specified at compile-time.
If the formal parameter was declared with an ellipsis, then
it is represented as an array of the type before the ellipsis.

locationsOfLine

Returns a List containing all Location objects
that map to the given line number and source name.

Returns a list containing each Location that maps
to the given line. The returned list will contain a
location for each disjoint range of code indices that have
been assigned to the given line by the compiler and/or
VM. Each returned location corresponds to the beginning of
this range. An empty list will be returned if there is no
executable code at the specified line number; specifically,
native and abstract methods will always return an empty
list.

Returned list is for the specified stratum
(see Location for a description of strata).

Parameters:

stratum - the stratum to use for comparing line number
and source name, or null to use the default
stratum

sourceName - the source name containing the
line number, or null to match all
source names

variables

Returns a list containing each LocalVariable declared
in this method. The list includes any variable declared in any
scope within the method. It may contain multiple variables of the
same name declared within disjoint scopes. Arguments are considered
local variables and will be present in the returned list.

Returns:

the list of LocalVariable objects which mirror
local variables declared in this method in the target VM.
If there are no local variables, a zero-length list is returned.

Throws:

AbsentInformationException - if there is no variable
information for this method.
Generally, local variable information is not available for
native or abstract methods (that is, their argument name
information is not available), thus they will throw this exception.

variablesByName

Returns a list containing each LocalVariable of a
given name in this method.
Multiple variables can be returned
if the same variable name is used in disjoint
scopes within the method.

Returns:

the list of LocalVariable objects of the given
name.
If there are no matching local variables, a zero-length list
is returned.

Throws:

AbsentInformationException - if there is no variable
information for this method.
Generally, local variable information is not available for
native or abstract methods (that is, their argument name
information is not available), thus they will throw this exception.

arguments

Returns a list containing each LocalVariable that is
declared as an argument of this method.

Returns:

the list of LocalVariable arguments.
If there are no arguments, a zero-length list is returned.

Throws:

AbsentInformationException - if there is no variable
information for this method.
Generally, local variable information is not available for
native or abstract methods (that is, their argument name
information is not available), thus they will throw this exception.