What are the Atomic Operations in Java ?

Java language provides some basic Atomic operations. These operations can be used to make sure that concurrent threads always see the same value.

Some of these Atomic operations are...

  • Read operations on reference variables and primitive variables (except long and double) .
  • Write operations on reference variables and primitive variables (except long and double) .
  • Read operations on all variables declared as volatile.
  • Write operations on all variables declared as volatile.


You May Interest

What is the Reason For Overriding equals Method in Java ?

Why Do We Use JSP Instead of Servlet in Java ?

When is UnsupportedOperationException Thrown in Java ?

Enumeration and Iterator, Which One Has Better Performance in Jav ...

What is the Purpose of Thread Groups in Java ?