Can't find ANY info about how to get data from one part of an OOP to another.

Started by
19 comments, last by Gwahir 21 years, 4 months ago
quote:Original post by Gwahir
The only problem I can see with this is if two of the inherited classes share a method name... From the examples in my books, things can get very messy very quickly.

But that is how the interface works... derived classes have the same method name, but slightly different behaviour. The idea is that the ''outside world'' only needs to know the interface (ie. the method name, defined in the base class) and the individual classes take care of the differences by executing the correct function for each object.



[ MSVC Fixes | STL | SDL | Game AI | Sockets | C++ Faq Lite | Boost | Asking Questions | Organising code files | My stuff ]

This topic is closed to new replies.

Advertisement