Top Description Classes
[default module]

Package org.apache.commons.collections4.bag


This package contains implementations of the Bag and SortedBag interfaces. A bag stores an object and a count of the number of occurrences of the object.

The following implementations are provided in the package:

The following decorators are provided in the package:

Class Summary

Modifier and TypeClass and Description
public abstract class
AbstractBagDecorator<
the type of elements in this bag
E
>

Decorates another Bag to provide additional behaviour.

public abstract class
AbstractMapBag<
the type of elements in this bag
E
>

Abstract implementation of the Bag interface to simplify the creation of subclass implementations.

public abstract class
AbstractSortedBagDecorator<
the type of elements in this bag
E
>

Decorates another SortedBag to provide additional behaviour.

public class
CollectionBag<
the type of elements in this bag
E
>

Decorates another Bag to comply with the Collection contract.

public class
CollectionSortedBag<
the type of elements in this bag
E
>

Decorates another SortedBag to comply with the Collection contract.

public class
HashBag<
the type of elements in this bag
E
>

Implements Bag, using a HashMap to provide the data storage.

public class
PredicatedBag<
the type of elements in this bag
E
>

Decorates another Bag to validate that additions match a specified predicate.

public class
PredicatedSortedBag<
the type of elements in this bag
E
>

Decorates another SortedBag to validate that additions match a specified predicate.

public class
SynchronizedBag<
the type of elements in this bag
E
>

Decorates another Bag to synchronize its behaviour for a multi-threaded environment.

public class
SynchronizedSortedBag<
the type of elements in this bag
E
>

Decorates another SortedBag to synchronize its behaviour for a multi-threaded environment.

public class
TransformedBag<
the type of elements in this bag
E
>

Decorates another Bag to transform objects that are added.

public class
TransformedSortedBag<
the type of elements in this bag
E
>

Decorates another SortedBag to transform objects that are added.

public class
TreeBag<
the type of elements in this bag
E
>

Implements SortedBag, using a TreeMap to provide the data storage.

public class
UnmodifiableBag<
the type of elements in this bag
E
>

Decorates another Bag to ensure it can't be altered.

public class
UnmodifiableSortedBag<
the type of elements in this bag
E
>

Decorates another SortedBag to ensure it can't be altered.