Class DynamicInvocation

java.lang.Object
org.eolang.opeo.ast.DynamicInvocation
All Implemented Interfaces:
AstNode, Typed, Xmir

public final class DynamicInvocation extends Object implements AstNode, Typed
Dynamic invocation.
Since:
0.5
  • Constructor Details

    • DynamicInvocation

      public DynamicInvocation(org.eolang.jeo.representation.xmir.XmlNode root)
      Constructor.
      Parameters:
      root - XMIR node to parse.
    • DynamicInvocation

      public DynamicInvocation(org.eolang.jeo.representation.xmir.XmlNode root, Parser parser)
      Constructor.
      Parameters:
      root - XMIR node to parse.
      parser - Parser to find AST nodes of children.
    • DynamicInvocation

      public DynamicInvocation(org.eolang.jeo.representation.xmir.XmlNode root, List<org.eolang.jeo.representation.xmir.XmlNode> chldren, Parser parser)
      Constructor. Added for efficiency to receive children nodes only once.
      Parameters:
      root - XMIR node to parse.
      chldren - XMIR node children.
      parser - Parser to find AST nodes of children.
    • DynamicInvocation

      public DynamicInvocation(String name, Handle factory, String descriptor, List<Object> arguments)
      Constructor.
      Parameters:
      name - Name of the method.
      factory - Factory method reference.
      descriptor - Method descriptor.
      arguments - Factory method arguments.
    • DynamicInvocation

      public DynamicInvocation(String name, Handle factory, String descriptor, List<Object> farguments, List<AstNode> arguments)
      Constructor.
      Parameters:
      name - Name of the method.
      factory - Factory method reference.
      descriptor - Method descriptor.
      farguments - Factory method arguments.
      arguments - Dynamic invocation method arguments.
    • DynamicInvocation

      public DynamicInvocation(String name, Handle factory, Attributes attributes, List<Object> farguments, List<AstNode> arguments)
      Constructor.
      Parameters:
      name - Name of the method.
      factory - Factory method reference.
      attributes - Method attributes.
      farguments - Factory method arguments.
      arguments - Dynamic invocation arguments.
  • Method Details

    • toXmir

      public Iterable<org.xembly.Directive> toXmir()
      Description copied from interface: Xmir
      Convert node to XMIR.
      Specified by:
      toXmir in interface Xmir
      Returns:
      XMIR XML.
    • opcodes

      public List<AstNode> opcodes()
      Description copied from interface: AstNode
      Bytecode instructions.
      Specified by:
      opcodes in interface AstNode
      Returns:
      List of opcodes.
    • type

      public org.objectweb.asm.Type type()
      Description copied from interface: Typed
      Node type.
      Specified by:
      type in interface Typed
      Returns:
      Type.