manager

package
v0.9.2 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2021 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package manager provides a simple group plugin manager.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ForEach

func ForEach(iterator func(key string, manager Manager) bool)

ForEach iterates through managers.

Types

type Manager

type Manager interface {
	zero.Hooker
	Enable(groupID int64)
	Disable(groupID int64)
}

Manager is the interface of plugin group manager.

func Lookup

func Lookup(service string) Manager

Lookup returns a Manager by the service name, if not exist, it will returns nil.

func New

func New(service string, o *Options) Manager

New returns Manager with settings.

type Options

type Options struct {
	DisableOnDefault bool
}

Options holds the optional parameters for the Manager.

Jump to

Keyboard shortcuts

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