Trait

scala.math

PartialOrdering

Related Doc: package math

Permalink

trait PartialOrdering[T] extends Equiv[T]

A trait for representing partial orderings. It is important to distinguish between a type that has a partial order and a representation of partial ordering on some type. This trait is for representing the latter.

A partial ordering is a binary relation on a type T, exposed as the lteq method of this trait. This relation must be:

Additionally, a partial ordering induces an equivalence relation on a type T: x and y of type T are equivalent if and only if lteq(x, y) && lteq(y, x) == true. This equivalence relation is exposed as the equiv method, inherited from the Equiv trait.

Self Type
PartialOrdering[T]
Version

1.0, 2008-04-0-3

Since

2.7

Linear Supertypes
Equiv[T], Serializable, java.io.Serializable, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. PartialOrdering
  2. Equiv
  3. Serializable
  4. Serializable
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def lteq(x: T, y: T): Boolean

    Permalink

    Returns true iff x comes before y in the ordering.

  2. abstract def tryCompare(x: T, y: T): Option[Int]

    Permalink

    Result of comparing x with operand y.

    Result of comparing x with operand y. Returns None if operands are not comparable. If operands are comparable, returns Some(r) where

    • r < 0 iff x < y
    • r == 0 iff x == y
    • r > 0 iff x > y

Concrete Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  7. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  8. def equiv(x: T, y: T): Boolean

    Permalink

    Returns true iff x is equivalent to y in the ordering.

    Returns true iff x is equivalent to y in the ordering.

    Definition Classes
    PartialOrderingEquiv
  9. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  10. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  11. def gt(x: T, y: T): Boolean

    Permalink

    Returns true iff y comes before x in the ordering and is not the same as x.

  12. def gteq(x: T, y: T): Boolean

    Permalink

    Returns true iff y comes before x in the ordering.

  13. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  14. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  15. def lt(x: T, y: T): Boolean

    Permalink

    Returns true iff x comes before y in the ordering and is not the same as y.

  16. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  17. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  18. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  19. def reverse: PartialOrdering[T]

    Permalink
  20. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  21. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  22. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Equiv[T]

Inherited from Serializable

Inherited from java.io.Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped