Class Subject.ParamSubject

  • All Implemented Interfaces:
    Subject
    Enclosing interface:
    Subject

    public static final class Subject.ParamSubject
    extends Object
    implements Subject
    A declared method parameter, identified by position; type is its descriptor from the method signature.
    • Constructor Detail

      • ParamSubject

        public ParamSubject​(MethodEntry method,
                            int index,
                            String type,
                            EvalContext context)
        Binds the cursor to a declared parameter.
        Parameters:
        method - the declaring method
        index - the parameter's position in the signature
        type - the parameter's descriptor
        context - the shared evaluation context
    • Method Detail

      • method

        public MethodEntry method()
        Returns:
        the method declaring this parameter
      • index

        public int index()
        Returns:
        the parameter's position in the signature
      • type

        public String type()
        Returns:
        the parameter's descriptor
      • kind

        public SubjectKind kind()
        Specified by:
        kind in interface Subject
        Returns:
        which variant this subject is, selecting the attributes that apply to it
      • context

        public EvalContext context()
        Specified by:
        context in interface Subject
        Returns:
        the evaluation context shared across every subject in a run