Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

Reply
 
Thread Tools Display Modes
List/Array question
Old
Choad
Guest
 
Status:
Posts: n/a
Question List/Array question - 03-09-2007, 09:53 AM

I have created a new class 'marchingSoldier' which contains a method 'march'.
I have a list of four marchingSoldier instances called 'soldierList'. I want to iterate through the list using 'For all together' such that each element in the list has its 'march' element called.

E. g.,
For all world.soldierList, every obj item from_soldierList together
obj item_from_soldierList.march

I cannot find a way to accomplish this where the method to be called is local to an object in the List - a new method in the object.

Help?

TJ
   
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Copyright ©2024, Carnegie Mellon University
Alice 2.x © 1999-2012, Alice 3.x © 2008-2012, Carnegie Mellon University. All rights reserved.