[BangPypers] problem with python classes

Noufal Ibrahim noufal at nibrahim.net.in
Fri May 10 06:17:14 CEST 2013


hiharry danny <hrdspl at gmail.com> writes:


[...]

> if this be the case , then without using inheritance property of OOP ,i,e,
> without creating further new subclasses , how can I access other user
> defined methods of ClassOne class via Class Two class. The ouput value will
> be returned by a user defined method of ClassTwo but the computation will
> be done by a method of ClassOne which is called by the user defined method
> of class two ...?
>
> so what will be the solution ?

Can you post back some examples of how you would use ClassTwo? The basic
solution is to delegate all the work to the instances of ClassOne and
return results. 

Whether you do this by accessing certain attributes or calling different
functions will make the code different.

[...]


-- 
Cordially,
Noufal
http://nibrahim.net.in


More information about the BangPypers mailing list