How to map persistent object to DTO? So that no additional behavior is taken. I know it is quite common and easy, but many people - many opinions, what are the best approaches?
(talking about Java)
Thanks,
How to map persistent object to DTO? So that no additional behavior is taken. I know it is quite common and easy, but many people - many opinions, what are the best approaches?
(talking about Java)
Thanks,
You can also use Orika it also support hetrogenous mapping with ease coding.
Another alternative is MapStruct (disclaimer: I'm the original author of this project). MapStruct generates mapping code at compile-time which is thus fast and type-safe, i.e. you don't have any runtime dependencies and get feedback about incompatible mappings at build time, e.g. within your IDE.