if i call an interface method will it get the method body from implementation class and execute ?
Posted
by
sij
on Stack Overflow
See other posts from Stack Overflow
or by sij
Published on 2010-12-29T14:39:40Z
Indexed on
2010/12/29
14:54 UTC
Read the original article
Hit count: 138
please forgive me if i am wrong:
I have an interface Interface1
I have its implementation Imple implements Interface
(all methods hav been implemented :) )
now consider a third class CheckCall
can I do a call in the class CheckCall
like I mention below
Interface1 interface1;
interface1.method();
all necessary imports have been done. Please tell me is it possible or not , if not then ok and if yes then tell me what will happen if i have more than one impl classes for the same interface and i am doing the same call.
© Stack Overflow or respective owner