Java AtomicIntegerArray.get(int i)

Syntax

AtomicIntegerArray.get(int i) has the following syntax.

public final int get(int i)

Example

In the following code shows how to use AtomicIntegerArray.get(int i) method.


import java.util.concurrent.atomic.AtomicIntegerArray;
/*www .ja v  a2 s  . com*/
public class Main {
  public static void main(String[] argv) throws Exception {
    AtomicIntegerArray atomicIntegerArray = new AtomicIntegerArray(10);
    
    System.out.println(atomicIntegerArray.get(3));
  }
}

The code above generates the following result.





















Home »
  Java Tutorial »
    java.util.concurrent.atomic »




AtomicBoolean
AtomicInteger
AtomicIntegerArray
AtomicLong
AtomicLongArray