Top Description Methods
org.eclipse.collections.api.set.primitive

public Interface ShortSet

extends ShortIterable
Known Direct Subinterfaces
org.eclipse.collections.api.set.primitive.ImmutableShortSet, org.eclipse.collections.api.set.primitive.MutableShortSet
Imports
java.util.Set, org.eclipse.collections.api.ShortIterable, .LazyIterable, org.eclipse.collections.api.block.function.primitive.ShortToObjectFunction, org.eclipse.collections.api.block.predicate.primitive.ShortPredicate, org.eclipse.collections.api.block.procedure.primitive.ShortProcedure, org.eclipse.collections.api.set.SetIterable, org.eclipse.collections.api.tuple.primitive.ShortShortPair

This file was automatically generated from template file primitiveSet.stg.
Since
3.0.

Method Summary

Modifier and TypeMethod and Description
public LazyIterable<ShortShortPair>
cartesianProduct(ShortSet set)

Returns the set whose members are all possible ordered pairs (a, b) where a is a member of this and b is a member of set.

public <V> SetIterable<V>
collect(ShortToObjectFunction<? extends V> function)

Redeclares org.eclipse.collections.api.ShortIterable.collect.

Returns a new collection with the results of applying the specified function on each element of the source collection.

public ShortSet
difference(ShortSet set)

Returns the set of all members of this that are not members of set.

public boolean
equals(Object o)

Follows the same general contract as Set#equals(Object).

public ShortSet
freeze()

Returns a frozen copy of this set.

public int
hashCode()

Follows the same general contract as Set#hashCode().

public ShortSet
intersect(ShortSet set)

Returns the set of all objects that are members of both this and set.

public default boolean
isProperSubsetOf(ShortSet set)

Returns true if all the members of this are also members of set and the two sets are not equal.

public default boolean
isSubsetOf(ShortSet set)

Returns true if all the members of this are also members of set.

public ShortSet
reject(ShortPredicate predicate)

Redeclares org.eclipse.collections.api.ShortIterable.reject.

Returns a new ShortIterable with all of the elements in the ShortIterable that return false for the specified predicate.

public ShortSet
select(ShortPredicate predicate)

Redeclares org.eclipse.collections.api.ShortIterable.select.

Returns a new ShortIterable with all of the elements in the ShortIterable that return true for the specified predicate.

public ShortSet
symmetricDifference(ShortSet set)

Returns the set of all objects that are a member of exactly one of this and set (elements which are in one of the sets, but not in both).

public default ShortSet
public ImmutableShortSet
toImmutable()

Returns an immutable copy of this set.

public ShortSet
Inherited from org.eclipse.collections.api.ShortIterable:
allSatisfyanySatisfyasLazyaverageaverageIfEmptychunkcollectcollectBooleancollectBytecollectCharcollectDoublecollectFloatcollectIntcollectLongcollectShortcontainscontainsAllcontainsAllcontainsAnycontainsAnycontainsNonecontainsNonecountdetectIfNoneeachflatCollectforEachinjectIntoinjectIntoBooleaninjectIntoByteinjectIntoCharinjectIntoDoubleinjectIntoFloatinjectIntoIntinjectIntoLonginjectIntoShortmaxmaxIfEmptymedianmedianIfEmptyminminIfEmptynoneSatisfyreducereduceIfEmptyrejectselectshortIteratorsumsummaryStatisticstoArraytoArraytoBagtoListtoSettoSortedArraytoSortedListtoSortedListtoSortedListBytoSortedListBy

Method Detail

cartesianProductback to summary
public LazyIterable<ShortShortPair> cartesianProduct(ShortSet set)

Returns the set whose members are all possible ordered pairs (a, b) where a is a member of this and b is a member of set.

Since
11.0.
collectback to summary
public <V> SetIterable<V> collect(ShortToObjectFunction<? extends V> function)

Redeclares org.eclipse.collections.api.ShortIterable.collect.

Doc from org.eclipse.collections.api.ShortIterable.collect.

Returns a new collection with the results of applying the specified function on each element of the source collection. This method is also commonly called transform or map.

Annotations
@Override
differenceback to summary
public ShortSet difference(ShortSet set)

Returns the set of all members of this that are not members of set. The difference of [1, 2, 3] and [2, 3, 4] is the set [1].

Since
11.0.
equalsback to summary
public boolean equals(Object o)

Follows the same general contract as Set#equals(Object).

Annotations
@Override
freezeback to summary
public ShortSet freeze()

Returns a frozen copy of this set. If the set is frozen, it returns itself. A frozen copy is the same thing as an immutable copy without safe-publish guarantees.

hashCodeback to summary
public int hashCode()

Follows the same general contract as Set#hashCode().

Annotations
@Override
intersectback to summary
public ShortSet intersect(ShortSet set)

Returns the set of all objects that are members of both this and set. The intersection of [1, 2, 3] and [2, 3, 4] is the set [2, 3].

Since
11.0.
isProperSubsetOfback to summary
public default boolean isProperSubsetOf(ShortSet set)

Returns true if all the members of this are also members of set and the two sets are not equal. For example, [1, 2] is a proper subset of [1, 2, 3], but [1, 2, 3] is not.

Since
11.0.
isSubsetOfback to summary
public default boolean isSubsetOf(ShortSet set)

Returns true if all the members of this are also members of set. For example, [1, 2] is a subset of [1, 2, 3], but [1, 4] is not.

Since
11.0.
rejectback to summary
public ShortSet reject(ShortPredicate predicate)

Redeclares org.eclipse.collections.api.ShortIterable.reject.

Doc from org.eclipse.collections.api.ShortIterable.reject.

Returns a new ShortIterable with all of the elements in the ShortIterable that return false for the specified predicate.

Annotations
@Override
selectback to summary
public ShortSet select(ShortPredicate predicate)

Redeclares org.eclipse.collections.api.ShortIterable.select.

Doc from org.eclipse.collections.api.ShortIterable.select.

Returns a new ShortIterable with all of the elements in the ShortIterable that return true for the specified predicate.

Annotations
@Override
symmetricDifferenceback to summary
public ShortSet symmetricDifference(ShortSet set)

Returns the set of all objects that are a member of exactly one of this and set (elements which are in one of the sets, but not in both). For instance, for the sets [1, 2, 3] and [2, 3, 4], the symmetric difference set is [1, 4] . It is the set difference of the union and the intersection.

Since
11.0.
tapback to summary
public default ShortSet tap(ShortProcedure procedure)

Overrides default org.eclipse.collections.api.ShortIterable.tap.

Annotations
@Override
Since
9.0.
toImmutableback to summary
public ImmutableShortSet toImmutable()

Returns an immutable copy of this set. If the set is immutable, it returns itself.

unionback to summary
public ShortSet union(ShortSet set)
Since
11.0.