Base interface for classes that represent a double-ended queue of elements.
interface
|
IDeque
|
with
|
<T>
|
||
extends
|
ICollector<T>
|
||||
IVectorConst<T>
|
|||||
base of
|
DequeBase
|
The number of elements in this collection.
property
|
Count
{
get
}
|
||
type
|
int32
|
||
value
|
|
The number of elements. | |
inherited
|
IBagConst.Count
|
Adds the given element to this collection.
method
|
Add
(T element)
|
||
type
|
bool
|
||
params
|
element
|
The element to add. | |
returns
|
true
if
the
collection
has
changed,
false
if
not. |
||
inherited
|
ICollector.Add
|
Remarks:
Implementing
methods
shall
return
false
iff
the
element
has
already
been
collected,
i.e.
it
is
contained
in
the
collection.
If
in
doubt,
return
true
.
Removes all elements from the queue.
method
|
Clear
()
|
Returns if this collection contains the given element.
[Pure]
|
||||
method
|
Contains
(T element)
|
|||
type
|
bool
|
|||
params
|
element
|
The element. | ||
returns
|
true
if
element
is
contained
in
this
collection,
false
if
not.
|
|||
inherited
|
IBagConst.Contains
|
Returns if this collection contains all given elements.
method
|
ContainsAll
(IEnumerable<T> elements)
|
||
type
|
bool
|
||
params
|
elements
|
[not-null]
|
The elements. |
returns
|
true
if
all
elements
are
contained
in
this
collection,
false
if
not.
|
||
inherited
|
IBagConst.ContainsAll
|
Returns the first enumerated value.
[Pure]
|
||||
method
|
First
()
|
|||
type
|
T
|
|||
returns
|
The first enumerated value. | |||
inherited
|
IBagConst.First
|
Exceptions:
Returns the element at the given list index.
[Pure]
|
||||
method
|
GetAt
(int32 index)
|
|||
type
|
T
|
|||
params
|
index
|
[0..Count-1]
|
The list index. | |
returns
|
The element. | |||
inherited
|
IVectorConst.GetAt
|
method
|
GetEnumerator
()
|
||
type
|
IEnumerator<T>
|
||
inherited
|
IEnumerable.GetEnumerator
|
Returns the list index of the given element.
[Pure]
|
||||
method
|
IndexOf
(T element)
|
|||
type
|
int32
|
|||
params
|
element
|
The element. | ||
returns
|
The
list
index
or
-1
if
the
element
is
not
contained
in
the
list. |
|||
inherited
|
IVectorConst.IndexOf
|
Returns the last enumerated value.
[Pure]
|
||||
method
|
Last
()
|
|||
type
|
T
|
|||
returns
|
The last enumerated value. | |||
inherited
|
IBagConst.Last
|
Exceptions:
Returns the first element in the queue without removing it.
method
|
PeekFirst
()
|
||
type
|
T
|
||
returns
|
The first element. |
Returns the last element in the queue without removing it.
method
|
PeekLast
()
|
||
type
|
T
|
||
returns
|
The last element. |
Returns the first element in the queue and removes it.
method
|
PopFirst
()
|
||
type
|
T
|
||
returns
|
The first element. |
Returns the last element in the queue and removes it.
method
|
PopLast
()
|
||
type
|
T
|
||
returns
|
The last element. |
Prepends the given element to the queue.
method
|
PushFirst
(T element)
|
||
params
|
element
|
The element. |
Appends the given element to the queue.
method
|
PushLast
(T element)
|
||
params
|
element
|
The element. |
Returns the elements of this enumerable object as a fresh array.
[Pure]
|
||||
method
|
ToArray
()
|
|||
type
|
T[]
|
|||
returns
|
|
The array of elements. | ||
inherited
|
IBagConst.ToArray
|
Returns the elements of this collection as an array.
method
|
ToArrayCopy
(T[] array,
int32 offset = 0)
|
||
type
|
T[]
|
||
params
|
array
|
[not-null]
|
The output array. |
offset
|
[>=0]
|
Offset
into
array.
Defaults
to
0 .
|
|
returns
|
|
The filled array. | |
inherited
|
IBagConst.ToArrayCopy
|
Remarks:
The elements in this collection will be copied into the given array, starting at the array index specified by offset.
Returns the elements of this enumerable object as a list.
[Pure]
|
||||
method
|
ToArrayList
()
|
|||
type
|
IArrayVector<T>
|
|||
returns
|
|
The list of elements. | ||
inherited
|
IBagConst.ToArrayList
|
Returns the elements of this enumerable object as a list.
[Pure]
|
||||
method
|
ToList
()
|
|||
type
|
IVectorConst<T>
|
|||
returns
|
|
The list of elements. | ||
inherited
|
IBagConst.ToList
|