Enum DoubleEvaluator.Style

java.lang.Object
java.lang.Enum<DoubleEvaluator.Style>
com.fathzer.soft.javaluator.DoubleEvaluator.Style
All Implemented Interfaces:
Serializable, Comparable<DoubleEvaluator.Style>, java.lang.constant.Constable
Enclosing class:
DoubleEvaluator

public static enum DoubleEvaluator.Style extends Enum<DoubleEvaluator.Style>
The order or operations (operator precedence) is not clearly defined, especially between the unary minus operator and exponentiation operator (see http://en.wikipedia.org/wiki/Order_of_operations). These constants define the operator precedence styles.
  • Enum Constant Details

    • STANDARD

      public static final DoubleEvaluator.Style STANDARD
      The most commonly operator precedence, where the unary minus as a lower precedence than the exponentiation.
      With this style, used by Google, Wolfram alpha, and many others, -2^2=-4.
    • EXCEL

      public static final DoubleEvaluator.Style EXCEL
      The operator precedence used by Excel, or bash shell script language, where the unary minus as a higher precedence than the exponentiation.
      With this style, -2^2=4.
  • Method Details

    • values

      public static DoubleEvaluator.Style[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static DoubleEvaluator.Style valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null