-
Notifications
You must be signed in to change notification settings - Fork 0
Deliverable 2 Design Decisions
The business methods were implemented, knowing that they could be accessed by the application user from the frontend. These methods were mainly retrieved from the use case diagrams and include login, logout, uploadArtWork, ascending and descending filtering, sorting by price, etc. The argument inputs of these methods are not objects, but mainly Strings, integers or double, since those are the data types an application user can input in the frontend. Then, these inputs are used inside the business methods to access the object by methods such as findByName(String name) which will return the ApplicationUser object with the specified username. Moreover, each time a change is made to an object inside a business method, this object is saved to the appropriate object repository to ensure the changes are saved on the server-side of the application.
An important design decision is in the conversion of objects to DTOs. In the case of a bidirectional association between two classes, the team made the decision to first convert the first object to a DTO without setting any association with the other object (on the other end of the association). Only when converting the second object to a DTO have we set the associations. This process has allowed us to solve the issue pertaining to the execution of undesired infinite loops.