fr.umlv.corosol.classfile.constant
Interface JConstantMethodref

All Superinterfaces:
JClassFileItem, JConstant, JObject
All Known Implementing Classes:
DefaultJConstantMethodref

public interface JConstantMethodref
extends JConstant

A JConstantMethodref object represents a CONSTANT_Methodref_info entry of a constant pool.

A CONSTANT_Methodref_info entry is used to represent a method. Among its items there is two index into the constant pool. The first index is an index to a CONSTANT_Class_info entry representing the class type that contains the declaration of the method. The second index is an index to a CONSTANT_NameAndType_info entry that indicates the name and descriptor of the method.

Author:
Christophe Deleray
See Also:
JConstantPool

Field Summary
 
Fields inherited from interface fr.umlv.corosol.classfile.constant.JConstant
CONSTANT_CLASS, CONSTANT_DOUBLE, CONSTANT_FIELDREF, CONSTANT_FLOAT, CONSTANT_INTEGER, CONSTANT_INTERFACE_METHODREF, CONSTANT_LONG, CONSTANT_METHODREF, CONSTANT_NAME_AND_TYPE, CONSTANT_STRING, CONSTANT_UTF8
 
Method Summary
 int getClassIndex()
          Returns the index of a CONSTANT_Class_info entry representing a valid fully qualified class name.
 java.lang.String getClassName()
          Returns the fully qualified class name of a method.
 java.lang.String getDescriptor()
          Returns a method descriptor.
 java.lang.String getName()
          Returns a method name.
 int getNameAndTypeIndex()
          Returns the index of a CONSTANT_Class_info entry representing the name and the descriptor of a method.
 JClassMethod getResolvedMethod()
           
 boolean isResolved()
           
 void setClassIndex(int classIndex)
          Sets the index of a CONSTANT_Class_info entry representing a valid fully qualified class name.
 void setNameAndTypeIndex(int nameAndTypeIndex)
          Sets the index of a CONSTANT_NameAndType_info entry representing the name and the descriptor of a method.
 void setResolvedMethod(JClassMethod method)
           
 
Methods inherited from interface fr.umlv.corosol.classfile.constant.JConstant
getLength, getTag, toString
 
Methods inherited from interface fr.umlv.corosol.classfile.JClassFileItem
getConstantPool, readItem, setConstantPool, writeItem
 

Method Detail

getClassName

java.lang.String getClassName()
Returns the fully qualified class name of a method.

Returns:
a fully qualified class name

getName

java.lang.String getName()
Returns a method name.

Returns:
a method name

getDescriptor

java.lang.String getDescriptor()
Returns a method descriptor.

Returns:
a method descriptor

getClassIndex

int getClassIndex()
Returns the index of a CONSTANT_Class_info entry representing a valid fully qualified class name.


getNameAndTypeIndex

int getNameAndTypeIndex()
Returns the index of a CONSTANT_Class_info entry representing the name and the descriptor of a method.


setClassIndex

void setClassIndex(int classIndex)
Sets the index of a CONSTANT_Class_info entry representing a valid fully qualified class name.

Parameters:
classIndex - an index of a constant pool entry representing the name of the declaring class of a method

setNameAndTypeIndex

void setNameAndTypeIndex(int nameAndTypeIndex)
Sets the index of a CONSTANT_NameAndType_info entry representing the name and the descriptor of a method.

Parameters:
nameAndTypeIndex - an index of a constant pool entry representing the name and the descriptor of a method

getResolvedMethod

JClassMethod getResolvedMethod()

setResolvedMethod

void setResolvedMethod(JClassMethod method)

isResolved

boolean isResolved()