K
- type of key contentsV
- type of value contentspublic class NSDictionary<K,V> extends Object implements Cloneable, Serializable, com.webobjects.foundation.NSCoding, com.webobjects.foundation.NSKeyValueCoding, com.webobjects.foundation.NSKeyValueCodingAdditions, com.webobjects.foundation._NSFoundationCollection, Map<K,V>
NSDictionary<String, String> env = new NSDictionary<String, String>(System.getenv(), true);
for (String key : env)
logger.debug(env.valueForKey(key));
Modifier and Type | Class and Description |
---|---|
class |
NSDictionary._JavaNSDictionaryMapEntry<P,Q> |
com.webobjects.foundation.NSCoding._BigDecimalSupport, com.webobjects.foundation.NSCoding._BigIntegerSupport, com.webobjects.foundation.NSCoding._BooleanSupport, com.webobjects.foundation.NSCoding._ByteSupport, com.webobjects.foundation.NSCoding._CharacterSupport, com.webobjects.foundation.NSCoding._DateSupport, com.webobjects.foundation.NSCoding._DoubleSupport, com.webobjects.foundation.NSCoding._FloatSupport, com.webobjects.foundation.NSCoding._IntegerSupport, com.webobjects.foundation.NSCoding._LongSupport, com.webobjects.foundation.NSCoding._NumberSupport, com.webobjects.foundation.NSCoding._ShortSupport, com.webobjects.foundation.NSCoding._StringSupport, com.webobjects.foundation.NSCoding.Support
com.webobjects.foundation.NSKeyValueCodingAdditions.DefaultImplementation, com.webobjects.foundation.NSKeyValueCodingAdditions.Utility
com.webobjects.foundation.NSKeyValueCoding._BooleanFieldBinding, com.webobjects.foundation.NSKeyValueCoding._BooleanMethodBinding, com.webobjects.foundation.NSKeyValueCoding._FieldBinding, com.webobjects.foundation.NSKeyValueCoding._ForwardingBinding, com.webobjects.foundation.NSKeyValueCoding._KeyBinding, com.webobjects.foundation.NSKeyValueCoding._KeyBindingCreation, com.webobjects.foundation.NSKeyValueCoding._MethodBinding, com.webobjects.foundation.NSKeyValueCoding._NumberFieldBinding, com.webobjects.foundation.NSKeyValueCoding._NumberMethodBinding, com.webobjects.foundation.NSKeyValueCoding._ReflectionKeyBindingCreation, com.webobjects.foundation.NSKeyValueCoding.ErrorHandling, com.webobjects.foundation.NSKeyValueCoding.MapImplementation, com.webobjects.foundation.NSKeyValueCoding.Null<T>, com.webobjects.foundation.NSKeyValueCoding.UnknownKeyException, com.webobjects.foundation.NSKeyValueCoding.ValueAccessor
Modifier and Type | Field and Description |
---|---|
protected int |
_capacity |
static Class |
_CLASS |
protected int |
_count |
protected int |
_deletionLimit |
protected Set<Map.Entry<K,V>> |
_entrySetCache |
protected byte[] |
_flags |
protected int |
_hashCache |
protected int |
_hashtableBuckets |
protected Object[] |
_keys |
protected Object[] |
_keysCache |
protected Set<K> |
_keySetCache |
static Class |
_MAP_ENTRY_CLASS |
protected static int |
_NSDictionaryClassHashCode |
protected static int |
_NSDictionaryMapEntryHashCode |
protected Object[] |
_objects |
protected Object[] |
_objectsCache |
static boolean |
CheckForNull |
static NSDictionary |
EmptyDictionary |
static boolean |
IgnoreNull |
Constructor and Description |
---|
NSDictionary() |
NSDictionary(Dictionary<? extends K,? extends V> dictionary,
boolean ignoreNull) |
NSDictionary(Map<? extends K,? extends V> map) |
NSDictionary(Map<? extends K,? extends V> map,
boolean ignoreNull) |
NSDictionary(NSArray<? extends V> objects,
NSArray<? extends K> keys) |
NSDictionary(NSDictionary<? extends K,? extends V> otherDictionary) |
NSDictionary(V[] objects,
K[] keys) |
NSDictionary(V object,
K key) |
finalize, getClass, notify, notifyAll, wait, wait, wait
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
public static final Class _CLASS
public static final Class _MAP_ENTRY_CLASS
public static final NSDictionary EmptyDictionary
protected transient int _capacity
protected transient int _hashtableBuckets
protected transient int _count
protected Object[] _objects
protected transient Object[] _objectsCache
protected transient byte[] _flags
protected Object[] _keys
protected transient Object[] _keysCache
protected transient int _hashCache
protected transient int _deletionLimit
protected static int _NSDictionaryClassHashCode
protected static int _NSDictionaryMapEntryHashCode
public static final boolean CheckForNull
public static final boolean IgnoreNull
public NSDictionary()
public NSDictionary(NSDictionary<? extends K,? extends V> otherDictionary)
public NSDictionary(Dictionary<? extends K,? extends V> dictionary, boolean ignoreNull)
protected void _initializeDictionary()
protected void _ensureCapacity(int capacity)
protected void _clearDeletionsAndCollisions()
protected Object[] keysNoCopy()
protected Object[] objectsNoCopy()
public int count()
public boolean isEqualToDictionary(NSDictionary<?,?> otherDictionary)
public boolean equals(Object object)
public Enumeration<K> keyEnumerator()
public Enumeration<V> objectEnumerator()
public Object valueForKey(String key)
valueForKey
in interface com.webobjects.foundation.NSKeyValueCoding
public void takeValueForKey(Object value, String key)
takeValueForKey
in interface com.webobjects.foundation.NSKeyValueCoding
public Object valueForKeyPath(String keyPath)
valueForKeyPath
in interface com.webobjects.foundation.NSKeyValueCodingAdditions
public void takeValueForKeyPath(Object value, String keyPath)
takeValueForKeyPath
in interface com.webobjects.foundation.NSKeyValueCodingAdditions
public Class classForCoder()
classForCoder
in interface com.webobjects.foundation.NSCoding
public static final <K,V> NSDictionary<K,V> emptyDictionary()
public static Object decodeObject(com.webobjects.foundation.NSCoder coder)
public void encodeWithCoder(com.webobjects.foundation.NSCoder coder)
encodeWithCoder
in interface com.webobjects.foundation.NSCoding
public int _shallowHashCode()
_shallowHashCode
in interface com.webobjects.foundation._NSFoundationCollection
public int hashCode()
public NSDictionary<K,V> immutableClone()
public NSMutableDictionary<K,V> mutableClone()
public boolean containsKey(Object key)
containsKey
in interface Map<K,V>
public boolean containsValue(Object value)
containsValue
in interface Map<K,V>
Copyright © 2002 – 2020 Project Wonder.