logic

package
v0.0.0-...-41cd4ca Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2022 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Activity

type Activity interface {
	DeliverActivity(ctx context.Context, jid string, instanceID int64, activity ap.Activity) Error
	ProcessActivity(ctx context.Context, jid string, instanceID int64, actorIRI *url.URL, activity ap.Activity) Error
}

type Error

type Error error
var (
	ErrCantCast       Error = errors.New("unable to cast interface to type")
	ErrNotFound       Error = errors.New("not found")
	ErrTokenWrongKind Error = errors.New("token is wrong kind")
)

func NewError

func NewError(m string) Error

NewError wraps a message in an Error object.

func NewErrorf

func NewErrorf(m string, args ...interface{}) Error

NewErrorf wraps a message in an Error object.

type GeminiIdentity

type GeminiIdentity interface {
	GetOrCreateGeminiIdentity(ctx context.Context, hash string) (*models.GeminiIdentity, Error)
}

type Instance

type Instance interface {
	GetInstanceSelf(ctx context.Context) (*models.Instance, Error)
}

type Logic

type Logic interface {
	Activity
	GeminiIdentity
	Instance
}

type LogicError

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

LogicError represents a logic specific error.

func (*LogicError) Error

func (e *LogicError) Error() string

Error returns the error message as a string.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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