Class UnmodifiableBooleanStack
- java.lang.Object
-
- org.eclipse.collections.impl.stack.mutable.primitive.UnmodifiableBooleanStack
-
- All Implemented Interfaces:
Serializable
,BooleanIterable
,OrderedBooleanIterable
,PrimitiveIterable
,BooleanStack
,MutableBooleanStack
public class UnmodifiableBooleanStack extends Object implements MutableBooleanStack, Serializable
This file was automatically generated from template file unmodifiablePrimitiveStack.stg.- Since:
- 3.1.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description UnmodifiableBooleanStack(MutableBooleanStack stack)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
allSatisfy(BooleanPredicate predicate)
boolean
anySatisfy(BooleanPredicate predicate)
void
appendString(Appendable appendable)
void
appendString(Appendable appendable, String separator)
void
appendString(Appendable appendable, String start, String separator, String end)
LazyBooleanIterable
asLazy()
MutableBooleanStack
asSynchronized()
MutableBooleanStack
asUnmodifiable()
BooleanIterator
booleanIterator()
RichIterable<BooleanIterable>
chunk(int size)
void
clear()
<V> MutableStack<V>
collect(BooleanToObjectFunction<? extends V> function)
<V> MutableStack<V>
collectWithIndex(BooleanIntToObjectFunction<? extends V> function)
Returns a new MutableStack using results obtained by applying the specified function to each element and its corresponding index.<V,R extends Collection<V>>
RcollectWithIndex(BooleanIntToObjectFunction<? extends V> function, R target)
Adds elements to the target Collection using results obtained by applying the specified function to each element and its corresponding index.boolean
contains(boolean value)
boolean
containsAll(boolean... source)
boolean
containsAll(BooleanIterable source)
int
count(BooleanPredicate predicate)
boolean
detectIfNone(BooleanPredicate predicate, boolean ifNone)
void
each(BooleanProcedure procedure)
boolean
equals(Object otherStack)
void
forEachWithIndex(BooleanIntProcedure procedure)
boolean
getFirst()
int
hashCode()
int
indexOf(boolean value)
<T> T
injectInto(T injectedValue, ObjectBooleanToObjectFunction<? super T,? extends T> function)
<T> T
injectIntoWithIndex(T injectedValue, ObjectBooleanIntToObjectFunction<? super T,? extends T> function)
boolean
isEmpty()
String
makeString()
String
makeString(String separator)
String
makeString(String start, String separator, String end)
MutableBooleanStack
newEmpty()
boolean
noneSatisfy(BooleanPredicate predicate)
boolean
notEmpty()
boolean
peek()
BooleanList
peek(int count)
boolean
peekAt(int index)
boolean
pop()
BooleanList
pop(int count)
void
push(boolean item)
MutableBooleanStack
reject(BooleanPredicate predicate)
MutableBooleanStack
select(BooleanPredicate predicate)
int
size()
boolean[]
toArray()
boolean[]
toArray(boolean[] target)
MutableBooleanBag
toBag()
ImmutableBooleanStack
toImmutable()
MutableBooleanList
toList()
MutableBooleanSet
toSet()
String
toString()
-
Methods inherited from interface org.eclipse.collections.api.BooleanIterable
collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, containsAny, containsAny, containsNone, containsNone, flatCollect, forEach, injectIntoBoolean, injectIntoByte, injectIntoChar, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, injectIntoShort, reduce, reduceIfEmpty, reject, select
-
Methods inherited from interface org.eclipse.collections.api.stack.primitive.MutableBooleanStack
rejectWithIndex, selectWithIndex, tap
-
Methods inherited from interface org.eclipse.collections.api.ordered.primitive.OrderedBooleanIterable
rejectWithIndex, selectWithIndex
-
-
-
-
Constructor Detail
-
UnmodifiableBooleanStack
public UnmodifiableBooleanStack(MutableBooleanStack stack)
-
-
Method Detail
-
push
public void push(boolean item)
- Specified by:
push
in interfaceMutableBooleanStack
-
pop
public boolean pop()
- Specified by:
pop
in interfaceMutableBooleanStack
-
pop
public BooleanList pop(int count)
- Specified by:
pop
in interfaceMutableBooleanStack
-
peek
public boolean peek()
- Specified by:
peek
in interfaceBooleanStack
-
peek
public BooleanList peek(int count)
- Specified by:
peek
in interfaceBooleanStack
-
peekAt
public boolean peekAt(int index)
- Specified by:
peekAt
in interfaceBooleanStack
-
size
public int size()
- Specified by:
size
in interfacePrimitiveIterable
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interfacePrimitiveIterable
-
notEmpty
public boolean notEmpty()
- Specified by:
notEmpty
in interfacePrimitiveIterable
-
clear
public void clear()
- Specified by:
clear
in interfaceMutableBooleanStack
-
contains
public boolean contains(boolean value)
- Specified by:
contains
in interfaceBooleanIterable
-
containsAll
public boolean containsAll(boolean... source)
- Specified by:
containsAll
in interfaceBooleanIterable
-
containsAll
public boolean containsAll(BooleanIterable source)
- Specified by:
containsAll
in interfaceBooleanIterable
-
booleanIterator
public BooleanIterator booleanIterator()
- Specified by:
booleanIterator
in interfaceBooleanIterable
-
each
public void each(BooleanProcedure procedure)
- Specified by:
each
in interfaceBooleanIterable
- Since:
- 7.0.
-
count
public int count(BooleanPredicate predicate)
- Specified by:
count
in interfaceBooleanIterable
-
anySatisfy
public boolean anySatisfy(BooleanPredicate predicate)
- Specified by:
anySatisfy
in interfaceBooleanIterable
-
allSatisfy
public boolean allSatisfy(BooleanPredicate predicate)
- Specified by:
allSatisfy
in interfaceBooleanIterable
-
noneSatisfy
public boolean noneSatisfy(BooleanPredicate predicate)
- Specified by:
noneSatisfy
in interfaceBooleanIterable
-
detectIfNone
public boolean detectIfNone(BooleanPredicate predicate, boolean ifNone)
- Specified by:
detectIfNone
in interfaceBooleanIterable
-
select
public MutableBooleanStack select(BooleanPredicate predicate)
- Specified by:
select
in interfaceBooleanIterable
- Specified by:
select
in interfaceBooleanStack
- Specified by:
select
in interfaceMutableBooleanStack
- Specified by:
select
in interfaceOrderedBooleanIterable
-
reject
public MutableBooleanStack reject(BooleanPredicate predicate)
- Specified by:
reject
in interfaceBooleanIterable
- Specified by:
reject
in interfaceBooleanStack
- Specified by:
reject
in interfaceMutableBooleanStack
- Specified by:
reject
in interfaceOrderedBooleanIterable
-
collect
public <V> MutableStack<V> collect(BooleanToObjectFunction<? extends V> function)
- Specified by:
collect
in interfaceBooleanIterable
- Specified by:
collect
in interfaceBooleanStack
- Specified by:
collect
in interfaceMutableBooleanStack
- Specified by:
collect
in interfaceOrderedBooleanIterable
-
toArray
public boolean[] toArray()
- Specified by:
toArray
in interfaceBooleanIterable
-
toArray
public boolean[] toArray(boolean[] target)
- Specified by:
toArray
in interfaceBooleanIterable
-
toString
public String toString()
- Specified by:
toString
in interfacePrimitiveIterable
- Overrides:
toString
in classObject
-
makeString
public String makeString()
- Specified by:
makeString
in interfacePrimitiveIterable
-
makeString
public String makeString(String separator)
- Specified by:
makeString
in interfacePrimitiveIterable
-
makeString
public String makeString(String start, String separator, String end)
- Specified by:
makeString
in interfacePrimitiveIterable
-
appendString
public void appendString(Appendable appendable)
- Specified by:
appendString
in interfacePrimitiveIterable
-
appendString
public void appendString(Appendable appendable, String separator)
- Specified by:
appendString
in interfacePrimitiveIterable
-
appendString
public void appendString(Appendable appendable, String start, String separator, String end)
- Specified by:
appendString
in interfacePrimitiveIterable
-
toList
public MutableBooleanList toList()
- Specified by:
toList
in interfaceBooleanIterable
-
toSet
public MutableBooleanSet toSet()
- Specified by:
toSet
in interfaceBooleanIterable
-
toBag
public MutableBooleanBag toBag()
- Specified by:
toBag
in interfaceBooleanIterable
-
equals
public boolean equals(Object otherStack)
- Specified by:
equals
in interfaceBooleanStack
- Overrides:
equals
in classObject
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfaceBooleanStack
- Overrides:
hashCode
in classObject
-
asLazy
public LazyBooleanIterable asLazy()
- Specified by:
asLazy
in interfaceBooleanIterable
-
asUnmodifiable
public MutableBooleanStack asUnmodifiable()
- Specified by:
asUnmodifiable
in interfaceMutableBooleanStack
-
asSynchronized
public MutableBooleanStack asSynchronized()
- Specified by:
asSynchronized
in interfaceMutableBooleanStack
-
toImmutable
public ImmutableBooleanStack toImmutable()
- Specified by:
toImmutable
in interfaceBooleanStack
-
newEmpty
public MutableBooleanStack newEmpty()
- Specified by:
newEmpty
in interfaceMutableBooleanStack
- Since:
- 9.2.
-
injectInto
public <T> T injectInto(T injectedValue, ObjectBooleanToObjectFunction<? super T,? extends T> function)
- Specified by:
injectInto
in interfaceBooleanIterable
-
chunk
public RichIterable<BooleanIterable> chunk(int size)
- Specified by:
chunk
in interfaceBooleanIterable
-
getFirst
public boolean getFirst()
- Specified by:
getFirst
in interfaceOrderedBooleanIterable
-
indexOf
public int indexOf(boolean value)
- Specified by:
indexOf
in interfaceOrderedBooleanIterable
-
injectIntoWithIndex
public <T> T injectIntoWithIndex(T injectedValue, ObjectBooleanIntToObjectFunction<? super T,? extends T> function)
- Specified by:
injectIntoWithIndex
in interfaceOrderedBooleanIterable
-
forEachWithIndex
public void forEachWithIndex(BooleanIntProcedure procedure)
- Specified by:
forEachWithIndex
in interfaceOrderedBooleanIterable
-
collectWithIndex
public <V> MutableStack<V> collectWithIndex(BooleanIntToObjectFunction<? extends V> function)
Returns a new MutableStack using results obtained by applying the specified function to each element and its corresponding index.- Specified by:
collectWithIndex
in interfaceBooleanStack
- Specified by:
collectWithIndex
in interfaceMutableBooleanStack
- Specified by:
collectWithIndex
in interfaceOrderedBooleanIterable
- Since:
- 9.1.
-
collectWithIndex
public <V,R extends Collection<V>> R collectWithIndex(BooleanIntToObjectFunction<? extends V> function, R target)
Adds elements to the target Collection using results obtained by applying the specified function to each element and its corresponding index.- Specified by:
collectWithIndex
in interfaceOrderedBooleanIterable
- Since:
- 9.1.
-
-