ConfigManager implements
This commit is contained in:
parent
297afd4dc1
commit
7c70d2ca1f
|
@ -188,9 +188,9 @@ func (c *configManager) removeConfig() {
|
|||
func (c *configManager) GetGlobalConfig() *config_manager.GlobalConfig {
|
||||
return &c.globalConfig
|
||||
}
|
||||
func (c *configManager) GetCrawlerById(id string) *config_manager.Config {
|
||||
func (c *configManager) GetSensorById(id string) *config_manager.Config {
|
||||
return c.configs[id]
|
||||
}
|
||||
func (c *configManager) GetCrawlers() map[string] *config_manager.Config {
|
||||
func (c *configManager) GetSensors() map[string] *config_manager.Config {
|
||||
return c.configs
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@ func TestLoadConfig(t *testing.T) {
|
|||
go func() {
|
||||
data :=<- ch
|
||||
c := data.(config_manager.ConfigManager)
|
||||
cc := c.GetCrawlers()
|
||||
cc := c.GetSensors()
|
||||
|
||||
//ccc := cc["75045c53-a78d-4589-b8c1-4482cab720b6"]
|
||||
//
|
||||
|
|
Loading…
Reference in New Issue
Block a user