Reply To: Adding exceptions

#5618
Levi
Participant

An exception provides the modeler an avenue to model exceptional behavior in the application itself. For example, a MASL analyst may model a domain Cellphone, a class Antenna, and an exception TowerUnreachable. A class operation acquireTower() on Antenna may raise the TowerUnreachable exception and handle it in a certain way, or let the caller of acquireTower() to handle the exception. Of course, the same behavior can be modelled with “if” statements and calls to the LOG domain, however exceptions add richness and meaning to the language.

Read more about exceptions in the reference manual here (starting on page 93):
https://github.com/xtuml/bridgepoint/blob/master/src/org.xtuml.bp.doc/Reference/MASL/LanguageReference/legacy/maslrefman.pdf

Note that this is the legacy manual, a detailed explanation of exceptions is not available in the current manual.

Here is the pull request associated with this work:
https://github.com/xtuml/bridgepoint/pull/155