Value Members
-
final
def
!=(arg0: Any): Boolean
-
final
def
##(): Int
-
final
def
==(arg0: Any): Boolean
-
final
def
asInstanceOf[T0]: T0
-
def
clone(): AnyRef
-
final
def
eq(arg0: AnyRef): Boolean
-
def
equals(arg0: Any): Boolean
-
def
finalize(): Unit
-
final
def
getClass(): Class[_]
-
def
hashCode(): Int
-
final
def
isInstanceOf[T0]: Boolean
-
implicit
def
mapEqualityConstraint[KA, VA, CA[ka, kb] <: GenMap[ka, kb], KB, VB, CB[kb, vb] <: GenMap[kb, vb]](implicit equalityOfA: Equality[CA[KA, VA]], evKey: Constraint[KA, KB], evValue: Constraint[VA, VB]): Constraint[CA[KA, VA], CB[KB, VB]]
-
final
def
ne(arg0: AnyRef): Boolean
-
final
def
notify(): Unit
-
final
def
notifyAll(): Unit
-
implicit
def
seqEqualityConstraint[EA, CA[ea] <: GenSeq[ea], EB, CB[eb] <: GenSeq[eb]](implicit equalityOfA: Equality[CA[EA]], ev: Constraint[EA, EB]): Constraint[CA[EA], CB[EB]]
-
implicit
def
setEqualityConstraint[EA, CA[ea] <: GenSet[ea], EB, CB[eb] <: GenSet[eb]](implicit equalityOfA: Equality[CA[EA]], ev: Constraint[EA, EB]): Constraint[CA[EA], CB[EB]]
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
-
def
toString(): String
-
final
def
wait(): Unit
-
final
def
wait(arg0: Long, arg1: Int): Unit
-
final
def
wait(arg0: Long): Unit
Value Members
-
implicit
def
mapEqualityConstraint[KA, VA, CA[ka, kb] <: GenMap[ka, kb], KB, VB, CB[kb, vb] <: GenMap[kb, vb]](implicit equalityOfA: Equality[CA[KA, VA]], evKey: Constraint[KA, KB], evValue: Constraint[VA, VB]): Constraint[CA[KA, VA], CB[KB, VB]]
Value Members
-
implicit
def
setEqualityConstraint[EA, CA[ea] <: GenSet[ea], EB, CB[eb] <: GenSet[eb]](implicit equalityOfA: Equality[CA[EA]], ev: Constraint[EA, EB]): Constraint[CA[EA], CB[EB]]
Value Members
-
implicit
def
seqEqualityConstraint[EA, CA[ea] <: GenSeq[ea], EB, CB[eb] <: GenSeq[eb]](implicit equalityOfA: Equality[CA[EA]], ev: Constraint[EA, EB]): Constraint[CA[EA], CB[EB]]
Inherited from AnyRef
Value Members
-
final
def
!=(arg0: Any): Boolean
-
final
def
##(): Int
-
final
def
==(arg0: Any): Boolean
-
def
clone(): AnyRef
-
final
def
eq(arg0: AnyRef): Boolean
-
def
equals(arg0: Any): Boolean
-
def
finalize(): Unit
-
final
def
getClass(): Class[_]
-
def
hashCode(): Int
-
final
def
ne(arg0: AnyRef): Boolean
-
final
def
notify(): Unit
-
final
def
notifyAll(): Unit
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
-
def
toString(): String
-
final
def
wait(): Unit
-
final
def
wait(arg0: Long, arg1: Int): Unit
-
final
def
wait(arg0: Long): Unit
Inherited from Any
Value Members
-
final
def
asInstanceOf[T0]: T0
-
final
def
isInstanceOf[T0]: Boolean
Ungrouped
-
final
def
!=(arg0: Any): Boolean
-
final
def
##(): Int
-
final
def
==(arg0: Any): Boolean
-
final
def
asInstanceOf[T0]: T0
-
def
clone(): AnyRef
-
final
def
eq(arg0: AnyRef): Boolean
-
def
equals(arg0: Any): Boolean
-
def
finalize(): Unit
-
final
def
getClass(): Class[_]
-
def
hashCode(): Int
-
final
def
isInstanceOf[T0]: Boolean
-
implicit
def
mapEqualityConstraint[KA, VA, CA[ka, kb] <: GenMap[ka, kb], KB, VB, CB[kb, vb] <: GenMap[kb, vb]](implicit equalityOfA: Equality[CA[KA, VA]], evKey: Constraint[KA, KB], evValue: Constraint[VA, VB]): Constraint[CA[KA, VA], CB[KB, VB]]
-
final
def
ne(arg0: AnyRef): Boolean
-
final
def
notify(): Unit
-
final
def
notifyAll(): Unit
-
implicit
def
seqEqualityConstraint[EA, CA[ea] <: GenSeq[ea], EB, CB[eb] <: GenSeq[eb]](implicit equalityOfA: Equality[CA[EA]], ev: Constraint[EA, EB]): Constraint[CA[EA], CB[EB]]
-
implicit
def
setEqualityConstraint[EA, CA[ea] <: GenSet[ea], EB, CB[eb] <: GenSet[eb]](implicit equalityOfA: Equality[CA[EA]], ev: Constraint[EA, EB]): Constraint[CA[EA], CB[EB]]
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
-
def
toString(): String
-
final
def
wait(): Unit
-
final
def
wait(arg0: Long, arg1: Int): Unit
-
final
def
wait(arg0: Long): Unit
Provides three implicit methods that loosen the equality constraint defined by
TypeCheckedTripleEquals
orConversionCheckedTripleEquals
for ScalaTraversable
s to one that more closely matches Scala's approach toTraversable
equality.Scala's approach to
Traversable
equality is that if the objects being compared are ether bothSeq
s, bothSet
s, or bothMap
s, the elements are compared to determine equality. This means you could compare an immutableVector
and a mutableListBuffer
for equality, for instance, and get true so long as the twoSeq
s contained the same elements in the same order. Here's an example:Such a comparison would not, however, compile if you used
===
under eitherTypeCheckedTripleEquals
orConversionCheckedTripleEquals
, becauseVector
andListBuffer
are not in a subtype/supertype relationship, nor does an implicit conversion by default exist between them:If you mix or import the implicit conversion provided by
TraversableEqualityConstraint
, however, the comparison will be allowed:The equality constraints provided by this trait require that left and right sides are both subclasses of either
scala.collection.GenSeq
,scala.collection.GenSet
, orscala.collection.GenMap
, and that anEqualityConstraint
can be found for the element types forSeq
andSet
, or the key and value types forMap
s. In the example above, both theVector
andListBuffer
are subclasses ofscala.collection.GenSeq
, and the regularTypeCheckedTripleEquals
provides equality constraints for the element types, both of which areInt
. By contrast, this trait would not allow aVector[Int]
to be compared against aListBuffer[java.util.Date]
, because no equality constraint will exist between the element typesInt
andDate
:This trait simply mixes together
SeqEqualityConstraints
,SetEqualityConstraints
, andMapEqualityConstraints
.