fume-fhir-converter
Version:
FHIR-Utilized Mapping Engine - Community
27 lines • 1.01 kB
JavaScript
;
/**
* © Copyright Outburn Ltd. 2022-2024 All Rights Reserved
* Project name: FUME-COMMUNITY
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.selectKeys = exports.omitKeys = exports.isEmpty = void 0;
const tslib_1 = require("tslib");
const jsonataExpression_1 = tslib_1.__importDefault(require("./jsonataExpression"));
const selectKeys = async (obj, skeys) => {
const res = await jsonataExpression_1.default.selectKeys.evaluate({}, { in: obj, skeys });
return res;
};
exports.selectKeys = selectKeys;
const omitKeys = async (obj, okeys) => {
const res = await jsonataExpression_1.default.omitKeys.evaluate({}, { in: obj, okeys });
return res;
};
exports.omitKeys = omitKeys;
const isEmpty = async (value) => {
if (value === undefined || value === null)
return true;
const res = await jsonataExpression_1.default.isEmpty.evaluate({}, { value });
return res;
};
exports.isEmpty = isEmpty;
//# sourceMappingURL=objectFunctions.js.map