pinazo at async.com.br
Fri Oct 10 14:00:32 BRST 2003
On Fri, 10 Oct 2003, Christian Robottom Reis wrote:
> On Thu, Oct 09, 2003 at 07:43:12PM -0300, Juan Pinazo wrote:
> > This is a proposed dump_list for CListDelegate, which returns a list of
> > the clist instances in the same order as they appear.
> I just read through the code. I thought about having an extra API for
> this functionality (dump_list_ordered() or dump_list_sorted()). The
> reason is twofold:
Well, I don't think this names are good, because the clist maybe not be
sorted sometimes. This can happen when no column have the argument
sorted set to TRUE as default and no sort was selected in the interface.
> a. I think it *may* be useful in certain cases to retrieve the list
> in the original order it was posted. In that case, we'd need
> dump_list() to behave as it has.
> b. Your implementation is slightly less efficient than the original
> code (it is O(n)) and in certain cases it may be important to
> grab the list as fast as possible.
> What do you think about using dump_list_X()?
It's a good idea. But a good name to this method is hard to find. It
should be something like "dump_list_as_it_appears". :-)
So far, so good.
Juan Pinazo :: pinazo at async.com.br :: +55 19 91661096 :: 16 33724826
Async Open Source - Brazil / http://www.async.com.br/
More information about the Kiwi