Class DirectivesMethod

java.lang.Object
org.eolang.jeo.representation.directives.DirectivesMethod
All Implemented Interfaces:
Iterable<org.xembly.Directive>

public final class DirectivesMethod extends Object implements Iterable<org.xembly.Directive>
Directives Method.
Since:
0.1
  • Constructor Details

    • DirectivesMethod

      public DirectivesMethod()
      Constructor.
    • DirectivesMethod

      public DirectivesMethod(String name)
      Constructor.
      Parameters:
      name - Method name
    • DirectivesMethod

      public DirectivesMethod(String name, DirectivesMethodProperties properties)
      Constructor.
      Parameters:
      name - Method name
      properties - Method properties
    • DirectivesMethod

      public DirectivesMethod(String name, boolean counting, DirectivesMethodProperties properties)
      Constructor.
      Parameters:
      name - Method name
      counting - Opcodes counting
      properties - Method properties
  • Method Details

    • opcode

      public DirectivesMethod opcode(int opcode, Object... operands)
      Add opcode to the directives.
      Parameters:
      opcode - Opcode
      operands - Operands
      Returns:
      This object
    • operand

      public void operand(Iterable<org.xembly.Directive> directives)
      Add operand to the directives.
      Parameters:
      directives - Operand directives.
    • maxs

      public void maxs(int stack, int locals)
      Add maxs to the directives.
      Parameters:
      stack - Max stack size
      locals - Max locals size
    • annotation

      public DirectivesMethod annotation(DirectivesAnnotation annotation)
      Add annotation to the directives.
      Parameters:
      annotation - Annotation directives.
      Returns:
      This object.
    • iterator

      public Iterator<org.xembly.Directive> iterator()
      Specified by:
      iterator in interface Iterable<org.xembly.Directive>