Index: trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/ExpressionFactory.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/ExpressionFactory.java	(revision 6898)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/ExpressionFactory.java	(revision 6899)
@@ -19,4 +19,5 @@
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
+import java.util.zip.CRC32;
 
 import org.openstreetmap.josm.Main;
@@ -204,4 +205,19 @@
 
         /**
+         * Create color from hsb color model. (arguments form 0.0 to 1.0)
+         * @param h hue
+         * @param s saturation
+         * @param b brightness
+         * @return the corresponding color
+         */
+        public static Color hsb_color(float h, float s, float b) {
+            try {
+                return Color.getHSBColor(h, s, b);
+            } catch (IllegalArgumentException e) {
+                return null;
+            }
+        }
+
+        /**
          * Creates a color value from an HTML notation, i.e., {@code #rrggbb}.
          */
@@ -552,4 +568,15 @@
         public static String XML_encode(String s) {
             return s == null ? null : XmlWriter.encode(s);
+        }
+
+        /**
+         * Calculate the CRC32 checksum from a string
+         * @param s the string
+         * @return long value from 0 to 2^32-1
+         */
+        public static long CRC32_checksum(String s) {
+            CRC32 cs = new CRC32();
+            cs.update(s.getBytes());
+            return cs.getValue();
         }
     }
