Ordered version of NSDictionary
backed by a NSOrderedSet
.
The main purpose of this class is to provide a guaranteed order to a NSDictionary
as the keys are set on the dictionary. The standard NSDictionary
does not keep the order of items as they are entered, where as RDHOrderedDictionary
uses a NSOrderedSet
as its key storage. As well as meaning that the key order is kept constant, it also means various methods are available such as firstKey
and firstValue
(also lastKey
and lastValue
) for convenient accessing of entries.