From d498863d0d08eafbdee55c8dbd647cb0c8d49c29 Mon Sep 17 00:00:00 2001 From: Xiang Li Date: Sat, 4 Jun 2016 20:57:29 -0700 Subject: [PATCH] blockset.go: add BlockReconstructor interface for erasure-encoding --- blockset.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/blockset.go b/blockset.go index 6cdc91d..4dd1760 100644 --- a/blockset.go +++ b/blockset.go @@ -24,6 +24,12 @@ type Blockset interface { String() string } +// BlockReconstructor can reconstruct a block in a Blockset. +type BlockReconstructor interface { + // ReconstructBlock reconstructs the ith block in the Blockset. + ReconstructBlock(ctx context.Context, inde INodeRef, i int) error +} + type BlockLayerKind int type BlockLayer struct {