Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var MinManager []Access = []Access{Owner, Manager}
Functions ¶
func AccessContain ¶
func NewPluginList ¶
func NewPluginList() iPluginList
Types ¶
type Command ¶
type Command struct { Cmd []string `json:"cmd"` Description string `json:"description"` Usage string `json:"usage"` Passed bool `json:"passed"` Disabled bool `json:"disabled"` Expires float64 `json:"expires"` Insensitive bool `json:"Insensitive"` Execute CommandExecute `json:"execute"` }
func (Command) MarshalJSON ¶
func (*Command) SetDisabled ¶
func (c *Command) SetDisabled()
type CommandExecute ¶
type IAuth ¶
type IAuth interface { UserRemove(id string) (bool, error) UserAdd(user User, perm Permission) (bool, error) UserExists(id string) (User, error) UserList() ([]User, error) PermissionRemove(id string, access Access) (bool, error) PermissionAdd(perm Permission) (bool, error) ValidManyPermission(id string, access []Access) ([]Permission, bool) ValidPermission(id string, access Access) (Permission, bool) HitCommand(id, appname, command string) (Hit, error) }
func NewAuthenticator ¶
type Permission ¶
type Plugin ¶
type Plugin struct { Name string `json:"name"` Description string `json:"description"` Commands []*Command `json:"commands"` Tags []string `json:"tags"` Permissions []string `json:"permissions"` Disabled bool `json:"disabled"` Validate Validator `json:"validate"` }
func (*Plugin) CommandAdd ¶
func (*Plugin) CommandAddMany ¶
func (*Plugin) CommandCopy ¶
func (*Plugin) SetDisabled ¶
func (p *Plugin) SetDisabled()
Click to show internal directories.
Click to hide internal directories.