Back to Acra

ImmutableMap

web/static/javadoc/5.1.3/org/acra/collections/ImmutableMap.html

latest8.4 KB
Original Source

Skip navigation links

org.acra.collections

Class ImmutableMap<K,V>


public final classImmutableMap\<K,V\>extends[Object](http://d.android.com/reference/java/lang/Object.html?is-external=true "class or interface in java.lang")implements[Map](http://d.android.com/reference/java/util/Map.html?is-external=true "class or interface in java.util")<K,V>,[Serializable](http://d.android.com/reference/java/io/Serializable.html?is-external=true "class or interface in java.io")

Naive (not optimized) implementation of an Immutable Map Since:4.9.0See Also:Serialized Form

Nested Class Summary

- 

Nested classes/interfaces inherited from interface java.util.Map

Map.Entry<K,V>

Constructor Summary

Constructors | Constructor and Description | | --- | | ImmutableMap(Map<K,V> map) |

Method Summary

All Methods Instance Methods Concrete Methods | Modifier and Type | Method and Description | | --- | --- | | void | clear() | | boolean | containsKey(Object key) | | boolean | containsValue(Object value) | | Set<Map.Entry<K,V>> | entrySet() | | V | get(Object key) | | boolean | isEmpty() | | Set<K> | keySet() | | V | put(K key, V value) | | void | putAll(Map<? extends K,? extends V> map) | | V | remove(Object object) | | int | size() | | Collection<V> | values() |

- 

Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

- 

Methods inherited from interface java.util.Map

compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll

Constructor Detail

- 

ImmutableMap

public ImmutableMap([@NonNull](http://d.android.com/reference/android/support/annotation/NonNull.html?is-external=true "class or interface in android.support.annotation")[Map](http://d.android.com/reference/java/util/Map.html?is-external=true "class or interface in java.util")<[K](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap"),[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")> map)

Method Detail

- 

clear

public void clear()

Specified by:clear in interface Map<K,V>

- 

containsKey

public boolean containsKey([Object](http://d.android.com/reference/java/lang/Object.html?is-external=true "class or interface in java.lang")key)

Specified by:containsKey in interface Map<K,V>

- 

containsValue

public boolean containsValue([Object](http://d.android.com/reference/java/lang/Object.html?is-external=true "class or interface in java.lang")value)

Specified by:containsValue in interface Map<K,V>

- 

entrySet

[@NonNull](http://d.android.com/reference/android/support/annotation/NonNull.html?is-external=true "class or interface in android.support.annotation")public[Set](http://d.android.com/reference/java/util/Set.html?is-external=true "class or interface in java.util")<[Map.Entry](http://d.android.com/reference/java/util/Map.Entry.html?is-external=true "class or interface in java.util")<[K](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap"),[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")>> entrySet()

Specified by:entrySet in interface Map<K,V>

- 

get

public[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")get([Object](http://d.android.com/reference/java/lang/Object.html?is-external=true "class or interface in java.lang")key)

Specified by:get in interface Map<K,V>

- 

isEmpty

public boolean isEmpty()

Specified by:isEmpty in interface Map<K,V>

- 

keySet

[@NonNull](http://d.android.com/reference/android/support/annotation/NonNull.html?is-external=true "class or interface in android.support.annotation")public[Set](http://d.android.com/reference/java/util/Set.html?is-external=true "class or interface in java.util")<[K](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")> keySet()

Specified by:keySet in interface Map<K,V>

- 

put

public[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")put([K](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")key,[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")value)

Specified by:put in interface Map<K,V>

- 

putAll

public void putAll([@NonNull](http://d.android.com/reference/android/support/annotation/NonNull.html?is-external=true "class or interface in android.support.annotation")[Map](http://d.android.com/reference/java/util/Map.html?is-external=true "class or interface in java.util")<? extends[K](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap"),? extends[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")> map)

Specified by:putAll in interface Map<K,V>

- 

remove

public[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")remove([Object](http://d.android.com/reference/java/lang/Object.html?is-external=true "class or interface in java.lang")object)

Specified by:remove in interface Map<K,V>

- 

size

public int size()

Specified by:size in interface Map<K,V>

- 

values

[@NonNull](http://d.android.com/reference/android/support/annotation/NonNull.html?is-external=true "class or interface in android.support.annotation")public[Collection](http://d.android.com/reference/java/util/Collection.html?is-external=true "class or interface in java.util")<[V](../../../org/acra/collections/ImmutableMap.html "type parameter in ImmutableMap")> values()

Specified by:values in interface Map<K,V>

Skip navigation links