Class ImmutableBooleanArrayStack
java.lang.Object
org.eclipse.collections.impl.stack.primitive.AbstractBooleanStack
org.eclipse.collections.impl.stack.immutable.primitive.ImmutableBooleanArrayStack
- All Implemented Interfaces:
Serializable
,BooleanIterable
,OrderedBooleanIterable
,PrimitiveIterable
,BooleanStack
,ImmutableBooleanStack
final class ImmutableBooleanArrayStack
extends AbstractBooleanStack
implements ImmutableBooleanStack, Serializable
ImmutableBooleanArrayStack is the non-modifiable equivalent of
BooleanArrayStack
.
This file was automatically generated from template file immutablePrimitiveArrayStack.stg.- Since:
- 4.0.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
ImmutableBooleanArrayStack
(boolean[] newElements) private
ImmutableBooleanArrayStack
(BooleanArrayList newElements) -
Method Summary
Modifier and TypeMethodDescriptionprivate void
checkNegativeCount
(int count) private void
checkOptimizedSize
(int length) <V> ImmutableStack
<V> collect
(BooleanToObjectFunction<? extends V> function) Returns a new collection with the results of applying the specified function on each element of the source collection.protected BooleanArrayList
boolean
isEmpty()
Returns true if this iterable has zero items.static ImmutableBooleanArrayStack
newStack
(BooleanIterable iterable) static ImmutableBooleanArrayStack
newStackFromTopToBottom
(boolean... items) static ImmutableBooleanArrayStack
static ImmutableBooleanArrayStack
newStackWith
(boolean... elements) boolean
notEmpty()
The English equivalent of !this.isEmpty()pop()
pop
(int count) push
(boolean item) reject
(BooleanPredicate predicate) Returns a new BooleanIterable with all of the elements in the BooleanIterable that return false for the specified predicate.select
(BooleanPredicate predicate) Returns a new BooleanIterable with all of the elements in the BooleanIterable that return true for the specified predicate.private Object
Methods inherited from class org.eclipse.collections.impl.stack.primitive.AbstractBooleanStack
allSatisfy, anySatisfy, appendString, appendString, appendString, asLazy, booleanIterator, checkEmptyStack, checkPositiveValueForCount, checkSizeLessThanCount, chunk, contains, containsAll, containsAll, count, detectIfNone, each, equals, forEachWithIndex, getFirst, hashCode, indexOf, injectInto, injectIntoWithIndex, makeString, makeString, makeString, noneSatisfy, peek, peek, peekAt, rangeCheck, size, toArray, toArray, toBag, toList, toSet, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.eclipse.collections.api.BooleanIterable
allSatisfy, anySatisfy, asLazy, booleanIterator, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, containsAny, containsAny, containsNone, containsNone, count, detectIfNone, each, flatCollect, forEach, injectInto, injectIntoBoolean, injectIntoByte, injectIntoChar, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, injectIntoShort, noneSatisfy, reduce, reduceIfEmpty, reject, select, toArray, toArray, toBag, toList, toSet
Methods inherited from interface org.eclipse.collections.api.stack.primitive.BooleanStack
equals, hashCode, peek, peek, peekAt
Methods inherited from interface org.eclipse.collections.api.stack.primitive.ImmutableBooleanStack
collectWithIndex, rejectWithIndex, selectWithIndex, tap
Methods inherited from interface org.eclipse.collections.api.ordered.primitive.OrderedBooleanIterable
collectWithIndex, forEachWithIndex, getFirst, indexOf, injectIntoWithIndex, rejectWithIndex, selectWithIndex
Methods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, appendString, makeString, makeString, makeString, size, toString
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
delegate
-
-
Constructor Details
-
ImmutableBooleanArrayStack
private ImmutableBooleanArrayStack(boolean[] newElements) -
ImmutableBooleanArrayStack
-
-
Method Details
-
checkOptimizedSize
private void checkOptimizedSize(int length) -
newStack
-
newStackWith
-
newStackFromTopToBottom
-
newStackFromTopToBottom
-
getDelegate
- Specified by:
getDelegate
in classAbstractBooleanStack
-
push
- Specified by:
push
in interfaceImmutableBooleanStack
-
pop
- Specified by:
pop
in interfaceImmutableBooleanStack
-
pop
- Specified by:
pop
in interfaceImmutableBooleanStack
-
checkNegativeCount
private void checkNegativeCount(int count) -
select
Description copied from interface:BooleanIterable
Returns a new BooleanIterable with all of the elements in the BooleanIterable that return true for the specified predicate.- Specified by:
select
in interfaceBooleanIterable
- Specified by:
select
in interfaceBooleanStack
- Specified by:
select
in interfaceImmutableBooleanStack
- Specified by:
select
in interfaceOrderedBooleanIterable
-
reject
Description copied from interface:BooleanIterable
Returns a new BooleanIterable with all of the elements in the BooleanIterable that return false for the specified predicate.- Specified by:
reject
in interfaceBooleanIterable
- Specified by:
reject
in interfaceBooleanStack
- Specified by:
reject
in interfaceImmutableBooleanStack
- Specified by:
reject
in interfaceOrderedBooleanIterable
-
collect
Description copied from interface:BooleanIterable
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.- Specified by:
collect
in interfaceBooleanIterable
- Specified by:
collect
in interfaceBooleanStack
- Specified by:
collect
in interfaceImmutableBooleanStack
- Specified by:
collect
in interfaceOrderedBooleanIterable
-
toImmutable
- Specified by:
toImmutable
in interfaceBooleanStack
-
isEmpty
public boolean isEmpty()Description copied from interface:PrimitiveIterable
Returns true if this iterable has zero items.- Specified by:
isEmpty
in interfacePrimitiveIterable
-
notEmpty
public boolean notEmpty()Description copied from interface:PrimitiveIterable
The English equivalent of !this.isEmpty()- Specified by:
notEmpty
in interfacePrimitiveIterable
-
writeReplace
-