Documentation of 'org.encog.ml.prg.expvalue.ExpressionValue' Java class
ExpressionValue
org.encog.ml.prg.expvalue

Class ExpressionValue

  • All Implemented Interfaces:
    java.io.Serializable


    public class ExpressionValue
    extends java.lang.Object
    implements java.io.Serializable
    An EncogProgram expression value. These is how Encog stores variables and calculates values.
    See Also:
    Serialized Form
    • Constructor Detail

      • ExpressionValue

        public ExpressionValue(boolean theValue)
        Construct a boolean expression.
        Parameters:
        theValue - The value to construct.
      • ExpressionValue

        public ExpressionValue(double theValue)
        Construct a boolean expression.
        Parameters:
        theValue - The value to construct.
      • ExpressionValue

        public ExpressionValue(ExpressionValue other)
        Construct a expression based on an expression.
        Parameters:
        other - The value to construct.
      • ExpressionValue

        public ExpressionValue(int theEnumType,
                               long theValue)
        Construct an enum expression.
        Parameters:
        theEnumType - The type.
        theValue - The value to construct.
      • ExpressionValue

        public ExpressionValue(long theValue)
        Construct an integer expression.
        Parameters:
        theValue - The value to construct.
      • ExpressionValue

        public ExpressionValue(java.lang.String theValue)
        Construct a string expression.
        Parameters:
        theValue - The value to construct.
      • ExpressionValue

        public ExpressionValue(ValueType theType)
        Construct a value of the specified type.
        Parameters:
        theType - The value to construct.
    • Method Detail

      • getEnumType

        public int getEnumType()
        Returns:
        the enumType
      • getExpressionType

        public ValueType getExpressionType()
        Returns:
        The expression type.
      • isBoolean

        public boolean isBoolean()
        Returns:
        True, if this is a boolean.
      • isEnum

        public boolean isEnum()
        Returns:
        True, if this is an enum.
      • isFloat

        public boolean isFloat()
        Returns:
        True, if this is a float.
      • isInt

        public boolean isInt()
        Returns:
        True, if this is an int.
      • isNumeric

        public boolean isNumeric()
        Returns:
        True, if the value is either int or float.
      • isString

        public boolean isString()
        Returns:
        True, if this is a string.
      • toBooleanValue

        public boolean toBooleanValue()
        Returns:
        The value as a boolean, or type mismatch if conversion is not possible.
      • toFloatValue

        public double toFloatValue()
        Returns:
        The value as a float, or type mismatch if conversion is not possible.
      • toIntValue

        public long toIntValue()
        Returns:
        The value as a int, or type mismatch if conversion is not possible.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • toStringValue

        public java.lang.String toStringValue()
        Returns:
        The value as a string, or type mismatch if conversion is not possible.

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.