Versions Compared

Key

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

...

The crewmember goes to the view races page where the front-end does a call to the backend. This activates the getAllRaces method in the Raceresource. The resource is only responsible for returning the response so it gets delegated to the racecontroller. The Racecontroller delegates this to the raceDAO because getting the data from the database is not the responsibility of the controller. In the RaceDAO a database connection is established to get all the data from the database. The benefit of this structure is that you can easily swap the classes which results in low cohesion and high coupling.  This structure is based of the the layer pattern.

Design decision

Decision

Description

Problem/Issue

The name of the racecar is not stored in the database because this is not necessary at the moment
DecisionIn the constructor of RaceDTO the car get's the value "BMW 320 4fl E46" assigned
AlternativesStore it in the database, leave it empty
Arguments

The BMW is the only car they intend to use in the near future so it's not necessary to make a new table for racecar. 

...