Fireable -> EventSwitch; rs in EventDataRoundState; fixes from review

This commit is contained in:
Ethan Buchman
2015-12-14 00:38:19 -05:00
parent 261647a012
commit b9e143d956
10 changed files with 127 additions and 166 deletions

View File

@ -101,7 +101,7 @@ func NewNode() *Node {
// add the event switch to all services
// they should all satisfy events.Eventable
SetFireable(eventSwitch, bcReactor, mempoolReactor, consensusReactor)
SetEventSwitch(eventSwitch, bcReactor, mempoolReactor, consensusReactor)
// run the profile server
profileHost := config.GetString("prof_laddr")
@ -144,9 +144,9 @@ func (n *Node) Stop() {
}
// Add the event switch to reactors, mempool, etc.
func SetFireable(evsw *events.EventSwitch, eventables ...events.Eventable) {
func SetEventSwitch(evsw *events.EventSwitch, eventables ...events.Eventable) {
for _, e := range eventables {
e.SetFireable(evsw)
e.SetEventSwitch(evsw)
}
}