* Move SavedObjectClient files to core/public * Initial SavedObjectsService in public Core * Public SavedObjectsClient tests * Import SimpleSavedObject from src/core/public * Use types from source files for kibana.d.ts * Add html raw loader to x-pack/jest * Cleanup * Drop case utilities and improve test coverage * Update types and documentation * Fix build breaking when importing directly from /server in /public * Ensure that all option paramaters are picked and renamed * Fix option mapping and introduce stronger types * Eslint: allow imports from src/core/*/types * Add compatibility layer for kfetch vs http.fetch error responses * Improve documentation * Expose SavedObjectsMigrationLogger * Documentation and type tweaks * Revert type changes from73e601f
and update api docs * Refactor request into savedObjectFetch + test * Make legacy SavedObject compatible with http.fetch exceptions * Fix types and tests * simple_saved_object import from src/core/server * server imports from root instead of server/types * Make SavedObjectsService a class * Don't pick unkown keys from server response * Rename SavedObjectsFindResponse to SavedObjectsFindResponsePublic * Remove err.response from SavedObjects fetch errors * Revert "Remove err.response from SavedObjects fetch errors" This reverts commit61705ca361
. * Don't introduce err.response until we deprecate err.res
2.3 KiB
2.3 KiB
Home > kibana-plugin-public > SimpleSavedObject
SimpleSavedObject class
This class is a very simple wrapper for SavedObjects loaded from the server with the SavedObjectsClient.
It provides basic functionality for creating/saving/deleting saved objects, but doesn't include any type-specific implementations.
Signature:
export declare class SimpleSavedObject<T extends SavedObjectAttributes>
Constructors
Constructor | Modifiers | Description |
---|---|---|
(constructor)(client, { id, type, version, attributes, error, references, migrationVersion }) | Constructs a new instance of the SimpleSavedObject class |
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
_version | SavedObjectType<T>['version'] |
||
attributes | T |
||
error | SavedObjectType<T>['error'] |
||
id | SavedObjectType<T>['id'] |
||
migrationVersion | SavedObjectType<T>['migrationVersion'] |
||
references | SavedObjectType<T>['references'] |
||
type | SavedObjectType<T>['type'] |
Methods
Method | Modifiers | Description |
---|---|---|
delete() | ||
get(key) | ||
has(key) | ||
save() | ||
set(key, value) |