eBiss 3

Hilfe & Dokumentation

User Tools

Site Tools


en:transformation:mappings:variablen:xvar

XVar

XVar accelerates access to variables, which is noticeable in multiple calls. For example, if the selection is called frequently in a RuleSet. XVar can be used in the selection and replaces e. g. $var with XVar ('var').

Reason: An XPath selection with a variable must be translated each time XPath accesses the variable to determine its content. If you use XVar, the selection is only translated once and calls the function XVar for further accesses.

This function determines the current value of a variable:

When using XPath, there is often a problem, if you work with variables, the values of the variables (theoretically) are retrieved only once and then remain constant.

This is not sufficient for the eBiss mapping context, which is why XPath expressions contained in mappings are not compiled internally, but are resolved live every time. This is the only way to really variables variables.

In cases where variables are used with lookups this can be problematic. The lookup function is often reinstalled at these points and has no way of caching, which leads to poor performance when used with variables.

The way out is the XVar function.

This function determines the current value of a variable, but in a compileable form. Now XVar (' var') can be entered in the selections (not in Target!!!!) everywhere where var is located, and would have the same result as before, but the variable value is cacheable.

variables_xvar.jpg

en/transformation/mappings/variablen/xvar.txt · Last modified: 2024/02/20 08:15 by 127.0.0.1