Re: [xml-dev] contradictory loader ordering in 3.5
Jesse Glick <[email protected]> Fri, 21 Mar 2003 11:20:24 -0500
| Newsgroups | gmane.comp.java.netbeans.modules.xml.devel |
|---|---|
| Organization | Sun Microsystems / NetBeans |
| Message-ID | <[email protected]> |
Petr Kuzel wrote: > From DataLoader JavaDoc: > > protected DataLoader(String representationClassName) > > Create a new data loader. Pass its representation class name as a > parameter to the constructor. The constructor is then allowed to return > only subclasses of the representation class as the result of > findDataObject(org.openide.filesystems.FileObject, > org.openide.loaders.DataLoader.RecognizedFiles). > > So it goes against contract. Yes, though this contract is not enforced that I am aware of. More correct is to simply make VXMLDL.DummyDataObject extend XMLDataObject (possibly empty except for the constructor calling super) and create instances of that. Simple and compliant with the API. > On the other hand you cannot > using manifest attributes order multiple loaders producing > the same data object class. Right. -Jesse -- Jesse Glick <mailto:[email protected]> x22801 NetBeans, Open APIs <http://www.netbeans.org/>