Returns a GenTraversable[E] containing the same elements (in the same
order, if the original collection had a defined order), as the passed collection .
Returns a GenTraversable[E] containing the same elements (in the same
order, if the original collection had a defined order), as the passed collection .
a collection to check the size of
a GenTraversable[E] containing the same elements as the passed collection
Implements the loneElement syntax of trait LoneElement.
Implements the loneElement syntax of trait LoneElement.
Returns the lone element contained in a collection, wrapped in a Some, or None
if the collection contains either no elements or more than one element.
a collection about which an assertion is being made
Some[E] if the collection contains one and only one element, None otherwise.
Returns the size of the passed collection.
Returns the size of the passed collection.
a collection to check the size of
the size of the passed collection
Supertrait for typeclasses that enable
loneElementand inspectors syntax for collections.A
Collecting[E, C]provides access to the "collecting nature" of typeCin such a way thatloneElementsyntax can be used with typeC. ACcan be any type of "collecting", a type that in some way collects or brings together elements of typeE. ScalaTest provides implicit implementations for several types. You can enable thecontainmatcher syntax on your own typeUby defining anCollecting[E, U]for the type and making it available implicitly.ScalaTest provides implicit
Collectinginstances forscala.collection.GenTraversable,Array,java.util.Collectionandjava.util.Mapin theCollectingcompanion object.