Java - Online Test - Interfaces - javasearch.buggybread.com


Share

Search Java Test Questions


 223 test questions in repository.




Java - Test Questions on 'interfaces' - 6 questions found


Interface can only have ...Core Java
Member elements and Methods.
Static Variables and Static Methods.
Static Final Variables and Instance Method Declarations.
Member Elements , Instance Methods, Static variables and Static Methods.

  java  oops  interfaces

Which method needs to be implemented if a class is implementing comparable interface ?Core Java
comp
compare
compareTo
compareEquals

  comparable  interfaces  compare  compareTo

If X implements Y and Y extends Z, Which of the following initialization is correct ?Core Java
X x = new Y();
X x = new Z();
Z z = new Y();
Z z = new X();

  interfaces

If class A implements X interface, and Class B implements Y interface, and X is the parent of Y, Which of the following initialization is correct ?Core Java
A a = new B();
Y y = new A();
X x = new B();
Y y = new A();

  interfaces   inheritance

Which of the following is a Marker Interface ?Core Java
Runnable
Serializable
Cloneable
Both Serializable and Cloneable

  marker interface  interfaces

Which of following is not core interface of Hibernate ?Hibernate
Session
Transaction
SessionFactory
TransactionFactory

  Hibernate  hibernate Core Interface







comments powered by Disqus