This week's book giveaway is in the OCAJP forum. We're giving away four copies of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) and have Khalid A Mughal & Rolf W Rasmussen on-line! See this thread for details.
i asked this question before but did not receive a satisfactory reply. thanks
posted 15 years ago
Hi sarim, yes of course both abstract/native methods be called. just think if a method can not be called then what is it for??? Now the thing is that what are the restrictions/conditions in calling them. 1) You should call a abstract method only if u have implemented the abstract method/u have provided the native code for the native method. If u keep the above rule in mind then u won't have any problem. I'm giving you an example.
run the above code and u'll see that it runs perfectly. similarly native methods can be called provided u have got the native code in place. regards Deekasha