A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Java SE 8 for the Really Impatient
this week in the
Programmer Certification (SCJP/OCPJP)
methods (class and instance)
Joined: Sep 03, 2007
Oct 28, 2007 00:46:00
whats the difference between class methods and instance methods?!
boolean b = true;<br />System.out.println ("I believe in Java.<br />Java will make my dream come " + b);
Joined: Aug 31, 2004
Oct 28, 2007 00:52:00
A class method is declared with the keyword "static." This means it can be called using the class, even if no instance of that class is created.
An instance method is not static. It must be called using an instance.
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award."
I agree. Here's the link:
subject: methods (class and instance)
Static and Non static Synchronized methods
Lock on hidden and hiding static method.
abstract class and "this"
Two sync methods of same class called by two threads
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014