-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypes.go
More file actions
37 lines (30 loc) · 693 Bytes
/
types.go
File metadata and controls
37 lines (30 loc) · 693 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
package dataflow
type (
// intermediate stage computations
StageExecution func(args ...interface{}) (interface{}, error)
// execution over entire network
TotalExecution func(arg interface{}) (interface{}, error)
// shutdown entire execution network
Destructor func()
// execution stage description
Stage struct {
label string
requires []string
exec StageExecution
}
// contains checked scheme of execution network flow
ExecutionGraph struct {
stages map[string]Stage
}
// node of execution network
node struct {
label string
exec StageExecution
in []<-chan either
out []chan<- either
}
either struct {
Value interface{}
Err error
}
)