diff --git a/tdt4140-gr1800/README.md b/tdt4140-gr1800/README.md index 56d967ff046c5bac409aed8e191777d4702c7fbb..a5744fec8485f4b7867e4ec6247ddac885182651 100644 --- a/tdt4140-gr1800/README.md +++ b/tdt4140-gr1800/README.md @@ -10,3 +10,9 @@ This project is about managing sets of geo-locations, like tracks from hiking og * a JavaFX app for visualising, analysing and editing sets of geo-locations * web server with a REST API for managing sets of geo-locations, primarily for collecting the geo-locations from apps, but also as persistence layer for the JavaFX app +The project is organized as a hierarchical maven project, with the follow sub-modules (contained in the root/aggregator project): +* [tdt4140.gr1800.app.core](app.core/README.md) (in app.core folder): Common domain classes and persistence support. +* [tdt4140.gr1800.app.ui](app.ui/README.md) (in app.ui folder): JavaFX app. +* [tdt4140.gr1800.web.server](web.server/README.md) (in web.server folder): Web server providing a REST API to domain data. + +There is no web client project, yet, since that is outside the scope of the course. We may add this later for completeness, and to illustrate the REST API. diff --git a/tdt4140-gr1800/app.core/README.md b/tdt4140-gr1800/app.core/README.md new file mode 100644 index 0000000000000000000000000000000000000000..f292c7aced46833d99b0b6cbaa9be2e4b5a44fd5 --- /dev/null +++ b/tdt4140-gr1800/app.core/README.md @@ -0,0 +1,6 @@ +# app.core module - domain classes for example project + +* [Domain model](doc/domain-model.md) +* [DB-based persistence](doc/db-persistence.md) +* [JSON-based serialization](doc/json-persistence.md) +* [Location-based storage](doc/location-based-storage.md) diff --git a/tdt4140-gr1800/app.core/doc/db-persistence.md b/tdt4140-gr1800/app.core/doc/db-persistence.md new file mode 100644 index 0000000000000000000000000000000000000000..a5aca736d100973c4ccf66b25550af9c03a79a63 --- /dev/null +++ b/tdt4140-gr1800/app.core/doc/db-persistence.md @@ -0,0 +1,5 @@ +# DB-based persistence of domain data + +A class diagram of the main classes related to db-based persistence is shown below. + +<img src="db-persistence-classes.png" alt="DB-based persistence" style="width: 800px;"/> diff --git a/tdt4140-gr1800/app.core/doc/db-persistence.png b/tdt4140-gr1800/app.core/doc/db-persistence.png new file mode 100644 index 0000000000000000000000000000000000000000..c3ecd5c6aed12106dd0d7f310ac9be9d0287ebc5 Binary files /dev/null and b/tdt4140-gr1800/app.core/doc/db-persistence.png differ diff --git a/tdt4140-gr1800/app.core/doc/domain-classes.png b/tdt4140-gr1800/app.core/doc/domain-classes.png new file mode 100644 index 0000000000000000000000000000000000000000..9a4e5d456b431e3c6ac0b0aaa0f2dc9a5b411286 Binary files /dev/null and b/tdt4140-gr1800/app.core/doc/domain-classes.png differ diff --git a/tdt4140-gr1800/app.core/doc/domain-model.md b/tdt4140-gr1800/app.core/doc/domain-model.md new file mode 100644 index 0000000000000000000000000000000000000000..2c179e924941cf16fecef48018cae7bc8ee892e4 --- /dev/null +++ b/tdt4140-gr1800/app.core/doc/domain-model.md @@ -0,0 +1,20 @@ +# Domain model for app and REST API + +The project is about managing sets of geo-locations, so the domain model includes classes for representing geo-locations, sets of these and owners of such sets. A class diagram of the core model is shown below. + +Main types related to geo-locations: +* **LatLong**: Value class representing a geo-location, i.e. latitude, longitude pair. Includes methods for distance calculations. +* **GeoLocated**: Interface for geo-located data, i.e. classes that can return a corresponding **LatLong** object. +* **GeoLocation**: Main implementation of **GeoLocated**. Combines a **LatLong** and *elevation* with generic values like name, description, time (implements **Timed**) and tags (implements **Tagged**). +* **GeoLocations** (unfortunate name): Container for **GeoLocated** objects. Includes a flag indicating of the geo-locations represents a *path* or not. Implements **Timed** and **Tagged**. +* **GeoLocationsOwner**: Container for **GeoLocations** objects. Meant as an abstract class, but is not since it is useful on its own. +* **Person**: Main subclass of **GeoLocationsOwner**. Includes *name* and *email* values. + +Generally useful types +* **Timed**: Interface for time-related data, including *date*, *time* of day and time *zone*. The idea is that elements left out are filled in with (default) values from the container. +* **TimedImpl**: Main implementation of **Timed**. +* **Tagged**: Interface for tags, i.e. sets of string labels. Includes methods for checking, getting, setting, adding and removing tags. +* **Tags**: Main implementation of **Tagged**. +* **TimedTaggedImpl**: Implementation of both **Timed** and **Tagged**, among others used as superclass for **GeoLocation** and **GeoLocations**. + +<img src="domain-classes.png" alt="Domain classes" style="width: 800px;"/> diff --git a/tdt4140-gr1800/app.core/doc/json-persistence-classes.png b/tdt4140-gr1800/app.core/doc/json-persistence-classes.png new file mode 100644 index 0000000000000000000000000000000000000000..2c258f0ea7777b87780c48a136a07c54757e5068 Binary files /dev/null and b/tdt4140-gr1800/app.core/doc/json-persistence-classes.png differ diff --git a/tdt4140-gr1800/app.core/doc/json-persistence.md b/tdt4140-gr1800/app.core/doc/json-persistence.md new file mode 100644 index 0000000000000000000000000000000000000000..a986df21fafaa379743de05214b9468a3a95cc34 --- /dev/null +++ b/tdt4140-gr1800/app.core/doc/json-persistence.md @@ -0,0 +1,5 @@ +# JSON-based persistence of domain data + +A class diagram of the main classes related to JSON-based persistence is shown below. + +<img src="json-persistence-classes.png" alt="JSON-based persistence" style="width: 800px;"/> diff --git a/tdt4140-gr1800/app.core/doc/location-based-storage.md b/tdt4140-gr1800/app.core/doc/location-based-storage.md new file mode 100644 index 0000000000000000000000000000000000000000..ce14abc190abd8681d4aa29f2ea61688ce427a04 --- /dev/null +++ b/tdt4140-gr1800/app.core/doc/location-based-storage.md @@ -0,0 +1,5 @@ +# Location-based storage of domain data + +A class diagram of the main classes related to location-based storage is shown below. + +<img src="location-based-storage.png" alt="Location-based persistence" style="width: 800px;"/> diff --git a/tdt4140-gr1800/app.core/doc/location-based-storage.png b/tdt4140-gr1800/app.core/doc/location-based-storage.png new file mode 100644 index 0000000000000000000000000000000000000000..ddf10fa5ca2db288455402aabd5db338158bb3ed Binary files /dev/null and b/tdt4140-gr1800/app.core/doc/location-based-storage.png differ diff --git a/tdt4140-gr1800/app.ui/README.md b/tdt4140-gr1800/app.ui/README.md new file mode 100644 index 0000000000000000000000000000000000000000..615dc5dd5d40e35cc1db3b622a8dab8076f3338a --- /dev/null +++ b/tdt4140-gr1800/app.ui/README.md @@ -0,0 +1 @@ +# app.ui module - JavaFX app for example project diff --git a/tdt4140-gr1800/web.server/README.md b/tdt4140-gr1800/web.server/README.md new file mode 100644 index 0000000000000000000000000000000000000000..c561b88708d4980efe97fd4832533e67d4212393 --- /dev/null +++ b/tdt4140-gr1800/web.server/README.md @@ -0,0 +1 @@ +# web.server module - Web server providing a REST API to domain data