UNPKG

@ic-wallet-kit/hpl

Version:
24 lines (23 loc) 841 B
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.HplDbContext = void 0; const schema_json_1 = __importDefault(require("./schema.json")); const common_1 = require("@ic-wallet-kit/common"); class HplDbContext extends common_1.BaseRxDbContext { identifierService; constructor(identifierService, rxStorage) { super(rxStorage); this.identifierService = identifierService; } getDbName() { const principal = this.identifierService.getPrincipalStr(); return `rx_db_hpl_${principal}`; // TODO: extends for readonly mode } getSchema() { return schema_json_1.default; } } exports.HplDbContext = HplDbContext;