java - Extending the automatically generated JPA controller (Netbeans 7.x) -
netbeans 7.x offers possibility generate entities (pojos) existing relational database (ex: customerentity, orderentity, etc.)
also, generates automatically controller each entity (ex: customerjpacontroller, orderjpacontroller, etc.).
the generated controllers contains many ready-to-use methods (findall, create, delete, etc.). advantage using controllers' generator possibility recreate/update them once entity (or table) modified (adding new constraints, new fields, etc.).
unlike "partial class" concept offered .net, not possible extend these controllers user-defined methods in separate classes.
what suggest (in terms of best practices or design patterns) take advantage of these automatically generated controllers?
i use generated controller classes in self-created dao classes.
Comments
Post a Comment