check_references
Checks S1000D document references (dmRef, pmRef, ICN, internalRef, applicRef) and reports unresolved targets with reasons, so you can fix broken links before publishing.
Instructions
List the references of one document and whether each target exists: dmRef (all contexts: brexDmRef, applicCrossRefTableRef, pmEntry, body), pmRef, ICN (graphic/@infoEntityIdent via the DOCTYPE ENTITY declaration to a file), internalRef (ids in the same document) and applicRefId (applic ids or referencedApplicGroupRef/applicRef). Unresolved references carry a reason (not-found, no-entity-declaration, file-not-found, no-such-id, no-csdb). dmRef to modelIdentCode "S1000D" point to the specification itself and are listed separately.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| xml | No | The document as an XML string (alternative to path; max 5 MB). | |
| path | No | File path of the data module (or PM) to check. | |
| kinds | No | Reference kinds to report (default: all). | |
| csdbDirs | No | Extra CSDB folders to search for referenced data modules, publication modules, ICN files and BREX (in addition to S1000D_CSDB_DIR; BREX also under S1000D_SPEC_DIR). | |
| maxItems | No | Cap on listed references (default 200). | |
| includeResolved | No | Also list resolved references with the file they resolve to (default false; counts are always returned). |