Top Description Constructors Methods
org.apache.commons.compress.utils

public Class Sets

extends Object
Class Inheritance
Imports
java.util.Collections, .HashSet

Set utilities
Since
1.13

Constructor Summary

AccessConstructor and Description
private
Sets()

Method Summary

Modifier and TypeMethod and Description
public static <
type of elements contained in new set
E
>
HashSet<E>

Returns:

A new HasSet
newHashSet
(final E...
the elements to fill the new set
elements
)

Creates a new HashSet filled with the given elements

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

Setsback to summary
private Sets()

Method Detail

newHashSetback to summary
public static <E> HashSet<E> newHashSet(final E... elements)

Creates a new HashSet filled with the given elements

Parameters
<E>
type of elements contained in new set
elements:E[]

the elements to fill the new set

Returns:HashSet<E>

A new HasSet

Annotations
@SafeVarargs