Next: Classes: Static Variables 1
Up: Java Notes
Previous: Classes: Access Modifiers
- Belongs to Class
- All instances of class share it
- Only 1 copy
-
static
-
public static
(global)
-
public static final
(const)
-
private static
(class variables or methods)
- Static (class) methods callable without instance.
- Non-static methods require to be called from an instance.
- Example:
Ananda Amatya
9/15/1999