lördag 30 augusti 2008

FindBugs is cool

This week we started to use a new tool in our biggest project called FindBugs. I read about this tool in Java Power Tools.

What this tool does is to find code that has bugs or has some other errors that you should take care of. These are issues that you compiler wont tell you.
Some examples:

You need a instance of Long and you do like this:
Long l = new Long(1);

if (l != null && l.equals("null")){
....

Java compiler wont say anything but probably you will get in trouble when this code is executed because you executing equals againts a String instance.

Another example is that how you should create Number instances:
Long l = new Long(1);

Better way is using Long.valueOf(1) and this is what findbugs will tell you.
Or in some situationes using autoboxing.

These are only some examples and there a lot of more situations where FindBugs will help you.

We have a small project with about 10 classes and a couple of thousand lines of code. I used FindBugs on it and cleared all warnings and errors. There where about 100 of those before. Extremly cool to have something not generating the smallest warning.

This tool was extremly simple to install in Eclipse (http://findbugs.cs.umd.edu/eclipse/) and to make a task for it in Ant is 5 minute work.
Now im thinking what tool we could start using in the project next week.

måndag 25 augusti 2008

Google is cool

I was looking around in Google labs to find some cool stuff and acctually i did ! :-)

I found http://www.lively.com/popular. I played around and started too feel like a children that plays around :-)

Its a three dimensional world where you can interact with others. Not not only chat, you kiss them, hug them, shake their hands or even kick their asses! Little violent put pretty cool :-)

I say try it, probably you a couple of hours to spend in there.

Who am i

Im a system developer working at Mobispine . We have a product called eSMS which is used for sending SMS/MMS from computers and its mainly the product i work with .

Im a Java guy and this blog will mainly be about my experience and opinions in different isues concerning Java and other cool tehnologies.
Hope someone likes it, otherwise dont read it :-)