forked from ethereum/go-ethereum
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request ethereum#718 from karalabe/whisper-cleanup
Whisper cleanup, part 2
- Loading branch information
Showing
16 changed files
with
899 additions
and
356 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,13 @@ | ||
// Contains the message filter for fine grained subscriptions. | ||
|
||
package whisper | ||
|
||
import "crypto/ecdsa" | ||
|
||
// Filter is used to subscribe to specific types of whisper messages. | ||
type Filter struct { | ||
To *ecdsa.PublicKey | ||
From *ecdsa.PublicKey | ||
Topics [][]byte | ||
Fn func(*Message) | ||
To *ecdsa.PublicKey // Recipient of the message | ||
From *ecdsa.PublicKey // Sender of the message | ||
Topics []Topic // Topics to watch messages on | ||
Fn func(*Message) // Handler in case of a match | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.