Documentation
¶
Index ¶
- Constants
- Variables
- type DBKey
- type MessagesRequestPayload
- type WMailServer
- func (s *WMailServer) Archive(env *whisper.Envelope)
- func (s *WMailServer) Close()
- func (s *WMailServer) DeliverMail(peer *whisper.Peer, request *whisper.Envelope)
- func (s *WMailServer) Init(shh *whisper.Whisper, config *params.WhisperConfig) error
- func (s *WMailServer) SyncMail(peer *whisper.Peer, request whisper.SyncMailRequest) error
Constants ¶
View Source
const ( // DBKeyLength is a size of the envelope key. DBKeyLength = common.HashLength + timestampLength + whisper.TopicLength CursorLength = common.HashLength + timestampLength )
Variables ¶
View Source
var ( // ErrInvalidByteSize is returned when DBKey can't be created // from a byte slice because it has invalid length. ErrInvalidByteSize = errors.New("byte slice has invalid length") )
Functions ¶
This section is empty.
Types ¶
type DBKey ¶
type DBKey struct {
// contains filtered or unexported fields
}
DBKey key to be stored in a db.
func (*DBKey) EnvelopeHash ¶ added in v0.35.0
type MessagesRequestPayload ¶ added in v0.35.0
type MessagesRequestPayload struct { // Lower is a lower bound of time range for which messages are requested. Lower uint32 // Upper is a lower bound of time range for which messages are requested. Upper uint32 // Bloom is a bloom filter to filter envelopes. Bloom []byte // Limit is the max number of envelopes to return. Limit uint32 // Cursor is used for pagination of the results. Cursor []byte // Batch set to true indicates that the client supports batched response. Batch bool }
MessagesRequestPayload is a payload sent to the Mail Server.
type WMailServer ¶
type WMailServer struct {
// contains filtered or unexported fields
}
WMailServer whisper mailserver.
func (*WMailServer) Archive ¶
func (s *WMailServer) Archive(env *whisper.Envelope)
Archive a whisper envelope.
func (*WMailServer) Close ¶
func (s *WMailServer) Close()
Close the mailserver and its associated db connection.
func (*WMailServer) DeliverMail ¶
func (s *WMailServer) DeliverMail(peer *whisper.Peer, request *whisper.Envelope)
DeliverMail sends mail to specified whisper peer.
func (*WMailServer) Init ¶
func (s *WMailServer) Init(shh *whisper.Whisper, config *params.WhisperConfig) error
Init initializes mailServer.
func (*WMailServer) SyncMail ¶ added in v0.35.0
func (s *WMailServer) SyncMail(peer *whisper.Peer, request whisper.SyncMailRequest) error
SyncMail syncs mail servers between two Mail Servers.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.