by<A, B> static method

PartialOrder<A> by<A, B>(
  1. B f(
    1. A a
    ),
  2. PartialOrder<B> po
)
override

Convert an implicit PartialOrder[B] to an PartialOrder[A] using the given function f.

Implementation

static PartialOrder<A> by<A, B>(B Function(A a) f, PartialOrder<B> po) =>
    _PartialOrder<A>((x, y) => po.partialCompare(f(x), f(y)));