Gallery Tutorial [TECHNICAL SLIDE TRAIL] The Webel libraries for Wolfram Mathematica: With SysMLv1 models. Section SECTION: The Webel '$opt$' and '$arg$' help holder conventions for options and arguments in the Wolfram Language Tags and keywords Mathematica keywords Association MTools MTools::Class Webel Mathematica keywords help holder '$arg$' '$opt$' 'rule$arg$' 'rule$opt$' MArg MOpt Keywords Wolfram Wolfram Language Mathematica Webel IT Australia Click on the image to view it full size Up next Webel ‘$arg$’ help is much easier with the MArg class using MTools! Notes [NAMING, PATTERN, POLICY]{STRICT} Webel: Mathematica: CONVENTION: Argument help holders use a String variable with the prefix '$arg$', a related '$info$arg$' String, a 'def$arg$' default value expression and/or 'req$arg$', and optional '$warn$arg$', '$tip$arg$, '$lab$arg$', 'type$arg$'.. [NAMING, PATTERN, POLICY]{STRICT} Webel: Mathematica: CONVENTION: Option help holders use a String variable with the prefix '$opt$', a related '$info$opt$' String, a 'def$opt$' default value expression, and optional '$warn$opt$', '$tip$opt$', '$lab$opt$', and 'type$opt$' indicator ... [TIP]{INFORMATIVE} Mathematica: TIPS for living with the user-contributed MTools for Object-Orientation (until a vendor-supported OO solution is eventually provided) [PATTERN, TIP, TOOL]{INFORMATIVE} Webel + Mathematica + MTools + SysML Snippets (quotes/extracts) Visit also The Webel SysML4Mathematica recipe for modelling Wolfram Language code in Systems Modeling Language (SysML) for Model-Based Systems Engineering Visit also (backlinks) Related slides (includes other tutorials) The Webel '$opt$', 'rule$opt$', '$arg$', 'rule$arg$' and supporting '$k$' conventions for "help holders" Related slides (backlinks, includes other tutorials) Association as SysML: CASE: Webel @RuleMap and @ArgsMap «pseudo» blocks. Very "fiddly" to represent in a SysML Block Definition Diagram! Association as SysML: CASE: Webel @ArgMap «pseudo» block (slightly less "fiddly" as an Internal Block Diagram) Webel ‘$opt$’ help even easier with makeOpt[$name] for MOpt! HelpM`: Use Webel MOpt and MArg objects to create ‘$doc$’ Strings for ::usage help The Webel W`Moo` package group: Additional utilities for the user-contributed MTools paclet for classes & object orientation Deployment folders for projects that depend on W`Base` and MTools OO (as SysML) HelpO`: addMethod: MTools method registration example for the Webel MAll class and an object Basic SysMLv1 example: The HelpM` package MTools classes as Blocks About «pseudo» blocks (always prefixed with ‘@’) SysML: OptionsPattern[] “Generalizations” using Join:" Example: HelpM` helper classes new functions The AOR Map (Arguments, Options, Rules): Integrated ::usage, HelpF`/HelpO` registration, and Options[] (without MTools) The AOR Map (Attributes, Options, Rules) Association: Example: aor$f$helpClass The AOR Map as SysML Blocks with Rules Convention-based MDemoConfig with fields for ‘$opt$’ options (works with any MTools class but prefer MOptsSet or MOpt) Flags Book traversal links for Easier ‘$arg$’ and ‘$opt$’ help Rules using the Webel MArg and MOpt helper classes and MTools for OO Previous Up Next