UnitCompositionHandlerYieldingNormalForm
public interface ConverterCompositionHandler
Modifier and Type | Method | Description |
---|---|---|
AbstractConverter |
compose(AbstractConverter left,
AbstractConverter right,
BiPredicate<AbstractConverter,AbstractConverter> canReduce,
BinaryOperator<AbstractConverter> doReduce) |
Takes two converters
left , right and returns a (not necessarily new)
converter that is equivalent to the mathematical composition of these: |
static ConverterCompositionHandler |
yieldingNormalForm() |
AbstractConverter compose(AbstractConverter left, AbstractConverter right, BiPredicate<AbstractConverter,AbstractConverter> canReduce, BinaryOperator<AbstractConverter> doReduce)
left
, right
and 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.
left
- right
- canReduce
- doReduce
- static ConverterCompositionHandler yieldingNormalForm()
Copyright © 2005–2020 Units of Measurement project. All rights reserved.