Skip to content
This repository has been archived by the owner on Sep 6, 2022. It is now read-only.

Commit

Permalink
add events for identify (#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
raulk authored Jun 26, 2019
1 parent b2f3be9 commit aca080d
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions event/identify.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
package event

import "github.com/libp2p/go-libp2p-core/peer"

// EvtPeerIdentificationCompleted is emitted when the initial identification round for a peer is completed.
type EvtPeerIdentificationCompleted struct {
// Peer is the ID of the peer whose identification succeeded.
Peer peer.ID
}

// EvtPeerIdentificationFailed is emitted when the initial identification round for a peer failed.
type EvtPeerIdentificationFailed struct {
// Peer is the ID of the peer whose identification failed.
Peer peer.ID
// Reason is the reason why identification failed.
Reason error
}

0 comments on commit aca080d

Please sign in to comment.