Categories:
.NET (961)
C (387)
C++ (185)
CSS (84)
DBA (8)
General (31)
HTML (48)
Java (641)
JavaScript (220)
JSP (109)
JUnit (31)
MySQL (297)
Networking (10)
Oracle (562)
Perl (48)
Perl (9)
PHP (259)
PL/SQL (140)
RSS (51)
Software QA (28)
SQL Server (5)
Struts (20)
Unix (2)
Windows (3)
XHTML (199)
XML (59)
Other Resources:
Is there any other way that you can achieve inheritance in Java?
Is there any other way that you can achieve inheritance in Java?
✍: Guest
There are a couple of ways. As you know, the straight way is to "extends" and/or "implements". The other way is to get an instance of the class to achieve the inheritance. That means to make the supposed-super-class be a field member. When you use an instance of the class, actually you get every function available from this class, but you may lose the dynamic features of OOP
2012-08-29, 2087👍, 0💬
Popular Posts:
What is the difference between strings and character arrays? A major difference is: string will have...
What exactly happens when ASPX page is requested from Browser? Note: - Here the interviewer is expec...
How To Run Stored Procedures in Debug Mode? - Oracle DBA FAQ - Introduction to Oracle SQL Developer ...
Where Do You Download JUnit? Where do I download JUnit? I don't think anyone will ask this question ...
If we inherit a class do the private variables also get inherited ? Yes, the variables are inherited...