Monthly Archives: April 2010
I was going through Chris Pine’s excellent “Learn to Program“, re-doing all of the exercises in Groovy (since it’s Ruby-centric). I ran across one where I need to get user input. Ruby’s got its easy “gets” method; what about Groovy? … Continue reading
We’ve got a Drools rule that contains this line in the consequence:eval(!StringUtils.containsAny((String)$rv, “neg”) )Uh uh. Can’t use the bang (!) to test for negation in the eval() statement. Won’t compile. Instead, we have to do this:eval(StringUtils.containsAny((String)$rv, “neg”) == false) This … Continue reading
I still go back and forth between development in gvim and gedit. Until I finally settle, I’ve needed to figure out a way to change the default/startup window size of gvim.To do so, open up ~/.vimrc in a text editor. … Continue reading
Sooner or later you know that I would weigh in on editors for Groovy and Grails. I’ve tried ’em all–heavyweight IDE’s like Intellij, Netbeans, and Eclipse (I’ve listed those in preferential order), specialized editors like python’s SPE, commercial offerings like … Continue reading
In the Java world, we don’t get closures until Java 7. Groovy already has them. Here’s what I’ve learned about these important programming structures, and why they’re powerful.
Just something interesting I came across in Dierk Koenig et al.’s excellent Groovy In Action (Manning): Groovy is not like other scripting languages that are processed line-by-line. Groovy code is fully parsed and a class is generated from the information … Continue reading
Note: I’ve been learning Groovy of late. It helps me learn a concept if I can ‘splain it, so I’ll be posting things I come across in an attempt to explain it written form. Dig?