-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdeprecates.go
More file actions
97 lines (79 loc) · 2.8 KB
/
deprecates.go
File metadata and controls
97 lines (79 loc) · 2.8 KB
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
package chain
// Deprecated. Use InternalTypeGetter
type AggregateGetter[T any, U any] InternalTypeGetter[T, U]
// Deprecated. Use ExternalTypeSetter
type AggregateSetter[T any, U any] ExternalTypeSetter[T, U]
// Deprecated. Use AdaptAction
func NewAggregateAction[T any, U any](
action Action[U],
getter AggregateGetter[T, U],
setter AggregateSetter[T, U],
) Action[T] {
return AdaptAction[T, U](
action,
(InternalTypeGetter[T, U])(getter),
(ExternalTypeSetter[T, U])(setter),
)
}
// Deprecated. Use AsParallelMapAction
func NewParallelMapPipeline[K comparable, T any](name string, action Action[T]) Action[map[K]T] {
return AsParallelMapAction[K, T](name, action)
}
// Deprecated. Use AsParallelSliceAction
func NewParallelSlicePipeline[T any](name string, action Action[T]) Action[[]T] {
return AsParallelSliceAction[T](name, action)
}
// Deprecated. Use AsSequenceMapAction
func NewSequenceMapPipeline[K comparable, T any](name string, action Action[T]) Action[map[K]T] {
return AsSequenceMapAction[K, T](name, action)
}
// Deprecated. Use AsSequenceSliceAction
func NewSequenceSlicePipeline[T any](name string, action Action[T], stopOnError bool) Action[[]T] {
return AsSequenceSliceAction[T](name, action, stopOnError)
}
// Deprecated. Use Workflow
type Pipeline[T any] struct {
*Workflow[T]
}
// Deprecated. Use NewWorkflow
func NewPipeline[T any](name string, memberActions ...Action[T]) *Pipeline[T] {
return &Pipeline[T]{
Workflow: NewWorkflow[T](name, memberActions...),
}
}
// Deprecated. Use AsParallelMapAction
func NewParallelMapAction[K comparable, T any](name string, action Action[T]) Action[map[K]T] {
return AsParallelMapAction[K, T](name, action)
}
// Deprecated. Use AsParallelSliceAction
func NewParallelSliceAction[T any](name string, action Action[T]) Action[[]T] {
return AsParallelSliceAction[T](name, action)
}
// Deprecated. Use AsSequenceMapAction
func NewSequenceMapAction[K comparable, T any](name string, action Action[T]) Action[map[K]T] {
return AsSequenceMapAction[K, T](name, action)
}
// Deprecated. Use AsSequenceSliceAction
func NewSequenceSliceAction[T any](name string, action Action[T], stopOnError bool) Action[[]T] {
return AsSequenceSliceAction[T](name, action, stopOnError)
}
// Deprecated. Use InternalTypeGetter
type InternalValueGetter[T any, U any] InternalTypeGetter[T, U]
// Deprecated. Use ExternalTypeSetter
type InternalValueSetter[T any, U any] ExternalTypeSetter[T, U]
// Deprecated. Use AdaptAction
func NewTypeAdapterAction[T any, U any](
action Action[U],
getter InternalValueGetter[T, U],
setter InternalValueSetter[T, U],
) Action[T] {
return AdaptAction[T, U](
action,
(InternalTypeGetter[T, U])(getter),
(ExternalTypeSetter[T, U])(setter),
)
}
// Deprecated. Use Failure
const Error = Failure
// Deprecated. Use RunPlan
type ActionPlan[T any] RunPlan[T]