package reed-solomon-erasure

  1. Overview
  2. Docs
val option_shards_to_shards_bytes : bytes option array -> bytes array

option_shards_to_shards_bytes shards

See option_shards_to_shards_bigstr.

val shards_to_option_shards_bytes : bytes array -> bytes option array

shards_to_option_shards_bytes shards

See shards_to_option_shards_bigstr.

val option_shards_to_shards_str : string option array -> string array

option_shards_to_shards_str shards

See option_shards_to_shards_bigstr.

val shards_to_option_shards_str : string array -> string option array

shards_to_option_shards_str shards

See shards_to_option_shards_bigstr.

val option_shards_to_shards_bigstr : bigstring option array -> bigstring array

option_shards_to_shards_bigstr shards

Transforms an array of shards into an array of option shards.

This is mainly useful when you want to repair an array of shards using reconstruct functions.

Remarks

Shards are copied - the returned array of shards do not share ownership with provided shards.

val shards_to_option_shards_bigstr : bigstring array -> bigstring option array

shards_to_option_shards_bigstr shards

Transforms array of shards to array of option shards.

This is mainly useful when you want to repair an array of shards using reconstruct functions.

Remarks

Shards are copied - the returned array of shards do not share ownership with provided shards.

val make_blank_shards_str : count:int -> size_per_shard:int -> string array

make_blank_shards_str ~count ~size_per_shard

Creates an string array of size count, each string is filled with zeros and of size size_per_shard.

val make_blank_shards_bytes : count:int -> size_per_shard:int -> bytes array

make_blank_shards_bytes ~count ~size_per_shard

Creates an bytes array of size count, each bytes is filled with zeros and of size size_per_shard.

val make_blank_shards_bigstr : count:int -> size_per_shard:int -> bigstring array

make_blank_shards_bigstr ~count ~size_per_shard

Creates an bigstring array of size count, each bigstring is filled with zeros and of size size_per_shard.

val copy_bigstr : bigstring -> bigstring
val copy_shards_bytes : bytes array -> bytes array
val copy_shards_str : string array -> string array
val copy_shards_bigstr : bigstring array -> bigstring array