fedi

package
v0.7.3 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2022 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrCantCast = errors.New("unable to cast interface to type")

Functions

This section is empty.

Types

type Module

type Module struct {
	// contains filtered or unexported fields
}

func New

func New(d db.DB, t *fedihelper.Transport, k kv.KV, tok *token.Tokenizer) (*Module, error)

func (*Module) CreateAccountHandler

func (m *Module) CreateAccountHandler(ctx context.Context, accountI fedihelper.Account) (err error)

func (*Module) FetchActor

func (m *Module) FetchActor(ctx context.Context, actorIRI *url.URL) (*fedihelper.Actor, error)

func (*Module) FetchHostMeta

func (m *Module) FetchHostMeta(ctx context.Context, domain string) (*fedihelper.HostMeta, error)

func (*Module) FetchWebFinger

func (m *Module) FetchWebFinger(ctx context.Context, wfURI fedihelper.WebfingerURI, username, domain string) (*fedihelper.WebFinger, error)

func (*Module) GenInstanceFromDomain

func (m *Module) GenInstanceFromDomain(ctx context.Context, domain string) (*models.Instance, error)

func (*Module) GetAccountHandler

func (m *Module) GetAccountHandler(ctx context.Context, instanceI fedihelper.Instance, username string) (fedihelper.Account, bool, error)

func (*Module) GetLoginURL

func (m *Module) GetLoginURL(ctx context.Context, redirectURI *url.URL, instance *models.Instance) (*url.URL, bool, error)

func (*Module) Helper

func (*Module) NewAccountFromUsername

func (m *Module) NewAccountFromUsername(ctx context.Context, username string, instance *models.Instance) (*models.Account, error)

func (*Module) NewAccountHandler

func (*Module) NewAccountHandler(_ context.Context) (account fedihelper.Account, err error)

func (*Module) NewInstanceFromDomain

func (m *Module) NewInstanceFromDomain(ctx context.Context, domain string) (*models.Instance, error)

func (*Module) UpdateAccountInfo added in v0.7.0

func (m *Module) UpdateAccountInfo(ctx context.Context, account *models.Account) error

func (*Module) UpdateInstanceInfo added in v0.7.0

func (m *Module) UpdateInstanceInfo(ctx context.Context, instance *models.Instance) error

Jump to

Keyboard shortcuts

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