mirror of
https://github.com/jwetzell/showbridge-go.git
synced 2026-04-26 21:05:30 +00:00
reorder functions
This commit is contained in:
16
route.go
16
route.go
@@ -26,14 +26,6 @@ type ProcessorRoute struct {
|
||||
output string
|
||||
}
|
||||
|
||||
func (r *ProcessorRoute) Input() string {
|
||||
return r.input
|
||||
}
|
||||
|
||||
func (r *ProcessorRoute) Output() string {
|
||||
return r.output
|
||||
}
|
||||
|
||||
func NewRoute(config config.RouteConfig) (Route, error) {
|
||||
processors := []processing.Processor{}
|
||||
|
||||
@@ -55,6 +47,14 @@ func NewRoute(config config.RouteConfig) (Route, error) {
|
||||
return &ProcessorRoute{input: config.Input, processors: processors, output: config.Output}, nil
|
||||
}
|
||||
|
||||
func (r *ProcessorRoute) Input() string {
|
||||
return r.input
|
||||
}
|
||||
|
||||
func (r *ProcessorRoute) Output() string {
|
||||
return r.output
|
||||
}
|
||||
|
||||
func (r *ProcessorRoute) HandleInput(sourceId string, payload any, router *Router) error {
|
||||
var err error
|
||||
for _, processor := range r.processors {
|
||||
|
||||
Reference in New Issue
Block a user