public class ResourceNameKeyedMap<T>
extends gnu.trove.THashMap<java.lang.String,T>
Map that treats all the keys as resources names. This class takes care of the key
flattening done by AAPT where '.', '-' and ':' are all replaced with '_' and will be able to find
resources with those characters in the name no matter the format. Because of that, for ResourceNameKeyedMap keys like 'my.key', 'my_key' and 'my-key' are exactly the same key.
ResourceNameKeyedMap will keep the original names given to the resources so calls to
THashMap.keySet() will return the names without modifications. Note that the set returned from
THashMap.keySet() uses the same strategy for normalizing strings, so it will equate resource
names that normalize to the same string in calls to Set.contains(Object) etc.
| Constructor and Description |
|---|
ResourceNameKeyedMap() |
ResourceNameKeyedMap(int expectedSize) |
clear, clone, containsKey, containsValue, entrySet, equals, forEachEntry, forEachKey, forEachValue, get, hashCode, keySet, put, putAll, rehash, remove, removeAt, retainEntries, setUp, toString, transformValues, valuescapacity, computeHashCode, contains, equals, forEach, index, insertionIndex, throwObjectContractViolationcalculateGrownCapacity, compact, ensureCapacity, isEmpty, postInsertHook, size, startCompactingOnRemove, stopCompactingOnRemove, trimToSize