Class UnitCompositionHandlerYieldingNormalForm
- java.lang.Object
-
- tech.units.indriya.internal.function.simplify.UnitCompositionHandlerYieldingNormalForm
-
- All Implemented Interfaces:
ConverterCompositionHandler
public class UnitCompositionHandlerYieldingNormalForm extends Object implements ConverterCompositionHandler
UnitCompositionHandler yielding a normal-form. A normal-form is required to decide whether two UnitConverters are equivalent.- Since:
- 2.0
- Version:
- 1.1
- Author:
- Andi Huber
-
-
Constructor Summary
Constructors Constructor Description UnitCompositionHandlerYieldingNormalForm()
-
Method Summary
Modifier and Type Method Description AbstractConvertercompose(AbstractConverter a, AbstractConverter b, BiPredicate<AbstractConverter,AbstractConverter> canReduce, BinaryOperator<AbstractConverter> doReduce)Takes two convertersleft,rightand returns a (not necessarily new) converter that is equivalent to the mathematical composition of these:
-
-
-
Constructor Detail
-
UnitCompositionHandlerYieldingNormalForm
public UnitCompositionHandlerYieldingNormalForm()
-
-
Method Detail
-
compose
public AbstractConverter compose(AbstractConverter a, AbstractConverter b, BiPredicate<AbstractConverter,AbstractConverter> canReduce, BinaryOperator<AbstractConverter> doReduce)
Description copied from interface:ConverterCompositionHandlerTakes two convertersleft,rightand returns a (not necessarily new) converter that is equivalent to the mathematical composition of these:compose(left, right) === left o right
Implementation Note: Instead of using AbstractConverter as parameter and result types, this could be generalized to UnitConverter, but that would require some careful changes within AbstractConverter itself.
- Specified by:
composein interfaceConverterCompositionHandler- Returns:
-
-