buffer.append('}');
return buffer.toString();
}
+
+ /**
+ * Method added for Jalview to increment a key's value if present, else add it
+ * with the value 1
+ *
+ * @param key
+ */
+ public void increment(int key)
+ {
+ int i = ContainerHelpers.binarySearch(mKeys, mSize, key);
+ if (i >= 0)
+ {
+ mValues[i]++;
+ }
+ else
+ {
+ put(key, 1);
+ }
+ }
}