logmania/receive/main.go

20 lines
334 B
Go
Raw Permalink Normal View History

2017-08-09 08:45:45 +02:00
package receive
import (
"dev.sum7.eu/genofire/logmania/lib"
2017-10-25 00:36:16 +02:00
log "github.com/sirupsen/logrus"
2017-08-09 08:45:45 +02:00
)
var Register = make(map[string]ReceiverInit)
type Receiver interface {
Listen()
Close()
}
type ReceiverInit func(*lib.ReceiveConfig, chan *log.Entry) Receiver
func AddReceiver(name string, n ReceiverInit) {
Register[name] = n
}