You can access the keys through the function allKeys().
Access to the objects stored for each key is given through the function objectForKey(String key).
java.util.LinkedHashMap
| Modifier and Type | Field and Description |
|---|---|
| private final HashMap |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public String[] | Returns: The list of all keys used in this NSDictionary.Gets a list of all keys used in this NSDictionary. |
| pack-priv void | assignIDs(BinaryPropertyListWriter out)
Overrides com. Assigns IDs to all the objects in this NSObject subtree. |
| public void | |
| public NSDictionary | clone()
Implements abstract com. Creates and returns a deep copy of this instance. |
| public int | compareTo(NSObject o)
Implements java. Compares this object with the specified object for order. |
| public boolean | containsKey(Object key)
Implements java. Returns |
| public boolean | Returns: Whether the key is contained in this dictionary.The key that will be searched for. key)Checks whether a given key is contained in this dictionary. |
| public boolean | containsValue(Object value)
Implements java. Returns |
| public boolean | Returns: Whether the key is contained in this dictionary.The value that will be searched for. val)Checks whether a given value is contained in this dictionary. |
| public boolean | Returns: Whether the key is contained in this dictionary.The value that will be searched for. val)Checks whether a given value is contained in this dictionary. |
| public boolean | Returns: Whether the key is contained in this dictionary.The value that will be searched for. val)Checks whether a given value is contained in this dictionary. |
| public boolean | Returns: Whether the key is contained in this dictionary.The value that will be searched for. val)Checks whether a given value is contained in this dictionary. |
| public boolean | Returns: Whether the key is contained in this dictionary.The value that will be searched for. val)Checks whether a given value is contained in this dictionary. |
| public boolean | Returns: Whether the key is contained in this dictionary.The value that will be searched for. val)Checks whether a given value is contained in this dictionary. |
| public boolean | Returns: Whether the key is contained in this dictionary.The value that will be searched for. val)Checks whether a given value is contained in this dictionary. |
| public int | |
| public Set | entrySet()
Implements java. Returns a |
| public boolean | equals(Object obj)
Overrides java. Implements java. Compares the specified object with this map for equality. |
| public NSObject | get(Object key)
Implements java. Returns the value to which the specified key is mapped,
or |
| public HashMap | Returns: The hash map which is used by this dictionary to store its contents.Gets the hash map which stores the keys and values of this dictionary. |
| public int | hashCode()
Overrides java. Implements java. Returns the hash code value for this map. |
| public boolean | |
| public Set | |
| public NSObject | |
| public NSObject | Returns: The value previously associated to the given key, or null, if no value was associated to it.The key. key, NSObject The value. obj)Implements java. Puts a new key-value pair into this dictionary. |
| public NSObject | Returns: The value previously associated to the given key, or null, if no value was associated to it.The key. key, Object The value. Supported object types are numbers, byte-arrays, dates, strings and arrays or sets of those. obj)Implements java. Puts a new key-value pair into this dictionary. |
| public void | putAll(Map<? extends String, ? extends NSObject> values)
Implements java. Copies all of the mappings from the specified map to this map (optional operation). |
| public NSObject | |
| public NSObject | remove(Object key)
Implements java. Removes the mapping for a key from this map if it is present (optional operation). |
| public int | |
| protected void | toASCII(StringBuilder ascii, int level)
Implements abstract com. Generates the ASCII representation of this object. |
| protected void | toASCIIGnuStep(StringBuilder ascii, int level)
Implements abstract com. Generates the ASCII representation of this object in the GnuStep format. |
| public String | Returns: ASCII representation of this object.Generates a valid ASCII property list which has this NSDictionary as its root object. |
| pack-priv void | toBinary(BinaryPropertyListWriter out)
Implements abstract com. Generates the binary representation of the object. |
| public String | Returns: GnuStep ASCII representation of this object.Generates a valid ASCII property list in GnuStep format which has this NSDictionary as its root object. |
| public Object | toJavaObject()
Implements abstract com. Converts this NSObject into an equivalent object of the Java Runtime Environment. |
| pack-priv void | toXML(StringBuilder xml, int level)
Implements abstract com. Generates the XML representation of the object (without XML headers or enclosing plist-tags). |
| public Collection | values()
Implements java. Returns a |
| dict | back to summary |
|---|---|
| private final HashMap<String, NSObject> dict | |
| NSDictionary | back to summary |
|---|---|
| public NSDictionary() Creates a new NSDictionary instance. | |
| allKeys | back to summary |
|---|---|
| public String[] allKeys() Gets a list of all keys used in this NSDictionary.
| |
| assignIDs | back to summary |
|---|---|
| pack-priv void assignIDs(BinaryPropertyListWriter out) Overrides com. Doc from com. Assigns IDs to all the objects in this NSObject subtree.
| |
| clear | back to summary |
|---|---|
| public void clear() Implements java. Removes all key-value pairs from this dictionary.
| |
| clone | back to summary |
|---|---|
| public NSDictionary clone() Implements abstract com. Doc from com. Creates and returns a deep copy of this instance.
| |
| compareTo | back to summary |
|---|---|
| public int compareTo(NSObject o) Implements java. Doc from java. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object. The implementor must ensure The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that
| |
| containsKey | back to summary |
|---|---|
| public boolean containsKey(Object key) Implements java. Doc from java. Returns | |
| containsKey | back to summary |
|---|---|
| public boolean containsKey(String key) Checks whether a given key is contained in this dictionary.
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(Object value) Implements java. Doc from java. Returns | |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(NSObject val) Checks whether a given value is contained in this dictionary.
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(String val) Checks whether a given value is contained in this dictionary.
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(long val) Checks whether a given value is contained in this dictionary.
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(double val) Checks whether a given value is contained in this dictionary.
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(boolean val) Checks whether a given value is contained in this dictionary.
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(Date val) Checks whether a given value is contained in this dictionary.
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(byte[] val) Checks whether a given value is contained in this dictionary.
| |
| count | back to summary |
|---|---|
| public int count() Counts the number of contained key-value pairs.
| |
| entrySet | back to summary |
|---|---|
| public Set Implements java. Doc from java. Returns a | |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Implements java. Doc from java. Compares the specified object with this map for equality. Returns
| |
| get | back to summary |
|---|---|
| public NSObject get(Object key) Implements java. Doc from java. Returns the value to which the specified key is mapped,
or More formally, if this map contains a mapping from a key
If this map permits null values, then a return value of
| |
| getHashMap | back to summary |
|---|---|
| public HashMap Gets the hash map which stores the keys and values of this dictionary. Changes to the hash map are directly reflected in this dictionary. | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Implements java. Doc from java. Returns the hash code value for this map. The hash code of a map is
defined to be the sum of the hash codes of each entry in the map's
| |
| isEmpty | back to summary |
|---|---|
| public boolean isEmpty() Implements java. Doc from java. Returns | |
| keySet | back to summary |
|---|---|
| public Set Implements java. Doc from java. Returns a | |
| objectForKey | back to summary |
|---|---|
| public NSObject objectForKey(String key) Gets the NSObject stored for the given key. | |
| put | back to summary |
|---|---|
| public NSObject put(String key, NSObject obj) Implements java. Puts a new key-value pair into this dictionary. If the value is null, no operation will be performed on the dictionary. | |
| put | back to summary |
|---|---|
| public NSObject put(String key, Object obj) Implements java. Puts a new key-value pair into this dictionary. If key or value are null, no operation will be performed on the dictionary. | |
| putAll | back to summary |
|---|---|
| public void putAll(Map<? extends String, ? extends NSObject> values) Implements java. Doc from java. Copies all of the mappings from the specified map to this map
(optional operation). The effect of this call is equivalent to that
of calling | |
| remove | back to summary |
|---|---|
| public NSObject remove(String key) Removes a key-value pair from this dictionary. | |
| remove | back to summary |
|---|---|
| public NSObject remove(Object key) Implements java. Doc from java. Removes the mapping for a key from this map if it is present
(optional operation). More formally, if this map contains a mapping
from key Returns the value to which this map previously associated the key,
or If this map permits null values, then a return value of
The map will not contain a mapping for the specified key once the call returns. | |
| size | back to summary |
|---|---|
| public int size() Implements java. Doc from java. Returns the number of key-value mappings in this map. If the
map contains more than | |
| toASCII | back to summary |
|---|---|
| protected void toASCII(StringBuilder ascii, int level) Implements abstract com. Doc from com. Generates the ASCII representation of this object. The generated ASCII representation does not end with a newline. Complies with the Old-Style ASCII Property Lists definition.
| |
| toASCIIGnuStep | back to summary |
|---|---|
| protected void toASCIIGnuStep(StringBuilder ascii, int level) Implements abstract com. Doc from com. Generates the ASCII representation of this object in the GnuStep format. The generated ASCII representation does not end with a newline.
| |
| toASCIIPropertyList | back to summary |
|---|---|
| public String toASCIIPropertyList() Generates a valid ASCII property list which has this NSDictionary as its root object. The generated property list complies with the format as described in Property List Programming Guide - Old-Style ASCII Property Lists.
| |
| toBinary | back to summary |
|---|---|
| pack-priv void toBinary(BinaryPropertyListWriter out) throws IOException Implements abstract com. Doc from com. Generates the binary representation of the object.
| |
| toGnuStepASCIIPropertyList | back to summary |
|---|---|
| public String toGnuStepASCIIPropertyList() Generates a valid ASCII property list in GnuStep format which has this NSDictionary as its root object. The generated property list complies with the format as described in GnuStep - NSPropertyListSerialization class documentation
| |
| toJavaObject | back to summary |
|---|---|
| public Object toJavaObject() Implements abstract com. Doc from com. Converts this NSObject into an equivalent object of the Java Runtime Environment.
| |
| toXML | back to summary |
|---|---|
| pack-priv void toXML(StringBuilder xml, int level) Implements abstract com. Doc from com. Generates the XML representation of the object (without XML headers or enclosing plist-tags).
| |
| values | back to summary |
|---|---|
| public Collection Implements java. Doc from java. Returns a | |