mirror of
https://github.com/mariocandela/beelzebub.git
synced 2025-07-01 18:47:26 -04:00
20 lines
477 B
Go
20 lines
477 B
Go
package protocols
|
|
|
|
import "beelzebub/parser"
|
|
|
|
type ProtocolManager struct {
|
|
strategy ServiceStrategy
|
|
}
|
|
|
|
func (pm *ProtocolManager) InitServiceManager() *ProtocolManager {
|
|
return &ProtocolManager{}
|
|
}
|
|
|
|
func (pm *ProtocolManager) SetProtocolStrategy(strategy ServiceStrategy) {
|
|
pm.strategy = strategy
|
|
}
|
|
|
|
func (pm *ProtocolManager) InitService(beelzebubServiceConfiguration parser.BeelzebubServiceConfiguration) error {
|
|
return pm.strategy.Init(beelzebubServiceConfiguration)
|
|
}
|