On Thu, Dec 31, 2009 at 9:12 PM, Retnuh <[email protected]> wrote:
> Well there are ways of pulling two different objects out from an Array, > but you will pull them all out and how are you sure of which one you are > going to get? > > Stephen > > > > > > > MARIO CAMPAZ wrote: > > > > To answer this: > > > > Why did you put them in one array instead of seperating them into > > different ones. I thunk you should have seperated them at first and > > add them to the corrct array. > > > > If you put them in one array, then you can exploit the polymorphic OO- > > design capabilities. > > Leaving the runtime engine take care of the differences using dynamic > > binding. > > Please, correct if I am wrong! > > > > Mario > > > The point of all this is that in a good OO design with polymorphic methods, your application code rarely needs to be aware of type in a situation like this, the runtime engine will select the correct method for you. -- To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/javaprogrammingwithpassion?hl=en
