scala.collection.JavaConversions

class JSetWrapper

[source: scala/collection/JavaConversions.scala]

case class JSetWrapper[A](val underlying : java.util.Set[A])
extends Set[A] with MutableSetTemplate[A, JSetWrapper[A]] with Product
Method Summary
def += (elem : A) : JSetWrapper[A]
Adds a new element to the set.
def -= (elem : A) : JSetWrapper[A]
Removes a single element from a set.
override def add (elem : A) : Boolean
Adds a new element to the set.
override def canEqual (arg0 : Any) : Boolean
An equality helper method to assist in maintaining reflexivity in the face of subtyping. For more, see http://www.artima.com/lejava/articles/equality.html
override def clear : Unit
Removes all elements from the set. After this operation is completed, the set will be empty.
def contains (elem : A) : Boolean
Checks if this set contains element elem.
override def empty : JSetWrapper[A]
def iterator : Iterator[A]
Creates a new iterator over all elements contained in this iterable object.
override def productArity : Int
return k for a product A(x_1,...,x_k)
override def productElement (arg0 : Int) : Any
for a product A(x_1,...,x_k), returns x_(n+1) for 0 <= n < k
override def productPrefix : java.lang.String
By default the empty string. Implementations may override this method in order to prepend a string prefix to the result of the toString methods.
override def remove (elem : A) : Boolean
Removes a single element from a set.
override def size : Int
The number of elements in this collection
Methods inherited from Product
productIterator, productElements
Methods inherited from Set
companion
Methods inherited from Unhashable
hashCode, identityHashCode
Methods inherited from MutableSetTemplate
newBuilder, update, retain, clone, result, +, +, ++, ++, -, -, --, --, <<
Methods inherited from Shrinkable
-=, --=, --=
Methods inherited from Builder
sizeHint, mapResult
Methods inherited from Growable
+=, ++=, ++=
Methods inherited from SetTemplate
isEmpty, apply, intersect, &, **, union, |, diff, &~, subsetOf, equals, stringPrefix, toString
Methods inherited from Function1
compose, andThen
Methods inherited from IterableTemplate
elements, foreach, foldRight, reduceRight, toIterable, head, takeRight, dropRight, sameElements, toStream, view, view, first, firstOption, toSeq, projection
Methods inherited from TraversableClass
genericBuilder, unzip, flatten, transpose
Methods inherited from TraversableTemplate
thisCollection, nonEmpty, hasDefiniteSize, ++, ++, map, flatMap, filter, filterMap, filterNot, remove, partition, groupBy, forall, exists, count, find, foldLeft, /:, :\, reduceLeft, reduceLeftOption, reduceRightOption, headOption, tail, last, lastOption, init, take, drop, slice, takeWhile, dropWhile, span, splitAt, copyToBuffer, copyToArray, copyToArray, toArray, toList, toSequence, toSet, mkString, mkString, mkString, addString, addString, addString
Methods inherited from AnyRef
getClass, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized
Methods inherited from Any
==, !=, isInstanceOf, asInstanceOf
Method Details
override def size : Int
The number of elements in this collection

def iterator : Iterator[A]
Creates a new iterator over all elements contained in this iterable object.
Returns
the new iterator

def contains(elem : A) : Boolean
Checks if this set contains element elem.
Parameters
elem - the element to check for membership.
Returns
true iff elem is contained in this set.

def +=(elem : A) : JSetWrapper[A]
Adds a new element to the set.
Parameters
elem - the element to be added
Overrides
MutableSetTemplate.+=

def -=(elem : A) : JSetWrapper[A]
Removes a single element from a set.
Parameters
elem - The element to be removed.
Overrides
MutableSetTemplate.-=

override def add(elem : A) : Boolean
Adds a new element to the set.
Parameters
elem - the element to be added
Returns
true if the element was not yet present in the set.
Overrides
MutableSetTemplate.add

override def remove(elem : A) : Boolean
Removes a single element from a set.
Parameters
elem - The element to be removed.
Returns
true if the element was already present in the set.
Overrides
MutableSetTemplate.remove

override def clear : Unit
Removes all elements from the set. After this operation is completed, the set will be empty.
Overrides
MutableSetTemplate.clear

override def empty : JSetWrapper[A]

override def productPrefix : java.lang.String
By default the empty string. Implementations may override this method in order to prepend a string prefix to the result of the toString methods.
Overrides
Product.productPrefix

override def productArity : Int
return k for a product A(x_1,...,x_k)
Overrides
Product.productArity

override def productElement(arg0 : Int) : Any
for a product A(x_1,...,x_k), returns x_(n+1) for 0 <= n < k
Parameters
n - the index of the element to return
Throws
IndexOutOfBoundsException -
Returns
The element n elements after the first element
Overrides
Product.productElement

override def canEqual(arg0 : Any) : Boolean
An equality helper method to assist in maintaining reflexivity in the face of subtyping. For more, see http://www.artima.com/lejava/articles/equality.html
Overrides
Product.canEqual