Re: What is Wrong! Re: Implementing FcFs queue with J2SE 5.0
- From: "Rhino" <no.offline.contact.please@xxxxxxxxxx>
- Date: Fri, 30 Dec 2005 16:27:35 -0500
It's pretty hard for us to diagnose warnings when you haven't told us what
they are. In any case, it would probably be better for you to start a new
thread for this problem and to make the title reflect the new problem, e.g.
Compiler warnings from PriorityQueue.
Rhino
"Veikka" <veikka@xxxxxxxxxx> wrote in message
news:dp45br$nv2$1@xxxxxxxxxxxxxxxxxxxxx
>I found a following snippet in Web but it gives warnings.
> This should the PriorityQueue I need but there is something wrong....
>
> PriorityQueue <Priority> priorityQueue = new PriorityQueue(10,
> new Comparator<Priority>()
> {
> public int compare(Priority a, Priority b)
> {
> System.out.println("Comparing Populations");
> int populationA = a.getPopulation();
> int populationB = b.getPopulation();
> if (populationB > populationA)
> return 1;
> else if (populationB < populationA)
> return -1;
> else
> return 0;
> }
> }
> );
> }
>
>
> "Veikka" <veikka@xxxxxxxxxx> wrote in message
> news:dp3rsp$gti$1@xxxxxxxxxxxxxxxxxxxxx
>> Hello,
>>
>> J2SE 5.0 has a lot's of new classes considering multithreading.
>> What is the best class to implement queue in FirstComesFirstServed model?
>>
>> Any sample code arapund?
>>
>> Cheers!
>>
>>
>
>
.
- References:
- Implementing FcFs queue with J2SE 5.0
- From: Veikka
- What is Wrong! Re: Implementing FcFs queue with J2SE 5.0
- From: Veikka
- Implementing FcFs queue with J2SE 5.0
- Prev by Date: Re: FileInputStream in Servlet
- Next by Date: Re: Recommendations for displaying rows throug servlets -- like displaytag
- Previous by thread: What is Wrong! Re: Implementing FcFs queue with J2SE 5.0
- Next by thread: Serving windows media and real audio streams as MP3
- Index(es):