UNPKG

@wildboar/pki-stub

Version:
65 lines (64 loc) 1.5 kB
import { INTEGER, ASN1Element as _Element } from "asn1-ts"; import * as $ from "asn1-ts/dist/node/functional"; /** * @summary Version * @description * * ### ASN.1 Definition: * * ```asn1 * Version ::= INTEGER {v1(0), v2(1), v3(2)} * ``` */ export declare type Version = INTEGER; /** * @summary Version_v1 * @constant * @type {number} */ export declare const Version_v1: Version; /** * @summary Version_v1 * @constant * @type {number} */ export declare const v1: Version; /** * @summary Version_v2 * @constant * @type {number} */ export declare const Version_v2: Version; /** * @summary Version_v2 * @constant * @type {number} */ export declare const v2: Version; /** * @summary Version_v3 * @constant * @type {number} */ export declare const Version_v3: Version; /** * @summary Version_v3 * @constant * @type {number} */ export declare const v3: Version; /** * @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 declare function _decode_Version(el: _Element): INTEGER; /** * @summary Encodes a(n) Version 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 Version, encoded as an ASN.1 Element. */ export declare function _encode_Version(value: Version, elGetter: $.ASN1Encoder<Version>): _Element;