plugins

package
v0.0.0-...-f1af43c Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2024 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Env

type Env struct {
	Method  string
	Session providers.SessionInfo
	Extra   map[string]any
}

type Plugin

type Plugin struct {
	Meta     PluginManifest
	Programs []Program
}

type PluginExpr

type PluginExpr struct {
	File      string `toml:"file"`
	AppliesTo string `toml:"applies_to"`
}

type PluginManifest

type PluginManifest struct {
	Name        string       `toml:"name"`
	Version     string       `toml:"version"`
	Author      string       `toml:"author"`
	Description string       `toml:"description"`
	ExprSources []PluginExpr `toml:"sources"`
}

type Program

type Program struct {
	Source    string
	AppliesTo string
	Prog      *vm.Program
}

type Provider

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

func NewProvider

func NewProvider(p ProviderParams) (*Provider, error)

func (*Provider) Check

func (p *Provider) Check(method string, env Env) (bool, error)

type ProviderParams

type ProviderParams struct {
	Config providers.ConfigurationProvider
	Logger *zap.Logger
}

Jump to

Keyboard shortcuts

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