Friday, June 26, 2009

Michael Jackson took over iTunes Store


In today's iTunes Store Top 10 album, nine of them are from Michael Jackson. I don't think there is anyone in the world can achieve the same for the next 20 years. Michael Jackson is part of everyone's childhood memory. He is a great artist and inspired people of the whole world. Thank you Michael Jackson.

There are a lot of his work not being published properly. Some of them is because record label think it is not proper for the market. I hope the record label can release all his work regardless of the sensitivity of the content.

By the way, where can I buy (buy) the song "Hold My Hand" ft. Akon and Michael Jackson?

Wednesday, June 24, 2009

Eclipse on Cocoa

Today is Eclipse's yearly release day. The new version (Galileo) on Mac OS X starts support on Cocoa framework. It won't look any different, but hopefully the easier coding style will attract more developers for Mac SWT development.

Sunday, June 14, 2009

Dependency Injection might become official (JSR 330)

Finally all the popular dependency injection (DI) experts in Java platform sits down together. JSR 330 is lead by the founder of Google Guice and the Spring Framework. The effort is also supported by the founder of PicoContainer, Plexus and Tapestry IoC.

Here is my understanding of three popular Java SE dependency injection containers:

Spring DI configuration is mainly XML based. It allow you to use pre Java 5 classes for dependency injection. Setter injection is the preferred style. All Java classes can be used for injection without noticing the Spring framework in advance. This allow legacy code to retrofit into the framework.

PicoContainer is by far the lightest DI container in Java. It is small enough to run on mobile devices. PicoContainer uses mainly class-based configuration. The configuration file is a Java class itself. Constructor injection is more common in PicoContainer, and the code base is so stable it did not get any update for years.

Guice is an annotation based container. This means it requires Java 5 and later, both for the classes being injected, as well as the classes receive injected objects. Guice is significantly easier to use due to the annotation. Unlike the other two containers above, projects that use Guice will have direct compilation dependency if Guice jar files, also due to the nature of Java annotation. I guess that's why people what to put it into standard Java SDK - so we don't need to make a choice anymore.

I hope the the final result will be as easy to use as Google Guice.