Reputation: 311
There are any way to extend a DAO file (by example: myEntityDao) to add custom queries without losing that code when the daogenerator runs?
I found a way to extend entities (using the "keep" section) but I didn't found a way to extend te Dao files permanently.
Thanks
Upvotes: 4
Views: 286
Reputation: 6285
I've spent quite a lot of time on that and I was not able to do that. My solution for this problem is to create another layer, services in my case, which have all the custom queries. It works well also for the testing purposes.
Upvotes: 2