Package dev.cel.common.values
Class DoubleValue
- java.lang.Object
-
- dev.cel.common.values.CelValue
-
- dev.cel.common.values.DoubleValue
-
@Immutable public final class DoubleValue extends CelValue
DoubleValue is a simple CelValue wrapper around Java doubles.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description CelTypecelType()The CelType that represents this value.static DoubleValuecreate(double value)doubledoubleValue()booleanequals(java.lang.Object o)inthashCode()booleanisZeroValue()Returns true if theCelValue.value()is a zero value for its type.java.lang.Doublevalue()The underlying value.
-
-
-
Method Detail
-
value
public java.lang.Double value()
Description copied from class:CelValueThe underlying value. This is typically the Java native value or a derived instance of CelValue (ex: an element in lists or key/value pair in maps).
-
doubleValue
public double doubleValue()
-
isZeroValue
public boolean isZeroValue()
Description copied from class:CelValueReturns true if theCelValue.value()is a zero value for its type.- Specified by:
isZeroValuein classCelValue
-
celType
public CelType celType()
Description copied from class:CelValueThe CelType that represents this value.
-
create
public static DoubleValue create(double value)
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
-