Class MethodInfo


  • public class MethodInfo
    extends Object
    Keeps information about a method that is useful for writing out decl and/or dtrace information. Original information is filled out during the transformation and other information is added the first time a method is called.
    • Field Detail

      • method_name

        public String method_name
        Method name. For example: "public static void sort(int[] arr)" would have method_name "sort".
      • arg_names

        public String[] arg_names
        Array of argument names for this method.
      • arg_type_strings

        public @ClassGetName String[] arg_type_strings
        Array of argument types for this method (fully qualified). For example: "public static void examineObject(Object x)" would have arg_types {"java.lang.Object"}.
      • arg_types

        public Class<?>[] arg_types
        Array of argument types as classes for this method.
      • is_included

        public List<Boolean> is_included
        Tells whether each exit point in method is instrumented, based on filters.
      • traversalEnter

        public @MonotonicNonNull RootInfo traversalEnter
        The root of the variable tree for the method entry program point.

        Set by Runtime and read by DeclWriter and DTraceWriter.

      • traversalExit

        public @MonotonicNonNull RootInfo traversalExit
        The root of the variable tree for the method exit program point(s).

        Set by Runtime and read by DeclWriter and DTraceWriter.

      • call_cnt

        public int call_cnt
        The number of times this method has been called.
      • capture_cnt

        public int capture_cnt
        The number of times we have captured the output for this method.
    • Method Detail

      • initViaReflection

        public void initViaReflection()
        Populates this class with data from reflection.
      • is_constructor

        @Pure
        public boolean is_constructor()
        Returns true iff this method is a constructor.
        Returns:
        true iff this method is a constructor
      • is_class_initializer

        @Pure
        public boolean is_class_initializer()
        Returns true iff this method is a class initializer.
        Returns:
        true iff this method is a class initializer
      • is_static

        @RequiresNonNull("member")
        @Pure
        public boolean is_static()
        Returns true iff this method is static.
        Returns:
        true iff this method is static
      • init_traversal

        public void init_traversal​(int depth)
        Initialize the enter and exit daikon variable trees (traversalEnter and traversalExit). The reflection information must have already been initialized.
      • isPure

        public boolean isPure()
      • return_type

        public Class<?> return_type()
        Returns the turn type of the method, or Void.TYPE for a constructor.