Mathematica: Webel ADT pseudo classes: «adt:ref» applied to a property indicates that it is resolved by ID through the ADT store using adt$fetch[id]. Use adt$store[adt] for very large ADTs and for cleaner ADT views and easier Notebook development.

Webel IT Australia promotes the amazing Mathematica tool and the powerful Wolfram Language and offers professional Mathematica services for computational computing and data analysis. Our Mathematica tips, issue tracking, and wishlist is offered here most constructively to help improve the tool and language and support the Mathematica user community.
DISCLAIMER: Wolfram Research does not officially endorse analysis by Webel IT Australia.
Icon class
icon_class
far fa-sticky-note
icon_class_computed
far fa-sticky-note
Note kind
Policy level
Webel Mathematica keywords
Keywords

Because a Webel ADT is stateless, ADTs that wrap other large ADTs can quickly become unwieldy, noting that a Webel ADT does not (yet) use "pointer-like" references.

For example, in the Webel OpenXML libraries for creating structured data from unstructured spreadsheet data, a US$Cell needs an XL$ResourcesMap (which contains a lot of spreadsheet bundle information), so wrapping an XL$ResourcesMap in each US$Cell would make each US$Cell large (and difficult to view in Notebooks during development). So instead, each US$Cell just carries the ID of an XL$ResourcesMap and looks it up as needed (optionally with efficient UUID-driven Once-caching), as shown in these slides:

The adt$store[adt] and adt$fetch[id] functions enable an ADT to use lookup against the id of a Webel ADT, so the ID is used a bit like a pointer. In the Webel SysML4Mathematica (v1) modelling a property that is resolved by adt$fetch[id] lookup is denoted «adt:ref» - with a tagged value 'id' which is the name of the corresponding wrapped ID property of the ADT (typically the 2nd argument after the special '$$' primary).

A Webel ADT currently uses Hash to create Integer IDs. Chances of ID clashes are very small (especially if the ADT store only has a few large ADTs), but ID clashes are possible, so this ID strategy may be revised. Tests show that Hash is faster than using CreateUUID Strings.

Compare with MTools, where each object gets a Unique identifier and there is a behind the scenes lookup. In this example, the newAll function is used to create a Webel MAll MTools extension object:

newAll[]
MAll[object$3931820]
Relates to
Related notes
Related notes (backlinks)
Related snippets (extracts)
Visit also
Visit also (backlinks)