diff options
Diffstat (limited to 'shared/models/plugins')
-rw-r--r-- | shared/models/plugins/plugin-storage-manager.model.ts | 7 | ||||
-rw-r--r-- | shared/models/plugins/register-options.model.ts | 3 |
2 files changed, 10 insertions, 0 deletions
diff --git a/shared/models/plugins/plugin-storage-manager.model.ts b/shared/models/plugins/plugin-storage-manager.model.ts new file mode 100644 index 000000000..8a1f389f1 --- /dev/null +++ b/shared/models/plugins/plugin-storage-manager.model.ts | |||
@@ -0,0 +1,7 @@ | |||
1 | import * as Bluebird from 'bluebird' | ||
2 | |||
3 | export interface PluginStorageManager { | ||
4 | getData: (key: string) => Bluebird<string> | ||
5 | |||
6 | storeData: (key: string, data: any) => Bluebird<any> | ||
7 | } | ||
diff --git a/shared/models/plugins/register-options.model.ts b/shared/models/plugins/register-options.model.ts index e60ce3fe0..e3a7cff08 100644 --- a/shared/models/plugins/register-options.model.ts +++ b/shared/models/plugins/register-options.model.ts | |||
@@ -1,6 +1,7 @@ | |||
1 | import { RegisterHookOptions } from './register-hook.model' | 1 | import { RegisterHookOptions } from './register-hook.model' |
2 | import { RegisterSettingOptions } from './register-setting.model' | 2 | import { RegisterSettingOptions } from './register-setting.model' |
3 | import { PluginSettingsManager } from './plugin-settings-manager.model' | 3 | import { PluginSettingsManager } from './plugin-settings-manager.model' |
4 | import { PluginStorageManager } from './plugin-storage-manager.model' | ||
4 | 5 | ||
5 | export type RegisterOptions = { | 6 | export type RegisterOptions = { |
6 | registerHook: (options: RegisterHookOptions) => void | 7 | registerHook: (options: RegisterHookOptions) => void |
@@ -8,4 +9,6 @@ export type RegisterOptions = { | |||
8 | registerSetting: (options: RegisterSettingOptions) => void | 9 | registerSetting: (options: RegisterSettingOptions) => void |
9 | 10 | ||
10 | settingsManager: PluginSettingsManager | 11 | settingsManager: PluginSettingsManager |
12 | |||
13 | storageManager: PluginStorageManager | ||
11 | } | 14 | } |