stephenh / dtonator

code generator for creating DTOs and mapping to domain objects
Other
14 stars 5 forks source link

'Set' Properties not Currently Supported #6

Open pbtura opened 7 years ago

pbtura commented 7 years ago

While the generation process can handle properties of type java.util.List, there is no equivalent support for java.util.Set.

stephenh commented 7 years ago

True. I generally consider "this is a set" a kind of validation rule, e.g. "bob" can't be in the list of names twice, and so model it on top of the DTO layer, but I'm not against some sort of hint that things are a set.

I guess if the domain model has collections that are sets, that would make sense to support them. I didn't think of that.

pbtura commented 7 years ago

I have a pull request ready to go. Would it be better to submit it now, or wait until after the other one I submitted is merged in?

stephenh commented 7 years ago

Keeping them separate I think would be easier.