- 博客(1)
- 资源 (2)
- 收藏
- 关注
转载 Java中的volatile关键字
我们知道,在Java中设置变量值的操作,除了long和double类型的变量外都是原子操作,也就是说,对于变量值的简单读写操作没有必要进行同步。这在JVM 1.2之前,Java的内存模型实现总是从主存读取变量,是不需要进行特别的注意的。而随着JVM的成熟和优化,现在在多线程环境下 volatile关键字的使用变得非常重要。在当前的Java内存模型下,线程可以把变量保存在本地内存(比如机器的寄存
2013-04-22 16:14:17 670
Next Generation Java Testing TestNG
Doing the right thing is rarely easy. Most of us should probably eat better,
exercise more, and spend more time with our families. But each day, when
confronted with the choice of being good or doing the easy thing, we often
choose the easy thing because, well, it’s easier.
It is the same way with software testing. We all know that we should
spend more effort on testing, that more testing will make our code more
reliable and maintainable, that our users will thank us if we do, that it will
help us better understand our own programs, but each day when we sit
down to the computer and choose between writing more tests and writing
more application code, it is very tempting to reach for the easy choice.
2015-10-08
OCA Java SE 7 Programmer I Certification Guide
OCA Java SE 7 Programmer I Certification Guide
2014-03-17
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人