UNPKG

@wildboar/pki-stub

Version:
54 lines (53 loc) 1.34 kB
import * as $ from "@wildboar/asn1/functional"; /** * @summary Version_v1 * @constant * @type {number} */ export const Version_v1 = 0; /* LONG_NAMED_INTEGER_VALUE */ /** * @summary Version_v1 * @constant * @type {number} */ export const v1 = Version_v1; /* SHORT_NAMED_INTEGER_VALUE */ /** * @summary Version_v2 * @constant * @type {number} */ export const Version_v2 = 1; /* LONG_NAMED_INTEGER_VALUE */ /** * @summary Version_v2 * @constant * @type {number} */ export const v2 = Version_v2; /* SHORT_NAMED_INTEGER_VALUE */ /** * @summary Version_v3 * @constant * @type {number} */ export const Version_v3 = 2; /* LONG_NAMED_INTEGER_VALUE */ /** * @summary Version_v3 * @constant * @type {number} */ export const v3 = Version_v3; /* SHORT_NAMED_INTEGER_VALUE */ /** * @summary Decodes an ASN.1 element into a(n) Version * @function * @param {_Element} el The element being decoded. * @returns {Version} The decoded data structure. */ export const _decode_Version = $._decodeInteger; /** * @summary Encodes a(n) Version into an ASN.1 Element. * @function * @param value The element being encoded. * @param elGetter A function that can be used to get new ASN.1 elements. * @returns {_Element} The Version, encoded as an ASN.1 Element. */ export const _encode_Version = $._encodeInteger; /* eslint-enable */