Gallery Tutorial [TECHNICAL SLIDE TRAIL] The Webel libraries for Wolfram Mathematica: With SysMLv1 models. Section SECTION: The Webel Abstract Data Type (ADT) stateless pseudo-classes with inheritance (with SysMLv1 models) Tags and keywords UML keywords Generalization Property::redefinedProperty Webel Mathematica keywords ADT` Webel ADT ADT$List XL$XL XL$RowList «adt:memberInterface» adt$addSuper ADT definer function Keywords Wolfram Wolfram Language Mathematica Webel::SysML4Mathematica Webel IT Australia Abstract Data Types Webel:ADT Systems Modeling Language SysMLv1 Click on the image to view it full size For reference, some associated Policy Notes (you don't need to visit these links yet): Mathematica: Webel ADT pseudo classes: There is an 'ADT' universal base that has no supers. It "blesses" every other sub-class ADT by populating it with some common ADT-Method UpValues against a signature pattern via the 'adt$def$All[]' definer function. Mathematica: Webel ADT pseudo classes: DEFINITION/CONVENTION: Functions that populate ADTs with reusable ADT-method UpValues are called 'definers' and include '$def' in the name after a Package scope indicator: Example: adt$def$ADT, my$def$MY$CleverList Mathematica: Webel ADT pseudo classes: POLICY: Multiple inheritance is supported via ONE (only) ADT-Class and one or more ADT-MemberInterfaces (which have no ADT-Method UpValues) Mathematica: Webel ADT pseudo classes: POLICY/DEFINITION: Every "hard coded" definer or defining client of a definer has a corresponding ADT ArchetypeClass. Example ("hard coded"): The definer 'my$def$MY$SmartList' has ArchetypeClass 'MY$SmartList'. Up next Extending ADT sub-classes represented as SysML Blocks with redefined wrapped ‘$$’ Notes [CONVENTION, POLICY]{STRICT} Mathematica: Webel ADT pseudo classes: POLICY: Every named concrete Abstract Data Type (ADT) has a ONE unique "signature" (which is the pattern passed to the "definer" functions). To vary a signature, define another unique ADT name. [POLICY]{STRICT} Mathematica: Webel ADT pseudo classes: POLICY: The expression '$$' is reserved as the primary named parameter for the defining pattern of all ADT classes that extend the universal base 'ADT' class. [CONVENTION, NAMING, POLICY]{STRONG} Mathematica: Webel ADT pseudo classes: DEFINITION/CONVENTION: Functions that populate ADTs with reusable ADT-method UpValues are called 'definers' and include '$def' in the name after a Package scope indicator: Example: adt$def$ADT, my$def$MY$CleverList [POLICY]{STRICT} Mathematica: Webel ADT pseudo classes: There is an 'ADT' universal base that has no supers. It "blesses" every other sub-class ADT by populating it with some common ADT-Method UpValues against a signature pattern via the 'adt$def$All[]' definer function. [POLICY]{STRICT} Mathematica: Webel ADT pseudo classes: POLICY: Definer functions MUST return the self-declared or injected 'pattern' that determines the unique "ADT-signature" of the defined ADT class. [CONVENTION, NAMING, POLICY]{STRICT} Mathematica: Webel ADT pseudo classes: POLICY/DEFINITION: Every "hard coded" definer or defining client of a definer has a corresponding ADT ArchetypeClass. Example ("hard coded"): The definer 'my$def$MY$SmartList' has ArchetypeClass 'MY$SmartList'. [POLICY]{STRICT} Mathematica: Webel ADT pseudo classes: ADTs that define membership of ADT-classes in a domain package have ADT-signature MemberInterface[$$:None] and MUST NOT populate ADT-method UpValues in their definers. [POLICY]{STRICT} Mathematica: Webel ADT pseudo classes: POLICY: Multiple inheritance is supported via ONE (only) ADT-Class and one or more ADT-MemberInterfaces (which have no ADT-Method UpValues) Snippets (quotes/extracts) Related slides (includes other tutorials) Introduction to Webel Abstract Data Types (ADTs) with SysMLv1 models Webel Abstract Data Types (ADTs) vs the user-contributed MTools for OO Webel ADTs include inheritance (and aren’t actually formal ADTs) Webel ADT hierarchy views as tree, graph, and SysML Webel ADT`package: Some ADT pseudo class utility functions in a ::usage help viewer. Diagnostic, help, and development functions. Classes in the ADT` package: Extendable ADT pseudo classes have corresponding "definer functions" Simple Webel ADT in the development view dV[adt] and class/methods help hC[adt] Related slides (backlinks, includes other tutorials) Webel «adt:pseudo» elements in the SysMLv1 ADT model (1) Webel «adt:pseudo» elements in the SysMLv1 ADT model (2) Chained wrapped ADT pseudo Lists: Example: EX` package structured data ADTs Chained wrapped ADT pseudos as a SysMLv1 Internal Block Diagram (IBD) Clients of List ADTs don’t usually directly access the wrapped Lists (but can for testing with ADT⊙get which BREAKS ENCAPSULATION) Webel ADT SysMLv1 Stereotypes adt$graphHierarchy example: The EX` package for structured data ADT finder functions and “methods” adt$findUp, adt$findUpArg, ADT⊙fM ADT help functions and methods: adt$treeHierarchy (adt$tH), adt$hC, ADT⊙hC: Example: XL$Cell ADT`: helpADT[class]: help on methods registered with HelpO`: Example: XL$Cell Visit also Mathematica: POLICY NOTES for the Webel Abstract Data Type (ADT) pseudo classes with inheritance for the Wolfram Language Dr Darren of Webel IT Australia makes the case for better object-orientation for Mathematica using pseudo class ADTs without losing the super-functional power of the Wolfram Language Visit also (backlinks) Flags Book traversal links for Creating new ADTs that extend other classes using a definer function (and adt$addSuper) Previous Up Next