Let’s suppose a user wants to add a customer to the system. He fills a form with the customer information and then press a button. The click event is captured by a form object in the UI layer. Who is responsible for creating a new customer object with the information provided by the user, the form itself or the controller in the Business layer?
In the book “Applying UML and Patterns”, in the examples I’ve seen so far the user input is passed to the controller in the form or parameters, and then the controller creates the appropriate object. My doubt is because I was told that it’s preferable to pass data between layers using objects instead, and not a bunch of parameters.