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 do you use, call, and access a static method in Java?

Answer Posted / glibwaresoftsolutions

• The static keyword needs to appear before the method name.
• Use the class (className.methodName) to invoke a static method.
• No non-static instance variables or methods can be accessed by static methods.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the swingutilities.invokelater(runnable) method for? : Java thread

997


Can we call the run() method instead of start()?

991


What is the use of default method in interface in java?

973


What is the base class for error and exception?

952


What is the function of static in java?

1023


What is variable and its types?

977


How to split arraylist elements in java?

1109


Is finalize() similar to a destructor?

984


What are the differences between throw and throws?

1035


What is oops in java?

963


What is java util concurrentmodificationexception?

876


Explain the selection sort algorithm and state its time complexity?

977


What is a bubble sort in java?

908


What is serialization in java?

1017


What are internal and external variables?

916