Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

For every resource we have made, there's a few extra classes that we have generalised here. The DTO classes are being used to model the data in a single format for easier use, this way we only need to edit data in one place.
In the DAO classes we put all the logic that is needed to get the data from the database. Here we will process the data from a query result into the DTO and pass it back to the services.  This way we create a layer pattern in our application which gives better readability and clearity for the next team that wants to alter our code after us.

...