Interface InvocationNode

All Superinterfaces:
GenericNode<JavaNode>, JavaNode, JjtreeNode<JavaNode>, MethodUsage, Node, Reportable, TextAvailableNode, TypeNode
All Known Implementing Classes:
ASTConstructorCall, ASTEnumConstant, ASTExplicitConstructorInvocation, ASTMethodCall

public interface InvocationNode extends TypeNode, MethodUsage
Groups method and constructor call, together, as well as explicit constructor invocation statements, and enum constant declarations. Those last two are included, because they are special syntax to call a constructor.

The arguments of the invocation are said to be in an "invocation context", which influences what conversions they are subject to. It also means the type of the arguments may depend on the resolution of the compile-time declaration of this node.

  • Method Details

    • getArguments

      @Nullable ASTArgumentList getArguments()
      Returns the node representing the list of arguments passed to the invocation. Can be null if this is an ASTEnumConstant.
    • getExplicitTypeArguments

      @Nullable ASTTypeArguments getExplicitTypeArguments()
      Returns the explicit type arguments if they exist.
    • getMethodType

      default JMethodSig getMethodType()
      Gets the type of the method or constructor that is called by this node. See OverloadSelectionResult.getMethodType().