Web applications typically send a list of identifiers to the server when selecting collection items. There may be an HTML form representing the course, and it will contain a list with all students of the semester. By selecting some students, they will be associated with the course. The server will receive a list of student IDs.
What is the best practice for converting this list of identifiers (primary keys in the database) to a list of domain objects with ORMs like Hibernate? I would like to avoid re-writing the same code for each domain class. Grails does something similar (but I don't know how).
source
share