Okay - here's the problem.  The current BinaryHeap interface expects a
Comparable for it's public interface.  In order to maintain backwards
compatibility I must either:

1. Add new public methods to the BinaryHeap class (e.g., insertObject,
peekObject, popObject) and change the insert, peek, and pop methods to
invoke these new methods, or
2. I can create a new BinaryObjectHeap class and have the BinaryHeap class
act as a wrapper class.

I am also wondering how I would modify the PriorityQueue interface w/o
breaking backwards compatibility...

Any suggestions would be appreciated.

----- Original Message -----
From: "Peter Donald" <[EMAIL PROTECTED]>
To: "Avalon Developers List" <avalon-dev@jakarta.apache.org>
Sent: Wednesday, November 07, 2001 1:27 AM
Subject: Re: [Excalibur] PriorityQueue & BinaryHeap proposal


> On Wed, 7 Nov 2001 12:31, Chad Stansbury wrote:
> > Disclaimer: I'm new to this list so if I'm out of order, please feel
free
> > to say so...
>
> welcome.
>
> > I've tossed my own binary heap in favor of that provided by the
excalibur
> > lib.  However, the 4.0 implementation restricts its usage to Comparable
> > objects.  However, I need the ability to add Objects to the heap, and
> > specify a Comparator (ala Java collections).  If no one objects, I will
add
> > this as a feature request and provide a patch to do so...
>
> sounds like a good idea.
>
> --
> Cheers,
>
> Pete
>
> -----------------------------------------------
> "Only two things are infinite, the universe and
> human stupidity, and I'm not sure about the
> former." -Albert Einstein
> -----------------------------------------------
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to