Dart/Flutter version of Missile Site Demo

Missile Site using Rocket lib which uses SAMCAS library as its engine.

Description

This app implements in Dart using the Flutter platform a demonstration of combining many SAMCAS models into a working app. It demonstrates the SAM pattern proposed by Jean-Jacques Dubray and explained at sam.js.org.

SAM (State-Action-Model) is a software engineering pattern that helps manage the application state and reason about temporal aspects with precision and clarity. In brief, it provides a robust pattern with which to organize complex state mutations found in modern applications.

The Dart version of SAMCAS is a table driven approach to the SAM pattern and extends the SAM pattern by including a simple signal protocol for child models to inform their parents of their state changes.

This app demonstrates:

  1. Many SamModels interacting together (parent to child and child to parent).

  2. More complex widget build structures

  3. Use of Navigator component to change pages

  4. State transitions for the Site itself as well as the children

  5. Flutter screen size dependent layout

  6. Logging window

The source code available at missile-dart-app along with these documents can be used as a road map to build a SAMCAS application.

The companion Rocket is a simpler application incorporating the SAMCAS facility into a Flutter app.

How to Use

  1. You are asked to define the Missile Site. Just pressing the BUILD button will build an unnamed default site. Giving the site a name or varying the number of banks will cause the site to be built according to the non-default values.

  2. You will see one or more Banks. Start the missile in each.

  3. Turning on the Auto Mode switch will display the Incoming button. Pressing this will launch all available missiless with a delay in between. You will also be asked to choose a delay time (10, 15, 20) seconds.

  4. When all the missiles are used in a bank it will be marked DEPLETED. Pressing the Replenish button will replenish the site.

  5. When there is only 1 bank left the site will enter a blinking Distressed state.

  6. When there are no Banks left the site will enter a Defunct state.

License

Copyright (c) 2020 Steve Pritchard of Rexcel Systems Inc.

Released under the The MIT License

Reference Resources

Source repository at GitHub

Libraries

missile
The missile portion of the app provides app navigation and initial configuration. [...]
site
These classes are used to assemble the Missile Site structure. [...]