fsprojects/FSharpx.Collections


HoodMelvilleQueue

Namespace: FSharpx.Collections.Experimental

Functions and values

Function or valueDescription
empty ()
Signature: unit -> HoodMelvilleQueue<'?13401>
Type parameters: '?13401

returns queue of no elements

fold f state q
Signature: f:('State -> 'T -> 'State) -> state:'State -> q:HoodMelvilleQueue<'T> -> 'State
Type parameters: 'State, 'T

applies a function to each element of the queue, threading an accumulator argument through the computation, left to right

foldBack f q state
Signature: f:('T -> 'State -> 'State) -> q:HoodMelvilleQueue<'T> -> state:'State -> 'State
Type parameters: 'T, 'State

applies a function to each element of the queue, threading an accumulator argument through the computation, right to left

head q
Signature: q:HoodMelvilleQueue<'T> -> 'T
Type parameters: 'T

returns the first element

isEmpty q
Signature: q:HoodMelvilleQueue<'T> -> bool
Type parameters: 'T

returns true if the queue has no elements

length q
Signature: q:HoodMelvilleQueue<'T> -> int
Type parameters: 'T

returns the count of elememts

ofList xs
Signature: xs:seq<'?13417> -> HoodMelvilleQueue<'?13417>
Type parameters: '?13417

returns a queue of the list

ofSeq xs
Signature: xs:seq<'?13419> -> HoodMelvilleQueue<'?13419>
Type parameters: '?13419

returns a queue of the seq

snoc x q
Signature: x:'T -> q:HoodMelvilleQueue<'T> -> HoodMelvilleQueue<'T>
Type parameters: 'T

returns a new queue with the element added to the end

tail q
Signature: q:HoodMelvilleQueue<'T> -> HoodMelvilleQueue<'T>
Type parameters: 'T

returns a new queue of the elements trailing the first element

tryGetHead q
Signature: q:HoodMelvilleQueue<'T> -> 'T option
Type parameters: 'T

returns option first element

tryGetTail q
Signature: q:HoodMelvilleQueue<'T> -> HoodMelvilleQueue<'T> option
Type parameters: 'T

returns option queue of the elements trailing the first element

tryUncons q
Signature: q:HoodMelvilleQueue<'T> -> ('T * HoodMelvilleQueue<'T>) option
Type parameters: 'T

returns option first element and tail

uncons q
Signature: q:HoodMelvilleQueue<'T> -> 'T * HoodMelvilleQueue<'T>
Type parameters: 'T

returns the first element and tail

Active patterns

Active patternDescription
( |Cons|Nil| ) q
Signature: q:HoodMelvilleQueue<'T> -> Choice<('T * HoodMelvilleQueue<'T>),unit>
Type parameters: 'T

CompiledName: |Cons|Nil|

Fork me on GitHub