mark-p-thomas : GIS.ly Track Managers

GIS.ly uses a Manager Pattern in order to perform CRUD operations with Tracks.

The following illustrates how Tracks are edited in the application using a Track Manager with the following steps:

  1. Get Track from React state hook.

  2. Inject Track into manager object.

  3. Call manager methods, which might alter the Track. Additionally, a fresh copy of the Track is returned as a result. This may update the hooked GeoJSON object. See ref: updateTrack for more details on how.

  4. Update relevant React state hooks with modified Track. See ref: updateFromTrack sequence diagram for more detail.