The following are class, method, or variable
modifiers:
·
abstract a method or class that can not be instantiated, and
which may define methods to be overwritten.
·
class keyword used to specify a class.
·
extends used to indicate the super-class that a subclass is
extending.
·
final makes it impossible to extend a class, override a
method, or reinitialize a variable.
·
implements used to indicate the interfaces that a class will use.
·
interface keyword used to specify an interface.
·
native indicates a method is written in a platform-dependant
language, such as C.
·
new used to instantiate an object by invoking the
constructor method.
·
static makes a method or variable belong to a class.
·
synchronized indicates that a method can be accessed by only one
thread at a time.
·
transient indicates which variables are not to have their data
written to an ObjectStream.
·
volatile indicates a variable may change out of sync due to its
usage in threads.
Variables
|
Methods
|
Classes
|
|
Access Modifiers
|
|||
private
|
x
|
x
|
|
protected
|
x
|
x
|
|
none (default)
|
x
|
x
|
x
|
public
|
x
|
x
|
x
|
Special Modifiers(Not
Access Modifiers)
|
|||
abstract
|
x
|
x
|
|
final
|
x
|
x
|
x
|
native
|
x
|
||
static
|
x
|
x
|
x
|
synchronized
|
x
|
x
|
|
transient
|
x
|
||
volatile
|
x
|