Package com.yahoo.document.update
Class TensorRemoveUpdate
- java.lang.Object
-
- com.yahoo.document.update.ValueUpdate<TensorFieldValue>
-
- com.yahoo.document.update.TensorRemoveUpdate
-
public class TensorRemoveUpdate extends ValueUpdate<TensorFieldValue>
An update used to remove cells from a sparse tensor or dense sub-spaces from a mixed tensor. The specification of which cells to remove contains addresses using a subset or all of the sparse dimensions of the tensor type. This is represented as a sparse tensor where cell values are set to 1.0.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.yahoo.document.update.ValueUpdate
ValueUpdate.ValueUpdateClassID
-
-
Field Summary
-
Fields inherited from class com.yahoo.document.update.ValueUpdate
valueUpdateClassID
-
-
Constructor Summary
Constructors Constructor Description TensorRemoveUpdate(TensorFieldValue value)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description FieldValue
applyTo(FieldValue oldValue)
protected void
checkCompatibility(DataType fieldType)
boolean
equals(java.lang.Object o)
static com.yahoo.tensor.TensorType
extractSparseDimensions(com.yahoo.tensor.TensorType type)
TensorFieldValue
getValue()
Returns the primary "value" of this update, or null if this kind of update has no valueint
hashCode()
void
serialize(DocumentUpdateWriter data, DataType superType)
void
setValue(TensorFieldValue value)
Sets the value of this.java.lang.String
toString()
void
verifyCompatibleType(com.yahoo.tensor.TensorType originalType)
-
Methods inherited from class com.yahoo.document.update.ValueUpdate
createAdd, createAdd, createAddAll, createAddAll, createAssign, createClear, createDecrement, createDecrement, createDivide, createDivide, createIncrement, createIncrement, createMap, createMultiply, createMultiply, createRemove, createRemoveAll, createRemoveAll, getValueUpdateClassID
-
-
-
-
Constructor Detail
-
TensorRemoveUpdate
public TensorRemoveUpdate(TensorFieldValue value)
-
-
Method Detail
-
verifyCompatibleType
public void verifyCompatibleType(com.yahoo.tensor.TensorType originalType)
-
checkCompatibility
protected void checkCompatibility(DataType fieldType)
- Specified by:
checkCompatibility
in classValueUpdate<TensorFieldValue>
-
serialize
public void serialize(DocumentUpdateWriter data, DataType superType)
- Specified by:
serialize
in classValueUpdate<TensorFieldValue>
-
applyTo
public FieldValue applyTo(FieldValue oldValue)
- Specified by:
applyTo
in classValueUpdate<TensorFieldValue>
-
getValue
public TensorFieldValue getValue()
Description copied from class:ValueUpdate
Returns the primary "value" of this update, or null if this kind of update has no value- Specified by:
getValue
in classValueUpdate<TensorFieldValue>
-
setValue
public void setValue(TensorFieldValue value)
Description copied from class:ValueUpdate
Sets the value of this. Ignored by update who have no value- Specified by:
setValue
in classValueUpdate<TensorFieldValue>
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classValueUpdate<TensorFieldValue>
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classValueUpdate<TensorFieldValue>
-
toString
public java.lang.String toString()
- Overrides:
toString
in classValueUpdate<TensorFieldValue>
-
extractSparseDimensions
public static com.yahoo.tensor.TensorType extractSparseDimensions(com.yahoo.tensor.TensorType type)
-
-