How multipleInheritance is possible in java?
Answer Posted / uthrakumar-wipro technologies
multiple inheritance is not possible in java but we can
apply the multiple inheritance concept using interfaces in
java but it doesn't meant that java will support multiple
inheritance rather we can implement the idea of multiple
inheritance as follows......
eg:
<class name> implements <class1>,<class2>,...
{
}
but the interface technique will not gives the
exact definition of multiple inheritance.....
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Can there be an abstract method without an abstract class?
What is command line argument
What is the concatenation operator in java?
what is meant wrapper classes?
What are the different ways to handle exceptions?
What is ternary operator?
What is thread safe java?
Draw a UML class diagram for the code fragment given below: public class StringApplet extends Applet { private Label sampleString; private Button showTheString; private ButtonHandler bHandler; private FlowLayout layout; public StringApplet() { sampleString = new Label(" "); showTheString = new Button (" Show the String"); bHandler = new ButtonHandler(); layout = new FlowLayout(); showTheString.addActionListener(bHandler); setLayout(layout); add(sampleString); add(showTheString); } class ButtonHandler implements ActionListener { public void actionPerformed(ActionEvent e) { samplestring.setText("Good Morning"); } } } Note: The methods need not be indicated on the diagram.
What are daemon Threads in java?
What is meant by method overriding?
Similarity and difference between static block and static method ?
Can interface be private in java?
What is lastindexof in java?
Can a abstract class be declared final?
What is an infinite loop in java? Explain with an example.