Idris2Doc : Data.Buffer.Mutable

Data.Buffer.Mutable

(source)

Reexports

importpublic Data.Array.Index
importpublic Data.Buffer.Core
importpublic Data.Linear.Token

Definitions

setAtSuffix : MBuffers (lengthys) ->Suffix (x::xs) ys->Bits8->F1's
  Set a value in a mutable byte array corresponding to a position in a list
used for filling said array.

Totality: total
Visibility: export
setBits8 : MBuffers256->Bits8->Bits8->F1's
  Safely access a value at the given byte position.

Totality: total
Visibility: export
getBits8 : MBuffers256->Bits8->F1sBits8
  Safely access a value at the given byte position.

Totality: total
Visibility: export
setIx : MBuffersn-> (0m : Nat) ->Ix (Sm) n=>Bits8->F1's
  Set a value at index `n - m` in a mutable byte array.

This actually uses the auto implicit argument for accessing the
the array. It is mainly useful for iterating over an array from the left
by using a natural number for counting down (see also the documentation
for `Ix`).

Totality: total
Visibility: export
setNat : MBuffersn-> (m : Nat) -> {auto0_ : LTmn} ->Bits8->F1's
  Set a value at index `m` in a mutable byte array.

Totality: total
Visibility: export
getIx : MBuffersn-> (0m : Nat) ->Ix (Sm) n=>F1sBits8
  Read a value at index `n - m` from a mutable byte array.

This actually uses the auto implicit argument for accessing the
the array. It is mainly useful for iterating over an array from the left
by using a natural number for counting down (see also the documentation
for `Ix`).

Totality: total
Visibility: export
getNat : MBuffersn-> (m : Nat) -> {auto0_ : LTmn} ->F1sBits8
  Read a value at index `m` from a mutable byte array.

Since mutable arrays must be used in a linear context, and this
function "uses up" its input as far as the linearity checker is
concerned, this also returns a new `MBuffer` wrapper, which must then
again be used exactly once.

Totality: total
Visibility: export
modifyIx : MBuffersn-> (0m : Nat) ->Ix (Sm) n=> (Bits8->Bits8) ->F1's
  Modify a value at index `n - m` in a mutable byte array.

This actually uses the auto implicit argument for accessing the
the array. It is mainly useful for iterating over an array from the left
by using a natural number for counting down (see also the documentation
for `Ix`).

Totality: total
Visibility: export
modifyNat : MBuffersn-> (m : Nat) -> {auto0_ : LTmn} -> (Bits8->Bits8) ->F1's
  Modify a value at index `m` in a mutable byte array.

Totality: total
Visibility: export
writeList : MBuffers (lengthxs) -> (ys : ListBits8) ->Suffixysxs=>F1's
  Writes the data from a list to a mutable byte array.

Totality: total
Visibility: export
writeVect : MBuffersn->VectkBits8->Ixkn=>F1's
  Writes the data from a vector to a mutable byte array.

Totality: total
Visibility: export
writeVectRev : MBuffersn-> (m : Nat) ->VectkBits8-> {auto0_ : LTEmn} ->F1's
  Writes the data from a vector to a mutable byte array in reverse order.

Totality: total
Visibility: export
genFrom : MBuffersn-> (m : Nat) -> {auto0_ : LTEmn} -> (Finn->Bits8) ->F1's
  Overwrite the values in a mutable byte array from the
given index downward with the result of the given function.

Totality: total
Visibility: export
genFrom' : MBuffersn-> (m : Nat) -> {auto0_ : LTEmn} -> (Finn->F1sBits8) ->F1's
  Overwrite the values in a mutable buffer from the
given index downward with the result of the given function.

Totality: total
Visibility: export
iterateFrom : MBuffersn-> (m : Nat) ->Ixmn=> (Bits8->Bits8) ->Bits8->F1's
  Overwrite the values in a mutable byte array from the
given index upward with the results of applying the given
function repeatedly.

Totality: total
Visibility: export
mgrow : MBuffersn-> (m : Nat) ->F1s (MBuffers (m+n))
  Allocates a new mutable byte array and adds the elements from `r`
at its beginning.

Totality: total
Visibility: export
mappend : MBuffersm->MBuffersn->F1s (MBuffers (m+n))
  Allocates a new mutable byte array and adds the elements from `p`
at its beginning, followed by adding the elements from `q`.

Totality: total
Visibility: export
mfilter : (Bits8->Bool) ->MBuffersn->F1s (m : Nat**MBuffersm)
  Filters the values in a mutable byte array according to the given predicate.

Totality: total
Visibility: export
mdrop : (m : Nat) ->MBuffersn->F1s (MBuffers (minusnm))
  Drop `m` elements from a mutable byte array.

Totality: total
Visibility: export
mmap1 : (Bits8->F1sBits8) ->MBuffersn->F1s (MBuffersn)
  Apply a function `f` to each element of the mutable buffer.

Totality: total
Visibility: export
mmap : (Bits8->Bits8) ->MBuffersn->F1s (MBuffersn)
  Apply a function `f` to each element of the mutable buffer.

Totality: total
Visibility: export
mreverse : MBuffersn->F1s (MBuffersn)
  Reverse the order of elements in a mutable buffer.

Totality: total
Visibility: export