@wildboar/rose
Version:
Remote Operation Service Element PDUs in TypeScript
129 lines • 3.98 kB
text/typescript
import { OPTIONAL, ASN1Element as _Element } from '@wildboar/asn1';
import * as $ from '@wildboar/asn1/functional';
import { Code } from '../Remote-Operations-Information-Objects/Code.ta.mjs';
import { InvokeId } from '../Remote-Operations-Generic-ROS-PDUs/InvokeId.ta.mjs';
/**
* @summary ReturnError
* @description
*
* ### ASN.1 Definition:
*
* ```asn1
* ReturnError{ERROR:Errors} ::= SEQUENCE {
* invokeId
* InvokeId
* (CONSTRAINED BY {-- must be that for an outstanding operation -- } !
* RejectProblem:returnError-unrecognizedInvocation)
* (CONSTRAINED BY {-- which returns an error -- } !
* RejectProblem:returnError-errorResponseUnexpected),
* errcode
* ERROR.&errorCode({Errors} !RejectProblem:returnError-unrecognizedError)
* (CONSTRAINED BY {-- must be in the &Errors field of the associated operation --
* } !RejectProblem:returnError-unexpectedError),
* parameter
* ERROR.&ParameterType
* ({Errors}{@errcode} !RejectProblem:returnError-mistypedParameter)
* OPTIONAL
* }
* (CONSTRAINED BY { -- must conform to the above definition --} !
* RejectProblem:general-mistypedPDU)
* ```
*
*/
export declare class ReturnError {
/**
* @summary `invokeId`.
* @public
* @readonly
*/
readonly invokeId: InvokeId;
/**
* @summary `errcode`.
* @public
* @readonly
*/
readonly errcode: Code;
/**
* @summary `parameter`.
* @public
* @readonly
*/
readonly parameter: OPTIONAL<_Element>;
constructor(
/**
* @summary `invokeId`.
* @public
* @readonly
*/
invokeId: InvokeId,
/**
* @summary `errcode`.
* @public
* @readonly
*/
errcode: Code,
/**
* @summary `parameter`.
* @public
* @readonly
*/
parameter: OPTIONAL<_Element>);
/**
* @summary Restructures an object into a ReturnError
* @description
*
* This takes an `object` and converts it to a `ReturnError`.
*
* @public
* @static
* @method
* @param {Object} _o An object having all of the keys and values of a `ReturnError`.
* @returns {ReturnError}
*/
static _from_object(_o: {
[_K in keyof ReturnError]: ReturnError[_K];
}): ReturnError;
}
/**
* @summary The Leading Root Component Types of ReturnError
* @description
*
* This is an array of `ComponentSpec`s that define how to decode the leading root component type list of a SET or SEQUENCE.
*
* @constant
*/
export declare const _root_component_type_list_1_spec_for_ReturnError: $.ComponentSpec[];
/**
* @summary The Trailing Root Component Types of ReturnError
* @description
*
* This is an array of `ComponentSpec`s that define how to decode the trailing root component type list of a SET or SEQUENCE.
*
* @constant
*/
export declare const _root_component_type_list_2_spec_for_ReturnError: $.ComponentSpec[];
/**
* @summary The Extension Addition Component Types of ReturnError
* @description
*
* This is an array of `ComponentSpec`s that define how to decode the extension addition component type list of a SET or SEQUENCE.
*
* @constant
*/
export declare const _extension_additions_list_spec_for_ReturnError: $.ComponentSpec[];
/**
* @summary Decodes an ASN.1 element into a(n) ReturnError
* @function
* @param {_Element} el The element being decoded.
* @returns {ReturnError} The decoded data structure.
*/
export declare function _decode_ReturnError(el: _Element): ReturnError;
/**
* @summary Encodes a(n) ReturnError 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 ReturnError, encoded as an ASN.1 Element.
*/
export declare function _encode_ReturnError(value: ReturnError, elGetter: $.ASN1Encoder<ReturnError>): _Element;
//# sourceMappingURL=ReturnError.ta.d.mts.map