Package com.yahoo.tensor
Class Tensor.Cell
- java.lang.Object
-
- com.yahoo.tensor.Tensor.Cell
-
- All Implemented Interfaces:
java.util.Map.Entry<TensorAddress,java.lang.Double>
- Enclosing interface:
- Tensor
public static class Tensor.Cell extends java.lang.Object implements java.util.Map.Entry<TensorAddress,java.lang.Double>
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Tensor.Cell
detach()
Return a copy of this tensor cell which is valid beyond the lifetime of any iterator state which supplied it.boolean
equals(java.lang.Object o)
double
getDoubleValue()
Returns the value as a doublefloat
getFloatValue()
Returns the value as a floatTensorAddress
getKey()
java.lang.Double
getValue()
Returns the value as a doubleint
hashCode()
java.lang.Double
setValue(java.lang.Double value)
java.lang.String
toString(TensorType type)
-
-
-
Method Detail
-
getKey
public TensorAddress getKey()
- Specified by:
getKey
in interfacejava.util.Map.Entry<TensorAddress,java.lang.Double>
-
getValue
public java.lang.Double getValue()
Returns the value as a double- Specified by:
getValue
in interfacejava.util.Map.Entry<TensorAddress,java.lang.Double>
-
getFloatValue
public float getFloatValue()
Returns the value as a float
-
getDoubleValue
public double getDoubleValue()
Returns the value as a double
-
setValue
public java.lang.Double setValue(java.lang.Double value)
- Specified by:
setValue
in interfacejava.util.Map.Entry<TensorAddress,java.lang.Double>
-
equals
public boolean equals(java.lang.Object o)
- Specified by:
equals
in interfacejava.util.Map.Entry<TensorAddress,java.lang.Double>
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfacejava.util.Map.Entry<TensorAddress,java.lang.Double>
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString(TensorType type)
-
detach
public Tensor.Cell detach()
Return a copy of this tensor cell which is valid beyond the lifetime of any iterator state which supplied it.
-
-