Seems like we are getting even more abstract. I hope we don't over abstract the code.
Here is my best guess for an interface getSize() // Total # of elements in collection. The way you retrieve this may differ depending on your data source. getStartIndex() // Get the Current Start Index setEndIndex() // Get the Current End Index setSetSize() // Set the Number of elements on a page getSetSize() // get the Number of elements on a page getNumberOfPages() // get Total Number of Pages given the size of the collection and the start and end index. setNumberOfPages() // set The Total Number of Pages and adjust the SetSize and start and end Index. retrieveCurrentCollectionSubset() // Retrieve the subset of the Collect given the current Start and End Index. You can implement this anyway you want given your data source. Given this interface you can implement whatever data source you want. We could probably create and implementation for a Database using DatabaseMetaData and since maybe even create an impl that just accepts an XQuery and paginates accordingly. On Tue, 31 Aug 2004 17:27:23 +1000, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > You can do this without a data model. Just let the user specify > > any table and use DatabaseMetaData to retrieve the columns. > > My query isn't coming directly from a database. It's (a) on another tier, > and (b) the result of an XQuery, so unfortunately that doesn't do the job > for my purposes. > > cheers > dim > > > > > On Mon, 30 Aug 2004 10:27:39 +1000, [EMAIL PROTECTED] > <[EMAIL PROTECTED]> wrote: > > > To me the most important change will be the re-factoring to allow > > > database loading (using paging and sorting). And I won't like to see > > > any JDBC or any ORM-tool code for this. Just an interface that has > > > to be implemented and linked. > > > > I'm not sure how you're thinking of doing this, but I'd also like to > > see the data model abstracted in a similar fashion to the way the > > swing table model is. This would make dynamic lists simpler to > implement imo. > > > > cheers > > dim > > > > ###################################################################### > > DISCLAIMER: > > This email and any attachment may contain confidential information. > > If you are not the intended recipient you are not authorized to copy > > or disclose all or any part of it without the prior written consent of > > Toyota. > > > > Opinions expressed in this email and any attachment are those of the > > sender and not necessarily the opinions of Toyota. > > Please scan this email and any attachment for viruses. > > Toyota does not accept any responsibility for problems caused by > > viruses, whether it is Toyota's fault or not. > > ###################################################################### > > > > > > > > > > ------------------------------------------------------- > > This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java > > Enterprise J2EE developer tools! > > Get your free copy of BEA WebLogic Workshop 8.1 today. > > http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click > > _______________________________________________ > > displaytag-devel mailing list > > [EMAIL PROTECTED] > > https://lists.sourceforge.net/lists/listinfo/displaytag-devel > > > > ------------------------------------------------------- > This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java > Enterprise J2EE developer tools! > Get your free copy of BEA WebLogic Workshop 8.1 today. > http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click > _______________________________________________ > displaytag-devel mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/displaytag-devel > > ###################################################################### > DISCLAIMER: > This email and any attachment may contain confidential information. > If you are not the intended recipient you are not authorized to copy > or disclose all or any part of it without the prior written consent > of Toyota. > > Opinions expressed in this email and any attachment are those of the > sender and not necessarily the opinions of Toyota. > Please scan this email and any attachment for viruses. > Toyota does not accept any responsibility for problems > caused by viruses, whether it is Toyota's fault or not. > ###################################################################### > > ------------------------------------------------------- > This SF.Net email is sponsored by BEA Weblogic Workshop > FREE Java Enterprise J2EE developer tools! > Get your free copy of BEA WebLogic Workshop 8.1 today. > http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click > _______________________________________________ > displaytag-devel mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/displaytag-devel > ------------------------------------------------------- This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools! Get your free copy of BEA WebLogic Workshop 8.1 today. http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click _______________________________________________ displaytag-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/displaytag-devel