Class XorBitFunction

All Implemented Interfaces:
Iterable<GroupingExpression>

public class XorBitFunction extends FunctionNode
This class represents an xor-function in a GroupingExpression. It evaluates to a long that equals the xor of 'width' bits over the binary representation of the result of the argument.
Author:
Simon Thoresen Hult, bratseth
  • Constructor Details

    • XorBitFunction

      public XorBitFunction(GroupingExpression exp, int numBits)
      Constructs a new instance of this class.
      Parameters:
      exp - The expression to evaluate.
      numBits - The number of bits of the expression value to xor.
  • Method Details

    • copy

      public XorBitFunction copy()
      Description copied from class: GroupingExpression
      Returns a deep copy of this
      Specified by:
      copy in class GroupingExpression
    • getNumBits

      public int getNumBits()
      Returns the number of bits of the expression value to xor.
      Returns:
      The bit count.