UNPKG

@simplito/privmx-webendpoint

Version:

PrivMX Web Endpoint library

76 lines (73 loc) 3.19 kB
"use strict"; /*! PrivMX Web Endpoint. Copyright © 2024 Simplito sp. z o.o. This file is part of the PrivMX Platform (https://privmx.dev). This software is Licensed under the PrivMX Free License. See the License for the specific language governing permissions and limitations under the License. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.KvdbApiNative = void 0; const BaseNative_1 = require("./BaseNative"); class KvdbApiNative extends BaseNative_1.BaseNative { async newApi(connectionPtr) { return this.runAsync((taskId) => this.api.lib.KvdbApi_newKvdbApi(taskId, connectionPtr)); } async deleteApi(ptr) { await this.runAsync((taskId) => this.api.lib.KvdbApi_deleteKvdbApi(taskId, ptr)); this.deleteApiRef(); } async create(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_create(taskId, ptr, args)); } async createKvdb(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_createKvdb(taskId, ptr, args)); } async updateKvdb(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_updateKvdb(taskId, ptr, args)); } async deleteKvdb(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_deleteKvdb(taskId, ptr, args)); } async getKvdb(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_getKvdb(taskId, ptr, args)); } async listKvdbs(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_listKvdbs(taskId, ptr, args)); } async hasEntry(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_hasEntry(taskId, ptr, args)); } async getEntry(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_getEntry(taskId, ptr, args)); } async listEntriesKeys(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_listEntriesKeys(taskId, ptr, args)); } async listEntries(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_listEntries(taskId, ptr, args)); } async setEntry(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_setEntry(taskId, ptr, args)); } async deleteEntry(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_deleteEntry(taskId, ptr, args)); } async deleteEntries(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_deleteEntries(taskId, ptr, args)); } async subscribeFor(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_subscribeFor(taskId, ptr, args)); } async unsubscribeFrom(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_unsubscribeFrom(taskId, ptr, args)); } async buildSubscriptionQuery(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_buildSubscriptionQuery(taskId, ptr, args)); } async buildSubscriptionQueryForSelectedEntry(ptr, args) { return this.runAsync((taskId) => this.api.lib.KvdbApi_buildSubscriptionQueryForSelectedEntry(taskId, ptr, args)); } } exports.KvdbApiNative = KvdbApiNative;