erasure

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 17, 2025 License: Apache-2.0 Imports: 7 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RSRestore added in v0.3.18

func RSRestore(outpath string, shardspath []string) error

Restore files from shards and save to outpath.

Receive parameter:

  • outpath: file save location.
  • shardspath: file fragments.

Return parameter:

  • error: error message.

func RSRestoreData added in v0.3.18

func RSRestoreData(outpath string, sharddata [][]byte) error

Restore files from shards and save to outpath.

Receive parameter:

  • outpath: file save location.
  • sharddata: file fragments data.

Return parameter:

  • error: error message.

func ReedSolomon

func ReedSolomon(file string, saveDir string) ([]string, error)

ReedSolomon uses reed-solomon algorithm to redundancy file

Receive parameter:

  • file: the file to be processed
  • saveDir: save directory

Return parameter:

  • []string: processed data fragmentation
  • error: error message.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL