Class IncOperand


  • public class IncOperand
    extends java.lang.Object
    IncOperand encapsulates the operands to the iinc instruction. It is necessary because the iinc has two operands: a local variable and an integer by which to increment the local variable.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int incr()
      Get the amount to increment by.
      java.lang.String toString()
      Convert the operand to a string.
      LocalVariable var()
      Get the local variable to increment.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • IncOperand

        public IncOperand​(LocalVariable var,
                          int incr)
        Constructor.
        Parameters:
        var - The local variable to increment.
        incr - The amount to increment by.
    • Method Detail

      • var

        public LocalVariable var()
        Get the local variable to increment.
        Returns:
        The local variable to increment.
      • incr

        public int incr()
        Get the amount to increment by.
        Returns:
        The amount to increment by.
      • toString

        public java.lang.String toString()
        Convert the operand to a string.
        Overrides:
        toString in class java.lang.Object
        Returns:
        A string representation of the operand.