Documentation
¶
Index ¶
- Constants
- type GroupFunctionality
- func (gf *GroupFunctionality) GetServerInfo(serverOnion string, profile peer.ReadContacts) Server
- func (gf *GroupFunctionality) GetServerInfoList(profile ReadServerInfo) []Server
- func (gf *GroupFunctionality) HandleImportString(peer peer.CwtchPeer, importString string) error
- func (gf *GroupFunctionality) SendMessage(peer peer.CwtchPeer, handle string, message string) (string, error)
- func (gf *GroupFunctionality) ValidPrefix(importString string) bool
- type ReadServerInfo
- type Server
- type ServerKey
Constants ¶
const ( // ServerList is a json encoded list of servers ServerList = event.Field("ServerList") )
const ( // UpdateServerInfo is an event containing a ProfileOnion and a ServerList UpdateServerInfo = event.Type("UpdateServerInfo") )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GroupFunctionality ¶
type GroupFunctionality struct { }
GroupFunctionality provides experiment gated server functionality
func ExperimentGate ¶
func ExperimentGate(experimentMap map[string]bool) (*GroupFunctionality, error)
ExperimentGate returns GroupFunctionality if the experiment is enabled, and an error otherwise.
func (*GroupFunctionality) GetServerInfo ¶
func (gf *GroupFunctionality) GetServerInfo(serverOnion string, profile peer.ReadContacts) Server
GetServerInfo compiles all the information the UI might need regarding a particular server including any verified cryptographic keys
func (*GroupFunctionality) GetServerInfoList ¶
func (gf *GroupFunctionality) GetServerInfoList(profile ReadServerInfo) []Server
GetServerInfoList compiles all the information the UI might need regarding all servers..
func (*GroupFunctionality) HandleImportString ¶
func (gf *GroupFunctionality) HandleImportString(peer peer.CwtchPeer, importString string) error
HandleImportString handles import strings for groups and servers
func (*GroupFunctionality) SendMessage ¶
func (gf *GroupFunctionality) SendMessage(peer peer.CwtchPeer, handle string, message string) (string, error)
SendMessage is a deprecated api
func (*GroupFunctionality) ValidPrefix ¶
func (gf *GroupFunctionality) ValidPrefix(importString string) bool
ValidPrefix returns true if an import string contains a prefix that indicates it contains information about a server or a group
type ReadServerInfo ¶
type ReadServerInfo interface { peer.ReadContacts peer.ReadServers }
ReadServerInfo is a meta-interface for reading information about servers..