Fabcoin Core  0.16.2
P2P Digital Currency
Public Member Functions | Private Member Functions | Private Attributes | List of all members
dev::shh::Message Class Reference

An (unencrypted) message, constructed from the combination of an Envelope, and, potentially, a Secret key to decrypt the Message. More...

#include <Message.h>

Collaboration diagram for dev::shh::Message:
[legend]

Public Member Functions

 Message ()
 
 Message (Envelope const &_e, Topics const &_t, Secret const &_s=Secret())
 
 Message (bytes const &_payload)
 
 Message (bytesConstRef _payload)
 
 Message (bytes &&_payload)
 
Public from () const
 
Public to () const
 
bytes const & payload () const
 
void setFrom (Public _from)
 
void setTo (Public _to)
 
void setPayload (bytes const &_payload)
 
void setPayload (bytes &&_payload)
 
 operator bool () const
 
Envelope seal (Secret const &_from, Topics const &_topics, unsigned _ttl=50, unsigned _workToProve=50) const
 Turn this message into a ditributable Envelope. More...
 
Envelope seal (Topics const &_topics, unsigned _ttl=50, unsigned _workToProve=50) const
 
Envelope sealTo (Public _to, Topics const &_topics, unsigned _ttl=50, unsigned _workToProve=50)
 
Envelope sealTo (Secret const &_from, Public _to, Topics const &_topics, unsigned _ttl=50, unsigned _workToProve=50)
 

Private Member Functions

bool populate (bytes const &_data)
 
bool openBroadcastEnvelope (Envelope const &_e, Topics const &_t, bytes &o_b)
 
Secret generateGamma (Secret const &_key, h256 const &_salt) const
 

Private Attributes

Public m_from
 
Public m_to
 
bytes m_payload
 

Detailed Description

An (unencrypted) message, constructed from the combination of an Envelope, and, potentially, a Secret key to decrypt the Message.

Definition at line 100 of file Message.h.

Constructor & Destructor Documentation

dev::shh::Message::Message ( )
inline

Definition at line 103 of file Message.h.

Message::Message ( Envelope const &  _e,
Topics const &  _t,
Secret const &  _s = Secret() 
)

Definition at line 30 of file Message.cpp.

Here is the call graph for this function:

dev::shh::Message::Message ( bytes const &  _payload)
inline

Definition at line 105 of file Message.h.

dev::shh::Message::Message ( bytesConstRef  _payload)
inline

Definition at line 106 of file Message.h.

dev::shh::Message::Message ( bytes &&  _payload)
inline

Definition at line 107 of file Message.h.

Here is the call graph for this function:

Member Function Documentation

Public dev::shh::Message::from ( ) const
inline

Definition at line 109 of file Message.h.

Here is the caller graph for this function:

Secret dev::shh::Message::generateGamma ( Secret const &  _key,
h256 const &  _salt 
) const
inlineprivate

Definition at line 130 of file Message.h.

Here is the call graph for this function:

bool Message::openBroadcastEnvelope ( Envelope const &  _e,
Topics const &  _t,
bytes o_b 
)
private

Definition at line 51 of file Message.cpp.

Here is the call graph for this function:

dev::shh::Message::operator bool ( ) const
inline

Definition at line 118 of file Message.h.

bytes const& dev::shh::Message::payload ( ) const
inline

Definition at line 111 of file Message.h.

Here is the caller graph for this function:

bool Message::populate ( bytes const &  _data)
private

Definition at line 79 of file Message.cpp.

Here is the call graph for this function:

Envelope Message::seal ( Secret const &  _from,
Topics const &  _topics,
unsigned  _ttl = 50,
unsigned  _workToProve = 50 
) const

Turn this message into a ditributable Envelope.

Definition at line 100 of file Message.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Envelope dev::shh::Message::seal ( Topics const &  _topics,
unsigned  _ttl = 50,
unsigned  _workToProve = 50 
) const
inline

Definition at line 123 of file Message.h.

Here is the call graph for this function:

Here is the caller graph for this function:

Envelope dev::shh::Message::sealTo ( Public  _to,
Topics const &  _topics,
unsigned  _ttl = 50,
unsigned  _workToProve = 50 
)
inline

Definition at line 124 of file Message.h.

Envelope dev::shh::Message::sealTo ( Secret const &  _from,
Public  _to,
Topics const &  _topics,
unsigned  _ttl = 50,
unsigned  _workToProve = 50 
)
inline

Definition at line 125 of file Message.h.

void dev::shh::Message::setFrom ( Public  _from)
inline

Definition at line 113 of file Message.h.

Here is the caller graph for this function:

void dev::shh::Message::setPayload ( bytes const &  _payload)
inline

Definition at line 115 of file Message.h.

Here is the caller graph for this function:

void dev::shh::Message::setPayload ( bytes &&  _payload)
inline

Definition at line 116 of file Message.h.

Here is the call graph for this function:

void dev::shh::Message::setTo ( Public  _to)
inline

Definition at line 114 of file Message.h.

Here is the caller graph for this function:

Public dev::shh::Message::to ( ) const
inline

Definition at line 110 of file Message.h.

Here is the caller graph for this function:

Member Data Documentation

Public dev::shh::Message::m_from
private

Definition at line 132 of file Message.h.

bytes dev::shh::Message::m_payload
private

Definition at line 134 of file Message.h.

Public dev::shh::Message::m_to
private

Definition at line 133 of file Message.h.


The documentation for this class was generated from the following files: