[Bluej-discuss] Ex.4.38

Colleen Penrowley cpen at telus.net
Sun Nov 12 00:30:32 GMT 2006


Mike,

Think about the fact that you need to check the entire stock array list 
before you know if it's ok to add the new item.

Colleen


At 01:34 AM 11/10/2006 -0800, Mike Stevens wrote:

>Thanks Jens for pointing the parameter out as a local var, that will 
>change the way Im looking at local vars when I m passing a parameter like this.
>
>
>
>The method compiled after I changed this but it is not adding in the 
>product now
>
>
>
>if(inStock.getID() != item.getID())
>
>                 {
>
>                     stock.add(item);
>
>                 }else{
>
>                     System.out.print("Id used");
>
>                 }
>
>
>
>Have I over looked something here?  I have the print out just to let me 
>know the if and else are working.
>_______________________________________________
>mailing list bluej-discuss at bluej.org
>To unsubscribe or change your preferences, go to
>http://lists.bluej.org/mailman/listinfo/bluej-discuss




More information about the bluej-discuss mailing list