Module coneforest.psylla
Package coneforest.psylla.core
Interface PsyFormalQueue<T extends PsyObject>
- Type Parameters:
T
- a type of contained objects.
- All Superinterfaces:
Iterable<T>
,PsyBounded
,PsyClearable
,PsyContainer<T>
,PsyIterable<T>
,PsyLengthy
,PsyObject
,PsySequential<T>
,PsyStreamable<T>
- All Known Implementing Classes:
PsyBlockingQueue
@Type("formalqueue")
public interface PsyFormalQueue<T extends PsyObject>
extends PsyBounded, PsyContainer<T>
The representation of
formalqueue
, an abstraction of a queue of object
s.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ContextAction
Context action of thedequeue
operator.static final ContextAction
Context action of theenqueue
operator.static final ContextAction
Context action of thegive
operator.static final ContextAction
Context action of thetake
operator.Fields inherited from interface coneforest.psylla.core.PsyBounded
PSY_CAPACITY, PSY_ISFULL
Fields inherited from interface coneforest.psylla.core.PsyClearable
PSY_CLEAR
Fields inherited from interface coneforest.psylla.core.PsyLengthy
PSY_ISEMPTY, PSY_LENGTH
Fields inherited from interface coneforest.psylla.core.PsyObject
PSY_CLONE, PSY_EQ, PSY_HASHCODE, PSY_INSTANCEOF, PSY_NE, PSY_TOSTRING, PSY_TOSTRINGBUFFER, PSY_TYPE
Fields inherited from interface coneforest.psylla.core.PsySequential
PSY_FORALL
Fields inherited from interface coneforest.psylla.core.PsyStreamable
PSY_STREAM
-
Method Summary
Modifier and TypeMethodDescriptionRemoves and returns the head of this queue.void
psyEnqueue
(T o) Inserts an element into this queue.void
psyTake()
Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
Methods inherited from interface coneforest.psylla.core.PsyBounded
capacity, isFull, psyCapacity, psyIsFull
Methods inherited from interface coneforest.psylla.core.PsyClearable
psyClear
Methods inherited from interface coneforest.psylla.core.PsyContainer
psyNewEmpty, toSyntaxStringHelper
Methods inherited from interface coneforest.psylla.core.PsyIterable
psyStream, psyToArray, psyUnite
Methods inherited from interface coneforest.psylla.core.PsyLengthy
isEmpty, length, psyIsEmpty, psyLength
Methods inherited from interface coneforest.psylla.core.PsyObject
convert, execute, invoke, psyClone, psyEq, psyHashCode, psyInstanceOf, psyNe, psySyntax, psyToString, psyToStringBuffer, psyType, toSyntaxString, typeName
Methods inherited from interface coneforest.psylla.core.PsyStreamable
psyForAll
-
Field Details
-
PSY_DEQUEUE
Context action of thedequeue
operator. -
PSY_ENQUEUE
Context action of theenqueue
operator. -
PSY_GIVE
Context action of thegive
operator. -
PSY_TAKE
Context action of thetake
operator.
-
-
Method Details
-
psyDequeue
Removes and returns the head of this queue.- Returns:
- a head of this queue.
- Throws:
PsyErrorException
- when this queue is empty.
-
psyEnqueue
Inserts an element into this queue.- Parameters:
o
- the element to enqueue.- Throws:
PsyErrorException
- when the element can not be inserted without violation of the capacity restrictions.
-
psyTake
- Throws:
PsyErrorException
-
psyGive
- Throws:
PsyErrorException
-