Skip to content

Documentation / @facturometro/core / RulesetInfo

Interface: RulesetInfo ​

Defined in: packages/core/src/issue.ts:95

The composition of rulesets a diagnostic was produced by.

A document is validated against an ordered list of ruleset constants (EN 16931, then Peppol, then a national or company ruleset). ids and versions list the members in list order, so a report can tell which version of which ruleset ran; id and version are display strings that join them with +, so ${id}@${version} still names the composition in one string. Split the arrays, not the strings: an id or a version may itself contain + (SemVer build metadata such as 1.0.0+build.7).

Example ​

ts
import type { RulesetInfo } from '@facturometro/core';

const ruleset: RulesetInfo = {
  id: 'en16931+peppol',
  ids: ['en16931', 'peppol'],
  version: '1.3.15+3.0.21',
  versions: ['1.3.15', '3.0.21'],
};

Extended by ​

Properties ​

id ​

readonly id: string

Defined in: packages/core/src/issue.ts:97

The members' ids joined with +, in list order, for example en16931+peppol.


ids ​

readonly ids: readonly string[]

Defined in: packages/core/src/issue.ts:99

Ids of the composed rulesets, in list order.


version ​

readonly version: string

Defined in: packages/core/src/issue.ts:101

The members' versions joined with +, in the order of ids, for example 1.3.15+3.0.21.


versions ​

readonly versions: readonly string[]

Defined in: packages/core/src/issue.ts:103

Versions of the composed rulesets, parallel to ids.

MIT licensed. Specification artefacts belong to OpenPEPPOL, CEN and OASIS.