An Order
instance that considers all A
instances to be equal.
Access an implicit Order[A]
.
Access an implicit Order[A]
.
Convert an implicit Order[B]
to an Order[A]
using the given
function f
.
Implicitly derive a scala.math.Ordering[A]
from a Order[A]
instance.
Implicitly derive a scala.math.Ordering[A]
from a Order[A]
instance.
Define an Order[A]
using the given function f
.
Defines an ordering on A
from the given order such that all arrows switch direction.
Returns a new Order[A]
instance that first compares by the first
Order
instance and uses the second Order
instance to "break ties".
Returns a new Order[A]
instance that first compares by the first
Order
instance and uses the second Order
instance to "break ties".
That is, Order.whenEqual(x, y)
creates an Order
that first orders by x
and
then (if two elements are equal) falls back to y
for the comparison.
A Monoid[Order[A]]
can be generated for all A
with the following
properties:
A Monoid[Order[A]]
can be generated for all A
with the following
properties:
empty
returns a trivial Order[A]
which considers all A
instances to
be equal.
combine(x: Order[A], y: Order[A])
creates an Order[A]
that first
orders by x
and then (if two elements are equal) falls back to y
.
This monoid is also a Band[Order[A]]
since its combine
operations is idempotent.