Static
:
access modifier. Signa: Variable-Static int b; Method- static
void meth(int x)
Ø
When a
member is declared as Static, it can be accessed before any objects of its
class are created and without reference to any object. Eg : main(),it must call
before any object exit.
Ø
Static
can be applied to Inner classes, Variables and Methods.
Local
variables can’t be declared as static.
A static
method can access only static Variables. and they can’t refer to this or
super in any way.
Static
methods can’t be abstract.
A static
method may be called without creating any instance of the class.
Only one
instance of static variable will exit any amount of class instances.