Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


can we have virtual functions in java?

Answers were Sorted based on User's Feedback



can we have virtual functions in java?..

Answer / bindhu solomon

In java, all methods are virtual functions by default. So
we can override a method in any subclasses .

Is This Answer Correct ?    123 Yes 24 No

can we have virtual functions in java?..

Answer / magan

By default all the methods are virtual functions in java.
So there is no need of virtual functions.

Is This Answer Correct ?    57 Yes 18 No

can we have virtual functions in java?..

Answer / meera

virtual functions are abstract methods in java. by default
all the methods are abstract in interface.

Is This Answer Correct ?    60 Yes 37 No

can we have virtual functions in java?..

Answer / rakesh kumar jha

In java all method use dynamic method lookup and therefore
are be default virtual. so there is no way to explicity
call an overriden base class method, but overwriting can be
prevented by declare a method final.

Is This Answer Correct ?    29 Yes 12 No

can we have virtual functions in java?..

Answer / amar

In object-oriented programming, a virtual function or
virtual method is one whose behavior can be overridden
within an inheriting class by a function with the same
signature. irtual functions are abstract methods in java. by
default
all the methods are abstract in interface.

Is This Answer Correct ?    20 Yes 6 No

can we have virtual functions in java?..

Answer / mohan

In java all non static methods are virtual functions by
default.. so there is no need to explicitly specify the
virtual keyword..

Is This Answer Correct ?    16 Yes 2 No

can we have virtual functions in java?..

Answer / dhawal

all methods in java are virtual.

Is This Answer Correct ?    21 Yes 8 No

can we have virtual functions in java?..

Answer / abdul nasir

virtual functions are present in java. but there is no need to write virtual with methods because it is built-in in java. you can override and call with their respective class objects and references directly........... :) b hapy dont confuse. programer is here.

Is This Answer Correct ?    0 Yes 1 No

can we have virtual functions in java?..

Answer / krishna

First of all that I would like to tell u that there is no keyword like virtual in Java. and all the guys are saying that all methods are virtual in Java. But it is not true.
While we try to override private methods then it is not override. this shows all the methods are not virtual in Java.

Is This Answer Correct ?    5 Yes 10 No

can we have virtual functions in java?..

Answer / krishna

what virtual bebeen abstract diffrance

Is This Answer Correct ?    2 Yes 13 No

Post New Answer

More Core Java Interview Questions

Make a data structure and implement an algorithm to print all the files in a directory. (The root directory can have sub-directories too.)

0 Answers   Amazon,


Can we serialize static variables in java?

0 Answers  


How to call static method?

4 Answers   Epoch,


What is the benefit of inner / nested classes ?

0 Answers  


Are strings immutable in java?

0 Answers  


How can we get one Interface methods whit out using implementation of interface

1 Answers   Oracle,


Can an abstract class be final?

10 Answers  


what is the role of xml in core java?? and how we can use it?? can somebody give a sample program with explanation and from where i can read more about xml?????

0 Answers   HCL, SAP Labs, Vital Soft,


What is a war file?

0 Answers  


Which methods are used during serialization and deserialization process?

0 Answers  


What is lazy activation?

2 Answers   CMC,


How many threads can I run java?

0 Answers  


Categories