Aug 172012

There are many ways to update a value atomically, so without introducing racing conditions in multithreaded environments. A well-performing way of doing this in Java is to use an AtomicReference or one of its companion classes in the package java.util.concurrent.atomic. However, using an AtomicReference is quite cumbersome. But with Scala, you can easily factor out the cumbersome usage pattern like follows. Continue reading »

 Comments Off on Generic CAS (compare-and-set) for Scala  Tagged with: ,
Oct 042011

I have updated the archetype for JavaFX 2.0 applications in Scala to version 0.4 in order to reflect the release of JavaFX 2.0. Note that the environment variable JAVAFX_HOME must now refer to the base installation directory of the JavaFX 2.0 SDK, not the bin subdirectory anymore. Here are the updated Maven coordinates for the archetype:


 Comments Off on Updated Maven archetype for JavaFX 2.0 in Scala  Tagged with:
Sep 132011

I’m sick of Java’s low abstraction level which implies lots of coding overhead/boilerplate, so I’ve just started looking at Scala. While the language is definitely appealing, setting up my tool chain was not such a pleasant ride because the information I needed was dispersed across many web pages and well hidden between obsoleted or misleading information. This post shows what I did to succeed so you can use it as a guide line. Continue reading »

 Comments Off on How to set up Scala 2.8.1 with NetBeans 7.0.1 and Maven 3.0.3  Tagged with: , ,