package com.gochinatv.cdn.api.jdk.atomic;

import java.util.concurrent.atomic.AtomicBoolean;

import org.junit.Test;

/**
 * 原子boolean
 * @author jacktomcat
 *
 */
public class AtomicBooleanTest {

	@Test
	public void test(){
		AtomicBoolean ab = new AtomicBoolean(true);
		
		
	}
}

@@ -89,18 +89,16 @@
 olean;%0D%0A
-%0D%0A
 import o
@@ -115,16 +115,18 @@
 est;%0D%0A%0D%0A
+%0D%0A
 /**%0D%0A * 
@@ -283,20 +283,387 @@
 ue);%0D%0A%09%09
-%0D%0A%09%09
+System.out.println(ab.get());//true%0D%0A%09%09%0D%0A%09%09ab.set(false);%0D%0A%09%09System.out.println(ab.get());//false%0D%0A%09%09%0D%0A%09%09boolean andSet = ab.getAndSet(true);%0D%0A%09%09System.out.println(andSet);//false%0D%0A%09%09System.out.println(ab.get());//true%0D%0A%09%09%0D%0A%09%09%0D%0A%09%09//%E8%80%8ClazySet()%E7%9A%84%E7%94%A8%E6%B3%95%EF%BC%8C%E5%B0%B1%E6%98%AF%E5%9C%A8%E4%B8%8D%E9%9C%80%E8%A6%81%E8%AE%A9%E5%85%B1%E4%BA%AB%E5%8F%98%E9%87%8F%E7%9A%84%E4%BF%AE%E6%94%B9%E7%AB%8B%E5%88%BB%E8%AE%A9%E5%85%B6%E4%BB%96%E7%BA%BF%E7%A8%8B%E5%8F%AF%E8%A7%81%E7%9A%84%E6%97%B6%E5%80%99%EF%BC%8C%E4%BB%A5%E8%AE%BE%E7%BD%AE%E6%99%AE%E9%80%9A%E5%8F%98%E9%87%8F%E7%9A%84%E6%96%B9%E5%BC%8F%E6%9D%A5%E4%BF%AE%E6%94%B9%E5%85%B1%E4%BA%AB%E7%8A%B6%E6%80%81%EF%BC%8C%E5%8F%AF%E4%BB%A5%E5%87%8F%E5%B0%91%E4%B8%8D%E5%BF%85%E8%A6%81%E7%9A%84%E5%86%85%E5%AD%98%E5%B1%8F%E9%9A%9C%EF%BC%8C%E4%BB%8E%E8%80%8C%E6%8F%90%E9%AB%98%E7%A8%8B%E5%BA%8F%E6%89%A7%E8%A1%8C%E7%9A%84%E6%95%88%E7%8E%87%E3%80%82%0D%0A%09%09ab.lazySet(false);%0D%0A%09%09System.out.println(ab.get());
 %0D%0A%09%7D%0D%0A%7D%0D

add atomicboolean support