This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | [60cat] Create a "dataprovider" out of a Entity Bean | ||
---|---|---|---|
Product: | obsolete | Reporter: | racx <racx> |
Component: | visualweb | Assignee: | issues@obsolete <issues> |
Status: | NEW --- | ||
Severity: | blocker | CC: | romanmostyka |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Issue Type: | ENHANCEMENT | Exception Reporter: |
Description
racx
2007-10-10 14:09:14 UTC
Additional Explanation: Having a JSF application and working with JPA as our data backend. While injecting the entity beans to the visual web component, we have to create a data provider class for the entity bean we need to inject, that data provider class usually extends the "ObjectListDataProvider" class. And then we bind the "Table"(for instance) in the visual web to that Data Provider. So it would be practical to have the possibility to create on design time that DataProvider class. to be able to bind it to our visual componet. Please look at this example, where Members is the entity bean, and MembersDataProvider is the needed Data Provider: public class MembersDataProvider extends ObjectListDataProvider{ private List membersList = new ArrayList(); /** Creates a new instance of MembersDataProviderr */ public MembersDataProvider() { // Dummy data for design time membersList.add(new Members()); // Wrap the list setList(membersList); } } no resources to implement for 6.x |