extensions

package
v0.29.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProfileValueExtension

type ProfileValueExtension struct {
}

ProfileValueExtension implements custom Profile Names over Cwtch

func (ProfileValueExtension) EventsToRegister

func (pne ProfileValueExtension) EventsToRegister() []event.Type

func (ProfileValueExtension) ExperimentsToRegister

func (pne ProfileValueExtension) ExperimentsToRegister() []string

func (ProfileValueExtension) NotifySettingsUpdate added in v0.19.2

func (pne ProfileValueExtension) NotifySettingsUpdate(_ settings.GlobalSettings)

func (ProfileValueExtension) OnContactReceiveValue

func (pne ProfileValueExtension) OnContactReceiveValue(profile peer.CwtchPeer, conversation model.Conversation, szp attr.ScopedZonedPath, value string, exists bool)

OnContactReceiveValue for ProfileValueExtension handles saving specific Public Profile Values like Profile Name

func (ProfileValueExtension) OnContactRequestValue

func (pne ProfileValueExtension) OnContactRequestValue(profile peer.CwtchPeer, conversation model.Conversation, eventID string, szp attr.ScopedZonedPath)

OnContactRequestValue for ProfileValueExtension handles returning Public Profile Values

func (ProfileValueExtension) OnEvent

func (pne ProfileValueExtension) OnEvent(ev event.Event, profile peer.CwtchPeer)

type SendWhenOnlineExtension added in v0.28.0

type SendWhenOnlineExtension struct {
}

SendWhenOnlineExtension implements automatic sending Some Considerations:

  • There are race conditions inherant in this approach e.g. a peer could go offline just after recieving a message and never sending an ack
  • In that case the next time we connect we will send a duplicate message.
  • Currently we do not include metadata like sent time in raw peer protocols (however Overlay does now have support for that information)

func (SendWhenOnlineExtension) EventsToRegister added in v0.28.0

func (soe SendWhenOnlineExtension) EventsToRegister() []event.Type

func (SendWhenOnlineExtension) ExperimentsToRegister added in v0.28.0

func (soe SendWhenOnlineExtension) ExperimentsToRegister() []string

func (SendWhenOnlineExtension) NotifySettingsUpdate added in v0.28.0

func (soe SendWhenOnlineExtension) NotifySettingsUpdate(_ settings.GlobalSettings)

func (SendWhenOnlineExtension) OnContactReceiveValue added in v0.28.0

func (soe SendWhenOnlineExtension) OnContactReceiveValue(profile peer.CwtchPeer, conversation model.Conversation, szp attr.ScopedZonedPath, value string, exists bool)

OnContactReceiveValue is nop for SendWhenOnnlineExtension

func (SendWhenOnlineExtension) OnContactRequestValue added in v0.28.0

func (soe SendWhenOnlineExtension) OnContactRequestValue(profile peer.CwtchPeer, conversation model.Conversation, eventID string, szp attr.ScopedZonedPath)

OnContactRequestValue is nop for SendWhenOnnlineExtension

func (SendWhenOnlineExtension) OnEvent added in v0.28.0

func (soe SendWhenOnlineExtension) OnEvent(ev event.Event, profile peer.CwtchPeer)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL