Under what circumstances an object reference be cast to an
interface reference?
Answers were Sorted based on User's Feedback
Answer / muthusenthil
when a class implements an interface then an object
referance of that class can be casted to interface referance
class A implements B{
public static void main(String args[]){
B b=new A();
}
| Is This Answer Correct ? | 6 Yes | 1 No |
Answer / janet
When the object implements the referenced interface, an
object reference be cast to an interface reference.
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / debapriya maity
Exactly whenever ur entity passed the IS-A Test ,
A is B :)
| Is This Answer Correct ? | 1 Yes | 0 No |
How many digits can a float hold?
How to initialize an Applet ?
What are internal and external variables?
What is meant by controls and types?
What do you mean by platform independence?
What are virtual functions?
Java is based on pass by reference or pass by value ..
How does predicate work in java?
What do you mean by local variable and instance variable?
Why call by value prevents parameter value change?
how to get the max salary and name of employee from arraylist without using the Comperator or even Comparable interface?
Difference between JDK, JRE, JVM
16 Answers Deloitte, HCL, Mind Tree, Oracle, Reliance, TCS, ThinkBox,