commit
9c0c38b0fd
@ -0,0 +1,11 @@ |
||||
package ida |
||||
|
||||
// HarmonyIDA implements IDA interface.
|
||||
type HarmonyIDA struct { |
||||
raptorQImp *RaptorQ |
||||
} |
||||
|
||||
// TakeRaptorQ takes RaptorQ implementation.
|
||||
func (ida *HarmonyIDA) TakeRaptorQ(raptorQImp *RaptorQ) { |
||||
ida.raptorQImp = raptorQImp |
||||
} |
@ -0,0 +1,22 @@ |
||||
package ida |
||||
|
||||
import ( |
||||
"github.com/simple-rules/harmony-benchmark/p2p" |
||||
) |
||||
|
||||
// Symbol is produced from a RaptorQ implementation.
|
||||
type Symbol []byte |
||||
|
||||
// Message is type of general message gopssiped
|
||||
type Message []byte |
||||
|
||||
// RaptorQ interface.
|
||||
type RaptorQ interface { |
||||
Init() |
||||
Process(msg Message) chan Symbol |
||||
} |
||||
|
||||
// IDA interface.
|
||||
type IDA interface { |
||||
Process(msg Message, peers []p2p.Peer, timeout int) |
||||
} |
Loading…
Reference in new issue