Class QuantityAdditiveInversion<S>
- java.lang.Object
-
- org.tensorics.core.quantity.operations.AbstractQuantityOperation<S>
-
- org.tensorics.core.quantity.operations.QuantityUnaryOperation<S>
-
- org.tensorics.core.quantity.operations.QuantityAdditiveInversion<S>
-
- Type Parameters:
S
- the type of scalars on which all the operations are based (elements of a field)
- All Implemented Interfaces:
java.io.Serializable
,UnaryOperation<QuantifiedValue<S>>
public class QuantityAdditiveInversion<S> extends QuantityUnaryOperation<S>
The unary operation which which calculates the additive inversion of a quantity (aka 'the negative'). Error, validity and the base of the result are the same as the input quantity, only the value itself will be inverted.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description QuantityAdditiveInversion(QuantityEnvironment<S> environment)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description QuantifiedValue<S>
perform(QuantifiedValue<S> scalar)
performs the operation on the given value-
Methods inherited from class org.tensorics.core.quantity.operations.AbstractQuantityOperation
environment, equals, hashCode, productError, toString, validityFor
-
-
-
-
Constructor Detail
-
QuantityAdditiveInversion
public QuantityAdditiveInversion(QuantityEnvironment<S> environment)
-
-
Method Detail
-
perform
public QuantifiedValue<S> perform(QuantifiedValue<S> scalar)
Description copied from interface:UnaryOperation
performs the operation on the given value- Parameters:
scalar
- the input value, on which the operation shall be applied- Returns:
- the resulting value after the operation
-
-