public void putEncodedProperty(String token) {

    int index = token.indexOf(':');
    if (index == -1) throw new IllegalArgumentException("invalid encoded property: " + token);

    String key = token.substring(0, index);
    token = token.substring(index + 1);

    index = token.indexOf(':');
    if (index == -1) throw new IllegalArgumentException("invalid encoded property: " + token);

    EAlertPropertyType type = EAlertPropertyType.valueOf(token.substring(0, index));
    String value = token.substring(index + 1);

    putProperty(key, type, value);
  }
 public AlertProperties subset(String... keys) {
   AlertProperties sub = new AlertProperties();
   for (String key : keys) sub.putProperty(key, getProperty(key));
   return sub;
 }
 public void putProperty(String key, EAlertPropertyType type, String value) {
   putProperty(key, new AlertProperty(type, value));
 }