Documentation ¶
Index ¶
- Variables
- func BroadcastMessage(msg common.Message)
- func CreateConnection(ip string, silent bool)
- func GetMessageChannel() chan common.Message
- func GetOutputChannel() chan chan string
- func Listen(port int)
- func LoadPeers() error
- func SavePeers() error
- type EncyptedMessage
- type Node
- type Peer
- type SavedPeer
Constants ¶
This section is empty.
Variables ¶
View Source
var SelfNode = Node{}
The node of the program
Functions ¶
func BroadcastMessage ¶
Takes message, encrypts it, and sends it to all peers
func CreateConnection ¶
Adds a connection to the peers
Types ¶
type EncyptedMessage ¶
type EncyptedMessage struct {
EncyptedMessage string
}
The struct that is sent to peers
Click to show internal directories.
Click to hide internal directories.