UNPKG

@wildboar/pki-stub

Version:
45 lines 1.87 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports._encode_PkiPath = exports._decode_PkiPath = void 0; const $ = require("asn1-ts/dist/node/functional"); const Certificate_ta_1 = require("../PKI-Stub/Certificate.ta"); /* END_OF_SYMBOL_DEFINITION PkiPath */ /* START_OF_SYMBOL_DEFINITION _cached_decoder_for_PkiPath */ let _cached_decoder_for_PkiPath = null; /* END_OF_SYMBOL_DEFINITION _cached_decoder_for_PkiPath */ /* START_OF_SYMBOL_DEFINITION _decode_PkiPath */ /** * @summary Decodes an ASN.1 element into a(n) PkiPath * @function * @param {_Element} el The element being decoded. * @returns {PkiPath} The decoded data structure. */ function _decode_PkiPath(el) { if (!_cached_decoder_for_PkiPath) { _cached_decoder_for_PkiPath = $._decodeSequenceOf(() => Certificate_ta_1._decode_Certificate); } return _cached_decoder_for_PkiPath(el); } exports._decode_PkiPath = _decode_PkiPath; /* END_OF_SYMBOL_DEFINITION _decode_PkiPath */ /* START_OF_SYMBOL_DEFINITION _cached_encoder_for_PkiPath */ let _cached_encoder_for_PkiPath = null; /* END_OF_SYMBOL_DEFINITION _cached_encoder_for_PkiPath */ /* START_OF_SYMBOL_DEFINITION _encode_PkiPath */ /** * @summary Encodes a(n) PkiPath into an ASN.1 Element. * @function * @param {value} el The element being decoded. * @param elGetter A function that can be used to get new ASN.1 elements. * @returns {_Element} The PkiPath, encoded as an ASN.1 Element. */ function _encode_PkiPath(value, elGetter) { if (!_cached_encoder_for_PkiPath) { _cached_encoder_for_PkiPath = $._encodeSequenceOf(() => Certificate_ta_1._encode_Certificate, $.BER); } return _cached_encoder_for_PkiPath(value, elGetter); } exports._encode_PkiPath = _encode_PkiPath; /* END_OF_SYMBOL_DEFINITION _encode_PkiPath */ /* eslint-enable */ //# sourceMappingURL=PkiPath.ta.js.map