Grails: publish a plugin in a self-hosted maven repository

junio 10, 2013 at 10:08

Introduction and usage example of Grails Plugin Maven Deployer, a small scripting tool I created. The tool allows you to publish a plugin in a self-hosted maven repo by packaging it as a JAR file.

New Grails plugin – Timestamped

junio 3, 2013 at 09:46

A Grails plugin to inject the auto-timestamp properties using a configurable, joda-time compatible AST transform that can be used both by a project and by other plugins.

Grails – small and simple method to convert objects to JSON

enero 12, 2013 at 11:03

I was playing around with Grails and JSON and came up with a small method to convert a given collection of objects into JSON (typically, domain class objects, but it would work with anything). It’s nothing new or fancy, but maybe usefull for anybody who is starting to explore Grails [...]

Grails – generic methods for equals and hashCode calculation

diciembre 27, 2012 at 23:11

In modern versions of Grails, you can use the Groovy annotation EqualsAndHashCode for generating the equals and hashCode methods of your domain classes using an AST transformation, but if you are in any 1.x.x Grails version (that uses a Groovy version prior to 1.8.0), you won’t be able to use [...]

Bash – How to dynamically evaluate and set a variable

diciembre 19, 2012 at 16:54

One of the things that opens the gate to truly code reusation in Bash is, in my opinion, the hability of evaluate and set variables in a dynamic way. By dynamic, I mean that the variable name is constructed dynamically, or passed as a parameter, and ends up being in [...]

Groovy: using parameters with default values to separate method configuration from method body

noviembre 23, 2012 at 10:37

And with that huge title , I want to talk about a little technique that I like to use in Groovy by taking advantage of the method parameters with default values feature. By method configuration and method body I am refering to two typical parts of a business logic method [...]

Execute around pattern in Groovy

noviembre 7, 2012 at 11:41

The execute around pattern seems to be a common practice in fuctional related languages (although probably Rafael Luque would claim that, as almost everything else , made it first appearance in Smalltalk, and Marcin Gryszko would say that is just the old plain template method ), but it’s probably kind [...]

Java Fixed Hashtable (tabla hash de longitud fija en Java)

mayo 11, 2007 at 17:04

Recientemente he tenido la necesidad de implementar una tabla hash de longitud fija (es decir, cada elemento de la tabla es una lista enlazada con los distintos valores cuya clave tiene la misma hash en lenguaje Java por motivos que no vienen al caso . Busqué (escasamente, todo hay que [...]