-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLibsAddonTools.definition.lua
More file actions
36 lines (32 loc) · 1.79 KB
/
LibsAddonTools.definition.lua
File metadata and controls
36 lines (32 loc) · 1.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
---@meta
-- Type definitions for Libs-AddonTools ProfileManager
-- This file is not packaged - used for IDE support only
---@class LibsAddonTools
---@field ProfileManager LibsAddonTools.ProfileManager
LibsAddonTools = {}
---@class LibsAddonTools.ProfileManager
---@field RegisterAddon fun(self: LibsAddonTools.ProfileManager, addonName: string, aceDB: AceDB): LibsAddonTools.RegisteredAddon
---@field IsProfileManagerAvailable fun(self: LibsAddonTools.ProfileManager): boolean
---@field ShowWindow fun(self: LibsAddonTools.ProfileManager)
---@field HideWindow fun(self: LibsAddonTools.ProfileManager)
---@field ExportProfile fun(self: LibsAddonTools.ProfileManager, format?: string): string|nil
---@field ImportProfile fun(self: LibsAddonTools.ProfileManager, data: string): boolean
LibsAddonTools.ProfileManager = {}
---@class LibsAddonTools.RegisteredAddon
---@field addonName string
---@field aceDB AceDB
---@field ExportProfile fun(self: LibsAddonTools.RegisteredAddon, format?: string): string|nil
---@field ImportProfile fun(self: LibsAddonTools.RegisteredAddon, data: string): boolean
---@field GetProfiles fun(self: LibsAddonTools.RegisteredAddon): string[]
---@field CreateProfile fun(self: LibsAddonTools.RegisteredAddon, name: string): boolean
---@field DeleteProfile fun(self: LibsAddonTools.RegisteredAddon, name: string): boolean
---@field SwitchProfile fun(self: LibsAddonTools.RegisteredAddon, name: string): boolean
---@class AceDB
---@field profiles table<string, any>
---@field profile any
---@field global any
---@field SetProfile fun(self: AceDB, name: string)
---@field GetProfiles fun(self: AceDB): string[]
---@field NewProfile fun(self: AceDB, name: string, copyFrom?: string): boolean
---@field DeleteProfile fun(self: AceDB, name: string): boolean
---@field GetCurrentProfile fun(self: AceDB): string