mirror of
https://github.com/logos-storage/swarmsim.git
synced 2026-01-07 16:23:09 +00:00
change lifecycle event handler name
This commit is contained in:
parent
df3bd77384
commit
ed0b88c990
@ -41,7 +41,7 @@ method atScheduledTime*(self: PeerLifecycleChange,
|
|||||||
# ... but self-transitions do not get reported downstream.
|
# ... but self-transitions do not get reported downstream.
|
||||||
if oldState != newState:
|
if oldState != newState:
|
||||||
self.peer.protocols.values.toSeq.apply(p =>
|
self.peer.protocols.values.toSeq.apply(p =>
|
||||||
p.onLifecycleEventType(self.peer, self.event, self.network))
|
p.onPeerLifecycleChange(self.peer, self.event, self.network))
|
||||||
|
|
||||||
proc getProtocol*(self: Peer, id: string): Option[Protocol] =
|
proc getProtocol*(self: Peer, id: string): Option[Protocol] =
|
||||||
if self.protocols.hasKey(id):
|
if self.protocols.hasKey(id):
|
||||||
|
|||||||
@ -15,7 +15,7 @@ method deliver*(
|
|||||||
): void {.base.} =
|
): void {.base.} =
|
||||||
raise newException(CatchableError, "Method without implementation override")
|
raise newException(CatchableError, "Method without implementation override")
|
||||||
|
|
||||||
method onLifecycleEventType*(
|
method onPeerLifecycleChange*(
|
||||||
self: Protocol,
|
self: Protocol,
|
||||||
peer: Peer,
|
peer: Peer,
|
||||||
event: LifecycleEventType,
|
event: LifecycleEventType,
|
||||||
|
|||||||
@ -25,7 +25,7 @@ method deliver*(
|
|||||||
|
|
||||||
method `protocolId`*(self: Inbox): string = self.protocolId
|
method `protocolId`*(self: Inbox): string = self.protocolId
|
||||||
|
|
||||||
method onLifecycleEventType*(
|
method onPeerLifecycleChange*(
|
||||||
self: Inbox,
|
self: Inbox,
|
||||||
peer: Peer,
|
peer: Peer,
|
||||||
event: LifecycleEventType,
|
event: LifecycleEventType,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user