Posted November 25th, 2011 by Julien
How could I not see this till now? Here is a very usefull piece of info that I stumbled upon while reading Play Framework doc: The play.db.jpa.Model defines a set of generic methods. These generic methods use a type parameter to specify the method’s return type. When using those methods, the concrete type to be [...]
Tags: generics, java, language, tip
Posted February 24th, 2010 by Julien
… is neat! At the beginning of a project, everybody in the team agrees to make things properly, identify layers, isolate responsibilities, code with defined formatting rules, etc. But after a few weeks, rules tend to be bent and laxism is all over the place. Formatting rules can be checked at code-time using Checkstyle Eclipse [...]
Tags: architecture, checkstyle, java, test, unit
Posted February 23rd, 2010 by Julien
I was modifying someone else’s code the other day and I was looking at something I find awful : if (condition == true) { someThing(); } else { someOtherThing(); } And I was thinking “ok, this is ugly but whatever…” but if I had to work full-time on this project, I don’t think I could [...]
Tags: formatting, java, rules
Posted January 22nd, 2010 by Julien
TheServerSide has recently published part 2 of an article explaining the Contexts & Dependency Injection (CDI) in JEE6. It seems to be very interesting. Part 1 Part 2 I particularly like this extract from part 1 : If you are familiar with Spring IoC, CDI is likely to feel more type-safe, futuristic and annotation-driven. Seam [...]
Tags: guice, ioc, java, jee6, reading
Posted November 26th, 2009 by Julien
Recently I have been working on a internal component providing features similar to a rule engine. This component is embedded into live applications and as its behaviour can be tricky and time consuming, we had to provide a way to monitor method calls to this inner component. We used the JETM library to monitor method [...]
Tags: java, jetm, library, monitoring, statistics
Posted August 6th, 2009 by Julien
Recently I realized that Lightroom (Adobe image organizer for photographers) did not allow to display easily which focal lengths were mostly used and which ones are not (a focal length is the equivalent to a zoom factor, in a nutshell). It did not really annoy me but a coworker said to me “it would not [...]
Tags: exif, homemade, image, java, sanselan, statistics
Posted April 19th, 2009 by Julien
I was recently asked the question of what tool to use in order to compare two xml files. I had no good answer to give… I mainly use notepad++ to deal with xml files. And what I do is only browsing them looking for a particular tag, searching them and so on. I don’t need [...]
Tags: c++, diff, java, library, xml