Skip to main content

Interface: XpathToRelContext

Defined in: xpath.ts:45

Properties

choiceListOf?

optional choiceListOf?: (elementName) => string | undefined;

Defined in: xpath.ts:61

Resolves the choice list backing an element, for jr:choice-name(${q}, …)choiceLabel(${q}, 'L'). The list name simply is not present in the XPath — ODK's second argument is the question name — so without this the translation has to guess and reports lossless: false. The importer owns the element → list map and passes it in.

Parameters

ParameterType
elementNamestring

Returns

string | undefined


scopePath?

optional scopePath?: string;

Defined in: xpath.ts:53

Dotted path of the repeats enclosing the expression's owner, e.g. "hh_members" or "hh_members.kids". Used to clamp ../ hops: an ODK path that climbs above the outermost scope is the root in RFD terms, so ../../q written one repeat deep becomes ${/q} rather than a reference the engine would reject at load with RASD_EXPR_UNKNOWN_REF.