Re: Barracuda: Patch for IterativeListModel
Jacob Kjome <[email protected]>
| Newsgroups | gmane.comp.java.enhydra.barracuda.general |
|---|---|
| Message-ID | <[email protected]> |
Hi Stefan, The thing is, the name of the class is Iterative*List*Model. Given the name, it makes sense that it uses a List. That said, maybe the class should have been called something else that doesn't constrain it semantically? I guess we're kind of stuck with the name now. If we changed that, we'd break lots of applications. So, maybe the change is a good idea, even if it doesn't match up semantically. I'm +1 on the change if others are. Christian, what do you think? Jake At 11:59 AM 12/6/2002 +0100, you wrote: >Hi, > >IterativeListModel uses internally a List. The only operation called >upon this is iterator(). Since List extends Collection, it is sufficient >to use Collection instead of List inside IterativeListModel. >The attached patch solves this. > >There's no need to modify any code that uses IterativeListModel, only a >recompile is necessary. > >The benefit from this is, you can pass e.g. Set to IterativeListModel. > >Regards, >Stefan