Kostas Lps wrote:
> Hi guys,
> i have 2 classes say class A and class B. How can the A object that i'll
> create to call a class B method????
> Say we have this code:
> 
> class A
>   def printA
>     puts = "Class A method"
>   end
> end
> 
> class B
>   def printB
>     puts "Class B method"
>   end
> end
> 
> I want to make something like this:
> a = A.new
> a.printB
> 
> I this possible someway???
> 

a's available methods are:

1) The methods defined in A.
2) The methods defined in the classes A inherits from.
3) The methods that A mixes in.
4) The object specific "singleton" methods of a.

The method B#printB is not one of those.

-- 
Posted via http://www.ruby-forum.com/.