org.scalautils

Equalizer

class Equalizer [L] extends AnyRef

Class used via an implicit conversion to enable any two objects to be compared with === and !== with a Boolean result and no enforced type constraint between two object types. For example:

assert(a === b)
assert(c !== d)

You can also check numeric values against another with a tolerance. Here are some examples:

assert(a === (2.0 +- 0.1))
assert(c !== (2.0 +- 0.1))

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. Equalizer
  2. AnyRef
  3. Any
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Equalizer (left: L)

    left

    An object to convert to Equalizer, which represents the value on the left side of a === or !== invocation.

Value Members

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

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

    Attributes
    final
    Definition Classes
    Any
  3. def !== (literalNull: Null): Boolean

    Determines whether an object reference is non-null.

    Determines whether an object reference is non-null.

    literalNull

    a null value against which to compare the value passed to the constructor as left for inequality

    returns

    true if the value passed to the constructor as left is non-null.

  4. def !== (interval: Interval[L]): Boolean

    Determine whether a numeric object is outside the passed Interval, returning a Boolean.

    Determine whether a numeric object is outside the passed Interval, returning a Boolean.

    interval

    the Interval against which to compare the value passed to the constructor as left

    returns

    true if the value passed to the constructor as left is not within the Interval passed to this method.

  5. def !== (right: Any)(implicit equality: Equality[L]): Boolean

    Compare two objects for inequality, returning a Boolean, using the Equality type class passed as equality.

    Compare two objects for inequality, returning a Boolean, using the Equality type class passed as equality.

    right

    the object to compare for inequality with left, passed to the constructor

    equality

    an implicit Equality type class that defines a way of calculating equality for objects of type L

    returns

    true if the left and right objects are not equal according to the passed Equality type class.

  6. def ## (): Int

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

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

    Attributes
    final
    Definition Classes
    Any
  9. def === (literalNull: Null): Boolean

    Determine whether an object reference is null.

    Determine whether an object reference is null.

    literalNull

    a null value against which to compare the value passed to the constructor as left for equality

    returns

    true if the value passed to the constructor as left is null.

  10. def === (interval: Interval[L]): Boolean

    Determine whether a numeric object is within the passed Interval, returning a Boolean.

    Determine whether a numeric object is within the passed Interval, returning a Boolean.

    interval

    the Interval against which to compare the value passed to the constructor as left

    returns

    true if the value passed to the constructor as left is within the Interval passed to this method.

  11. def === (right: Any)(implicit equality: Equality[L]): Boolean

    Compare two objects for equality, returning a Boolean, using the Equality type class passed as equality.

    Compare two objects for equality, returning a Boolean, using the Equality type class passed as equality.

    right

    the object to compare for equality with left, passed to the constructor

    equality

    an implicit Equality type class that defines a way of calculating equality for objects of type L

    returns

    true if the left and right objects are equal according to the passed Equality type class.

  12. def asInstanceOf [T0] : T0

    Attributes
    final
    Definition Classes
    Any
  13. def clone (): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  14. def eq (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  15. def equals (arg0: Any): Boolean

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

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  17. def getClass (): java.lang.Class[_]

    Attributes
    final
    Definition Classes
    AnyRef → Any
  18. def hashCode (): Int

    Definition Classes
    AnyRef → Any
  19. def isInstanceOf [T0] : Boolean

    Attributes
    final
    Definition Classes
    Any
  20. def ne (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  21. def notify (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  22. def notifyAll (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  23. def synchronized [T0] (arg0: ⇒ T0): T0

    Attributes
    final
    Definition Classes
    AnyRef
  24. def toString (): String

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

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

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

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()

Inherited from AnyRef

Inherited from Any