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...

How to call static method?

Answer Posted / maharajan j

Static methods we can call without class reference.We don't
need to create an object of that particular class.

For example:
class A{

static void disp(){
sysout("Java")
}
}
class B{

B(){
A.disp();
}

}

Is This Answer Correct ?    13 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many types of voids are there?

919


What is the public method modifier?

952


What is the difference between replace and replace all?

944


Can we override constructors?

939


Explain the features of interfaces in java?

924


How we can run a jar file through command prompt in java?

912


What is boolean used for?

985


Tell me a few examples of final classes defined in Java API?

1015


What is final keyword?

1086


What is the file type?

963


What is the difference between static and non-static variables in java programming?

912


What does string mean in java?

1038


What does arrays sort do in java?

960


What are the types of java languages?

929


Why is String immutable?

1015