Class AnyMethodrefConstant

All Implemented Interfaces:
Serializable, Processable
Direct Known Subclasses:
InterfaceMethodrefConstant, MethodrefConstant

public abstract class AnyMethodrefConstant extends RefConstant
This Constant represents a method reference constant in the constant pool.
See Also:
  • Field Details

    • referencedMethod

      public Method referencedMethod
      An extra field optionally pointing to the referenced Method object. This field is typically filled out by the ClassReferenceInitializer.
  • Constructor Details

    • AnyMethodrefConstant

      public AnyMethodrefConstant()
      Creates an uninitialized AnyMethodrefConstant.
    • AnyMethodrefConstant

      public AnyMethodrefConstant(int u2classIndex, int u2nameAndTypeIndex, Clazz referencedClass, Method referencedMethod)
      Creates a new AnyMethodrefConstant with the given name and type indices.
      Parameters:
      u2classIndex - the index of the class in the constant pool.
      u2nameAndTypeIndex - the index of the name and type entry in the constant pool.
      referencedClass - the referenced class.
      referencedMethod - the referenced method.
  • Method Details

    • referencedMethodAccept

      public void referencedMethodAccept(MemberVisitor memberVisitor)
      Lets the referenced class method accept the given visitor.
    • referencedMemberAccept

      public void referencedMemberAccept(MemberVisitor memberVisitor)
      Description copied from class: RefConstant
      Lets the referenced class member accept the given visitor.
      Specified by:
      referencedMemberAccept in class RefConstant