Interface PartitionMutableStack<T>
- All Superinterfaces:
PartitionIterable<T>
,PartitionOrderedIterable<T>
,PartitionStack<T>
- All Known Implementing Classes:
PartitionArrayStack
public interface PartitionMutableStack<T> extends PartitionStack<T>
A PartitionMutableStack is the result of splitting a mutable stack into two mutable stacks on a Predicate.
The results that answer true for the Predicate will be returned from the getSelected() method and the results
that answer false for the predicate will be returned from the getRejected() method.
-
Method Summary
Modifier and Type Method Description void
add(T t)
Deprecated.in 5.0MutableStack<T>
getRejected()
MutableStack<T>
getSelected()
PartitionImmutableStack<T>
toImmutable()
-
Method Details
-
getSelected
MutableStack<T> getSelected()- Specified by:
getSelected
in interfacePartitionIterable<T>
- Specified by:
getSelected
in interfacePartitionOrderedIterable<T>
- Specified by:
getSelected
in interfacePartitionStack<T>
-
getRejected
MutableStack<T> getRejected()- Specified by:
getRejected
in interfacePartitionIterable<T>
- Specified by:
getRejected
in interfacePartitionOrderedIterable<T>
- Specified by:
getRejected
in interfacePartitionStack<T>
-
toImmutable
PartitionImmutableStack<T> toImmutable() -
add
Deprecated.in 5.0
-