From: Robert Klemme Date: 2005-10-20T06:17:02+09:00 Subject: Re: Searching for a name Brian Schr�der wrote: > On 19/10/05, ES wrote: >> Brian Schr�der wrote: >>>> [snip] >>> >>> "delete_min_return_priority" returns the priority of the element >>> that was removed by calling this method. >> >> I am still not sure :) By 'this method', do you mean delete/dequeue? >> Or does delete_min_return_priority itself delete? >> >> If it does not delete, then #last_(deleted_)priority is fine; >> otherwise you might do something like #dequeue_by and document the >> return value. It would get excessively verbose to include all that >> information in the method name. >> > > delete_min_return_priority deletes the key that has the lowest > assigned priority and returns this priority. Honestly, what would anyone do with this method? Removing the key and getting ignoring the prio is fine, but removing an element from the PK without knowing which element sounds pretty much useless to me. I would not keep it - not even for symmetry reasons... > delete_min_return_key > does the same but returns the key that had the lowest assigned > priority. Finally delete_min deletes the same key and returns a pair > [key, priority]. Both of these seem useful to me. In that case the deq_* approach would make sense IMHO. Kind regards robert