bertyaccount

package
v2.466.2 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2023 License: Apache-2.0, MIT Imports: 45 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddArgsUsingNetworkConfig added in v2.308.0

func AddArgsUsingNetworkConfig(m *accounttypes.NetworkConfig, args []string) []string

func AddDHTArgsUsingNetworkConfig added in v2.308.0

func AddDHTArgsUsingNetworkConfig(m *accounttypes.NetworkConfig, args []string, defaultConfig *accounttypes.NetworkConfig) []string

func AddRDVPArgsUsingNetworkConfig added in v2.308.0

func AddRDVPArgsUsingNetworkConfig(m *accounttypes.NetworkConfig, args []string, defaultConfig *accounttypes.NetworkConfig) []string

func ArgSet added in v2.302.0

func ArgSet(flagName string, value string) string

func ArgsHasWithPrefix added in v2.302.0

func ArgsHasWithPrefix(args []string, prefix string) bool

func NetworkConfigGetBlank added in v2.302.0

func NetworkConfigGetBlank() *accounttypes.NetworkConfig

func NetworkConfigGetDefault added in v2.302.0

func NetworkConfigGetDefault() *accounttypes.NetworkConfig

func SanitizeCheckMultiAddr added in v2.302.8

func SanitizeCheckMultiAddr(addrs []string) error

Types

type Options

type Options struct {
	SharedRootDirectory string
	AppRootDirectory    string

	MDNSLocker            sync.Locker
	NetManager            *netmanager.NetManager
	Languages             []language.Tag
	ServiceClientRegister bertybridge.ServiceClientRegister
	LifecycleManager      *lifecycle.Manager
	NotificationManager   notification.Manager
	BleDriver             proximity.ProximityDriver
	NBDriver              proximity.ProximityDriver
	Keystore              accountutils.NativeKeystore
	Logger                *zap.Logger
	ServiceListeners      string
}

type Service

type Service interface {
	accounttypes.AccountServiceServer

	// SetLanguage set the use language for translate
	SetPreferredLanguages(tags ...language.Tag)

	// WakeUp should be used for background task or similar task.
	WakeUp(ctx context.Context) error

	// Close the service.
	Close() error

	// GetMessengerClient returns the Messenger Client of the actual Berty account if there is one selected.
	GetMessengerClient() (messengertypes.MessengerServiceClient, error)

	// GetProtocolClient returns the Protocol Client of the actual Berty account if there is one selected.
	GetProtocolClient() (protocoltypes.ProtocolServiceClient, error)
}

func NewService

func NewService(opts *Options) (_ Service, err error)

Jump to

Keyboard shortcuts

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