org.bitbucket.inkytonik.kiama.util

Comparison

object Comparison

Utility module for comparison routines.

Source
Comparison.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Comparison
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. class TOrdering[T] extends Ordering[T]

    An ordering that says two values are equal if same says they are, otherwise earlier elements are greater than later ones.

Value Members

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

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

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

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def contains[T](s: Iterable[T], t: T): Boolean

    Does the iterable s contain t? Equality is tested using same.

  9. def distinct[T](s: Seq[T]): Vector[T]

    Return a vector with only the distinct elements from the sequence s.

    Return a vector with only the distinct elements from the sequence s. "distinct" in this case means compare using same.

  10. final def eq(arg0: AnyRef): Boolean

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

    Definition Classes
    AnyRef → Any
  12. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. def flatDistinct[T](ss: Seq[Seq[T]]): Vector[T]

    As for distinct but works over a sequence of sequences.

  14. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  15. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  16. def indexOf[T](s: Seq[T], elem: T): Int

    Return the first zero-based index at which elem occurs in s using same to perform comparisons, or -1 if elem does not occur in s.

  17. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  18. def lastIndexOf[T](s: Seq[T], elem: T): Int

    Return the last zero-based index at which elem occurs in s using same to perform comparisons, or -1 if elem does not occur in s.

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

    Definition Classes
    AnyRef
  20. final def notify(): Unit

    Definition Classes
    AnyRef
  21. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  22. def optsame(v1: Any, v2: Any): Boolean

    As for same, except that if the two values are Some options containing references, they are unwrapped first and the contents are compared by reference.

  23. def same(v1: Any, v2: Any): Boolean

    Compare two arbitrary values.

    Compare two arbitrary values. If they are both references and not tuples, use reference equality. If they are tuples, use same to compare the components. Otherwise use value equality.

  24. def sameCollection(v1: Any, v2: Any): Boolean

    Compare two Iterable collections or options and tuples containing that kind of collection.

    Compare two Iterable collections or options and tuples containing that kind of collection. Use same to compare the individual elements in the same order.

  25. def sameElements[T](t1: Seq[_], t2: Seq[_]): Boolean

    Compare two Seq collections or options and tuples containing that kind of collection.

    Compare two Seq collections or options and tuples containing that kind of collection. Use same to compare the individual elements in any order.

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

    Definition Classes
    AnyRef
  27. def toString(): String

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

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped