Documentation
¶
Index ¶
- Constants
- func PeerFromFindString(find string) (p *keys.Peer, err error)
- func StartWebProgram(hash [32]byte, args vm.WebArgs) (output vm.WebRets, err error)
- func StoreProgram(data []byte) (hash [32]byte, err error)
- type AnyMsg
- type EncryptedMsg
- type LocalNet
- type LocalPeer
- type MessageType
- type Node
- type SentMsg
Constants ¶
View Source
const FindStart = "cofind:"
Variables ¶
This section is empty.
Functions ¶
func StartWebProgram ¶
func StoreProgram ¶
Types ¶
type AnyMsg ¶
type AnyMsg struct {
From *keys.Peer
Type MessageType
Body []byte
}
func (AnyMsg) Deserialise ¶
type EncryptedMsg ¶
type EncryptedMsg []byte
type LocalPeer ¶
type LocalPeer struct {
keys.Peer
Receive chan<- EncryptedMsg
}
type MessageType ¶
type MessageType uint8
type Node ¶
type Node struct {
keys.ThisPeer
Peers map[keys.PK]*keys.Peer // known peers
SendRaw func(peer *keys.Peer, msg []byte) (err error)
ReceiveRaw chan EncryptedMsg
// contains filtered or unexported fields
}
func (Node) FindString ¶
A find string encodes the pk and addresses
func (*Node) RunWebProgram ¶
func (*Node) StoreProgram ¶
Click to show internal directories.
Click to hide internal directories.