Date: July 30, 2010
A Groovy function demonstrating how to replace high-level Unicode characters with their HTML entity equivalents. The entitize function iterates through a string, converting characters with code points above 127 to numeric character references like € for the Euro symbol, useful for HTML/XML output.